[bitcoin/bitcoin] PSBT key path cleanups (#13723)

This PR adds «key origin» (master fingeprint + key path) information to what is exposed from `SigningProvider`s, allowing this information to be used by the generic PSBT code instead of having the RPC pull it directly from the wallet.

This is also a preparation to having PSBT interact with output descriptors, which can then directly expose key origin information for the scripts they generate.
You can view, comment on, or merge this pull request online at:

https://github.com/bitcoin/bitcoin/pull/13723

— Commit Summary —

* Introduce KeyOriginInfo for fingerprint + path
* Make SigningProvider expose key origin information
* Generalize PublicOnlySigningProvider into HidingSigningProvider
* [MOVEONLY] Move ParseHDKeypath to utilstrencodings
* Implement key origin lookup in CWallet
* Pass HD path data through SignatureData

— File Changes —

M src/rpc/rawtransaction.cpp (15)
M src/script/sign.cpp (40)
M src/script/sign.h (47)
M src/utilstrencodings.cpp (40)
M src/utilstrencodings.h (3)
M src/wallet/rpcwallet.cpp (89)
M src/wallet/test/psbt_wallet_tests.cpp (2)
M src/wallet/wallet.cpp (25)
M src/wallet/wallet.h (3)

— Patch Links —

https://github.com/bitcoin/bitcoin/pull/13723.patch
https://github.com/bitcoin/bitcoin/pull/13723.diff

Добавить комментарий