Medium severityJavaScript / TypeScriptCryptographyHIGH confidence
Weak Hash Algorithm
MD5/SHA-1 are cryptographically broken and unsuitable for security (integrity, signatures, password storage).
Standards mapping
- OWASP Top 10
- A02:2021 - Cryptographic Failures
- OWASP ASVS
- V6.2.1 (L2)
Vulnerable vs. safe
Flagged by this check
const md5Digest = crypto.createHash("md5").update(data).digest("hex");Passes - the safe pattern
const sha256Digest = crypto.createHash("sha256").update(data).digest("hex");Why it matters & how to fix it
MD5/SHA-1 are cryptographically broken and unsuitable for security (integrity, signatures, password storage). Use SHA-256/SHA-3 for hashing, or a dedicated password hash (bcrypt/scrypt/argon2) for credentials.
References
Rule ID integsec-js-weak-hash-algorithm - engine: Opengrep - license: MIT - Copyright (c) IntegSec Inc.
TurboPentest runs this check automatically
Connect a GitHub repo and this check runs on every white-box pentest - AI-validated and reported with proof, from $99 per target.
Start a pentest