iceland2k14/secp256k1

please check how privatekey_to_h160 works

Closed this issue · 5 comments

Hello
please check how privatekey_to_h160 works

m/0'/1'/9
world evolve cry outer garden common differ jump few diet cliff lumber bd85556143de177ed9781ac3b24ba33d0bc4f8d6f34d9eaa1d9b8ab0ee3a7e84d42638b520043234bcedb4e869464b9f964e7e8dbf1588395f7a7782588ae664
dbb4ccf92b0a0742016c915585864a8261994ec2 | 1DMtkFF6J1abNqgVmpL5WtZZkcJtaCeW7d |
42a38914e258e63e4baaff51a62d61df0236f6d1 | 1DFWG8gL7jqRdwCogdKhXC9FRXuRb5Ed7X |

Example.......
ice.privatekey_to_address(0, False, 0x5562f) : '1HKN3PCv1QM5jAewhSoRDu3ecwA8KYeSpH'
ice.privatekey_to_address(0, True, 0x5562f) : '15tNpJpcZ5hbMNkQQfEpyNqKCe9uvGZY1Y'
ice.privatekey_to_h160(0, False, 0x5562f).hex() : 'b2fb10668c3e58c49c8292436503819abf35ee69'
ice.privatekey_to_h160(0, True, 0x5562f).hex() : '3597ed8f4787fdab2750324dc3e10d5bab0c37f3'

Thanks for the great library. she is excellent.
0x5562f - what is it?

0x5562f is Just a example Privatekey Key

bb = 29020650575839879017850673027181372401996640854786846585452941887353628706644
bip44_h160_c = privatekey_to_h160(0, True, bb)
print(bip44_h160_c)
addr = privatekey_to_address(0, True, bb) #1159hoiH2iUyQQy4tSbyFNWkUZ4YVeE1dS / True
print(addr)
addr2 = hash_to_address(0, True, bip44_h160_c)
print(addr2)

ADDR2 - displays different addresses. and they do not match the normal
ADDR - work OK!

Thanks for the feedback.