first commit

This commit is contained in:
jack
2025-11-12 16:47:21 +08:00
commit 266ba871a4
43 changed files with 3747 additions and 0 deletions
+25
View File
@@ -0,0 +1,25 @@
from web3 import Web3
from eth_account import Account
from bip44 import Wallet
mnemonic = "morning cool cake surface state crucial stool rocket lobster medal fossil talent"
w = Wallet(mnemonic)
private_keys = []
addresses = []
for i in range(20):
private_key, address = w.derive_account("eth", i)
account = Account.from_key(private_key)
# print(f"Private Key {i+1}: {private_key.hex()}")
# print(f"Address {i+1}: {account.address}")
private_keys.append(private_key.hex())
addresses.append(account.address)
print('private_keys:\n--------------------------\n')
for pk in private_keys:
print(pk)
print()
print('addresses:\n--------------------------\n')
for addr in addresses:
print(addr)