Remote Code Execution in Spring Framework
CISA potwierdza wykorzystanie tej podatności w rzeczywistych atakach. Priorytetowo sprawdź, czy dotyczy Twojej aplikacji. CISA KEV · CC0 1.0
Spring Framework prior to versions 5.2.20 and 5.3.18 contains a remote code execution vulnerability known as Spring4Shell.
Impact
A Spring MVC or Spring WebFlux application running on JDK 9+ may be vulnerable to remote code execution (RCE) via data binding. The specific exploit requires the application to run on Tomcat as a WAR deployment. If the application is deployed as a Spring Boot executable jar, i.e. the default, it is not vulnerable to the exploit. However, the nature of the vulnerability is more general, and there may be other ways to exploit it.
These are the prerequisites for the exploit:
- JDK 9 or higher
- Apache Tomcat as the Servlet container
- Packaged as WAR
spring-webmvcorspring-webfluxdependency
Patches
Workarounds
For those who are unable to upgrade, leaked reports recommend setting disallowedFields on WebDataBinder through an @ControllerAdvice. This works generally, but as a centrally applied workaround fix, may leave some loopholes, in particular if a controller sets disallowedFields locally through its own @InitBinder method, which overrides the global setting.
To apply the workaround in a more fail-safe way, applications could extend RequestMappingHandlerAdapter to update the WebDataBinder at the end after all other initialization. In order to do that, a Spring Boot application can declare a WebMvcRegistrations bean (Spring MVC) or a WebFluxRegistrations bean (Spring WebFlux).
Czego dotyczy
Kliknij technologię, aby zobaczyć wszystkie dotyczące jej podatności.
| Platforma | Paczka | Podatne wersje | Poprawka w wersji |
|---|---|---|---|
| Java / Kotlin (Maven) | org.springframework.boot:spring-boot-starter-web | < 2.5.12, >= 2.6.0, < 2.6.6 | 2.5.12, 2.6.6 |
| Java / Kotlin (Maven) | org.springframework.boot:spring-boot-starter-webflux | < 2.5.12, >= 2.6.0, < 2.6.6 | 2.5.12, 2.6.6 |
| Java / Kotlin (Maven) | org.springframework:spring-beans | < 5.2.20.RELEASE, >= 5.3.0, < 5.3.18 | 5.2.20.RELEASE, 5.3.18 |
| Java / Kotlin (Maven) | org.springframework:spring-webflux | < 5.2.20.RELEASE, >= 5.3.0, < 5.3.18 | 5.2.20.RELEASE, 5.3.18 |
| Java / Kotlin (Maven) | org.springframework:spring-webmvc | < 5.2.20.RELEASE, >= 5.3.0, < 5.3.18 | 5.2.20.RELEASE, 5.3.18 |
Odnośniki
- https://nvd.nist.gov/vuln/detail/CVE-2022-22965
- https://github.com/spring-projects/spring-framework/commit/002546b3e4b8d791ea6acccb81eb3168f51abb15
- https://cert-portal.siemens.com/productcert/pdf/ssa-254054.pdf
- https://github.com/spring-projects/spring-boot/releases/tag/v2.5.12
- https://github.com/spring-projects/spring-boot/releases/tag/v2.6.6
- https://github.com/spring-projects/spring-framework
- https://github.com/spring-projects/spring-framework/releases/tag/v5.2.20.RELEASE
- https://github.com/spring-projects/spring-framework/releases/tag/v5.3.18
- https://psirt.global.sonicwall.com/vuln-detail/SNWLID-2022-0005
- https://spring.io/blog/2022/03/31/spring-framework-rce-early-announcement
- https://tanzu.vmware.com/security/cve-2022-22965
- https://tools.cisco.com/security/center/content/CiscoSecurityAdvisory/cisco-sa-java-spring-rce-Zx9GUc67
- https://www.cisa.gov/known-exploited-vulnerabilities-catalog?field_cve=CVE-2022-22965
- https://www.kb.cert.org/vuls/id/970766
- https://www.oracle.com/security-alerts/cpuapr2022.html
- https://www.oracle.com/security-alerts/cpujul2022.html
- http://packetstormsecurity.com/files/166713/Spring4Shell-Code-Execution.html
- http://packetstormsecurity.com/files/167011/Spring4Shell-Spring-Framework-Class-Property-Remote-Code-Execution.html
- Wektor CVSS
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H/E:H- Słabość (CWE)
CWE-74, CWE-94- Platforma
- Java / Kotlin (Maven)
- Paczka
org.springframework.boot:spring-boot-starter-web, org.springframework.boot:spring-boot-starter-webflux, org.springframework:spring-beans- Ujawniono
- 31.03.2022
- Aktualizacja
- 11.10.2026 12:22
Źródła i licencje
OSV / GitHub Advisory Database - GHSA-36p3-wjmg-h94x - CC BY 4.0
Historia podatności: org.springframework:spring-webmvc
Wszystkie opisane podatności tej paczki (Java / Kotlin (Maven)), od najnowszej. Widać, czy to jednorazowa wpadka, czy paczka, której trzeba pilnować.
- Wszystkich wpisów
- 27
- Pierwsza → ostatnia
- 10.2018 08.2026
- Bez poprawki
- 0
- Wykorzystywana w atakach
- 1
Rozkład istotności
- Krytyczna 4
- Wysoka 8
- Średnia 13
- Niska 2
Ujawnienia w latach
- 2018: 1
- 2019: 0
- 2020: 2
- 2021: 0
- 2022: 5
- 2023: 2
- 2024: 3
- 2025: 1
- 2026: 13
-
Remote Code Execution in Spring Framework ten wpis
Dowiedz się, które podatności dotyczą Twojej aplikacji
Po podłączeniu integracji DockRay i włączeniu raportowania oprogramowania DockRay porównuje zgłoszone wersje komponentów ze znanymi podatnościami i powiadamia o potwierdzonych dopasowaniach. Zakres zależy od obsługiwanej technologii i dostępnych biuletynów.