TxValidationResult

A "reason" why a transaction was invalid, suitable for determining whether the provider of the transaction should be banned/ignored/disconnected/etc.

Synopsis

Declared in <consensus/validation.h>

enum class TxValidationResult : int;

Members

NameDescription
TX_RESULT_UNSET initial value. Tx has not yet been rejected
TX_CONSENSUS invalid by consensus rules
TX_INPUTS_NOT_STANDARD inputs (covered by txid) failed policy rules
TX_NOT_STANDARD otherwise didn't meet our local policy rules
TX_MISSING_INPUTS transaction was missing some of its inputs
TX_PREMATURE_SPEND transaction spends a coinbase too early, or violates locktime/sequence locks
TX_WITNESS_MUTATED Transaction might have a witness prior to SegWit activation, or witness may have been malleated (which includes non-standard witnesses).
TX_WITNESS_STRIPPED Transaction is missing a witness.
TX_CONFLICT Tx already in mempool or conflicts with a tx in the chain (if it conflicts with another tx in mempool, we use MEMPOOL_POLICY as it failed to reach the RBF threshold) Currently this is only used if the transaction already exists in the mempool or on chain.
TX_MEMPOOL_POLICY violated mempool's fee/size/descendant/RBF/etc limits
TX_NO_MEMPOOL this node does not have a mempool so can't validate the transaction
TX_RECONSIDERABLE fails some policy, but might be acceptable if submitted in a (different) package
TX_UNKNOWN transaction was not validated because package failed