mirror of
https://github.com/bitcoin/bips.git
synced 2026-10-19 19:29:18 +00:00
bip-138 treat content type 0x00 as the end of content items
This commit is contained in:
@@ -322,7 +322,7 @@ remaining bytes are `PADDING`. A `PAYLOAD` MUST contain at least one item (see
|
||||
|
||||
| Value | Definition |
|
||||
|:-------|:---------------------------------------|
|
||||
| 0x00 | Reserved |
|
||||
| 0x00 | End of content items; padding follows |
|
||||
| 0x01 | BIP Number (big-endian uint16) |
|
||||
| 0x02 | Vendor-Specific Opaque Tag |
|
||||
|
||||
@@ -333,7 +333,8 @@ For all `TYPE` values except `0x01`, `LENGTH` MUST be present.
|
||||
`DATA`: variable-length field whose encoding depends on `TYPE`.
|
||||
|
||||
For `TYPE` values defined above:
|
||||
- 0x00: parsers MUST reject the payload.
|
||||
- 0x00: parsers MUST stop reading content items and treat the remaining bytes as
|
||||
padding.
|
||||
- 0x01: `LENGTH` MUST be omitted and `DATA` is a 2-byte big-endian unsigned integer
|
||||
representing the BIP number that defines it.
|
||||
- 0x02: `DATA` MUST be `LENGTH` bytes of opaque, vendor-specific data.
|
||||
|
||||
Reference in New Issue
Block a user