CVE-2026-63576: URI name constraints checked against a mis-parsed host
Improper certificate validation in PkixNameConstraintValidator (ExtractHostFromURL) in Legion of the Bouncy Castle Inc. bc-csharp before 2.7.0 allows a name-constrained subordinate CA, or anyone able to obtain certificates with chosen subjectAltName URIs from such a CA, to bypass permitted or excluded uniformResourceIdentifier name constraints during certification path validation via a URI whose path, query, fragment or userinfo contains characters such as '@' or ':', because the host was extracted by string slicing without first isolating the RFC 3986 authority component, so the host compared against the constraints could differ from the URI's actual host.
Affected Software
Remediation
Patch Available
Event History
Frequently Asked Questions
Which deployments are exposed to this issue?
bc-csharp versions before 2.7.0 are affected where certification path validation enforces permitted or excluded uniformResourceIdentifier name constraints. The issue is relevant when validating certificates issued beneath a name-constrained subordinate CA.
What must an attacker be able to do to exploit the bypass?
An attacker must control a name-constrained subordinate CA or be able to obtain certificates with attacker-chosen subjectAltName URI values from such a CA. They can use URI path, query, fragment, or userinfo content containing characters such as '@' or ':' to cause the constrained host comparison to differ from the URI's actual host.
What is the practical impact of successful exploitation?
A certificate can bypass permitted or excluded URI name constraints during certification path validation. This can allow a URI whose actual host is outside the intended constraint to be accepted.
How can I remediate the issue?
Upgrade bc-csharp to version 2.7.0 or later. The affected behavior is present in versions before 2.7.0.