PQC Weak Key Length (Symmetric/Hash Strength Below the Post-Quantum Baseline)
ID |
go.pqc_weak_keylength |
Severity |
info |
Remediation Complexity |
low |
Remediation Risk |
low |
Remediation Effort |
low |
Resource |
Cryptography |
Language |
Go |
Tags |
ASVS50:v11.3.1, ASVS50:v11.3.2, ASVS50:v11.3.3, ASVS50:v11.3.4, ASVS50:v11.3.5, ASVS50:v12.1.1, ASVS50:v12.1.2, CWE:326, NIST.IR.8547, OWASP:2025:A04, crypto, pqc, quantum |
Description
Flags symmetric ciphers and hash functions whose key or digest size is adequate against a classical
attacker today but below the post-quantum baseline. This is the Grover axis of post-quantum
readiness, distinct from pqc_readiness (the Shor axis — public-key algorithms that no key-size
increase can save) and from insufficient_key_size (sizes that are already weak against classical
attackers).
Rationale
Grover’s algorithm gives a quadratic speed-up to brute-force search, halving the effective security of a symmetric key: AES-128 drops to ~64-bit effective strength, and a hash’s preimage resistance is similarly reduced. Such algorithms are perfectly safe against today’s classical computers but are not post-quantum ready. NSA’s CNSA 2.0 suite and NIST guidance therefore require AES-256 for symmetric encryption and SHA-384 / SHA-512 (or SHA3-384+) for hashing.
Only algorithms that are classically acceptable today are reported here; classically broken or deprecated primitives (DES, RC4, MD5, SHA-1) are reported by the weak-cipher / weak-hash detectors so the same usage is not flagged twice with conflicting advice. For symmetric ciphers, a finding requires an explicitly stated key size so a bare family reference sized elsewhere is not falsely flagged.
The post-quantum baselines are configurable via the minPqcStrength property (e.g. symmetric/256,
hash/384) so the thresholds can be adapted to an organization’s own standard.
In Go, the algorithm is named at the crypto/* package; a SHA-256 digest is fine today but not
post-quantum ready, whereas SHA-384/512 are:
sha256.New() // below the PQC baseline (Grover) — use SHA-384/512
sha512.New() // post-quantum ready
Remediation
Raise the parameter to the post-quantum baseline: use AES-256 for symmetric encryption and SHA-384 / SHA-512 (or SHA3-384+) for hashing. Unlike public-key algorithms on the Shor axis, no migration to a new algorithm family is required — the existing primitive is hardened in place by doubling its size.
References
-
CWE-326 : Inadequate Encryption Strength.
-
NSA CNSA 2.0 : Commercial National Security Algorithm Suite 2.0.
-
NIST IR 8547 : Transition to Post-Quantum Cryptography Standards.
-
NISTIR 8105 : Report on Post-Quantum Cryptography.