As discussed on the mailing list:
https://lists.linuxfoundation.org/pipermail/bitcoin-dev/2019-June/thread.html#start
Search the page for the following subject:
BIP174 extension proposal (Global Type: PSBT_GLOBAL_XPUB_SIGNATURE)
- POR_COMMITMENT is also a separate BIP, but the encoding spec is listed here, so I am following suit.
- Maybe there could be a way to offload the encoding descriptions into a "this key will represent the BIP number" etc. but for now no such spec exists. I may create a new BIP to cover the usage of this data for wallets to implement a whitelist for output verification.
Here is the description of the imagined use case:
- Securely verify the xpub of the warm / hot wallet.
- Using the airgap signing tool, sign the xpub with all cold keys.
- Upload the signature/xpub pairs to the online unsigned transaction generator.
- Include one keyval pair per coldkey/xpub pairing.
- When offline signing, if the wallet detects there is a global keyval XPUB_SIGNATURE with its pubkey in the key, it must verify that all outputs have BIP32_DERIVATION and that it can verify the outputs through the derivation, to the xpub, and to the signature.
The 0x01 global xpub entry allows HW wallet to verify change outputs.
This 0x02 global xpub signature will allow HW wallet to "verify" a whitelisted xpub that it has previously signed. Which is useful if HW wallets create some way for users to exchange xpubs securely. Instead of having to do the secure exchange every time, they would only need to do it once, then refer to the whitelist signature.
I was thinking of adding some extra data for a label which would also be signed, that way Trezor could say "Are you sure you want to pay Cindy?" instead of address verification.
Reducing address reuse is a two pronged motion of encouraging change address rotation (0x01) and encouraging people use new addresses every time (0x02 facilitates features that remove some friction)
Any comments are welcome.
Thanks.