GitHub Advisoryadvisory · npm
GHSA-xxxq-chmp-67g4 RSA PKCS#1 decryption vulnerability with prepending zeros in jsrsasign
CRITICAL
Official page ↗
- Aliases
- CVE-2020-14967
- Ecosystem
- npm
- Packages
- jsrsasign
- Severity
- Critical
- CVSS vector
- CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
- Weaknesses
- CWE-119
- Reviewed
- 2020-06-26
Affected packages
• npm jsrsasign: < 8.0.18 → fixed in 8.0.18
Description
Impact
Jsrsasign supports RSA PKCS#1 v1.5 (i.e. RSAES-PKCS1-v1_5) and RSA-OAEP encryption and decryption. Its encrypted message is represented as BigInteger. When there is a valid encrypted message, a crafted message with prepending zeros can be decrypted by this vulnerability.
• If you don't use RSA PKCS1-v1_5 or RSA-OAEP decryption, this vulnerability is not affected.
• Risk to forge contents of encrypted message is very low.
• Risk to raise memory corruption is low since jsrsasign uses BigInteger class.
Patches
Users using RSA PKCS1-v1_5 or RSA-OAEP decryption should upgrade to 8.0.18.
Workarounds
Reject RSA PKCS1-v1_5 or RSA-OAEP encrypted message with unnecessary prepending zeros.
References
https://nvd.nist.gov/vuln/detail/CVE-2020-14967
https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2020-14967
https://vuldb.com/?id.157124
https://kjur.github.io/jsrsasign/api/symbols/KJUR.crypto.Cipher.html#.decrypt
https://github.com/kjur/jsrsasign/issues/439
Related
Alias · CVE (1)
- CVE-2020-14967 An issue was discovered in the jsrsasign package before 8.0.18 for Node.js. vulnerability
Weakness · CWE (1)
- CWE-119 Improper Restriction of Operations within the Bounds of a Memory Buffer weakness
References
- https://github.com/kjur/jsrsasign/security/advisories/GHSA-xxxq-chmp-67g4 web
- https://nvd.nist.gov/vuln/detail/CVE-2020-14967 advisory
- https://github.com/kjur/jsrsasign/issues/439 web
- https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2020-14967 web
- https://github.com/kjur/jsrsasign package
- https://github.com/kjur/jsrsasign/releases/tag/8.0.17 web
- https://github.com/kjur/jsrsasign/releases/tag/8.0.18 web
- https://kjur.github.io/jsrsasign web
- https://kjur.github.io/jsrsasign/api/symbols/KJUR.crypto.Cipher.html#.decrypt web
- https://security.netapp.com/advisory/ntap-20200724-0001 web
- https://vuldb.com/?id.157124 web
- https://www.npmjs.com/package/jsrsasign web