HomePhabricator

Add a CHashWriter::GetSHA256() method to compute a single sha256

Description

Add a CHashWriter::GetSHA256() method to compute a single sha256

Summary:
This is a partial backport of core#19601

The unbackported part of the PR is currently only used by Bitcoin Core for Taproot related code, so I don't excpect we will need it. The backported method is needed in the MuHash3072 implementation.

The test vectors are from https://www.di-mgt.com.au/sha_testvectors.html

Test Plan: ninja all check-all

Reviewers: #bitcoin_abc, Fabien

Reviewed By: #bitcoin_abc, Fabien

Subscribers: Fabien

Differential Revision: https://reviews.bitcoinabc.org/D11149

Details

Provenance
Jeremy Rubin <j@rubin.io>Authored on Oct 7 2019, 20:45
PiRKCommitted on Mar 14 2022, 07:44
PiRKPushed on Mar 14 2022, 07:44
Reviewer
Restricted Project
Differential Revision
D11149: Add a CHashWriter::GetSHA256() method to compute a single sha256
Parents
rABCc5d495ce0325: [avalanche] Add a getavalancheinfo RPC for general status info
Branches
Unknown
Tags
Unknown