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

Prepare Payjoin PSBT with no output keypaths #270

Merged
merged 3 commits into from
Jun 4, 2024

Conversation

DanGould
Copy link
Contributor

The BIP78 sender checklist "Verif[ies] that no keypaths is in the PSBT output," and this check was failing with our receiver.

This change ensures that check is satisfied.


https://github.com/bitcoin/bips/blob/master/bip-0078.mediawiki#user-content-Senders_payjoin_proposal_checklist

@spacebear21
Copy link
Collaborator

This seems like something that should be checked in the integration tests.

DanGould added 3 commits June 2, 2024 23:07
This is a verbatim check the sender does. This change prepares the Payjoin PSBT
from the receiver to satisfy that check.
Don't construct BTreeMap::new(), just use .clear() to same effect
Both input and output keypath information is supposed to be removed
according to bip78. Include them during construction so that our library
removes them and thaht removal does not regress.

See: https://github.com/bitcoin/bips/blob/master/bip-0078.mediawiki#senders-payjoin-proposal-checklist
@DanGould
Copy link
Contributor Author

DanGould commented Jun 3, 2024

Good point. I made bitcoind add bip32derivs (keypaths) in integration tests to check that they're properly cleared. If you cherry-pick 69e2fa1 onto master you can see that it fails without the change.

@DanGould DanGould added bug Something isn't working receive receiving payjoin labels Jun 3, 2024
Copy link
Collaborator

@spacebear21 spacebear21 left a comment

Choose a reason for hiding this comment

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

tACK

@DanGould DanGould merged commit 2f75497 into payjoin:master Jun 4, 2024
5 checks passed
@DanGould DanGould deleted the no-output-keys branch June 4, 2024 04:11
@DanGould DanGould mentioned this pull request Jun 17, 2024
17 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working receive receiving payjoin
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants