Add sm3{,-yescrypt} backend and tests. #206
All Vouch review confidence checks passed
Residual risk 0.16 = Change Risk (0.72) × (1 − Review Confidence (0.77)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.72 · 3033 lines diff across 39 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.56 · 2 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 50%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.400
Mass File Touch
mass_file_touch
0.080
Real PR Conversation Timeline
2 comments
doc/crypt.5
"I think we should use the `Acceptable for new hashes where required.` wording also for `sm3crypt`, do not omit the ` where required` part here."
clarifying
weight: 0.45
doc/crypt.5
"Thanks for the feedback! Fixed in rebased commit."
clarifying
weight: 0.45
solardiz
besser82
These hashing methods are useful in applications that need modern password hashing methods, but require to rely on cryptographic properties that have been approved by the Chinese Office of State Commercial Cryptography Administration (OSCCA).
ShangMi 3 is a cryptographic hash function used in the Chinese National Standard. It was published by the National Cryptography Administration (Chinese: 国家密码管理局) on 2010-12-17 as "GM/T 0004-2012: SM3 cryptographic hash algorithm".
SM3 is used for implementing digital signatures, message authentication codes, and pseudorandom number generators. The algorithm is public and is considered similar to SHA-256 in security and efficiency. SM3 is also used with Transport Layer Security.
SM3 is defined in each of:
GM/T 0004-2012: SM3 cryptographic hash algorithm
GB/T 32905-2016: Information security techniques SM3 cryptographic hash algorithm
ISO/IEC 10118-3:2018: IT Security techniques—Hash-functions, Part 3: Dedicated hash-functions
IETF RFC draft-sca-cfrg-sm3-02
See: https://datatracker.ietf.org/doc/html/draft-sca-cfrg-sm3
sm3crypt is currently in active use by the EulerOS, Kylin, openEuler, and openKylin distributions.
The additionally - in hope of adaption by the afore mentioned distributions - implemented sm3-yescrypt uses the output from the yescrypt hashing method in place of a hmac message. Thus, the yescrypt crypto properties are superseeded by the ShangMi 3 hash function with a 256 bit digest.
Fixes #188.