Bitcoin Core  0.20.99
P2P Digital Currency
Functions | Variables
signet.cpp File Reference
#include <signet.h>
#include <array>
#include <cstdint>
#include <vector>
#include <consensus/merkle.h>
#include <consensus/params.h>
#include <consensus/validation.h>
#include <core_io.h>
#include <hash.h>
#include <primitives/block.h>
#include <primitives/transaction.h>
#include <span.h>
#include <script/interpreter.h>
#include <script/standard.h>
#include <streams.h>
#include <util/strencodings.h>
#include <util/system.h>
#include <uint256.h>
Include dependency graph for signet.cpp:

Go to the source code of this file.

Functions

static bool FetchAndClearCommitmentSection (const Span< const uint8_t > header, CScript &witness_commitment, std::vector< uint8_t > &result)
 
static uint256 ComputeModifiedMerkleRoot (const CMutableTransaction &cb, const CBlock &block)
 
bool CheckSignetBlockSolution (const CBlock &block, const Consensus::Params &consensusParams)
 Extract signature and check whether a block has a valid solution. More...
 

Variables

static constexpr uint8_t SIGNET_HEADER [4] = {0xec, 0xc7, 0xda, 0xa2}
 
static constexpr unsigned int BLOCK_SCRIPT_VERIFY_FLAGS = SCRIPT_VERIFY_P2SH | SCRIPT_VERIFY_WITNESS | SCRIPT_VERIFY_DERSIG | SCRIPT_VERIFY_NULLDUMMY
 

Function Documentation

◆ CheckSignetBlockSolution()

bool CheckSignetBlockSolution ( const CBlock block,
const Consensus::Params consensusParams 
)

Extract signature and check whether a block has a valid solution.

Definition at line 124 of file signet.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ComputeModifiedMerkleRoot()

static uint256 ComputeModifiedMerkleRoot ( const CMutableTransaction cb,
const CBlock block 
)
static

Definition at line 57 of file signet.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FetchAndClearCommitmentSection()

static bool FetchAndClearCommitmentSection ( const Span< const uint8_t >  header,
CScript witness_commitment,
std::vector< uint8_t > &  result 
)
static

Definition at line 30 of file signet.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ BLOCK_SCRIPT_VERIFY_FLAGS

constexpr unsigned int BLOCK_SCRIPT_VERIFY_FLAGS = SCRIPT_VERIFY_P2SH | SCRIPT_VERIFY_WITNESS | SCRIPT_VERIFY_DERSIG | SCRIPT_VERIFY_NULLDUMMY
static

Definition at line 28 of file signet.cpp.

◆ SIGNET_HEADER

constexpr uint8_t SIGNET_HEADER[4] = {0xec, 0xc7, 0xda, 0xa2}
static

Definition at line 26 of file signet.cpp.