CVE-2026-140099: Forge: RSA multi-prime private keys are read as two-prime keys, and signatures leak a factor of the modulus
pki.privateKeyFromPem() and pki.privateKeyFromAsn1() ignore the RSAPrivateKey version and the otherPrimeInfos field, so a multi-prime RSA key is read with only its first two primes. Signatures made with such a key are invalid, and each one reveals a factor of the modulus to anyone who sees it. Fixed in node-forge 1.4.4.
References
- github.com/advisories/GHSA-w73w-hhm4-q25p
- github.com/digitalbazaar/forge/commit/8d1a7bc8ad514e70f85bf5cbe4c60cd52916fdef
- github.com/digitalbazaar/forge/issues/1143
- github.com/digitalbazaar/forge/releases/tag/v1.4.4
- github.com/digitalbazaar/forge/security/advisories/GHSA-w73w-hhm4-q25p
- nvd.nist.gov/vuln/detail/CVE-2026-140099
Code Behaviors & Features
Detect and mitigate CVE-2026-140099 with GitLab Dependency Scanning
Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Dependency Scanning using SBOM also detects vulnerabilities from proprietary advisories that this site does not include. Learn more about Dependency Scanning using SBOM →