Bitcoin Core 28.99.0
P2P Digital Currency
|
#include <string>
#include <consensus/consensus.h>
#include <primitives/transaction.h>
#include <primitives/block.h>
Go to the source code of this file.
Classes | |
class | ValidationState< Result > |
Template for capturing information about block/transaction validation. More... | |
class | TxValidationState |
class | BlockValidationState |
Enumerations | |
enum class | TxValidationResult { TX_RESULT_UNSET = 0 , TX_CONSENSUS , TX_INPUTS_NOT_STANDARD , TX_NOT_STANDARD , TX_MISSING_INPUTS , TX_PREMATURE_SPEND , TX_WITNESS_MUTATED , TX_WITNESS_STRIPPED , TX_CONFLICT , TX_MEMPOOL_POLICY , TX_NO_MEMPOOL , TX_RECONSIDERABLE , TX_UNKNOWN } |
A "reason" why a transaction was invalid, suitable for determining whether the provider of the transaction should be banned/ignored/disconnected/etc. More... | |
enum class | BlockValidationResult { BLOCK_RESULT_UNSET = 0 , BLOCK_CONSENSUS , BLOCK_CACHED_INVALID , BLOCK_INVALID_HEADER , BLOCK_MUTATED , BLOCK_MISSING_PREV , BLOCK_INVALID_PREV , BLOCK_TIME_FUTURE , BLOCK_CHECKPOINT , BLOCK_HEADER_LOW_WORK } |
A "reason" why a block was invalid, suitable for determining whether the provider of the block should be banned/ignored/disconnected/etc. More... | |
Functions | |
static int32_t | GetTransactionWeight (const CTransaction &tx) |
static int64_t | GetBlockWeight (const CBlock &block) |
static int64_t | GetTransactionInputWeight (const CTxIn &txin) |
int | GetWitnessCommitmentIndex (const CBlock &block) |
Compute at which vout of the block's coinbase transaction the witness commitment occurs, or -1 if not found. More... | |
Variables | |
static constexpr int | NO_WITNESS_COMMITMENT {-1} |
Index marker for when no witness commitment is present in a coinbase transaction. More... | |
static constexpr size_t | MINIMUM_WITNESS_COMMITMENT {38} |
Minimum size of a witness commitment structure. More... | |
|
strong |
A "reason" why a block was invalid, suitable for determining whether the provider of the block should be banned/ignored/disconnected/etc.
These are much more granular than the rejection codes, which may be more useful for some other use-cases.
Definition at line 57 of file validation.h.
|
strong |
A "reason" why a transaction was invalid, suitable for determining whether the provider of the transaction should be banned/ignored/disconnected/etc.
Definition at line 23 of file validation.h.
|
inlinestatic |
Definition at line 137 of file validation.h.
|
inlinestatic |
Definition at line 141 of file validation.h.
|
inlinestatic |
Definition at line 133 of file validation.h.
|
inline |
Compute at which vout of the block's coinbase transaction the witness commitment occurs, or -1 if not found.
Definition at line 148 of file validation.h.
|
staticconstexpr |
Minimum size of a witness commitment structure.
Defined in BIP 141.
Definition at line 18 of file validation.h.
|
staticconstexpr |
Index marker for when no witness commitment is present in a coinbase transaction.
Definition at line 15 of file validation.h.