arbsep; conf/

This commit is contained in:
Tim
2024-06-30 19:29:47 -04:00
parent bb2d84a1e7
commit dbf1929175
19 changed files with 103 additions and 68 deletions

View File

@@ -0,0 +1,17 @@
import os
from eth_keys import keys
# Generating a private key
private_key_hex = os.urandom(32)
private_key = keys.PrivateKey(private_key_hex)
# Getting the public key
public_key = private_key.public_key
# compute the Ethereum address from the public key
address = public_key.to_checksum_address()
print(f"key='{hex(private_key)[2:]}' # {address}")
# print("Private key:", private_key)
# print("Public key:", public_key)
# print("Address:", address)