Path Traversal in Spring

CVE-2024-38816

Applications serving static resources through the functional web frameworks WebMvc.fn or WebFlux.fn are vulnerable to path traversal attacks. An attacker can craft malicious HTTP requests and obtain any file on the file system that is also accessible to the process in which the Spring application is running. Specifically, an application is vulnerable when both of the following are true: * the web application uses RouterFunctions to serve static resources * resource handling is explicitly configured with a FileSystemResource location However, malicious requests are blocked and rejected when any of the following is true: * the Spring Security HTTP Firewall https://docs.spring.io/spring-security/reference/servlet/exploits/firewall.html  is in use * the application runs on Tomcat or Jetty

Vulnerability class: Path Traversal (Directory Traversal)

EPSS: 0.147 (96.3th percentile) — read the EPSS interpretation.

CVSS v3 metric

CVSS v3 base score 7.5 (High). Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N.

Affected products

  • Spring — versions 5.3.x, 6.0.x, 6.1.x

Weakness classification (CWE)

Public proof-of-concept exploits

References

Frequently asked questions

What is CVE-2024-38816?
CVE-2024-38816 is a high-severity vulnerability in Spring, classified under Path Traversal. CVSS score: 7.5/10. Published 2024-09-13.
How severe is CVE-2024-38816?
High severity. CVSS v3 base score is 7.5 out of 10.
Is CVE-2024-38816 known to be exploited?
29 public proof-of-concept repositories are indexed. Not currently listed in the CISA KEV catalog.