HomePhabricator

Merge #11516: crypto: Add test cases covering the relevant HMAC-SHA{256,512}…

Description

Merge #11516: crypto: Add test cases covering the relevant HMAC-SHA{256,512} key length boundaries

Summary:
a3f5657 Add test cases covering the relevant key length boundaries: 64 bytes +/- 1 byte for HMAC-SHA256 and 128 bytes +/- 1 byte for HMAC-SHA512 (practicalswift)

Pull request description:

  • Add test cases covering the relevant key length boundaries: 64 bytes +/- 1 byte for HMAC-SHA256 and 128 bytes +/- 1 byte for HMAC-SHA512.
  • Avoid creating a one-past-the-end pointer in the case of key length 64 (HMAC-SHA256) and key length 128 (HMAC-SHA512).
  • Avoid performing a noop memset call (zero length argument) in the case of key length 64 (HMAC-SHA256) and key length 128 (HMAC-SHA512).

Tree-SHA512: 48ff9ab79d41aab97b5b8f6496cc08a39955a07eb424f74ada6440d3b168b6204d3527fa677e175c47e40142f9d62c7456ae162e5a2f5b557e90fb353beef1d0

Backport of Core PR11516

https://github.com/bitcoin/bitcoin/pull/11516/files

Test Plan: make check

Reviewers: #bitcoin_abc, deadalnix

Reviewed By: #bitcoin_abc, deadalnix

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

Details

Provenance
jasonbcoxAuthored on Jun 28 2019, 19:31
jasonbcoxPushed on Jul 1 2019, 21:35
Reviewer
Restricted Project
Differential Revision
D3468: Merge #11516: crypto: Add test cases covering the relevant HMAC-SHA{256,512} key length boundaries
Parents
rSTAGING30fdbefb9de0: Merge #14556: qt: fix confirmed transaction labeled "open"
Branches
Unknown
Tags
Unknown