-
Notifications
You must be signed in to change notification settings - Fork 1k
Fix TSP message imprint algorithm/digest length consistency #11153
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -325,6 +325,20 @@ enum wc_HashType wc_OidGetHash(int oid) | |
| hash_type = WC_ERR_TRACE(WC_HASH_TYPE_NONE); | ||
| #endif | ||
| break; | ||
| case SHA512_224h: | ||
| #if defined(WOLFSSL_SHA512) && !defined(WOLFSSL_NOSHA512_224) | ||
|
yosuke-wolfssl marked this conversation as resolved.
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🔵 [Low] New wc_OidGetHash() SHA-512/224 and SHA-512/256 cases use guards that do not match wc_HashGetDigestSize() · Preprocessor-conditional security bypass
Fix: Add There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🔵 [Low] New wc_OidGetHash SHA-512/224 and SHA-512/256 cases omit the FIPS/SELFTEST guard used by the rest of hash.c · Copy-paste errors The two new cases guard only on Fix: Add |
||
| hash_type = WC_HASH_TYPE_SHA512_224; | ||
| #else | ||
| hash_type = WC_ERR_TRACE(WC_HASH_TYPE_NONE); | ||
| #endif | ||
| break; | ||
| case SHA512_256h: | ||
| #if defined(WOLFSSL_SHA512) && !defined(WOLFSSL_NOSHA512_256) | ||
| hash_type = WC_HASH_TYPE_SHA512_256; | ||
| #else | ||
| hash_type = WC_ERR_TRACE(WC_HASH_TYPE_NONE); | ||
| #endif | ||
| break; | ||
| case SHA3_224h: | ||
| #ifdef WOLFSSL_SHA3 | ||
| hash_type = WC_HASH_TYPE_SHA3_224; | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.