CVE-2026-118513: Symfony X509Authenticator And X509AuthenticationListener Read Escaped Vulnerability
HIGHCVE-2026-118513 is a HIGH x509authenticator and x509authenticationlistener read escaped vulnerability (CWE-290: Authentication Bypass by Spoofing) affecting Symfony libraries in the Packagist ecosystem. The issue involves x509authenticator and x509authenticationlistener read escaped rfc 2253 commas and bare slashes inside a dn value as rdn boundaries. Remediation is available by upgrading affected packages to version 5.4.56, 6.4.50, 7.4.23, 8.1.11.
CVE-2026-118513 at a Glance
How to Fix CVE-2026-118513
To remediate this vulnerability, upgrade all affected Symfony dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade symfony/security-http to 5.4.56
Upgrade symfony/security-http to 6.4.50
Upgrade symfony/security-http to 7.4.23
Upgrade symfony/security-http to 8.1.11
Upgrade symfony/symfony to 5.4.56
Upgrade symfony/symfony to 6.4.50
Upgrade symfony/symfony to 7.4.23
Upgrade symfony/symfony to 8.1.11
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for symfony/security-http
How to Check if You Are Affected
To determine whether your application is affected by CVE-2026-118513, inspect your project dependencies for Symfony:
inspect dependencies for symfony/security-http
Analyze the terminal output to locate any version of Symfony in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 5.4.56), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-290: Authentication Bypass by Spoofing, where this attack-focused weakness is caused by incorrectly implemented authentication schemes that are subject to spoofing attacks. In Symfony, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2026-118513 Affected Symfony Versions
8 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
symfony/security-http
|
Packagist |
< 5.4.56
|
5.4.56
|
|
symfony/security-http
|
Packagist |
≥ 6.0.0
< 6.4.50
|
6.4.50
|
|
symfony/security-http
|
Packagist |
≥ 7.0.0
< 7.4.23
|
7.4.23
|
|
symfony/security-http
|
Packagist |
≥ 8.0.0
< 8.1.11
|
8.1.11
|
|
symfony/symfony
|
Packagist |
< 5.4.56
|
5.4.56
|
|
symfony/symfony
|
Packagist |
≥ 6.0.0
< 6.4.50
|
6.4.50
|
|
symfony/symfony
|
Packagist |
≥ 7.0.0
< 7.4.23
|
7.4.23
|
|
symfony/symfony
|
Packagist |
≥ 8.0.0
< 8.1.11
|
8.1.11
|
References
Frequently Asked Questions
What is CVE-2026-118513?
Which Symfony versions are affected?
What version fixes CVE-2026-118513?
Is symfony/security-http affected?
Is symfony/symfony affected?
What CWE is associated with CVE-2026-118513?
How can I check Packagist dependencies for CVE-2026-118513?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-5w3m-mfwg-9f8r",
"modified" : "2026-12-01T21:28:47Z",
"published" : "2026-12-01T21:28:47Z",
"aliases" : [ "CVE-2026-118513" ],
"summary" : "Symfony: X509Authenticator and X509AuthenticationListener Read Escaped RFC 2253 Commas and Bare Slashes Inside a DN Value as RDN Boundaries",
"details" : "### Description\n\n`X509Authenticator` extracts the user identifier from the Subject DN (Distinguished Name) that the web server passes in `$_SERVER['SSL_CLIENT_S_DN']`. The fix for CVE-2026-45063 anchored that extraction to an RDN (Relative Distinguished Name) boundary:\n\n```php\n'#(?:^|[,/])\\s*(?:emailAddress|1\\.2\\.840\\.113549\\.1\\.9\\.1)=([^,/@]++@[^,/]++)#'\n```\n\n`(?:^|[,/])` is not escape-aware. The expression runs against an already serialized DN, so it cannot tell an RDN separator from a separator character that occurs inside a value. Both serializations a web server can emit are affected, in opposite directions.\n\nUnder RFC 2253, used by Apache and by nginx's `$ssl_client_s_dn`, a comma inside a value is escaped as `\\,`, and the expression reads it as a separator regardless. A certificate whose single `CN` is `jdoe,emailAddress=admin@example.com`, issued to a holder whose genuine address is `jdoe@example.com`, serializes to:\n\n```\nCN=jdoe\\,emailAddress=admin@example.com,emailAddress=jdoe@example.com\n```\n\nRFC 2253 emits RDNs in reverse order, so the poisoned `CN` is scanned before the genuine `emailAddress` attribute and the authenticator returns `admin@example.com`.\n\nRFC 2253 does not treat `/` as a separator, so it leaves it bare inside a value, while the expression treats every `/` as one. A certificate whose single `CN` is `jdoe/emailAddress=admin@example.com` therefore authenticates as `admin@example.com` as well, with no `emailAddress` attribute needed. The legacy `X509_NAME_oneline()` format, used by Apache's `LegacyDNStringFormat` and by nginx's `$ssl_client_s_dn_legacy`, is the mirror image: it escapes `/` as `\\/` and leaves `,` bare. In that format, a certificate with no `emailAddress` attribute, or whose poisoned `CN` precedes it, authenticates as the smuggled address. Formats that quote a value instead of escaping its characters, such as OpenSSL's `XN_FLAG_ONELINE` (`CN = \"jdoe,emailAddress=admin@example.com\"`), are affected the same way.\n\nOn Symfony 5.4, the deprecated `X509AuthenticationListener`, which SecurityBundle uses when `security.enable_authenticator_manager` is not set to `true` (the default on 5.4), still matched `emailAddress=` anywhere in the DN: the fix for CVE-2026-45063 did not cover it, so applications on that code path were also exposed to the original report.\n\nAn attacker holding a certificate from the application's trusted CA who can influence the `CN` authenticates as an arbitrary user of the application, including a privileged one.\n\nApplications that pass a per-attribute `userKey`, such as Apache's `SSL_CLIENT_S_DN_Email`, never reach this fallback and are not affected, and neither are deployments whose CA generates or validates the subject itself rather than accepting requester-supplied values. The nginx configuration Symfony documents does reach the fallback, because nginx exposes no per-attribute equivalent.\n\n### Resolution\n\n`X509Authenticator` and `X509AuthenticationListener` now split the DN into RDNs before looking for the attribute, instead of matching the attribute against the serialized string. They select the separator from the serialization (`X509_NAME_oneline()` always prefixes the DN with a slash, RFC 2253 never does), split on unescaped occurrences of that separator only, unescape each RDN afterwards with the rules of its format, and require the attribute to span a whole RDN. A separator inside a quoted value doesn't split the DN either. The accepted value grammar is unchanged.\n\n`X509_NAME_oneline()` as implemented by OpenSSL before 3.0, and HAProxy's `ssl_c_s_dn` fetch, write a slash inside a value without escaping it, so such a DN cannot be parsed unambiguously by anyone. Deployments using Apache's `LegacyDNStringFormat` or nginx's `$ssl_client_s_dn_legacy` with those libraries, or HAProxy's `ssl_c_s_dn`, should switch to the RFC 2253 output (`$ssl_client_s_dn`, Apache's default, `ssl_c_s_dn(,rfc2253)`) or pass a per-attribute value as the user key (`SSL_CLIENT_S_DN_Email`, `ssl_c_s_dn(emailAddress)`).\n\nOne behaviour change is worth noting for reviewers: a slash-separated DN now has to start with a slash to be read as slash-separated. `CN=jdoe/emailAddress=admin@example.com` is byte for byte both the attack and a two-RDN slash-separated DN written without a leading slash, so one of the two readings had to go, and `X509_NAME_oneline()` always emits the leading slash.\n\nThe patches for this issue are available [here](https://github.com/symfony/symfony/commit/0f5e26b664d17cb235ca6b6d15bf4e7ac83d25cb) for branch 5.4 and [here](https://github.com/symfony/symfony/commit/e885d7549a234530ce1d59121d4ac3ee35b1caea) for branch 6.4 (and forward-ported to 7.4, 8.1 and 8.2). From 6.4 on, the identifier attribute is configurable through `credentialUserIdentifier`, and its value grammar accepts any value rather than an address, so the custom spelling was spoofable the same way. Both arms of the pattern are anchored to a whole RDN.\n\n### Credits\n\nSymfony would like to thank Oryam Halachmi, dahmani toumi and Stapat for reporting the issue.\n\nSymfony would also like to thank [Bruno Dias](https://github.com/cx-bruno-dias) and [João Oliveira](https://github.com/cx-joao-oliveira) from Checkmarx for their help getting a CVE assigned.",
"severity" : [ {
"type" : "CVSS_V4",
"score" : "CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "Packagist",
"name" : "symfony/security-http"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "5.4.56"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Packagist",
"name" : "symfony/security-http"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "6.0.0"
}, {
"fixed" : "6.4.50"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Packagist",
"name" : "symfony/security-http"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "7.0.0"
}, {
"fixed" : "7.4.23"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Packagist",
"name" : "symfony/security-http"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "8.0.0"
}, {
"fixed" : "8.1.11"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Packagist",
"name" : "symfony/symfony"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "5.4.56"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Packagist",
"name" : "symfony/symfony"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "6.0.0"
}, {
"fixed" : "6.4.50"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Packagist",
"name" : "symfony/symfony"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "7.0.0"
}, {
"fixed" : "7.4.23"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Packagist",
"name" : "symfony/symfony"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "8.0.0"
}, {
"fixed" : "8.1.11"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/symfony/symfony/security/advisories/GHSA-5w3m-mfwg-9f8r"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-118513"
}, {
"type" : "WEB",
"url" : "https://github.com/symfony/symfony/commit/0f5e26b664d17cb235ca6b6d15bf4e7ac83d25cb"
}, {
"type" : "WEB",
"url" : "https://github.com/symfony/symfony/commit/e885d7549a234530ce1d59121d4ac3ee35b1caea"
}, {
"type" : "WEB",
"url" : "https://github.com/FriendsOfPHP/security-advisories/blob/master/symfony/security-http/CVE-2026-118513.yaml"
}, {
"type" : "WEB",
"url" : "https://github.com/FriendsOfPHP/security-advisories/blob/master/symfony/symfony/CVE-2026-118513.yaml"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/symfony/symfony"
}, {
"type" : "WEB",
"url" : "https://github.com/symfony/symfony/releases/tag/v5.4.56"
}, {
"type" : "WEB",
"url" : "https://github.com/symfony/symfony/releases/tag/v6.4.50"
}, {
"type" : "WEB",
"url" : "https://github.com/symfony/symfony/releases/tag/v7.4.23"
}, {
"type" : "WEB",
"url" : "https://github.com/symfony/symfony/releases/tag/v8.1.11"
}, {
"type" : "WEB",
"url" : "https://symfony.com/cve-2026-118513"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-290" ],
"severity" : "HIGH",
"github_reviewed" : true,
"github_reviewed_at" : "2026-12-01T21:28:47Z",
"nvd_published_at" : "2026-11-04T13:17:25Z"
}
}