This PR extends the existing bip32derivs argument of the
walletprocesspsbt and descriptorprocesspsbt RPCs with explicit key-origin
modes.
Motivation
Setting bip32derivs=false prevents new key-origin fields from being added, but
does not explicitly remove fields already present in an input PSBT. Some
collaborative PSBT workflows need to remove that metadata before sharing the
PSBT.
Behavior
trueor"add"allows known key-origin fields to be added.falseor"preserve"does not add or explicitly remove key-origin fields."strip"does not add key-origin fields and removes surviving standard key-origin fields after normal processing.
The default remains true. The existing boolean values remain accepted for
compatibility.
Stripping removes global xpubs and legacy and Taproot BIP32 derivation fields from inputs and outputs. Unknown and proprietary PSBT fields are left unchanged. Finalization may independently remove input key-origin fields.
Closes #30294.