MCPcopy Create free account
hub / github.com/ElementsProject/elements / ComputeEntryRangeProof

Method ComputeEntryRangeProof

src/script/sigcache.cpp:75–78  ·  view source on GitHub ↗

ELEMENTS:

Source from the content-addressed store, hash-verified

73
74 // ELEMENTS:
75 void ComputeEntryRangeProof(uint256& entry, const std::vector<unsigned char>& proof, const std::vector<unsigned char>& commitment) {
76 CSHA256 hasher = m_salted_hasher_range_proof;
77 hasher.Write(proof.data(), proof.size()).Write(commitment.data(), commitment.size()).Finalize(entry.begin());
78 }
79 void ComputeEntrySurjectionProof(uint256& entry, const uint256 &hash, const std::vector<unsigned char>& proof, const std::vector<unsigned char>& commitment) {
80 CSHA256 hasher = m_salted_hasher_surjection_proof;
81 hasher.Write(hash.begin(), 32).Write(proof.data(), proof.size()).Write(commitment.data(), commitment.size()).Finalize(entry.begin());

Callers 1

VerifyRangeProofMethod · 0.80

Calls 5

FinalizeMethod · 0.45
WriteMethod · 0.45
dataMethod · 0.45
sizeMethod · 0.45
beginMethod · 0.45

Tested by

no test coverage detected