ZIP 244 changes how txids are derived (for v5 txs onward), to enable committing to the _effects_ of a transaction separately from its specific contents (as auth data can be malleated, e.g. re-signing a transaction). The places where `zcashd` assumes a `txid` has this effect-committing property, don't need to be changed. However, `zcashd` _also_ assumes a `txid` has an instance-committing property in other places, such as for mempool DoS prevention, as well as potentially other places inherited from `bitcoind`. If these use txids for v5 transactions, there is a user DoS problem: - User submits a valid v5 transaction to the network. - An adversary manipulates the authorizing data for the in-flight transaction, making it invalid. - `zcashd` nodes reject the transaction as invalid, and add its `txid` to the recently-rejected list. - The user cannot resubmit their transaction because its txid is blocked. Upstream had a similar problem for SegWit transactions, which they addressed four years after deploying SegWit by adding P2P support for relaying transactions via `wtxid` ([BIP 339](https://github.com/bitcoin/bips/blob/master/bip-0339.mediawiki), [impl](https://github.com/bitcoin/bitcoin/pull/18044)). This works because `wtxid` is a commitment to a Bitcoin SegWit transaction _instance_, including effecting data. In our case, we opted in ZIP 244 to instead have an `auth_digest` that commits to just the authorizing data of a transaction. The tuple `(txid, auth_digest)` is our equivalent of Bitcoin's `wtxid`. We should use this tuple wherever we need to reference a transaction instance. --- For the P2P changes, see #5199. This issue is for identifying and fixing code internal to `zcashd` that needs to be updated: - [ ] `CTxMempool::IsRecentlyEvicted`