Author

Topic: convert 256 bit to WIF - compress (Read 129 times)

newbie
Activity: 54
Merit: 0
May 10, 2022, 03:39:51 AM
#3
@stalker00075
For compressed just add 01 at end.
fullkey = "80"+"7542FB6685F9FD8F37D56FAF62F0BB4563684A51539E4B26F0840DB361E0027C" + "01"
Also i recommend use good python lib to do this not manually.
For example this one
https://ofek.dev/bit/


thank you very much!
member
Activity: 69
Merit: 53
May 10, 2022, 03:36:24 AM
#2
@stalker00075
For compressed just add 01 at end.
fullkey = "80"+"7542FB6685F9FD8F37D56FAF62F0BB4563684A51539E4B26F0840DB361E0027C" + "01"
Also i recommend use good python lib to do this not manually.
For example this one
https://ofek.dev/bit/
newbie
Activity: 54
Merit: 0
May 10, 2022, 03:33:33 AM
#1
this code

Code:
import os, binascii, hashlib, base58
fullkey = "80"+"7542FB6685F9FD8F37D56FAF62F0BB4563684A51539E4B26F0840DB361E0027C"
sha256a = hashlib.sha256(binascii.unhexlify(fullkey)).hexdigest()
sha256b = hashlib.sha256(binascii.unhexlify(sha256a)).hexdigest()
WIF = base58.b58encode(binascii.unhexlify(fullkey+sha256b[:8]))
print(WIF)


need "print " compress address pls help....
Jump to: