Security Vulnerability Report
中文
CVE-2026-4599 CVSS 9.1 CRITICAL

CVE-2026-4599

Published: 2026-03-23 06:16:22
Last Modified: 2026-03-23 16:17:45

Description

Versions of the package jsrsasign from 7.0.0 and before 11.1.1 are vulnerable to Incomplete Comparison with Missing Factors via the getRandomBigIntegerZeroToMax and getRandomBigIntegerMinToMax functions in src/crypto-1.1.js; an attacker can recover the private key by exploiting the incorrect compareTo checks that accept out-of-range candidates and thus bias DSA nonces during signature generation.

CVSS Details

CVSS Score
9.1
Severity
CRITICAL
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N

Configurations (Affected Products)

cpe:2.3:a:jsrsasign_project:jsrsasign:*:*:*:*:*:node.js:*:* - VULNERABLE
jsrsasign >= 7.0.0, < 11.1.1

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
// Conceptual PoC demonstrating the logic flaw in range checking // This simulates the vulnerable behavior where out-of-range values are accepted. const BigInteger = require('jsrsasign').BigInteger; function vulnerableGetRandom(max) { let candidate; let attempts = 0; do { // Simulate random byte generation candidate = new BigInteger(max.bitLength(), new SecureRandom()); attempts++; // VULNERABLE: Incomplete comparison logic // The actual bug allowed candidates that were technically out of bounds // due to missing checks on specific factors or incorrect comparison logic. // The fix ensures compareTo is strictly less than max. } while (candidate.compareTo(max) >= 0 && attempts < 1000); // Simplified return candidate; } // Note: A full exploit would require collecting many signatures to perform lattice reduction. // This code illustrates the source of the bias in the random number generation.

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2026-4599", "sourceIdentifier": "[email protected]", "published": "2026-03-23T06:16:21.513", "lastModified": "2026-03-23T16:17:45.400", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "Versions of the package jsrsasign from 7.0.0 and before 11.1.1 are vulnerable to Incomplete Comparison with Missing Factors via the getRandomBigIntegerZeroToMax and getRandomBigIntegerMinToMax functions in src/crypto-1.1.js; an attacker can recover the private key by exploiting the incorrect compareTo checks that accept out-of-range candidates and thus bias DSA nonces during signature generation."}, {"lang": "es", "value": "Versiones del paquete jsrsasign desde la 7.0.0 y hasta la 11.1.1 son vulnerables a Comparación Incompleta con Factores Faltantes a través de las funciones getRandomBigIntegerZeroToMax y getRandomBigIntegerMinToMax en src/crypto-1.1.js; un atacante puede recuperar la clave privada explotando las comprobaciones compareTo incorrectas que aceptan candidatos fuera de rango y, por lo tanto, sesgan los nonces DSA durante la generación de firmas."}], "metrics": {"cvssMetricV40": [{"source": "[email protected]", "type": "Secondary", "cvssData": {"version": "4.0", "vectorString": "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X", "baseScore": 9.3, "baseSeverity": "CRITICAL", "attackVector": "NETWORK", "attackComplexity": "LOW", "attackRequirements": "NONE", "privilegesRequired": "NONE", "userInteraction": "NONE", "vulnConfidentialityImpact": "HIGH", "vulnIntegrityImpact": "HIGH", "vulnAvailabilityImpact": "NONE", "subConfidentialityImpact": "NONE", "subIntegrityImpact": "NONE", "subAvailabilityImpact": "NONE", "exploitMaturity": "NOT_DEFINED", "confidentialityRequirement": "NOT_DEFINED", "integrityRequirement": "NOT_DEFINED", "availabilityRequirement": "NOT_DEFINED", "modifiedAttackVector": "NOT_DEFINED", "modifiedAttackComplexity": "NOT_DEFINED", "modifiedAttackRequirements": "NOT_DEFINED", "modifiedPrivilegesRequired": "NOT_DEFINED", "modifiedUserInteraction": "NOT_DEFINED", "modifiedVulnConfidentialityImpact": "NOT_DEFINED", "modifiedVulnIntegrityImpact": "NOT_DEFINED", "modifiedVulnAvailabilityImpact": "NOT_DEFINED", "modifiedSubConfidentialityImpact": "NOT_DEFINED", "modifiedSubIntegrityImpact": "NOT_DEFINED", "modifiedSubAvailabilityImpact": "NOT_DEFINED", "Safety": "NOT_DEFINED", "Automatable": "NOT_DEFINED", "Recovery": "NOT_DEFINED", "valueDensity": "NOT_DEFINED", "vulnerabilityResponseEffort": "NOT_DEFINED", "providerUrgency": "NOT_DEFINED"}}], "cvssMetricV31": [{"source": "[email protected]", "type": "Secondary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N", "baseScore": 9.1, "baseSeverity": "CRITICAL", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "NONE", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "HIGH", "integrityImpact": "HIGH", "availabilityImpact": "NONE"}, "exploitabilityScore": 3.9, "impactScore": 5.2}]}, "weaknesses": [{"source": "[email protected]", "type": "Secondary", "description": [{"lang": "en", "value": "CWE-1023"}]}], "configurations": [{"nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:a:jsrsasign_project:jsrsasign:*:*:*:*:*:node.js:*:*", "versionStartIncluding": "7.0.0", "versionEndExcluding": "11.1.1", "matchCriteriaId": "84D23509-C02E-4150-B186-0DCDD05DA887"}]}]}], "references": [{"url": "https://gist.github.com/Kr0emer/081681818b51605c91945126d74b4f20", "source": "[email protected]", "tags": ["Exploit", "Mitigation", "Third Party Advisory"]}, {"url": "https://github.com/kjur/jsrsasign/commit/ee4b013478366cb16cea9a4bdfb218b6077f83b1", "source": "[email protected]", "tags": ["Patch"]}, {"url": "https://github.com/kjur/jsrsasign/pull/647", "source": "[email protected]", "tags": ["Issue Tracking"]}, {"url": "https://security.snyk.io/vuln/SNYK-JS-JSRSASIGN-15370939", "source": "[email protected]", "tags": ["Third Party Advisory"]}]}}