diff options
author | dergoegge <n.goeggi@gmail.com> | 2024-01-19 15:09:28 +0000 |
---|---|---|
committer | dergoegge <n.goeggi@gmail.com> | 2024-02-27 14:19:15 +0000 |
commit | 66abce1d98115e41f394bc4f4f52341960ddc839 (patch) | |
tree | 80611efddb649953aee260eadb441e7acbfe11a7 /src/validation.h | |
parent | e7669e1343aec4298fd30d539847963e6fa5619c (diff) | |
download | bitcoin-66abce1d98115e41f394bc4f4f52341960ddc839.tar.xz |
[validation] Introduce IsBlockMutated
Diffstat (limited to 'src/validation.h')
-rw-r--r-- | src/validation.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/validation.h b/src/validation.h index fd9b53df8f..566153c150 100644 --- a/src/validation.h +++ b/src/validation.h @@ -383,6 +383,9 @@ bool TestBlockValidity(BlockValidationState& state, /** Check with the proof of work on each blockheader matches the value in nBits */ bool HasValidProofOfWork(const std::vector<CBlockHeader>& headers, const Consensus::Params& consensusParams); +/** Check if a block has been mutated (with respect to its merkle root and witness commitments). */ +bool IsBlockMutated(const CBlock& block, bool check_witness_root); + /** Return the sum of the work on a given set of headers */ arith_uint256 CalculateHeadersWork(const std::vector<CBlockHeader>& headers); |