Expand description
Consensus parameters for each Zcash network.
This module contains the consensus parameters which are required for parsing.
Some consensus parameters change based on network upgrades. Each network upgrade happens at a particular block height. Some parameters have a value (or function) before the upgrade height, at the upgrade height, and after the upgrade height. (For example, the value of the reserved field in the block header during the Heartwood upgrade.)
Typically, consensus parameters are accessed via a function that takes a
Network
and block::Height
.
Modules§
- arbitrary
- Arbitrary implementations for network parameters
- constants
- Definitions of Zebra chain constants, including:
- genesis 🔒
- Genesis consensus parameters for each Zcash network.
- network 🔒
- Consensus parameters for each Zcash network.
- network_
upgrade 🔒 - Network upgrade consensus parameters for Zcash.
- subsidy
- Constants and calculations for Block Subsidy and Funding Streams
- testnet
- Types and implementation for Testnet consensus parameters
- transaction 🔒
- Transaction consensus and utility parameters.
Structs§
- Consensus
Branch Id - The Consensus Branch Id, used to bind transactions and blocks to a particular network upgrade.
- Magic
- A magic number identifying the network.
Enums§
- Network
- An enum describing the possible network choices.
- Network
Kind - An enum describing the kind of network, whether it’s the production mainnet or a testnet.
- Network
Upgrade - A Zcash network upgrade.
Constants§
- GENESIS_
PREVIOUS_ BLOCK_ HASH - The previous block hash for the genesis block.
- OVERWINTER_
VERSION_ GROUP_ ID - The version group ID for Overwinter transactions.
- POST_
BLOSSOM_ POW_ TARGET_ SPACING - The target block spacing after Blossom activation.
- POW_
AVERAGING_ WINDOW - The averaging window for difficulty threshold arithmetic mean calculations.
- SAPLING_
VERSION_ GROUP_ ID - The version group ID for Sapling transactions.
- TESTNET_
MAX_ TIME_ START_ HEIGHT - The activation height for the block maximum time rule on Testnet.
- TX_
V5_ VERSION_ GROUP_ ID - The version group ID for version 5 transactions.
- TX_
V6_ VERSION_ GROUP_ ID - The version group ID for version 6 transactions. TODO: update this after it’s chosen