rust-bitcoin / rust-miniscript

Support for Miniscript and Output Descriptors for rust-bitcoin
Creative Commons Zero v1.0 Universal
343 stars 135 forks source link

Implement GetKey for KeyMap #709

Open LLFourn opened 1 month ago

LLFourn commented 1 month ago

See the trait here:

https://docs.rs/bitcoin/latest/bitcoin/psbt/trait.GetKey.html

I think it'd make sense if KeyMap (or something like it) implemented this trait so you could sign PSBTs with the secret keys extracted from a private descriptor.

apoelstra commented 1 month ago

Oo, neat. Concept ACK. May be a little bit because we are rejigging the relationship between rust-bitcoin and rust-miniscript and I'm unsure what happens to PSBT during that transition.

tcharding commented 1 month ago

Once bitcoin depends on miniscript hopefully we move psbt_v2 into bitcoin but that shouldn't effect this issue, we can solve this in either miniscript::psbt and port it or in psbt_v2 if we have done the move already. (psbt_v2 contains all the code from psbt::miniscript anyways.)