Skip to content

multisig support #4

@markblundeberg

Description

@markblundeberg

It should definitely be possible to support multisig. But, there are some weird snags with this which one should watch out for. If someone wants to pull their hair out in confusion, take a gander at how it really works in interpreter.cpp.

  • A multisig can include the same pubkey multiple times, in which signatures can be replayed. (e.g., a single unique signature could satisfy a 2-of-3; two unique signatures would then be enough to malleate)
  • The same pubkey can even appear in different guises (compressed / uncompressed).
  • It's not obvious which signature goes with which pubkey until you just try them out.
  • A multisig can include invalid pubkeys at the end! (e.g., totally fine if third pubkey in a 2-of-3 is "RALF" as long as the first two signatures work with first two pubkeys).
  • We need NULLDUMMY for these to be unmalleable, but that's likely going to happen in November along with SCRIPTSIGMINIMALPUSH rule.
  • added -- see below for more info: Each signature can choose its own sighash flag; each of the six possible sighash flags has a different preimage which must be included in the DS proof packet, if that signature is to be validated.

So, it's going to take some delicate thinking...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions