CVE-2023-34035
Spring Security's authorization rules can be misconfigured when using multiple servlets
Also known as GHSA-4vpr-xfrp-cj64
Mitigation
- Upgrade org.springframework.security:spring-security-config to one of 5.8.5, 6.0.5, 6.1.2 (or later in the same release line).
Who should check
- Projects that depend on Maven package org.springframework.security:spring-security-config (>= 5.8.0, < 5.8.5)
- Anyone running Spring Security Spring Security 5.8.0 to 5.8.4, Spring Security 6.0.0 to 6.0.4, Spring Security 6.1.0 to 6.1.1
Vulnerability facts
- Affected
- org.springframework.security:spring-security-config >= 5.8.0, < 5.8.5
- Fixed in
- 5.8.5, 6.0.5, 6.1.2
- Exploited in the wild
- Not in CISA KEV
- Public exploit / PoC
- Yes: see the exploit references below
- Remote exploitation
- Remote, no login needed
- CVSS
- 7.3 (v3.1, CNA)CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:LOpen in CVSS calculator
Show all 8 CVSS metrics
- Attack vector: Network
- Attack complexity: Low
- Privileges required: None
- User interaction: None
- Scope: Unchanged
- Confidentiality impact: Low
- Integrity impact: Low
- Availability impact: Low
- EPSS
- 0.64% chance of exploitation in 30 days (percentile 45, 2026-11-26)
- CWE
- CWE-863
- Modified
Description
Spring Security versions 5.8 prior to 5.8.5, 6.0 prior to 6.0.5, and 6.1 prior to 6.1.2 could be susceptible to authorization rule misconfiguration if the application uses requestMatchers(String) and multiple servlets, one of them being Spring MVC’s DispatcherServlet. (DispatcherServlet is a Spring MVC component that maps HTTP endpoints to methods on @Controller-annotated classes.) Specifically, an application is vulnerable when all of the following are true: * Spring MVC is on the classpath * Spring Security is securing more than one servlet in a single application (one of them being Spring MVC’s DispatcherServlet) * The application uses requestMatchers(String) to refer to endpoints that are not Spring MVC endpoints An application is not vulnerable if any of the following is true: * The application does not have Spring MVC on the classpath * The application secures no servlets other than Spring MVC’s DispatcherServlet * The application uses requestMatchers(String) only for Spring MVC endpoints
Affected and fixed versions
| Package / product | Affected | Fixed | Source |
|---|---|---|---|
| Maven org.springframework.security:spring-security-config | >= 5.8.0, < 5.8.5 | 5.8.5, 6.0.5, 6.1.2 | osv |
| Spring Security | Spring Security 5.8.0 to 5.8.4, Spring Security 6.0.0 to 6.0.4, Spring Security 6.1.0 to 6.1.1 | — | cvelist |
Check your systems with an agent
Paste this into Claude Code, Cursor or another coding agent. It only reads; it changes nothing.
Check whether anything I run is affected by CVE-2023-34035. Work read-only: do not install, upgrade, delete or change anything. Details: https://flawdb.com/CVE-2023-34035.md Affected: org.springframework.security:spring-security-config >= 5.8.0, < 5.8.5 Fixed in: 5.8.5, 6.0.5, 6.1.2 Steps: 1. Search this machine and project for org.springframework.security:spring-security-config (Maven), Spring Security: dependency manifests and lockfiles, installed packages, container images and running services. 2. For each match, note the installed version and whether it is inside the affected range. 3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
References
Vendor advisories
Patches
- https://github.com/spring-projects/spring-security-samples/commit/4e3bec904a5467db28ea33e25ac9d90524b53d66
- https://github.com/spring-projects/spring-security/commit/bb46a5427005e33e637b15948de8adae244ce547
- https://github.com/spring-projects/spring-security/commit/df239b6448ccf138b0c95b5575a88f33ac35cd9a
Exploits and PoCs
FAQ
Is CVE-2023-34035 being exploited?
There is no confirmed exploitation: CVE-2023-34035 is not in the CISA Known Exploited Vulnerabilities catalog. Public exploit code or a proof of concept is available. EPSS estimates a 0.64% chance of exploitation in the next 30 days (as of 2026-11-26).
How serious is CVE-2023-34035?
High: CVSS 7.3 (v3.1, scored by CNA). Remote, no login needed.
Which versions are affected by CVE-2023-34035?
org.springframework.security:spring-security-config >= 5.8.0, < 5.8.5.
Is there a fix for CVE-2023-34035?
Yes. Fixed in 5.8.5, 6.0.5, 6.1.2. Upgrade org.springframework.security:spring-security-config to one of 5.8.5, 6.0.5, 6.1.2 (or later in the same release line).
How do I check if I'm affected by CVE-2023-34035?
Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.