Improper validation of files in Apache Tomcat



| Updated: 2025-04-03
Risk Critical
Patch available YES
Number of vulnerabilities 1
CVE-ID CVE-2025-24813
CWE-ID CWE-20
Exploitation vector Network
Public exploit Vulnerability #1 is being exploited in the wild.
Vulnerable software
Apache Tomcat
Server applications / Web servers

Vendor Apache Foundation

Security Bulletin

This security bulletin contains one critical risk vulnerability.

1) Input validation error

EUVDB-ID: #VU105485

Risk: Critical

CVSSv4.0: 9.2 [CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:A/U:Red]

CVE-ID: CVE-2025-24813

CWE-ID: CWE-20 - Improper input validation

Exploit availability: Yes

Description

The vulnerability allows a remote attacker to compromise the affected system.

The vulnerability exists due to insufficient validation of user-supplied input when handling file uploads via HTTP PUT requests. A remote attacker can send a specially crafted HTTP PUT request to the server and gain access to sensitive information or even execute arbitrary code.

If all of the following were true, a malicious user was able to view security sensitive files and/or inject content into those files:

  • writes enabled for the default servlet (disabled by default)
  • support for partial PUT (enabled by default)
  • a target URL for security sensitive uploads that is a sub-directory of a target URL for public uploads
  • attacker knowledge of the names of security sensitive files being uploaded
  • the security sensitive files also being uploaded via partial PUT

If all of the following were true, a malicious user was able to perform remote code execution:

  • writes enabled for the default servlet (disabled by default)
  • support for partial PUT (enabled by default)
  • application was using Tomcat's file based session persistence with the default storage location
  • application included a library that may be leveraged in a deserialization attack


Mitigation

Install updates from vendor's website.

Vulnerable software versions

Apache Tomcat: 9.0.0-M1 - 11.0.2

CPE2.3 External links

https://tomcat.apache.org/security-11.html#Fixed_in_Apache_Tomcat_11.0.3
https://tomcat.apache.org/security-10.html
https://tomcat.apache.org/security-9.html#Fixed_in_Apache_Tomcat_9.0.99
https://github.com/apache/tomcat/commit/0a668e0c27f2b7ca0cc7c6eea32253b9b5ecb29c
https://github.com/apache/tomcat/commit/f6c01d6577cf9a1e06792be47e623d36acc3b5dc
https://github.com/apache/tomcat/commit/eb61aade8f8daccaecabf07d428b877975622f72
https://lists.apache.org/thread/xl35tnb4979lnk7stnvx9sll1hb68kvf


Q & A

Can this vulnerability be exploited remotely?

Yes. This vulnerability can be exploited by a remote non-authenticated attacker via the Internet.

How the attacker can exploit this vulnerability?

The attacker would have to send a specially crafted request to the affected application in order to exploit this vulnerability.

Is there known malware, which exploits this vulnerability?

Yes. This vulnerability is being exploited in the wild.



###SIDEBAR###