llamaCVEVulnerability Intelligence
/
Advisory · GitHub · Maven · org.springframework:spring-beans

GHSA-36P3-WJMG-H94X

Remote Code Execution in Spring Framework

Parche disponible
Descargar PNG JSON
CVSS
—
critical
Fuente: —
ExplotaciónSin evidenciaNo figura en CISA KEV
Exploits públicos0Ninguno conocido
Parche4 versionesPrimer parche el mismo día de la divulgación
Exposición1.695 dDesde la divulgación, 31 mar 2022, 1:30 p. m.
Detección1.691 dDesde la divulgación hasta su ingreso al índice
Timeline

Ciclo de vida de la vulnerabilidad

Hoy
Divulgación
Publicada
Modificada
Explotación
Remediación
Parche 5.2.20.RELEASE +3
Monitoreo
Detectada
31 mar 22
22 oct 25
17 nov 26
20 nov 26
31 mar 22
29 may 23
26 jul 24
23 sept 25
20 nov 26
FechaFaseEventoDetalle
Divulgación Publicada GHSA-36P3-WJMG-H94X divulgada
Remediación Parche 5.2.20.RELEASE org.springframework:spring-beans · 0 d desde divulgación
Remediación Parche 5.3.18 org.springframework:spring-beans · 0 d desde divulgación
Remediación Parche 2.5.12 org.springframework.boot:spring-boot-starter-web · 0 d desde divulgación
Remediación Parche 2.6.6 org.springframework.boot:spring-boot-starter-web · 0 d desde divulgación
Divulgación Modificada Última actualización del registro
Monitoreo Detectada Ingresó al índice
Resumen
Descripción del advisory
Texto original · GitHub · en inglés

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-webmvc` or `spring-webflux` dependency

Patches

  • Spring Framework 5.3.18 https://github.com/spring-projects/spring-framework/releases/tag/v5.3.18 and 5.2.20 https://github.com/spring-projects/spring-framework/releases/tag/v5.2.20.RELEASE
  • Spring Boot 2.6.6 https://github.com/spring-projects/spring-boot/releases/tag/v2.6.6 and 2.5.12 https://github.com/spring-projects/spring-boot/releases/tag/v2.5.12

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).

Incluye detalles técnicos publicados por el investigador. Úselos solo para validar y corregir sus propios sistemas.

Versiones

Rangos afectados

Afectada Corregida Última
org.springframework.boot:spring-boot-starter-web · org.springframework.boot:spring-boot-starter-webflux< 2.5.12
org.springframework:spring-beans · org.springframework:spring-webmvc · org.springframework:spring-webflux< 5.2.20.RELEASE
org.springframework.boot:spring-boot-starter-web · org.springframework.boot:spring-boot-starter-webflux≥ 2.6.0 < 2.6.6
org.springframework:spring-beans · org.springframework:spring-webmvc · org.springframework:spring-webflux≥ 5.3.0 < 5.3.18
2.5.12
2.6.0
2.6.6
4.2.0
5.2.20.RELEASE
5.3.0
5.3.18
7.1.0
Remediación

Estado del parche por paquete

Paquete / productoEstadoCorregida enDesde divulgaciónÚltima versión
mavenorg.springframework:spring-beans
Corregida 5.2.20.RELEASE, 5.3.18 0 d · 0 d 7.1.0 no afectada
mavenorg.springframework:spring-webmvc
Corregida 5.2.20.RELEASE, 5.3.18 0 d · 0 d 7.1.0 no afectada
mavenorg.springframework.boot:spring-boot-starter-web
Corregida 2.5.12, 2.6.6 0 d · 0 d 4.2.0 no afectada
mavenorg.springframework:spring-webflux
Corregida 5.2.20.RELEASE, 5.3.18 0 d · 0 d 7.1.0 no afectada
mavenorg.springframework.boot:spring-boot-starter-webflux
Corregida 2.5.12, 2.6.6 0 d · 0 d 4.2.0 no afectada
Versiones corregidas2.5.122.6.65.2.20.RELEASE5.3.18
Explotación

Arsenal público

Sin exploits, módulos ni PoC públicos conocidos a la fecha de verificación.

Referencias
Advisoryhttps://nvd.nist.gov/vuln/detail/CVE-2022-22965
Otrahttps://github.com/spring-projects/spring-framework/commit/002546b3e4b8d791ea6acccb81eb3168f51abb15
Otrahttps://cert-portal.siemens.com/productcert/pdf/ssa-254054.pdf
Otrahttps://github.com/spring-projects/spring-boot/releases/tag/v2.5.12
Otrahttps://github.com/spring-projects/spring-boot/releases/tag/v2.6.6
Otrahttps://github.com/spring-projects/spring-framework
Otrahttps://github.com/spring-projects/spring-framework/releases/tag/v5.2.20.RELEASE
Otrahttps://github.com/spring-projects/spring-framework/releases/tag/v5.3.18
Otrahttps://psirt.global.sonicwall.com/vuln-detail/SNWLID-2022-0005
Otrahttps://spring.io/blog/2022/03/31/spring-framework-rce-early-announcement
Otrahttps://tanzu.vmware.com/security/cve-2022-22965
Otrahttps://tools.cisco.com/security/center/content/CiscoSecurityAdvisory/cisco-sa-java-spring-rce-Zx9GUc67
Ver 6 referencias más
Otrahttps://www.cisa.gov/known-exploited-vulnerabilities-catalog?field_cve=CVE-2022-22965
Otrahttps://www.kb.cert.org/vuls/id/970766
Otrahttps://www.oracle.com/security-alerts/cpuapr2022.html
Otrahttps://www.oracle.com/security-alerts/cpujul2022.html
Otrahttp://packetstormsecurity.com/files/166713/Spring4Shell-Code-Execution.html
Otrahttp://packetstormsecurity.com/files/167011/Spring4Shell-Spring-Framework-Class-Property-Remote-Code-Execution.html

Las referencias externas se muestran para copiar: cve.llama.ec no lo redirige a otros sitios.