diff --git a/appdx-bips.asciidoc b/appdx-bips.asciidoc index e284f19e..7620bc2c 100644 --- a/appdx-bips.asciidoc +++ b/appdx-bips.asciidoc @@ -4,7 +4,7 @@ ((("bitcoin improvement proposals", "types of")))Bitcoin Improvement Proposals are design documents providing information to the bitcoin community, or for describing a new feature for bitcoin or its processes or environment. -As per BIP-01 _BIP Purpose and Guidelines_, there are three kinds of BIPs: +As per BIP1 _BIP Purpose and Guidelines_, there are three kinds of BIPs: _Standard_ BIP:: Describes any change that affects most or all bitcoin implementations, such as a change to the network protocol, a change in block or transaction validity rules, or any change or addition that affects the interoperability of applications using bitcoin. _Informational_ BIP:: Describes a bitcoin design issue, or provides general guidelines or information to the bitcoin community, but does not propose a new feature. Informational BIPs do not necessarily represent a bitcoin community consensus or recommendation, so users and implementors may ignore informational BIPs or follow their advice. @@ -18,54 +18,54 @@ significantly changed. BIPs that are implemented by Bitcoin Core: -- BIP 9: The changes allowing multiple soft-forks to be deployed in parallel have been implemented since v0.12.1 (PR #7575) -- BIP 11: Multisig outputs are standard since v0.6.0 (PR #669). -- BIP 13: The address format for P2SH addresses has been implemented since v0.6.0 (PR #669). -- BIP 14: The subversion string is being used as User Agent since v0.6.0 (PR #669). -- BIP 16: The pay-to-script-hash evaluation rules have been implemented since v0.6.0, and took effect on April 1st 2012 (PR #748). -- BIP 21: The URI format for Bitcoin payments has been implemented since v0.6.0 (PR #176). -- BIP 22: The 'getblocktemplate' (GBT) RPC protocol for mining has been implemented since v0.7.0 (PR #936). -- BIP 23: Some extensions to GBT have been implemented since v0.10.0rc1, including longpolling and block proposals (PR #1816). -- BIP 30: The evaluation rules to forbid creating new transactions with the same txid as previous not-fully-spent transactions were implemented since v0.6.0, and the rule took effect on March 15th 2012 (PR #915). -- BIP 31: The 'pong' protocol message (and the protocol version bump to 60001) has been implemented since v0.6.1 (PR #1081). -- BIP 32: Hierarchical Deterministic Wallets has been implemented since v0.13.0 (PR #8035). -- BIP 34: The rule that requires blocks to contain their height (number) in the coinbase input, and the introduction of version 2 blocks has been implemented since v0.7.0. The rule took effect for version 2 blocks as of block 224413 (March 5th 2013), and version 1 blocks are no longer allowed since block 227931 (March 25th 2013) (PR #1526). -- BIP 35: The 'mempool' protocol message (and the protocol version bump to 60002) has been implemented since v0.7.0 (PR #1641). As of v0.13.0, this is only available for NODE_BLOOM (BIP 111) peers. -- BIP 37: The bloom filtering for transaction relaying, partial Merkle trees for blocks, and the protocol version bump to 70001 (enabling low-bandwidth SPV clients) has been implemented since v0.8.0 (PR #1795). Disabled by default since v0.19.0, can be enabled by the -peerbloomfilters option. -- BIP 42: The bug that would have caused the subsidy schedule to resume after block 13440000 was fixed in v0.9.2 (PR #3842). -- BIP 43: The experimental descriptor wallets introduced in v0.21.0 by default use the Hierarchical Deterministic Wallet derivation proposed by BIP 43. (PR #16528) -- BIP 44: The experimental descriptor wallets introduced in v0.21.0 by default use the Hierarchical Deterministic Wallet derivation proposed by BIP 44. (PR #16528) -- BIP 49: The experimental descriptor wallets introduced in v0.21.0 by default use the Hierarchical Deterministic Wallet derivation proposed by BIP 49. (PR #16528) -- BIP 61: The 'reject' protocol message (and the protocol version bump to 70002) was added in v0.9.0 (PR #3185). Starting v0.17.0, whether to send reject messages can be configured with the -enablebip61 option, and support is deprecated (disabled by default) as of v0.18.0. Support was removed in v0.20.0 (PR #15437). -- BIP 65: The CHECKLOCKTIMEVERIFY softfork was merged in v0.12.0 (PR #6351), and backported to v0.11.2 and v0.10.4. Mempool-only CLTV was added in PR #6124. -- BIP 66: The strict DER rules and associated version 3 blocks have been implemented since v0.10.0 (PR #5713). -- BIP 68: Sequence locks have been implemented as of v0.12.1 (PR #7184), and have been buried since v0.19.0 (PR #16060). -- BIP 70 71 72: Payment Protocol support has been available in Bitcoin Core GUI since v0.9.0 (PR #5216). Support can be optionally disabled at build time since v0.18.0 (PR 14451), and it is disabled by default at build time since v0.19.0 (PR #15584). It has been removed as of v0.20.0 (PR 17165). -- BIP 84: The experimental descriptor wallets introduced in v0.21.0 by default use the Hierarchical Deterministic Wallet derivation proposed by BIP 84. (PR #16528) -- BIP 86: Descriptor wallets by default use the Hierarchical Deterministic Wallet derivation proposed by BIP 86 since v23.0 (PR #22364). -- BIP 90: Trigger mechanism for activation of BIPs 34, 65, and 66 has been simplified to block height checks since v0.14.0 (PR #8391). -- BIP 111: NODE_BLOOM service bit added, and enforced for all peer versions as of v0.13.0 (PR #6579 and PR #6641). -- BIP 112: The CHECKSEQUENCEVERIFY opcode has been implemented since v0.12.1 (PR #7524), and has been buried since v0.19.0 (PR #16060). -- BIP 113: Median time past lock-time calculations have been implemented since v0.12.1 (PR #6566), and has been buried since v0.19.0 (PR #16060). -- BIP 125: Opt-in full replace-by-fee signaling partially implemented. See doc/policy/mempool-replacements.md. -- BIP 130: direct headers announcement is negotiated with peer versions >=70012 as of v0.12.0 (PR 6494). -- BIP 133: feefilter messages are respected and sent for peer versions >=70013 as of v0.13.0 (PR 7542). -- BIP 141: Segregated Witness (Consensus Layer) as of v0.13.0 (PR 8149), defined for mainnet as of v0.13.1 (PR 8937), and buried since v0.19.0 (PR #16060). -- BIP 143: Transaction Signature Verification for Version 0 Witness Program as of v0.13.0 (PR 8149), defined for mainnet as of v0.13.1 (PR 8937), and buried since v0.19.0 (PR #16060). -- BIP 144: Segregated Witness as of 0.13.0 (PR 8149). -- BIP 145: getblocktemplate updates for Segregated Witness as of v0.13.0 (PR 8149). -- BIP 147: NULLDUMMY softfork as of v0.13.1 (PR 8636 and PR 8937), buried since v0.19.0 (PR #16060). -- BIP 152: Compact block transfer and related optimizations are used as of v0.13.0 (PR 8068). -- BIP 155: The 'addrv2' and 'sendaddrv2' messages which enable relay of Tor V3 addresses (and other networks) are supported as of v0.21.0 (PR 19954). -- BIP 157 158: Compact Block Filters for Light Clients can be indexed as of v0.19.0 (PR #14121) and served to peers on the P2P network as of v0.21.0 (PR #16442). -- BIP 159: The NODE_NETWORK_LIMITED service bit is signalled as of v0.16.0 (PR 11740), and such nodes are connected to as of v0.17.0 (PR 10387). -- BIP 173: Bech32 addresses for native Segregated Witness outputs are supported as of v0.16.0 (PR 11167). Bech32 addresses are generated by default as of v0.20.0 (PR 16884). -- BIP 174: RPCs to operate on Partially Signed Bitcoin Transactions (PSBT) are present as of v0.17.0 (PR 13557). -- BIP 176: Bits Denomination [QT only] is supported as of v0.16.0 (PR 12035). -- BIP 325: Signet test network is supported as of v0.21.0 (PR 18267). -- BIP 339: Relay of transactions by wtxid is supported as of v0.21.0 (PR 18044). -- BIP 340 341 342: Validation rules for Taproot (including Schnorr signatures and Tapscript leaves) are implemented as of v0.21.0 (PR 19953), with mainnet activation as of v0.21.1 (PR 21377, PR 21686). -- BIP 350: Addresses for native v1+ segregated Witness outputs use Bech32m instead of Bech32 as of v22.0 (PR 20861). -- BIP 371: Taproot fields for PSBT as of v24.0 (PR 22558). -- BIP 380 381 382 383 384 385: Output Script Descriptors, and most of Script Expressions are implemented as of v0.17.0 (PR 13697). -- BIP 386: tr() Output Script Descriptors are implemented as of v22.0 (PR 22051). +- BIP9: The changes allowing multiple soft-forks to be deployed in parallel have been implemented since v0.12.1 (PR #7575) +- BIP11: Multisig outputs are standard since v0.6.0 (PR #669). +- BIP13: The address format for P2SH addresses has been implemented since v0.6.0 (PR #669). +- BIP14: The subversion string is being used as User Agent since v0.6.0 (PR #669). +- BIP16: The pay-to-script-hash evaluation rules have been implemented since v0.6.0, and took effect on April 1st 2012 (PR #748). +- BIP21: The URI format for Bitcoin payments has been implemented since v0.6.0 (PR #176). +- BIP22: The 'getblocktemplate' (GBT) RPC protocol for mining has been implemented since v0.7.0 (PR #936). +- BIP23: Some extensions to GBT have been implemented since v0.10.0rc1, including longpolling and block proposals (PR #1816). +- BIP30: The evaluation rules to forbid creating new transactions with the same txid as previous not-fully-spent transactions were implemented since v0.6.0, and the rule took effect on March 15th 2012 (PR #915). +- BIP31: The 'pong' protocol message (and the protocol version bump to 60001) has been implemented since v0.6.1 (PR #1081). +- BIP32: Hierarchical Deterministic Wallets has been implemented since v0.13.0 (PR #8035). +- BIP34: The rule that requires blocks to contain their height (number) in the coinbase input, and the introduction of version 2 blocks has been implemented since v0.7.0. The rule took effect for version 2 blocks as of block 224413 (March 5th 2013), and version 1 blocks are no longer allowed since block 227931 (March 25th 2013) (PR #1526). +- BIP35: The 'mempool' protocol message (and the protocol version bump to 60002) has been implemented since v0.7.0 (PR #1641). As of v0.13.0, this is only available for NODE_BLOOM (BIP111) peers. +- BIP37: The bloom filtering for transaction relaying, partial Merkle trees for blocks, and the protocol version bump to 70001 (enabling low-bandwidth SPV clients) has been implemented since v0.8.0 (PR #1795). Disabled by default since v0.19.0, can be enabled by the -peerbloomfilters option. +- BIP42: The bug that would have caused the subsidy schedule to resume after block 13440000 was fixed in v0.9.2 (PR #3842). +- BIP43: The experimental descriptor wallets introduced in v0.21.0 by default use the Hierarchical Deterministic Wallet derivation proposed by BIP43. (PR #16528) +- BIP44: The experimental descriptor wallets introduced in v0.21.0 by default use the Hierarchical Deterministic Wallet derivation proposed by BIP44. (PR #16528) +- BIP49: The experimental descriptor wallets introduced in v0.21.0 by default use the Hierarchical Deterministic Wallet derivation proposed by BIP49. (PR #16528) +- BIP61: The 'reject' protocol message (and the protocol version bump to 70002) was added in v0.9.0 (PR #3185). Starting v0.17.0, whether to send reject messages can be configured with the -enablebip61 option, and support is deprecated (disabled by default) as of v0.18.0. Support was removed in v0.20.0 (PR #15437). +- BIP65: The CHECKLOCKTIMEVERIFY softfork was merged in v0.12.0 (PR #6351), and backported to v0.11.2 and v0.10.4. Mempool-only CLTV was added in PR #6124. +- BIP66: The strict DER rules and associated version 3 blocks have been implemented since v0.10.0 (PR #5713). +- BIP68: Sequence locks have been implemented as of v0.12.1 (PR #7184), and have been buried since v0.19.0 (PR #16060). +- BIP70 71 72: Payment Protocol support has been available in Bitcoin Core GUI since v0.9.0 (PR #5216). Support can be optionally disabled at build time since v0.18.0 (PR 14451), and it is disabled by default at build time since v0.19.0 (PR #15584). It has been removed as of v0.20.0 (PR 17165). +- BIP84: The experimental descriptor wallets introduced in v0.21.0 by default use the Hierarchical Deterministic Wallet derivation proposed by BIP84. (PR #16528) +- BIP86: Descriptor wallets by default use the Hierarchical Deterministic Wallet derivation proposed by BIP86 since v23.0 (PR #22364). +- BIP90: Trigger mechanism for activation of BIPs 34, 65, and 66 has been simplified to block height checks since v0.14.0 (PR #8391). +- BIP111: NODE_BLOOM service bit added, and enforced for all peer versions as of v0.13.0 (PR #6579 and PR #6641). +- BIP112: The CHECKSEQUENCEVERIFY opcode has been implemented since v0.12.1 (PR #7524), and has been buried since v0.19.0 (PR #16060). +- BIP113: Median time past lock-time calculations have been implemented since v0.12.1 (PR #6566), and has been buried since v0.19.0 (PR #16060). +- BIP125: Opt-in full replace-by-fee signaling partially implemented. See doc/policy/mempool-replacements.md. +- BIP130: direct headers announcement is negotiated with peer versions >=70012 as of v0.12.0 (PR 6494). +- BIP133: feefilter messages are respected and sent for peer versions >=70013 as of v0.13.0 (PR 7542). +- BIP141: Segregated Witness (Consensus Layer) as of v0.13.0 (PR 8149), defined for mainnet as of v0.13.1 (PR 8937), and buried since v0.19.0 (PR #16060). +- BIP143: Transaction Signature Verification for Version 0 Witness Program as of v0.13.0 (PR 8149), defined for mainnet as of v0.13.1 (PR 8937), and buried since v0.19.0 (PR #16060). +- BIP144: Segregated Witness as of 0.13.0 (PR 8149). +- BIP145: getblocktemplate updates for Segregated Witness as of v0.13.0 (PR 8149). +- BIP147: NULLDUMMY softfork as of v0.13.1 (PR 8636 and PR 8937), buried since v0.19.0 (PR #16060). +- BIP152: Compact block transfer and related optimizations are used as of v0.13.0 (PR 8068). +- BIP155: The 'addrv2' and 'sendaddrv2' messages which enable relay of Tor V3 addresses (and other networks) are supported as of v0.21.0 (PR 19954). +- BIP157 158: Compact Block Filters for Light Clients can be indexed as of v0.19.0 (PR #14121) and served to peers on the P2P network as of v0.21.0 (PR #16442). +- BIP159: The NODE_NETWORK_LIMITED service bit is signalled as of v0.16.0 (PR 11740), and such nodes are connected to as of v0.17.0 (PR 10387). +- BIP173: Bech32 addresses for native Segregated Witness outputs are supported as of v0.16.0 (PR 11167). Bech32 addresses are generated by default as of v0.20.0 (PR 16884). +- BIP174: RPCs to operate on Partially Signed Bitcoin Transactions (PSBT) are present as of v0.17.0 (PR 13557). +- BIP176: Bits Denomination [QT only] is supported as of v0.16.0 (PR 12035). +- BIP325: Signet test network is supported as of v0.21.0 (PR 18267). +- BIP339: Relay of transactions by wtxid is supported as of v0.21.0 (PR 18044). +- BIP340 341 342: Validation rules for Taproot (including Schnorr signatures and Tapscript leaves) are implemented as of v0.21.0 (PR 19953), with mainnet activation as of v0.21.1 (PR 21377, PR 21686). +- BIP350: Addresses for native v1+ segregated Witness outputs use Bech32m instead of Bech32 as of v22.0 (PR 20861). +- BIP371: Taproot fields for PSBT as of v24.0 (PR 22558). +- BIP380 381 382 383 384 385: Output Script Descriptors, and most of Script Expressions are implemented as of v0.17.0 (PR 13697). +- BIP386: tr() Output Script Descriptors are implemented as of v22.0 (PR 22051). diff --git a/appdx-bx.asciidoc b/appdx-bx.asciidoc index b4fd2a55..e39924e1 100644 --- a/appdx-bx.asciidoc +++ b/appdx-bx.asciidoc @@ -114,7 +114,7 @@ $ bx ec-to-address < public_key 17re1S4Q8ZHyCP8Kw7xQad1Lr6XUzWUnkG ---- -Keys generated in this manner produce a type-0 nondeterministic wallet. That means that each key is generated from an independent seed. Bitcoin Explorer commands can also generate keys deterministically, in accordance with BIP-32. In this case, a "master" key is created from a seed and then extended deterministically to produce a tree of subkeys, resulting in a type-2 deterministic wallet. +Keys generated in this manner produce a type-0 nondeterministic wallet. That means that each key is generated from an independent seed. Bitcoin Explorer commands can also generate keys deterministically, in accordance with BIP32. In this case, a "master" key is created from a seed and then extended deterministically to produce a tree of subkeys, resulting in a type-2 deterministic wallet. First, we use the +seed+ and +hd-new+ commands to generate a master key that will be used as the basis to derive a hierarchy of keys: diff --git a/appdx-pycoin.asciidoc b/appdx-pycoin.asciidoc index f4c1fbee..2e126958 100644 --- a/appdx-pycoin.asciidoc +++ b/appdx-pycoin.asciidoc @@ -9,9 +9,9 @@ The pycoin library supports both Python 2 (2.7.x) and Python 3 (3.3 and later) a === Key Utility (KU) -((("key utility (ku)", id="keyutil17")))The command-line utility +ku+ ("key utility") is a Swiss Army knife for manipulating keys. It supports BIP-32 keys, WIF, and addresses (bitcoin and alt coins). Following are some examples. +((("key utility (ku)", id="keyutil17")))The command-line utility +ku+ ("key utility") is a Swiss Army knife for manipulating keys. It supports BIP32 keys, WIF, and addresses (bitcoin and alt coins). Following are some examples. -Create a BIP-32 key using the default entropy sources of GPG and _/dev/random_: +Create a BIP32 key using the default entropy sources of GPG and _/dev/random_: ---- @@ -47,7 +47,7 @@ Bitcoin address : 1FNNRQ5fSv1wBi5gyfVBs2rkNheMGt86sp uncompressed : 1DSS5isnH4FsVaLVjeVXewVSpfqktdiQAM ---- -Create a BIP-32 key from a passphrase: +Create a BIP32 key from a passphrase: [WARNING] ==== diff --git a/appdx-scriptops.asciidoc b/appdx-scriptops.asciidoc index 977747dd..4a5df0c9 100644 --- a/appdx-scriptops.asciidoc +++ b/appdx-scriptops.asciidoc @@ -52,8 +52,8 @@ Tables and descriptions sourced from https://en.bitcoin.it/wiki/Script[]. [options="header"] |======= | Symbol | Value (hex) | Description -| OP_CHECKLOCKTIMEVERIFY (previously OP_NOP2) | 0xb1 | Marks transaction as invalid if the top stack item is greater than the transaction's nLockTime field, otherwise script evaluation continues as though an OP_NOP was executed. Transaction is also invalid if 1. the stack is empty; or 2. the top stack item is negative; or 3. the top stack item is greater than or equal to 500000000 while the transaction's nLockTime field is less than 500000000, or vice versa; or 4. the input's nSequence field is equal to 0xffffffff. The precise semantics are described in BIP-65 -| OP_CHECKSEQUENCEVERIFY (previously OP_NOP3) | 0xb2 | Marks transaction as invalid if the relative lock time of the input (enforced by BIP 0068 with nSequence) is not equal to or longer than the value of the top stack item. The precise semantics are described in BIP-112| +| OP_CHECKLOCKTIMEVERIFY (previously OP_NOP2) | 0xb1 | Marks transaction as invalid if the top stack item is greater than the transaction's lock time field, otherwise script evaluation continues as though an OP_NOP was executed. Transaction is also invalid if 1. the stack is empty; or 2. the top stack item is negative; or 3. the top stack item is greater than or equal to 500000000 while the transaction's lock time field is less than 500000000, or vice versa; or 4. the input's sequence field is equal to 0xffffffff. The precise semantics are described in BIP65 +| OP_CHECKSEQUENCEVERIFY (previously OP_NOP3) | 0xb2 | Marks transaction as invalid if the relative lock time of the input (enforced by BIP68 with sequence) is not equal to or longer than the value of the top stack item. The precise semantics are described in BIP112| |======= <> shows operators used to manipulate the stack. diff --git a/ch04.asciidoc b/ch04.asciidoc index 40cc8106..8edc6864 100644 --- a/ch04.asciidoc +++ b/ch04.asciidoc @@ -709,7 +709,7 @@ version prefixes and the resulting base58 characters are shown in | Testnet Address for P2PKH | 0x6F | m or n | Testnet Address for P2SH | 0xC4 | 2 | Private Key WIF | 0x80 | 5, K, or L -| BIP-32 Extended Public Key | 0x0488B21E | xpub +| BIP32 Extended Public Key | 0x0488B21E | xpub |======= Putting together public keys, hash-based commitments, and base58check diff --git a/ch08.asciidoc b/ch08.asciidoc index 096b5351..04ef4978 100644 --- a/ch08.asciidoc +++ b/ch08.asciidoc @@ -804,7 +804,7 @@ remove a pattern from a bloom filter, a client has to clear and resend a new bloom filter if a pattern is no longer desired. The network protocol and bloom filter mechanism for SPV clients is defined -in http://bit.ly/1x6qCiO[BIP-37 (Peer Services)].((("", +in http://bit.ly/1x6qCiO[BIP37 (Peer Services)].((("", startref="BNebloom08")))((("", startref="bloom08"))) Unfortunately, after the deployment of bloom filters, it became clear diff --git a/chapters/signatures.adoc b/chapters/signatures.adoc index 7b733214..cc41d98e 100644 --- a/chapters/signatures.adoc +++ b/chapters/signatures.adoc @@ -993,7 +993,7 @@ hash operations to verify the transaction. Segwit represented an opportunity to address this problem by changing the way the commitment hash is calculated. For segwit version 0 witness programs, signature verification occurs using an improved commitment -hash algorithm as specified in BIP-143. +hash algorithm as specified in BIP143. The new algorithm allows the number of hash operations increases by a much more gradual O(n) to the number of diff --git a/third_edition_changes.asciidoc b/third_edition_changes.asciidoc index 5556439f..f4d5b117 100644 --- a/third_edition_changes.asciidoc +++ b/third_edition_changes.asciidoc @@ -66,7 +66,7 @@ * Implementing Keys and Addresses in C++ * Implementing Keys and Addresses in Python * Advanced Keys and Addresses -* Encrypted Private Keys (BIP-38) +* Encrypted Private Keys (BIP38) * Pay-to-Script Hash (P2SH) and Multisig Addresses * Vanity Addresses * Paper Wallets @@ -74,12 +74,12 @@ * Wallet Technology Overview * Nondeterministic (Random) Wallets * Deterministic (Seeded) Wallets -* HD Wallets (BIP-32/BIP-44) -* Seeds and Mnemonic Codes (BIP-39) +* HD Wallets (BIP32/BIP44) +* Seeds and Mnemonic Codes (BIP39) * Wallet Best Practices * Using a Bitcoin Wallet * Wallet Technology Details -* Mnemonic Code Words (BIP-39) +* Mnemonic Code Words (BIP39) * Creating an HD Wallet from the Seed * Using an Extended Public Key on a Web Store === 6. Transactions @@ -203,9 +203,9 @@ Bitcoin Addresses, Balances, and Other Abstractions * Soft Forks * Criticisms of Soft Forks * Soft Fork Signaling with Block Version -* BIP-34 Signaling and Activation -* BIP-9 Signaling and Activation -* NEW BIP-8 Activation +* BIP34 Signaling and Activation +* BIP9 Signaling and Activation +* NEW BIP8 Activation * *NEW: Speedy Trial Activation* * Consensus Software Development === 11. Bitcoin Security