From 4e138b244e7ce0e2ec01603acbe54354db0b492b Mon Sep 17 00:00:00 2001 From: Daira Hopwood Date: Sat, 26 Jun 2021 17:20:16 +0100 Subject: [PATCH] ZIP 203: changes for Blossom and NU5. Signed-off-by: Daira Hopwood --- README.template | 1 + zip-0203.rst | 22 +++++++++++++++++++++- 2 files changed, 22 insertions(+), 1 deletion(-) diff --git a/README.template b/README.template index 99108c3c..b334bafb 100644 --- a/README.template +++ b/README.template @@ -46,6 +46,7 @@ This is the list of ZIPs relevant to the proposed NU5 Upgrade, which is planned to activate on Mainnet at the beginning of October 2021: - `ZIP 32: Shielded Hierarchical Deterministic Wallets `__ (updated) +- `ZIP 203: Transaction Expiry `__ (updated) - `ZIP 209: Prohibit Negative Shielded Chain Value Pool Balances `__ (updated) - `ZIP 212: Allow Recipient to Derive Ephemeral Secret from Note Plaintext `__ (updated) - `ZIP 213: Shielded Coinbase `__ (updated) diff --git a/zip-0203.rst b/zip-0203.rst index 6866c046..6d6d153e 100644 --- a/zip-0203.rst +++ b/zip-0203.rst @@ -49,7 +49,8 @@ after which transactions will be removed from the mempool if they have not been The data type for ``nExpiryHeight`` will be ``uint32_t``. If used in combination with ``nLockTime``, both ``nLockTime`` and ``nExpiryHeight`` must be block heights. ``nExpiryHeight`` will never be a UNIX timestamp, unlike ``nLockTime`` values, and thus -the maximum expiry height will be 499999999. +the maximum expiry height will be 499999999 (but see the exception for coinbase +transactions described in `Changes for NU5`_). For the example below, the last block that the transaction below could possibly be included in is 3539. After that, it will be removed from the mempool. @@ -77,6 +78,22 @@ convention. Every time a transaction expires and should be removed from the mempool, so should all of its dependent transactions. +Changes for Blossom +------------------- + +On Blossom activation [#zip-0206]_, the default changes to 40 blocks from the current +height, which still represents about 50 minutes at the revised 75-second target block +spacing. + +Changes for NU5 +--------------- + +As mentioned above, ``nExpiryHeight`` is ignored for coinbase transactions. However, from +NU5 activation [#zip-0252]_, the ``nExpiryHeight`` field of a coinbase transaction MUST +be set equal to the block height. Also, for coinbase transactions only, the bound of +499999999 on ``nExpiryHeight`` is removed. The motivation is to ensure that transaction +IDs remain unique, as explained in more detail in a note in Section 7.1 of the protocol +specification [#protocol-txnencodingandconsensus]_. Wallet behavior and UI ---------------------- @@ -126,3 +143,6 @@ References ========== .. [#zip-0201] `ZIP 201: Network Peer Management for Overwinter `_ +.. [#zip-0206] `ZIP 206: Deployment of the Blossom Network Upgrade `_ +.. [#zip-0252] `ZIP 252: Deployment of the NU5 Network Upgrade `_ +.. [#protocol-txnencodingandconsensus] `Zcash Protocol Specification, Version 2020.2.6. Section 7.1: Transaction Encoding and Consensus `_