Avoid weak hash algorithm from CryptoJS
이 페이지는 아직 한국어로 제공되지 않습니다. 번역 작업 중입니다.
현재 번역 프로젝트에 대한 질문이나 피드백이 있으신 경우
언제든지 연락주시기 바랍니다.ID: typescript-node-security/crypto-avoid-weak-hash
Language: TypeScript
Severity: Warning
Category: Security
CWE: 328
Related CWEs:
Description
Use of insecure hash functions like MD5 or SHA1 can expose your application to vulnerabilities.
Learn More
Non-Compliant Code Examples
const hash = CryptoJS.MD5("Message", "Secret Passphrase");
const hash = CryptoJS.SHA1("Message", "Secret Passphrase");
const hash = CryptoJS.HmacMD5("Message", "Secret Passphrase");
Compliant Code Examples
// Safe: using SHA256 instead of MD5/SHA1
const hash = CryptoJS.SHA256("Message");
const hmac = CryptoJS.HmacSHA256("Message", "Secret Passphrase");
원활한 통합. Datadog Code Security 사용해 보기