-
Notifications
You must be signed in to change notification settings - Fork 116
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
[tap channels preparation 1/?]: Add QueryInternalKey and QueryScriptKey RPCs, pre-fill script key info in vPSBT #765
Conversation
9e39e8e
to
3f4f12e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That was easy to review, thanks!
I think I'll be able to approve quickly on Monday.
3f4f12e
to
80c62f9
Compare
Thank you for the thorough review, @ffranr. I addressed all your comments. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
Added a comment on generalisation, otherwise I think this looks good.
80c62f9
to
f9a7286
Compare
Doesn't need a re-review, nothing major changed other than addressing @ffranr's comments. |
We'll need to be able to fetch the key family and index for an internal key of an address or asset by just specifying the internal public key. We add this method to the TapAddressBook as that already has a similar method for the script key.
When signing a virtual PSBT, we don't want to use the key descriptor info of the input asset's script key, as that information is not available when the input asset is created from a de-serialized asset. So previous to the change in this commit the SignVirtualPsbt RPC method could only be called on vPSBTs that were funded through FundVirtualPsbt that populated the key information. After this commit it is possible to sign a vPSBT that was created from an input proof only since the required key information is loaded from the database before signing.
The asset version v1 (segwit) allows an asset to be committed without the TxWitness field. Therefore, when comparing two such assets, we must also ignore the TxWitness field. If we don't do this, then the deep equal check when creating a proof for a split asset fails when checking if the split root asset was committed to the root tree.
f9a7286
to
3e7d61d
Compare
Comments addressed, should be good for final round of review. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 🐍
A couple of preparatory commits extracted from the TAP channel simulation branch.