Spring Security servlet-path, issuer, and X.509 validation batch (GHSA-4wrg-8wpc-h923 / GHSA-4vrc-j85c-598c / GHSA-cvc6-q2cp-2xhw / GHSA-2jrg-rf5x-568g)¶
Signal: GitHub Security Advisories updated 2026-04-29 for several Spring Security authorization and identity-validation edge cases.
What it is¶
The batch affects Spring Security configurations that rely on path matching, OIDC issuer discovery, or X.509 client certificates:
GHSA-4wrg-8wpc-h923/CVE-2026-22753:HttpSecurity#securityMatchersmay fail to include the servlet path when matching. Fixed inspring-security-config7.0.5.GHSA-4vrc-j85c-598c/CVE-2026-22754: XML authorization rules may fail to include the servlet path. Fixed inspring-security-config7.0.5.GHSA-cvc6-q2cp-2xhw/CVE-2026-22748:withIssuerLocationcan create a security misconfiguration risk. Fixed inspring-security-oauth2-jose6.5.10and7.0.5; older maintained lines should follow Spring guidance.GHSA-2jrg-rf5x-568g/CVE-2026-22747: X.509 client certificate auth can allow unauthorized user impersonation. Fixed inspring-security-web7.0.5.
References:
- https://github.com/advisories/GHSA-4wrg-8wpc-h923
- https://github.com/advisories/GHSA-4vrc-j85c-598c
- https://github.com/advisories/GHSA-cvc6-q2cp-2xhw
- https://github.com/advisories/GHSA-2jrg-rf5x-568g
Triage¶
- Inventory Spring Security
7.0.0through7.0.4, plus affected6.3-6.5OAuth2 JOSE users. - Search configs for
securityMatchers, XML authorization rules, servlet context paths,withIssuerLocation, and X.509 authentication. - Prioritize apps deployed under non-root servlet paths, behind reverse proxies, or with admin/API routes protected by path-specific matchers.
- Add regression tests that request protected endpoints through the exact deployed context path and proxy prefix.
Mitigation¶
- Upgrade Spring Security components to the fixed patch levels (
7.0.5+,6.5.10+where applicable). - Avoid relying only on path matchers for high-risk actions; pair route authorization with method-level checks.
- Pin and validate expected OIDC issuer metadata instead of discovering from attacker-influenced locations.
- For X.509 auth, bind identities to validated certificate fields and test ambiguous/duplicate subject cases.
Detection ideas¶
- Review access logs for protected paths reached through alternate servlet prefixes, encoded slashes, or proxy-rewritten paths.
- Hunt for authentication successes from certificates with unexpected subject/SAN mappings.
- Watch OIDC metadata fetches to nonstandard issuers or endpoints outside the identity-provider allowlist.
Durable lesson¶
Authorization rules must be tested in the deployed URL shape, not just the framework-local route shape. Context paths, proxy prefixes, issuer discovery, and certificate identity mapping are all trust boundaries.