REDHAT-BUG-2452458: High severity npm/node-forge vulnerability
Forge (also called node-forge) is a native implementation of Transport Layer Security in JavaScript. Prior to version 1.4.0, pki.verifyCertificateChain() does not enforce RFC 5280 basicConstraints requirements when an intermediate certificate lacks both the basicConstraints and keyUsage extensions. This allows any leaf certificate (without these extensions) to act as a CA and sign other certificates, which node-forge will accept as valid. Version 1.4.0 patches the issue.
Affected Software
Event History
Frequently Asked Questions
What certificate-chain condition is required for exploitation?
An intermediate certificate must lack both the basicConstraints and keyUsage extensions. In affected versions, node-forge can then accept a leaf certificate without these extensions as a CA capable of signing additional certificates.
Which versions address this issue?
Version 1.4.0 patches the issue. Versions prior to 1.4.0 are described as not enforcing the relevant RFC 5280 basicConstraints requirements.