From c27bc2500e64ce12c41d130970542a70cc3344b6 Mon Sep 17 00:00:00 2001 From: Daira Emma Hopwood Date: Mon, 15 Jan 2024 18:13:28 +0000 Subject: [PATCH] Formatting and CSS improvements: * ZIP 320: use normal block quote for modified sections of ZIP 316 rather than a literal block. * ZIP 320: add References heading. * ZIP 320: fix incorrect markup in two references. * CSS: adjust padding of block quotes and give them a grey background (light grey for light theme, dark grey for dark theme). * Regenerate README and index. Signed-off-by: Daira Emma Hopwood --- README.rst | 2 +- css/style.css | 10 +- index.html | 2 +- zip-0320.html | 284 ++++++++++++++++++++++++++------------------------ zip-0320.rst | 17 +-- 5 files changed, 170 insertions(+), 145 deletions(-) diff --git a/README.rst b/README.rst index 3473a409..ce552fba 100644 --- a/README.rst +++ b/README.rst @@ -138,7 +138,7 @@ Index of ZIPs 317 Proportional Transfer Fee Mechanism Active 318 Associated Payload Encryption Reserved 319 Options for Shielded Pool Retirement Reserved - 320 Defining an Address Type to which funds can only be sent from Transparent Addresses Reserved + 320 Defining an Address Type to which funds can only be sent from Transparent Addresses Draft 321 Payment Request URIs Proposed 322 Generic Signed Message Format Reserved 323 Specification of getblocktemplate for Zcash Reserved diff --git a/css/style.css b/css/style.css index deb7e43e..692e988e 100644 --- a/css/style.css +++ b/css/style.css @@ -41,6 +41,9 @@ aside > p > a:hover { color: #00455c; } + blockquote { + background-color: #e0e0e0 + } } @media (prefers-color-scheme: dark) { @@ -91,6 +94,9 @@ aside > p > a:hover { color: #90ffff; } + blockquote { + background-color: #202020 + } } aside { @@ -218,8 +224,8 @@ h8 { } blockquote { - margin: 0 1rem 1rem 1rem; - padding: 0; + margin: 0 1rem 1.5rem 1rem; + padding: 1rem 1rem 0 1rem; overflow-x: auto; } diff --git a/index.html b/index.html index 3aa4aff7..6c0cd01a 100644 --- a/index.html +++ b/index.html @@ -112,7 +112,7 @@ 317 Proportional Transfer Fee Mechanism Active 318 Associated Payload Encryption Reserved 319 Options for Shielded Pool Retirement Reserved - 320 Defining an Address Type to which funds can only be sent from Transparent Addresses Reserved + 320 Defining an Address Type to which funds can only be sent from Transparent Addresses Draft 321 Payment Request URIs Proposed 322 Generic Signed Message Format Reserved 323 Specification of getblocktemplate for Zcash Reserved diff --git a/zip-0320.html b/zip-0320.html index e6c2e6bf..7fa655df 100644 --- a/zip-0320.html +++ b/zip-0320.html @@ -98,22 +98,34 @@ console.log(t1) \(\mathtt{0x04}\) , the value of which MUST be the 20-byte validating key hash of a Zcash P2PKH Address as defined in 10.

The "Requirements for both Unified Addresses and Unified Viewing Keys" section of ZIP 316 7 will be modified as follows — the text:

-
A Unified Address or Unified Viewing Key MUST contain at least one
-shielded Item (Typecodes :math:`\mathtt{0x02}` and :math:`\mathtt{0x03}`).
-The rationale is that the existing P2SH and P2PKH transparent-only
-address formats, and the existing P2PKH extended public key format,
-suffice for representing transparent Items and are already supported
-by the existing ecosystem.
+
+

A Unified Address or Unified Viewing Key MUST contain at least one shielded Item (Typecodes + \(\mathtt{0x02}\) + and + \(\mathtt{0x03}\) + ). The rationale is that the existing P2SH and P2PKH transparent-only address formats, and the existing P2PKH extended public key format, suffice for representing transparent Items and are already supported by the existing ecosystem.

+

will be replaced by:

-
A Unified Address MUST contain at least one Receiver and any number
-of Metadata Items. The selection of Receivers is further restricted
-such that a Unified Address MUST **either**:
-* contain at least one shielded Receiver (Typecodes :math:`\mathtt{0x02}` and :math:`\mathtt{0x03}`),
-  and no Traceable P2PKH Receiver (Typecode :math:`\mathtt{0x04}`); **or**
-* contain **only** a Traceable P2PKH Receiver (Typecode :math:`\mathtt{0x04}`).
-
-A Unified Viewing Key MUST contain at least one shielded Item (Typecodes
-:math:`\mathtt{0x02}` and :math:`\mathtt{0x03}`).
+
+

A Unified Address MUST contain at least one Receiver and any number of Metadata Items. The selection of Receivers is further restricted such that a Unified Address MUST either:

+
    +
  • contain at least one shielded Receiver (Typecodes + \(\mathtt{0x02}\) + and + \(\mathtt{0x03}\) + ), and no Traceable P2PKH Receiver (Typecode + \(\mathtt{0x04}\) + ); or
  • +
  • contain only a Traceable P2PKH Receiver (Typecode + \(\mathtt{0x04}\) + ).
  • +
+

A Unified Viewing Key MUST contain at least one shielded Item (Typecodes + \(\mathtt{0x02}\) + and + \(\mathtt{0x03}\) + ).

+

A Traceable Unified Address is produced from a Mainnet Zcash P2PKH address by executing the following steps:

  1. Decode the address to a byte sequence using the Base58Check decoding algorithm 12.
  2. @@ -193,128 +205,130 @@ expiry time: Mon Feb 13 2024 01:14:18 GMT
  3. Unified Address encoding is slightly more complex than the proposed TEX address encoding, and requires use of the F4Jumble encoding algorithm 13. However, this can be readily mitigated by providing a purpose-built library for Traceable Unified Address encoding to Producers.
  4. A Traceable Unified Address is somewhat longer than a TEX address, although not excessively so.
  5. - - - - - - - -
    1Information on BCP 14 — "RFC 2119: Key words for use in RFCs to Indicate Requirement Levels" and "RFC 8174: Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words"
    - - - - - - - -
    2Zcash Community Forum thread "Important: Potential Binance Delisting"
    - - - - - - - -
    3'Zcash Community Forum user @hanh <https://forum.zcashcommunity.com/u/hanh/summary>'_
    - - - - - - - -
    4'Ywallet developer @hanh's proposal <https://forum.zcashcommunity.com/t/important-potential-binance-delisting/45954/112>'_
    - - - - - - - -
    5ZIP 316: Unified Addresses and Unified Viewing Keys — Terminology
    - - - - - - - -
    6ZIP 316: Unified Addresses and Unified Viewing Keys — Encoding of Unified Addresses
    - - - - - - - -
    7ZIP 316: Unified Addresses and Unified Viewing Keys — Requirements for both Unified Addresses and Unified Viewing Keys
    - - - - - - - -
    8ZIP 316: Unified Addresses and Unified Viewing Keys — Address Expiration Metadata
    - - - - - - - -
    9Zcash Protocol Specification, Version 2023.4.0. Section 3.12: Mainnet and Testnet
    - - - - - - - -
    10Zcash Protocol Specification, Version 2023.4.0. Section 5.6.1.1 Transparent Addresses
    - - - - - - - -
    11Zcash Community Forum post describing motivations for address expiry
    - - - - - - - -
    12Base58Check encoding — Bitcoin Wiki
    - - - - - - - -
    13ZIP 316: F4Jumble encoding
    - - - - - - - -
    14BIP 350: Bech32m format for v1+ witness addresses
    - - - - - - - -
    15zcash_address_wasm: Proof-of-concept library for Traceable Unified Address Encoding
    +

    References

    + + + + + + + +
    1Information on BCP 14 — "RFC 2119: Key words for use in RFCs to Indicate Requirement Levels" and "RFC 8174: Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words"
    + + + + + + + +
    2Zcash Community Forum thread "Important: Potential Binance Delisting"
    + + + + + + + +
    3Zcash Community Forum user @hanh
    + + + + + + + +
    4Ywallet developer @hanh's proposal
    + + + + + + + +
    5ZIP 316: Unified Addresses and Unified Viewing Keys — Terminology
    + + + + + + + +
    6ZIP 316: Unified Addresses and Unified Viewing Keys — Encoding of Unified Addresses
    + + + + + + + +
    7ZIP 316: Unified Addresses and Unified Viewing Keys — Requirements for both Unified Addresses and Unified Viewing Keys
    + + + + + + + +
    8ZIP 316: Unified Addresses and Unified Viewing Keys — Address Expiration Metadata
    + + + + + + + +
    9Zcash Protocol Specification, Version 2023.4.0. Section 3.12: Mainnet and Testnet
    + + + + + + + +
    10Zcash Protocol Specification, Version 2023.4.0. Section 5.6.1.1 Transparent Addresses
    + + + + + + + +
    11Zcash Community Forum post describing motivations for address expiry
    + + + + + + + +
    12Base58Check encoding — Bitcoin Wiki
    + + + + + + + +
    13ZIP 316: Unified Addresses and Unified Viewing Keys — Jumbling
    + + + + + + + +
    14BIP 350: Bech32m format for v1+ witness addresses
    + + + + + + + +
    15zcash_address_wasm: Proof-of-concept library for Traceable Unified Address Encoding
    +
    \ No newline at end of file diff --git a/zip-0320.rst b/zip-0320.rst index b5789bbf..652d28f5 100644 --- a/zip-0320.rst +++ b/zip-0320.rst @@ -187,7 +187,7 @@ in [#protocol-transparentaddrencoding]_. The "Requirements for both Unified Addresses and Unified Viewing Keys" section of ZIP 316 [#zip-0316-unified-requirements]_ will be modified as follows — the -text:: +text: A Unified Address or Unified Viewing Key MUST contain at least one shielded Item (Typecodes :math:`\mathtt{0x02}` and :math:`\mathtt{0x03}`). @@ -196,13 +196,15 @@ text:: suffice for representing transparent Items and are already supported by the existing ecosystem. -will be replaced by:: +will be replaced by: A Unified Address MUST contain at least one Receiver and any number of Metadata Items. The selection of Receivers is further restricted such that a Unified Address MUST **either**: - * contain at least one shielded Receiver (Typecodes :math:`\mathtt{0x02}` and :math:`\mathtt{0x03}`), - and no Traceable P2PKH Receiver (Typecode :math:`\mathtt{0x04}`); **or** + + * contain at least one shielded Receiver (Typecodes :math:`\mathtt{0x02}` + and :math:`\mathtt{0x03}`), and no Traceable P2PKH Receiver (Typecode + :math:`\mathtt{0x04}`); **or** * contain **only** a Traceable P2PKH Receiver (Typecode :math:`\mathtt{0x04}`). A Unified Viewing Key MUST contain at least one shielded Item (Typecodes @@ -344,10 +346,13 @@ Cons to Alternative 2 - A Traceable Unified Address is somewhat longer than a TEX address, although not excessively so. +References +========== + .. [#BCP14] `Information on BCP 14 — "RFC 2119: Key words for use in RFCs to Indicate Requirement Levels" and "RFC 8174: Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words" `_ .. [#binance-delisting] `Zcash Community Forum thread "Important: Potential Binance Delisting" `_ -.. [#hanh-profile] 'Zcash Community Forum user @hanh '_ -.. [#hanh-suggestion] 'Ywallet developer @hanh's proposal '_ +.. [#hanh-profile] `Zcash Community Forum user @hanh `_ +.. [#hanh-suggestion] `Ywallet developer @hanh's proposal `_ .. [#zip-0316-terminology] `ZIP 316: Unified Addresses and Unified Viewing Keys — Terminology `_ .. [#zip-0316-unified-addresses] `ZIP 316: Unified Addresses and Unified Viewing Keys — Encoding of Unified Addresses `_ .. [#zip-0316-unified-requirements] `ZIP 316: Unified Addresses and Unified Viewing Keys — Requirements for both Unified Addresses and Unified Viewing Keys `_