Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BIP141 Address Generation #33

Open
Abvit-eve opened this issue Feb 14, 2022 · 1 comment
Open

BIP141 Address Generation #33

Abvit-eve opened this issue Feb 14, 2022 · 1 comment

Comments

@Abvit-eve
Copy link

Describe the bug
BIP141 address generation does not match Ian Coleman tool and several others. https://iancoleman.io/bip39/

To Reproduce
zpub = generated zpub
pybtc.Address(key=zpub, testnet=False) ##Note P2WPKH can be set and outcome will be the same

Additional context
Example zpub = zpub6rn6SvAbbf9cGaiQv6SXnoFKa2BiKQSYx6YPtR2hi21RCQbziM3c5NVdYTvmpoZaYQrbrFviLvxcK83uQetbNgs1mRKj65bawemAWKid1ii

bc1qfs2a070gs9fp78pdg2zuv4da0gxx5wcymdac5y it output, which is noted at P2WPKH but is not listed on Ian Coleman tool nor other tools.

@4tochka
Copy link
Contributor

4tochka commented Feb 15, 2022

You try to use Address class incorrect

Try create HD wallet class

w = pybtc.Wallet(zpub, testnet=False)
w.get_address(0)
{'address': 'bc1qf4m44fznz6kfu3p2mpf46jxhu6srxnkls7pnw5', 'public_key': '02467dc825c7421999d8a981f95737ac33e3e7cec304c4662a8883b430c7d072af', 'path': "0'/0/0"}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants