Add bip-psbt-descriptors #1548

pull seedhammer wants to merge 7 commits into bitcoin:master from seedhammer:master changing 1 files +190 āˆ’0
  1. seedhammer commented at 2:30 pm on January 31, 2024: none

    A BIP 174 PSBT may contain an extended key for deriving input and output addresses. This document proposes an additional field for PSBTs to represent arbitrary BIP 380 output script descriptors.

    To support transfer of output descriptors outside signing flows, the proposal makes the unsigned transaction optional.

  2. add bip-psbt-descriptors c6521e4105
  3. achow101 commented at 6:45 pm on January 31, 2024: member

    I don’t think PSBT is the right way to be doing this. Descriptors are not necessary in PSBT, and relaxing the invariant that a PSBT represents a transaction (by allowing a PSBT to include no transaction data) would break many parsers and also just is antithetical to PSBT. It’s not a general purpose format for sending data around - you could use protobuf if you wanted that.

    If the goal is to have a machine parsable representation of descriptors, then by all means, do that. But it doesn’t need to (nor do I think it should) interact with PSBT, other than having a different header that identifies it.

    It’s also unnecessary to have a descriptor in a PSBT. A PSBT can contain all of the data to derive it from the scriptPubKey at a later time. If an updater has the descriptor in order to put it in the PSBT, then it can also put the rest of the data in the PSBT so that the descriptor can be inferred. I just don’t see how this proposal is at all useful.

    Also, descriptors are a textual format, and encoding text in binary is just not very efficient. There are better ways to do that if you really wanted to.

  4. seedhammer commented at 10:13 am on February 9, 2024: none

    I don’t think PSBT is the right way to be doing this. Descriptors are not necessary in PSBT, and relaxing the invariant that a PSBT represents a transaction (by allowing a PSBT to include no transaction data) would break many parsers and also just is antithetical to PSBT. It’s not a general purpose format for sending data around - you could use protobuf if you wanted that.

    If the goal is to have a machine parsable representation of descriptors, then by all means, do that. But it doesn’t need to (nor do I think it should) interact with PSBT, other than having a different header that identifies it.

    FWIW, the first draft was indeed PSBT with a different header: https://lists.linuxfoundation.org/pipermail/bitcoin-dev/2023-November/022184.html. https://lists.linuxfoundation.org/pipermail/bitcoin-dev/2023-November/022186.html suggested we add descriptors to PSBT proper, which seemed like a good idea.

    Would you support an alternative BIP that changed the header to make it intentionally different from PSBT files?

    It’s also unnecessary to have a descriptor in a PSBT. A PSBT can contain all of the data to derive it from the scriptPubKey at a later time. If an updater has the descriptor in order to put it in the PSBT, then it can also put the rest of the data in the PSBT so that the descriptor can be inferred.

    How can the scriptPubKey infer a descriptor that contains, say, a key expression that ends in ‘/*’?

    I just don’t see how this proposal is at all useful.

    The point of the BIP is to transfer descriptors between devices, in particular between a coordinator and (resource constrained) signing devices. It can be viewed as a codec for wallet policies.

    Today, there exists a plethora of formats for exchanging descriptors, all with downsides:

    • Raw xpubs are underspecified (missing script type)
    • The BlueWallet textual format is inefficient (base58 xpubs) and doesn’t support arbitrary descriptors.
    • Raw BIP-380 descriptors are also inefficient and lack metadata.
    • BCR-2023-010 are efficient but rely on the more complex (d)CBOR encoding.
    • JSON encoded textual descriptors are also inefficient and require a JSON implementation.

    This proposal addresses them all:

    • Based on PSBT, signing devices need not spend additional code space on a separate codec.
    • Efficient encoding of extended keys.
    • Metadata (title, birth block) supported.
    • Every current or future bip-380 descriptor can be represented.

    Also, descriptors are a textual format, and encoding text in binary is just not very efficient. There are better ways to do that if you really wanted to.

    We believe it’s hopeless to keep a binary representation of output descriptors up to date with the moving target that is textual bip-380 descriptors (BCR-2020-010 attempted but failed). This BIP (along with wallet policies) address the worst offender by encoding extended keys efficiently.

  5. achow101 commented at 6:11 pm on February 9, 2024: member

    Would you support an alternative BIP that changed the header to make it intentionally different from PSBT files?

    That would be fine with me.

    How can the scriptPubKey infer a descriptor that contains, say, a key expression that ends in ‘/*’?

    Although /* cannot be directly inferred, you can still make an educated guess. It only affects the ends of derivation paths from xpubs, so the last derivation index of a key expression with an xpub could just be replaced with /*. Although descriptors allow for xpubs without a /*, it seems unlikely to me that that would actually be used in practice.

    But I don’t understand why you’d need to have the parent descriptor at all. You’ll have enough key origin information to derive any private keys and be able to sign.

  6. 0xGRAV3R commented at 1:33 am on February 24, 2024: none
    This proposal aims to extend the capabilities of PSBTs by incorporating support for output script descriptors while also offering flexibility regarding the inclusion of the unsigned transaction within the PSBT structure. These enhancements could streamline certain Bitcoin transaction workflows and facilitate interoperability among different wallet implementations.
  7. 0xGRAV3R commented at 1:34 am on February 24, 2024: none

    BIP 174 PSBTs and Extended Keys: PSBTs, specified in BIP 174, are a format for partially signed Bitcoin transactions, enabling offline signing and multi-party approval workflows. These transactions may contain extended keys for deriving input and output addresses. Extended keys allow for hierarchical deterministic (HD) wallets, where multiple addresses can be derived from a single master key.

    Introduction of Output Script Descriptors: The proposal suggests introducing an additional field in PSBTs to represent arbitrary BIP 380 output script descriptors. Output script descriptors, specified in BIP 380, provide a concise way to describe various types of output scripts. This addition would enhance the flexibility and interoperability of PSBTs, allowing for more complex transaction scripts.

    Optional Unsigned Transaction: Traditionally, PSBTs include the unsigned transaction itself. However, this proposal suggests making the unsigned transaction optional. This change would allow for the transfer of output descriptors outside of the signing process, potentially simplifying certain workflows or reducing data redundancy.

  8. bitcoin deleted a comment on Mar 2, 2024
  9. bitcoin deleted a comment on Mar 2, 2024
  10. pythcoiner commented at 6:33 pm on March 16, 2024: none

    But I don’t understand why you’d need to have the parent descriptor at all. You’ll have enough key origin information to derive any private keys and be able to sign.

    By example in the current ledger miniscript signing flow, the hardware device produce a Proof of Registration (PoR) against the parent descriptor that is stored by the softwarewallet (in order to keep stateless) the first time the descriptor is checked by user on signer side, then every time the software wallet send a psbt to sign to ledger device, it should also supply also the parent descriptor and PoR.

    we previously discuss about this here

  11. pythcoiner commented at 6:34 pm on March 16, 2024: none
  12. bigspider commented at 10:45 am on March 18, 2024: contributor

    Hardware signing devices need knowledge of the full descriptor/wallet policy in order to:

    • recognize change addresses
    • recognize from which of your different accounts (sometimes called wallets) the inputs are spending from.

    (The second could perhaps be considered a strengthening of the traditional guarantees of hardware signers, not sure if it was ever formalized before wallet policies; I think it’s essential in practice for anything that is not single-user)

    While it’s true that PSBTs today have enough info to sign, they do not have enough info to do it securely - the descriptor is also needed. Therefore, I agree that it would be a great improvement to be able to pass this info via PSBTs; currently, the Ledger app’s signing flow is sign(PSBT, wallet_policy), and quite some work in the app goes into figuring out change/address_index for each input and change output based on the derivations in the PSBT.

    However, I think that’s a separate discussion, and it’s unclear that recycling PSBTs for a purpose other than representing transactions brings any benefit over than directly designing a space-efficient encoding specifically for descriptors or wallet policies ā€“ if the <30% space saving that can be obtained with a re-encoding is deemed important in practice.

  13. jonatack commented at 6:39 pm on April 24, 2024: contributor
    @seedhammer, do you plan to update here based on the review feedback?
  14. rename bip-psbt-descriptors and separate format from BIP 174 (PSBT) f9eff32736
  15. seedhammer commented at 2:02 pm on April 27, 2024: none

    Thanks for the prod, @jonatack . I’ve updated the proposal so it’s no longer a PSBT extension but a separate format merely based on PSBT key-value maps.

    I’d like to add proof-of-registration (PoR), but I’m not sure how it’s best done. There’s some discussion at https://github.com/wizardsardine/liana/issues/539#issuecomment-1877372827, where @bigspider suggests a HMAC scheme and in a later post @pythcoiner suggest that the format of PoR field should be vendor defined. I’m still of the position that to be maximally useful and interoperable, the PoR field should have a defined format and be a signature, not a HMAC.

  16. pythcoiner commented at 2:17 am on April 28, 2024: none

    I’d like to add proof-of-registration (PoR), but I’m not sure how it’s best done. There’s some discussion at wizardsardine/liana#539 (comment), where @bigspider suggests a HMAC scheme and in a later post @pythcoiner suggest that the format of PoR field should be vendor defined. I’m still of the position that to be maximally useful and interoperable, the PoR field should have a defined format and be a signature, not a HMAC.

    As i already said in previous discussion, i do not have strong opinion about wether the PoR should be standardized or not, but i do not think it should be standardized in this BIP.

    And anyway if i get it well both sheme (HMAC vs Signature) will be 32 bytes of data?

  17. pythcoiner commented at 2:23 am on April 28, 2024: none

    it should be interesting to have insight from other signing devices teams.

    cc @benma @scgbckbone @stepansnigirev @stepansnigirev @JamieDriver

  18. seedhammer commented at 6:48 am on April 28, 2024: none

    Also @kdmukai. Maybe others?

    However, I think that’s a separate discussion, and it’s unclear that recycling PSBTs for a purpose other than representing transactions brings any benefit over than directly designing a space-efficient encoding specifically for descriptors or wallet policies ā€“ if the <30% space saving that can be obtained with a re-encoding is deemed important in practice.

    I want to point out that while saving space is important to us, the ability to add metadata and eventually proof-of-registration is the more interesting feature in general.

  19. benma commented at 7:29 am on April 28, 2024: none

    I am in agreement with @bigspider’s comment above.

    BitBox02 libraries have functions like sign_psbt(psbt, wallet_policy) (example), and the policy/descriptor is required for anything but simple single-sigs.

    It would be helpful if the way the policy is described and transferred to signers was standardized so apps don’t have to implement different ways to interface with different signers.

    PSBT seems like the obvious location to put this information. Another format that contains both the PSBT and the policy, which is interoperable with all software, seems difficult to achieve and impractical.

  20. seedhammer commented at 12:23 pm on April 28, 2024: none

    Given

    • PSBTs are useful without descriptors, and
    • descriptors are useful without PSBTs (backups, registration), and
    • the combination of a PSBT and descriptor is useful for more secure signing flows,

    Perhaps it’s feasible to keep the formats separate, but concatenate them at the transport layer (QR code, files), in a backwards compatible way? Say, append the decriptor at the end of the PSBT, where devices without knowledge of descriptors may parse the PSBT and ignore the rest?

  21. in bip-bod-descriptors.mediawiki:6 in f9eff32736 outdated
    0@@ -0,0 +1,139 @@
    1+<pre>
    2+  BIP: ?
    3+  Layer: Applications
    4+  Title: Binary Output Descriptors
    5+  Author: SeedHammer <team@seedhammer.com>
    6+  License: BSD-2-Clause
    


    murchandamus commented at 1:47 pm on April 29, 2024:

    The preamble is missing a few mandatory headers:

    0  BIP: ?
    1  Layer: Applications
    2  Title: Binary Output Descriptors
    3  Author: SeedHammer <team@seedhammer.com>
    4  Comments-URI: https://github.com/bitcoin/bips/wiki/Comments:BIP-seedhammer-binary-output-descriptors
    5  Status: Draft
    6  Type: Standards Track
    7  Created: YYYY-MM-DD
    8  License: BSD-2-Clause
    
  22. murchandamus commented at 1:51 pm on April 29, 2024: contributor

    I have only lightly reviewed this document.

    It sounds to me that there is still some discussion what solution is exactly to be pursued for this document. Iā€™m going to change this to a draft PR for the moment, please set it ready to merge when the proposal is a bit more mature.

    Please note that you will need a Backwards Compatibility section, and without going into the content in detail, it seems to me that the Rationale section could be a bit more extensive.

  23. murchandamus marked this as a draft on Apr 29, 2024
  24. Vahid12015595 approved
  25. bip-bod-descriptors: add mandatory headers and compatibility section 5151e3f8e9
  26. bip-bod-descriptors: expanded rationale section e483f82999
  27. seedhammer commented at 4:57 pm on April 29, 2024: none

    Thanks, Murch. I’ve added the mandatory headers, added a compatibility section, and expanded the rationale section.

    It seems to me that the main source of contention is whether the format should be separate or part of PSBT. While convenient to extend PSBT, it’s probably best to separate the format if for nothing else than descriptors are useful outside signing flows.

    Proof of registration can wait for a future extension BIP, as suggested by @pythcoiner.

  28. pythcoiner commented at 10:45 pm on April 29, 2024: none

    Thanks, Murch. I’ve added the mandatory headers, added a compatibility section, and expanded the rationale section.

    It seems to me that the main source of contention is whether the format should be separate or part of PSBT. While convenient to extend PSBT, it’s probably best to separate the format if for nothing else than descriptors are useful outside signing flows.

    Proof of registration can wait for a future extension BIP, as suggested by @pythcoiner.

    To be more accurate, i think how is processed the PoR should de defined in a separate BIP, but having an optional key-value pair defined in this BIP should be useful imho.

  29. bip-bod-descriptors: add proprietary fields 710fe837a6
  30. seedhammer commented at 12:49 pm on April 30, 2024: none

    Thanks, Murch. I’ve added the mandatory headers, added a compatibility section, and expanded the rationale section. It seems to me that the main source of contention is whether the format should be separate or part of PSBT. While convenient to extend PSBT, it’s probably best to separate the format if for nothing else than descriptors are useful outside signing flows. Proof of registration can wait for a future extension BIP, as suggested by @pythcoiner.

    To be more accurate, i think how is processed the PoR should de defined in a separate BIP, but having an optional key-value pair defined in this BIP should be useful imho.

    Good point. Done.

  31. scgbckbone commented at 1:13 pm on April 30, 2024: contributor

    I’m very much PRO descriptors directly IN PSBTs. Even tho I understand @achow101 comments.

    Regardless of the format here (which i haven’t studied) it is useful to have descriptor (or at least policy) in PSBT. Example from Coldcard is when you want to have multiple miniscripts registered on device that have identical keys in miniscript but policy/script is different. Or same keys same policy but order of keys in policy is different. Here you just cannot infer solely from PSBT which wallet to use because keys match for all wallets…

    why not just use PSBT_GLOBAL_PROPRIETARY key and send descriptor in there?

  32. seedhammer commented at 7:02 pm on May 1, 2024: none

    I’m very much PRO descriptors directly IN PSBTs. Even tho I understand @achow101 comments.

    Descriptors in PSBTs are useful, but descriptors are also useful outside PSBTs: transferring descriptors between wallets, (long term) backups. It would be unfortunate to specify a descriptor format that only solved the signing use-cases.

    why not just use PSBT_GLOBAL_PROPRIETARY key and send descriptor in there?

    That would hijack PSBT_GLOBAL_PROPRIETARY, leaving it no longer available for vendor-specific uses.

  33. in bip-bod-descriptors.mediawiki:31 in 710fe837a6 outdated
    26+===Motivation===
    27+
    28+A BIP 380 output descriptor is a textual representation of a set of output
    29+scripts, such that Bitcoin wallets may agree on the scripts and addresses
    30+to provide the user. However, a descriptor string by itself is not ideal for
    31+transferring between wallets: it lacks a machine recognizable header, cannot
    


    jonatack commented at 8:40 pm on May 1, 2024:
    0transferring between wallets: it lacks a machine-recognizable header, cannot
    
  34. in bip-bod-descriptors.mediawiki:35 in 710fe837a6 outdated
    30+to provide the user. However, a descriptor string by itself is not ideal for
    31+transferring between wallets: it lacks a machine recognizable header, cannot
    32+represent metadata such as name and birth block, and its use of base58 for
    33+extended keys is inefficient.
    34+
    35+BIP 174 gives us a self-describing file format, metadata as well as a compact,
    


    jonatack commented at 8:40 pm on May 1, 2024:
    0BIP 174 gives us a self-describing file format, metadata, and a compact,
    
  35. in bip-bod-descriptors.mediawiki:36 in 710fe837a6 outdated
    31+transferring between wallets: it lacks a machine recognizable header, cannot
    32+represent metadata such as name and birth block, and its use of base58 for
    33+extended keys is inefficient.
    34+
    35+BIP 174 gives us a self-describing file format, metadata as well as a compact,
    36+binary representation of keys. Assuming most wallets already implements the PSBT
    


    jonatack commented at 8:41 pm on May 1, 2024:
    0binary representation of keys. Assuming most wallets already implement the PSBT
    
  36. in bip-bod-descriptors.mediawiki:45 in 710fe837a6 outdated
    40+are useful outside of signing flows (backup, initializing wallet
    41+software).</ref>
    42+<ref> '''Why not use the older Blockchain Commons BCR-2020-010 format?'''
    43+The format was [[https://github.com/BlockchainCommons/Research/blob/master/papers/bcr-2020-010-output-desc.md#deprecated-superseded-by-version-3-output-descriptors|recently deprecated]],
    44+because its use of reserved CBOR tags.</ref>
    45+<ref>'''Why not use the new Blockchain Commons BCR-2023-010 format?'''
    


    jonatack commented at 8:41 pm on May 1, 2024:
    0<ref>'''Why not use the new Blockchain Commons BCR-2023-010 format?'''.
    

    seedhammer commented at 9:02 am on May 2, 2024:
    On second thought, I reverted this suggestion. None of the other rationale headings have periods.

    fslmultiservice22 commented at 6:17 am on May 3, 2024:
    Grazie.
  37. in bip-bod-descriptors.mediawiki:44 in 710fe837a6 outdated
    39+The PSBT format is not a general purpose container format, and descriptors
    40+are useful outside of signing flows (backup, initializing wallet
    41+software).</ref>
    42+<ref> '''Why not use the older Blockchain Commons BCR-2020-010 format?'''
    43+The format was [[https://github.com/BlockchainCommons/Research/blob/master/papers/bcr-2020-010-output-desc.md#deprecated-superseded-by-version-3-output-descriptors|recently deprecated]],
    44+because its use of reserved CBOR tags.</ref>
    


    jonatack commented at 8:43 pm on May 1, 2024:
    0due to its use of reserved CBOR tags.</ref>
    

    or “because of”

  38. in bip-bod-descriptors.mediawiki:39 in 710fe837a6 outdated
    34+
    35+BIP 174 gives us a self-describing file format, metadata as well as a compact,
    36+binary representation of keys. Assuming most wallets already implements the PSBT
    37+format, the implementation overhead of this BIP is expected to be low
    38+<ref> '''Why not extend BIP 174?'''
    39+The PSBT format is not a general purpose container format, and descriptors
    


    jonatack commented at 8:45 pm on May 1, 2024:
    0The PSBT format is not a general-purpose container format, and descriptors
    
  39. in bip-bod-descriptors.mediawiki:55 in 710fe837a6 outdated
    50+In particular, we believe BCR-2023-010 would have faced opposition
    51+in the BIP process because it is based on the [[https://cbor.io/spec.html|CBOR encoding]].
    52+CBOR is designed for generality and compactness and is therefore significantly
    53+more complex than the PSBT encoding. In contrast, the PSBT key-value maps are
    54+supported by all wallet software that interact with PSBT files, are easier to
    55+review and fit in embedded devices.
    


    jonatack commented at 8:46 pm on May 1, 2024:
    0review, and they fit in embedded devices.
    
  40. in bip-bod-descriptors.mediawiki:57 in 710fe837a6 outdated
    52+CBOR is designed for generality and compactness and is therefore significantly
    53+more complex than the PSBT encoding. In contrast, the PSBT key-value maps are
    54+supported by all wallet software that interact with PSBT files, are easier to
    55+review and fit in embedded devices.
    56+
    57+Release in late 2023, BCR-2023-010 doesn't event have the advantage of widespread
    


    jonatack commented at 8:51 pm on May 1, 2024:
    0Released in late 2023, BCR-2023-010 doesn't even have the advantage of widespread
    

    seedhammer commented at 9:02 am on May 2, 2024:
    Removed the superfluous word.
  41. in bip-bod-descriptors.mediawiki:58 in 710fe837a6 outdated
    53+more complex than the PSBT encoding. In contrast, the PSBT key-value maps are
    54+supported by all wallet software that interact with PSBT files, are easier to
    55+review and fit in embedded devices.
    56+
    57+Release in late 2023, BCR-2023-010 doesn't event have the advantage of widespread
    58+support.</ref>.
    


    jonatack commented at 8:52 pm on May 1, 2024:
    0support at the time of this writing.</ref>.
    
  42. in bip-bod-descriptors.mediawiki:63 in 710fe837a6 outdated
    58+support.</ref>.
    59+
    60+==Specification==
    61+
    62+The Binary Output Descriptor (BOD) format consists of a fixed header, a
    63+key-value map describing the output descriptor and its metadata followed by a
    


    jonatack commented at 8:52 pm on May 1, 2024:
    It might be clearer to add a comma either after “descriptor” or “metadata”, depending on the intended meaning.

    seedhammer commented at 9:01 am on May 2, 2024:
    Removed the mention of metadata, since it’s clear from the detailed specification.
  43. in bip-bod-descriptors.mediawiki:90 in 710fe837a6 outdated
    85+| <tt><compact size uint birth block><bytes></tt>
    86+| The earliest block height that may contain transactions for the descriptor, optionally followed by the UTF-8 encoded name of the descriptor.
    87+| <tt><bytes descriptor></tt>
    88+| The output descriptor in BIP 380 format without inline keys<ref>''Why not encode the descriptor in binary?'''
    89+The BIP 380 descriptor language is complicated and expanding and we believe
    90+the efforts of designing a parallel binary encoding does not outweigh the
    


    jonatack commented at 8:55 pm on May 1, 2024:
    0the effort of designing a parallel binary encoding does not outweigh the
    

    (This sentence could be more clearly written, as well.)


    seedhammer commented at 9:01 am on May 2, 2024:
    Thanks. Rewritten.
  44. in bip-bod-descriptors.mediawiki:93 in 710fe837a6 outdated
    88+| The output descriptor in BIP 380 format without inline keys<ref>''Why not encode the descriptor in binary?'''
    89+The BIP 380 descriptor language is complicated and expanding and we believe
    90+the efforts of designing a parallel binary encoding does not outweigh the
    91+space savings.
    92+
    93+The major source of bloat, base58 encoded keys, are binary encoded for compactness and
    


    jonatack commented at 8:56 pm on May 1, 2024:
    0The major source of bloat, base58-encoded keys, are binary encoded for compactness and
    
  45. in bip-bod-descriptors.mediawiki:89 in 710fe837a6 outdated
    84+| <tt>BOD_GLOBAL_OUTPUT_DESCRIPTOR = 0x00</tt>
    85+| <tt><compact size uint birth block><bytes></tt>
    86+| The earliest block height that may contain transactions for the descriptor, optionally followed by the UTF-8 encoded name of the descriptor.
    87+| <tt><bytes descriptor></tt>
    88+| The output descriptor in BIP 380 format without inline keys<ref>''Why not encode the descriptor in binary?'''
    89+The BIP 380 descriptor language is complicated and expanding and we believe
    


    jonatack commented at 8:56 pm on May 1, 2024:
    0The BIP 380 descriptor language is complicated and expanding, and we believe
    

    seedhammer commented at 9:01 am on May 2, 2024:
    Thanks. Rewrote the paragraph.
  46. in bip-bod-descriptors.mediawiki:100 in 710fe837a6 outdated
     95+.</ref>
     96+|-
     97+| Proprietary Use Type
     98+| <tt>BOD_GLOBAL_PROPRIETARY = 0xFC</tt>
     99+| <tt><compact size uint identifier length> <bytes identifier> <compact size uint subtype> <bytes subkeydata></tt>
    100+| Compact size unsigned integer of the length of the identifier, followed by identifier prefix, followed by a compact size unsigned integer subtype, followed by the key data itself.
    


    jonatack commented at 8:57 pm on May 1, 2024:

    Suggest using an article for each item or for none.

    0| A compact size unsigned integer of the length of the identifier, followed by an identifier prefix, followed by a compact size unsigned integer subtype, followed by the key data itself.
    
  47. in bip-bod-descriptors.mediawiki:108 in 710fe837a6 outdated
    103+|}
    104+
    105+It is an error to omit the BOD_GLOBAL_OUTPUT_DESCRIPTOR entry.
    106+
    107+All key expressions in the BOD_GLOBAL_OUTPUT_DESCRIPTOR descriptor string must be
    108+specified as references on the form <tt>@<index></tt> where <tt>index</tt> is
    


    jonatack commented at 8:59 pm on May 1, 2024:

    IIUC

    0specified as references in the form of <tt>@<index></tt> where <tt>index</tt> is
    
  48. in bip-bod-descriptors.mediawiki:135 in 710fe837a6 outdated
    130+! <tt><valuedata></tt> Description
    131+|-
    132+| Extended Public Key
    133+| <tt>BOD_KEY_XPUB = 0x00</tt>
    134+| <tt><bytes xpub></tt>
    135+| The 78 byte serialized extended public key as defined by BIP 32.
    


    jonatack commented at 8:59 pm on May 1, 2024:
    0| The 78-byte serialized extended public key, as defined by BIP 32.
    
  49. in bip-bod-descriptors.mediawiki:137 in 710fe837a6 outdated
    132+| Extended Public Key
    133+| <tt>BOD_KEY_XPUB = 0x00</tt>
    134+| <tt><bytes xpub></tt>
    135+| The 78 byte serialized extended public key as defined by BIP 32.
    136+| <tt><4 byte fingerprint> <32-bit little endian uint path element>*</tt>
    137+| The master key fingerprint as defined by BIP 32 concatenated with the derivation path of the public key. The derivation path is represented as 32-bit little endian unsigned integer indexes concatenated with each other. The number of 32 bit unsigned integer indexes must match the depth provided in the extended public key.
    


    jonatack commented at 9:00 pm on May 1, 2024:
    0| The master key fingerprint, as defined by BIP 32, concatenated with the derivation path of the public key. The derivation path is represented as 32-bit little endian unsigned integer indexes concatenated with each other. The number of 32-bit unsigned integer indexes must match the depth provided in the extended public key.
    
  50. in bip-bod-descriptors.mediawiki:142 in 710fe837a6 outdated
    137+| The master key fingerprint as defined by BIP 32 concatenated with the derivation path of the public key. The derivation path is represented as 32-bit little endian unsigned integer indexes concatenated with each other. The number of 32 bit unsigned integer indexes must match the depth provided in the extended public key.
    138+|-
    139+| Proprietary Use Type
    140+| <tt>BOD_KEY_PROPRIETARY = 0xFC</tt>
    141+| <tt><compact size uint identifier length> <bytes identifier> <compact size uint subtype> <bytes subkeydata></tt>
    142+| Compact size unsigned integer of the length of the identifier, followed by identifier prefix, followed by a compact size unsigned integer subtype, followed by the key data itself.
    


    jonatack commented at 9:01 pm on May 1, 2024:

    idem

    0| A compact size unsigned integer of the length of the identifier, followed by an identifier prefix, followed by a compact size unsigned integer subtype, followed by the key data itself.
    
  51. in bip-bod-descriptors.mediawiki:156 in 710fe837a6 outdated
    151+A descriptor with a key reference out of bounds.
    152+ Descriptor: wpkh(@0/*)
    153+ Hex encoded BOD: 70736274ff0207000a77706b682840302f2a29000000
    154+
    155+A descriptor with an invalid UTF-8 name.
    156+ Hex encoded BOD: 70736274ff05070061c57a0a77706b682840302f2a2953010488b21e041c0ae906800000025afed56d755c088320ec9bc6acd84d33737b580083759e0a0ff8f26e429e0b77028342f5f7773f6fab374e1c2d3ccdba26bc0933fc4f63828b662b4357e4cc3791bec0fbd814c5d8729748000080000000800000008002000080000000
    


    jonatack commented at 9:02 pm on May 1, 2024:
    0 Hex-encoded BOD: 70736274ff05070061c57a0a77706b682840302f2a2953010488b21e041c0ae906800000025afed56d755c088320ec9bc6acd84d33737b580083759e0a0ff8f26e429e0b77028342f5f7773f6fab374e1c2d3ccdba26bc0933fc4f63828b662b4357e4cc3791bec0fbd814c5d8729748000080000000800000008002000080000000
    
  52. in bip-bod-descriptors.mediawiki:159 in 710fe837a6 outdated
    154+
    155+A descriptor with an invalid UTF-8 name.
    156+ Hex encoded BOD: 70736274ff05070061c57a0a77706b682840302f2a2953010488b21e041c0ae906800000025afed56d755c088320ec9bc6acd84d33737b580083759e0a0ff8f26e429e0b77028342f5f7773f6fab374e1c2d3ccdba26bc0933fc4f63828b662b4357e4cc3791bec0fbd814c5d8729748000080000000800000008002000080000000
    157+
    158+A descriptor with an inline key.
    159+  Hex encoded BOD: 70736274ff0207008e77706b68285b64633536373237362f3438682f30682f30682f32685d7870756236446959726652774e6e6a655834764873574d616a4a56464b726245456e753867415739764475517a675457457345484531367347576558585556314c42575145317943546d657072534e63715a3357373468715664674462745948557633654d3457325445556870616e2f2a29000000
    


    jonatack commented at 9:02 pm on May 1, 2024:
    0  Hex-encoded BOD: 70736274ff0207008e77706b68285b64633536373237362f3438682f30682f30682f32685d7870756236446959726652774e6e6a655834764873574d616a4a56464b726245456e753867415739764475517a675457457345484531367347576558585556314c42575145317943546d657072534e63715a3357373468715664674462745948557633654d3457325445556870616e2f2a29000000
    
  53. in bip-bod-descriptors.mediawiki:170 in 710fe837a6 outdated
    165+ Name: Satoshi's Stash
    166+ Birth block: 123456789012345
    167+ Key 0: [dc567276/48h/0h/0h/2h]xpub6DiYrfRwNnjeX4vHsWMajJVFKrbEEnu8gAW9vDuQzgTWEsEHE16sGWeXXUV1LBWQE1yCTmeprSNcqZ3W74hqVdgDbtYHUv3eM4W2TEUhpan
    168+ Key 1: [f245ae38/48h/0h/0h/2h]xpub6DnT4E1fT8VxuAZW29avMjr5i99aYTHBp9d7fiLnpL5t4JEprQqPMbTw7k7rh5tZZ2F5g8PJpssqrZoebzBChaiJrmEvWwUTEMAbHsY39Ge
    169+ Key 2: [c5d87297/48h/0h/0h/2h]xpub6DjrnfAyuonMaboEb3ZQZzhQ2ZEgaKV2r64BFmqymZqJqviLTe1JzMr2X2RfQF892RH7MyYUbcy77R7pPu1P71xoj8cDUMNhAMGYzKR4noZ
    170+ Hex encoded BOD: 70736274ff1907ff79df0d86487000005361746f73686927732053746173683477736828736f727465646d756c746928322c40302f3c303b313e2f2a2c40312f3c303b313e2f2a2c40322f3c303b313e2f2a292953010488b21e0418f8c2e7800000026b3a4cfb6a45f6305efe6e0e976b5d26ba27f7c344d7fc7abef7be2d06d52dfd021c0b479ecf6e67713ddf0c43b634592f51c037b6f951fb1dc6361a98b1e5735e0f8b515314dc5672764800008000000080000000800200008053010488b21e04221eb5a080000002c887c72d9d8ac29cddd5b2b060e8b0239039a149c784abe6079e24445db4aa8a0397fcf2274abd243d42d42d3c248608c6d1935efca46138afef43af08e971289657009d2b14f245ae384800008000000080000000800200008053010488b21e041c0ae906800000025afed56d755c088320ec9bc6acd84d33737b580083759e0a0ff8f26e429e0b77028342f5f7773f6fab374e1c2d3ccdba26bc0933fc4f63828b662b4357e4cc3791bec0fbd814c5d8729748000080000000800000008002000080000000
    


    jonatack commented at 9:02 pm on May 1, 2024:
    0 Hex-encoded BOD: 70736274ff1907ff79df0d86487000005361746f73686927732053746173683477736828736f727465646d756c746928322c40302f3c303b313e2f2a2c40312f3c303b313e2f2a2c40322f3c303b313e2f2a292953010488b21e0418f8c2e7800000026b3a4cfb6a45f6305efe6e0e976b5d26ba27f7c344d7fc7abef7be2d06d52dfd021c0b479ecf6e67713ddf0c43b634592f51c037b6f951fb1dc6361a98b1e5735e0f8b515314dc5672764800008000000080000000800200008053010488b21e04221eb5a080000002c887c72d9d8ac29cddd5b2b060e8b0239039a149c784abe6079e24445db4aa8a0397fcf2274abd243d42d42d3c248608c6d1935efca46138afef43af08e971289657009d2b14f245ae384800008000000080000000800200008053010488b21e041c0ae906800000025afed56d755c088320ec9bc6acd84d33737b580083759e0a0ff8f26e429e0b77028342f5f7773f6fab374e1c2d3ccdba26bc0933fc4f63828b662b4357e4cc3791bec0fbd814c5d8729748000080000000800000008002000080000000
    
  54. in bip-bod-descriptors.mediawiki:178 in 710fe837a6 outdated
    173+
    174+<references/>
    175+
    176+==Compatibility==
    177+
    178+This is a new format and as such have no campatibility burden.
    


    jonatack commented at 9:02 pm on May 1, 2024:
    0This is a new format and as such has no compatibility burden.
    
  55. jonatack commented at 9:04 pm on May 1, 2024: contributor
    A few review suggestions follow for the BIP text.
  56. bip-bod-descriptors: apply suggested edits
    Suggestions by @jonatack.
    
    Co-authored-by: Jon Atack <jon@atack.com>
    c6c727ccc8
  57. bip-bod-descriptors: apply more edits suggested during review
    Suggestions by @jonatack.
    36403bec01
  58. seedhammer force-pushed on May 2, 2024
  59. 5twelve approved

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bips. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2024-11-01 00:10 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me