Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from web3 import *
- web3 = Web3(IPCProvider(ipc_path='/path/to/geth.ipc'))
- random_private_key = '0x71a7f0e2ef1b7ff501b65a1650d48b8d5521fadc9539eec146d4faa6f5ca9ccc'
- random_password = 'qwertyuiop'
- address = web3.personal.importRawKey(random_private_key, random_password)
- # address -> '0x930198a4bdd322ee3305fcf0bcb106064b38754b'
- # web3.eth.accounts -> [..., '0x930198a4bdd322ee3305fcf0bcb106064b38754b']
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement