SHARE
TWEET

Untitled

a guest Aug 20th, 2019 79 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. def bytes_to_wif(x):
  2.     b = x
  3.     padded_private_key = b'\x80' + b
  4.     m = hashlib.sha256()
  5.     m.update(b)
  6.     print(b.hex())
  7.     b = m.digest()
  8.     m = hashlib.sha256()
  9.     m.update(b)
  10.     b = m.digest()
  11.     checksum = b[:4]
  12.     wallet_raw = padded_private_key + checksum
  13.     wallet = base58.b58encode(wallet_raw)
  14.     return wallet
  15. bytes_to_wif(bytearray.fromhex('5D37B37463C450C143A481CD9BB254DC887394B8D7A0E73A7CEFFFAFBB0ACC13'))
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top