Executive brief
jsrsasign is a popular JavaScript library used for cryptography, including the creation and verification of digital signatures and security certificates. A flaw in how the library handles certain digital signature parameters allows an attacker to create fake signatures or certificates that appear valid. This could allow an attacker to impersonate trusted services, bypass security checks, or provide fraudulent data that the system incorrectly trusts as authentic.
Technical details
The jsrsasign library (versions prior to 11.1.1) fails to properly validate DSA domain parameters within the 'KJUR.crypto.DSA.setPublic' function and related X.509 verification flows. By supplying specifically crafted, invalid domain parameters (such as g=1, y=1, and r=1), an attacker can satisfy the cryptographic verification equation regardless of the actual message hash. This allows for universal signature forgery and the creation of fraudulent X.509 certificates that 'X509.verifySignature()' will incorrectly accept as valid. The fix, introduced in version 11.1.1, implements strict validation of domain parameters (p, q, g, and y) during the public key import process.
Affected products
- kjur jsrsasign < 11.1.1
Timeline
- 2026-02-20: patched: Fix merged into master branch via PR #646
- 2026-03-23: advisory: GitHub Advisory and NVD entry published