Skip to main content
EPSS 0.2%top 95%

CVE-2026-71889: CWE-295 Improper Certificate Validation in Legion of the Bouncy Castle Inc. BC-JAVA

0
High
VulnerabilityCVE-2026-71889cvecve-2026-71889cwe-295
Published: 10/03/2026 (10/03/2026, 08:31:01 UTC)
Source: CVE Database V5
Vendor/Project: Legion of the Bouncy Castle Inc.
Product: BC-JAVA

Description

In Bouncy Castle for Java before 1.86, neither copy of PKIXCertPathReviewer - org.bouncycastle.pkix.jcajce.PKIXCertPathReviewer nor the legacy org.bouncycastle.x509.PKIXCertPathReviewer - applied X.509 name constraints to the end-entity certificate. checkNameConstraints walked the path with a loop bound of index greater than zero, which is the bound the CA-only steps require, but index zero is the target certificate under the standard CertPath ordering, so the permitted and excluded subtree checks of RFC 5280 sec. 6.1.3 (b) and (c) never ran against the leaf's subject DN or its subjectAltName. A chain whose leaf violated a NameConstraints extension imposed by its own issuing CA therefore reported isValidCertPath() true with an empty error list, while CertPathValidator.getInstance("PKIX", "BC"), which shares no code with the reviewer, rejected the identical chain against the identical trust anchor. An application using the reviewer to make the trust decision rather than for diagnostics alongside a real validation accepted a certificate the constrained CA was never authorised to issue. Both copies now check every certificate in the path including the target, waive the sec. 4.2.1.10 self-issued exemption for the final certificate as sec. 6.1.3 requires, and skip the sec. 6.1.4 (g) constraint-accumulation step for the target. This issue also affects Bouncy Castle for Java LTS before 2.73.13, which carries only the org.bouncycastle.pkix.jcajce copy of the reviewer. It also affects Bouncy Castle for Java FIPS (BC-FJA) before bcpkix-fips 1.0.13 (1.0.X series), 2.0.13 (2.0.X series) and 2.1.13 (2.1.X series).

CVSS v4.0

Score 8.7high

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
None
Vuln. Confidentiality
None
Vuln. Integrity
High
Vuln. Availability
None
Subsq. Confidentiality
None
Subsq. Integrity
None
Subsq. Availability
None
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N/U:Amber

Affected software

Legion of the Bouncy Castle Inc.

BC-JAVA

Affected versions
>=0 <1.86

Legion of the Bouncy Castle Inc.

BC-LTS-JAVA

Affected versions
>=2.73.0 <2.73.13

Legion of the Bouncy Castle Inc.

BC-FJA

Affected versions
>=1.0.4 <1.0.13>=2.0.0 <2.0.13>=2.1.0 <2.1.13
GitHub Actionsmore threats →cve
bcpkix
pkg:github/bcpkix
Affected versions
>=0 <1.86
GitHub Actionsmore threats →cve
bcprov
pkg:github/bcprov
Affected versions
>=0 <1.86
GitHub Actionsmore threats →cve
bcpkix-lts8on
pkg:github/bcpkix-lts8on
Affected versions
>=2.73.0 <2.73.13

Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 10/03/2026, 09:01:02 UTC

Technical Analysis

The vulnerability in BC-JAVA before version 1.86 and specific LTS and FIPS versions stems from the PKIXCertPathReviewer classes not applying X.509 name constraints to the leaf certificate in a certificate chain. The checkNameConstraints method iterated over the certificate path starting from index greater than zero, skipping the leaf certificate at index zero, thus omitting permitted and excluded subtree checks mandated by RFC 5280 section 6.1.3 (b) and (c). Consequently, certificate chains with leaf certificates violating name constraints were incorrectly validated as valid by the reviewer, although the standard CertPathValidator rejected them. The fix involves updating the reviewer to check every certificate including the leaf, properly applying the constraints and exemptions as per RFC 5280 requirements.

Potential Impact

Applications relying solely on the PKIXCertPathReviewer for trust decisions could accept certificates that violate name constraints imposed by their issuing CAs, potentially allowing unauthorized certificates to be trusted. This undermines the integrity of certificate validation and could lead to security breaches where constrained CAs issue certificates outside their authorized scope. However, the standard CertPathValidator implementation was not affected and correctly rejected such invalid chains.

Mitigation Recommendations

A fix is available in BC-JAVA version 1.86 and later, as well as in LTS version 2.73.13 and FIPS versions bcpkix-fips 1.0.13, 2.0.13, and 2.1.13. Users should upgrade to these fixed versions to ensure proper name constraint validation. Until upgraded, applications should avoid using PKIXCertPathReviewer alone for trust decisions and instead rely on the standard CertPathValidator for certificate path validation.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Data Version
5.2
Assigner Short Name
bcorg
Date Reserved
2026-08-08T00:06:07.401Z
Cvss Version
4.0
State
PUBLISHED

Threat ID: 6ac0c0f9a43b0b3b89b059bb

Added to database: 10/03/2026, 08:46:49 UTC

Last enriched: 10/03/2026, 09:01:02 UTC

Last updated: 10/04/2026, 04:45:56 UTC

Views: 16

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses