Summary
Envoy’s mTLS certificate matcher for match_typed_subject_alt_names may incorrectly treat certificates containing an embedded null byte (\0) inside an OTHERNAME SAN value as valid matches.
Details
This occurs when the SAN is encoded as a BMPSTRING or UNIVERSALSTRING, and its UTF-8 conversion result is truncated at the first null byte during string assignment. As a result, "victim\0evil" may match an exact: "victim" rule and be accepted by Envoy.
PoC
Create a CA and a server certificate signed by that CA.
Create two client certificates signed by the same CA:
client_evil with OTHERNAME BMPSTRING = "evil"
client_null with OTHERNAME BMPSTRING = "victim\0evil"
Configure Envoy with require_client_certificate: true and a match_typed_subject_alt_names entry for the OTHERNAME OID with matcher.exact: "victim".
Connect without a client cert → connection rejected.
Connect with client_evil → connection rejected.
Connect with client_null → connection accepted (but shouldn't!).
Credit
Impact
An attacker who can obtain a trusted client certificate with a null byte embedded in an OTHERNAME SAN can exploit this vulnerability. The practical impact is unauthorized impersonation of the matched identity, enabling access to services or APIs protected by that exact OTHERNAME check.
CVE-2025-66220 has a CVSS score of 5.0 (Medium). The vector is network-reachable, high privileges required, and no user interaction. A CVSS score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether this affects your application depends on whether the vulnerable code is present and reachable in your environment. A fixed version is available (1.36.3, 1.35.7, 1.34.11, 1.33.13); upgrading removes the vulnerable code path.
Affected versions
Security releases
Kodem intelligence
Severity tells you how bad this could be in the worst case. It does not tell you whether you are exposed. Exploitability and impact are functions of runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A vulnerable package can sit in your dependency tree and never run.
Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter. Kodem's runtime-powered SCA identifies whether this CVE is reachable in your applications.
Remediation advice
github.com/envoyproxy/envoy to 1.36.3 or later; github.com/envoyproxy/envoy to 1.35.7 or later; github.com/envoyproxy/envoy to 1.34.11 or later; github.com/envoyproxy/envoy to 1.33.13 or later
Kodem Kai can prioritize this vulnerability in your dependency tree and generate a fix recommendation.
Frequently Asked Questions
- What is CVE-2025-66220? CVE-2025-66220 is a medium-severity security vulnerability in github.com/envoyproxy/envoy (go), affecting versions >= 1.36.0, <= 1.36.2. It is fixed in 1.36.3, 1.35.7, 1.34.11, 1.33.13.
- How severe is CVE-2025-66220? CVE-2025-66220 has a CVSS score of 5.0 (Medium). This score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether it represents real risk in your environment depends on whether the vulnerable code is present and reachable.
- Which versions of github.com/envoyproxy/envoy are affected by CVE-2025-66220? github.com/envoyproxy/envoy (go) versions >= 1.36.0, <= 1.36.2 is affected.
- Is there a fix for CVE-2025-66220? Yes. CVE-2025-66220 is fixed in 1.36.3, 1.35.7, 1.34.11, 1.33.13. Upgrade to this version or later.
- Is CVE-2025-66220 exploitable, and should I be worried? Whether CVE-2025-66220 is exploitable in your environment depends on whether the vulnerable code is present and reachable. A CVSS score is a worst-case rating; it does not account for your specific deployment, configuration, or usage patterns. Kodem, an Intelligent Application Security platform, uses runtime intelligence to show which vulnerabilities actually execute in production, so you can focus on the ones that represent real risk. Get a demo
- What actually determines whether CVE-2025-66220 is exploitable, and how bad it is? Exploitability and impact are not fixed properties of a CVE. They depend on runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A high CVSS score on a dependency that never runs is not the same as real risk. Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter.
- How do I fix CVE-2025-66220?
- Upgrade
github.com/envoyproxy/envoyto 1.36.3 or later - Upgrade
github.com/envoyproxy/envoyto 1.35.7 or later - Upgrade
github.com/envoyproxy/envoyto 1.34.11 or later - Upgrade
github.com/envoyproxy/envoyto 1.33.13 or later
- Upgrade