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

Initial BIP-47 support #32

Open
wants to merge 11 commits into
base: master
Choose a base branch
from
Open

Conversation

kdmukai
Copy link
Contributor

@kdmukai kdmukai commented Aug 5, 2022

Implements:

  • generating the recipient's BIP-47 shareable payment code (version 1).
  • recipient's notification address.
  • generate the nth payment address for the payer.
  • generate the nth receive address for the recipient.
  • extract the payer's payment code from a notification tx.

Implementation matches Samourai (still to be confirmed) and Sparrow (tested).

src/embit/bip47.py Outdated Show resolved Hide resolved
src/embit/bip47.py Outdated Show resolved Hide resolved
Copy link
Contributor

@stepansnigirev stepansnigirev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall, looks good. A few small changes required (i.e. your test doesn't pass). Also not clear if TODO will be addressed in this PR or in a separate one.

src/embit/bip47.py Outdated Show resolved Hide resolved
src/embit/bip47.py Outdated Show resolved Hide resolved
src/embit/bip47.py Outdated Show resolved Hide resolved
src/embit/bip47.py Outdated Show resolved Hide resolved
src/embit/bip47.py Outdated Show resolved Hide resolved
tests/tests/test_bip47.py Outdated Show resolved Hide resolved
Note: regtest blind/unblind still has a bug I'm trying to work through. But as far as I can tell, mainnet works as expected, as confirmed via the test cases.
@kdmukai
Copy link
Contributor Author

kdmukai commented Sep 5, 2022

After my most recent commit, I am now satisfied with where this PR is at. Awaiting further review/feedback, but otherwise I consider this PR complete.

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

Successfully merging this pull request may close these issues.

2 participants