All vulnerabilities

npm

CVE-2026-85393

node-forge: RSA PKCS#1 v1.5 signature forgery via extra elements in nested DigestAlgorithm

Severity
High 7.5
Published
1 Dec 2026
Last changed
1 Dec 2026
Added to UpHeron
1 Dec 2026
Fixed in
1.4.1
Exploit chance
0.3% in the next 30 daysHigher than 20% of CVEs. EPSS by FIRST, 1 Dec 2026
Weakness
Improper verification of a cryptographic signature (CWE-347)
Attack
Over the network · No login needed · No user action needed
Attacker can
Change data
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N
Also known as
GHSA-2g46-22mc-6gwp
Sources
OSV.dev and GitHub

Description

RSASSA-PKCS1-v1_5 signature verification (publicKey.verify() with the default scheme, also used by X.509 certificate and PKCS#7 verification) ignored extra elements inside the nested DigestAlgorithm SEQUENCE of the DigestInfo. For RSA keys with a low public exponent (e=3) this allows signatures to be forged for an arbitrary message without the private key. This is an incomplete fix of CVE-2026-33894. Fixed in node-forge 1.4.1.

In lib/rsa.js, key.verify() with the default RSASSA-PKCS1-V1_5 scheme removes the padding, parses the recovered DigestInfo with asn1.fromDer() and checks it with asn1.validate() against digestInfoValidator. The fix for CVE-2026-33894 (GHSA-ppp5-5v6c-4jwp) added a check on the element count of the outer DigestInfo SEQUENCE only. asn1.validate() ignores extra children of the nested DigestAlgorithm SEQUENCE, so elements placed after the OID and NULL parameters were neither validated nor counted.

From the GitHub Advisory Database, CC BY 4.0. Shortened; the full text is there.

Workarounds

Do not use RSA keys with a low public exponent (e=3) for signature verification.

Workarounds as given by the GitHub Advisory Database, CC BY 4.0.

Affected software

SoftwareAffected versions
node-forgenpm · osv:npm:node-forge
  • Every version before 1.4.1

About node-forge

Weekly downloads (npm)
52,415,507npm, 1 Dec 2026

References