Vulnerability · Published Apr 28, 2025 · Assigned by apache
CVE-2025-31651Apache Tomcat: Bypass of rules in Rewrite Valve
Critical 9.8
In plain English
A critical-severity security flaw in Apache Tomcat from Apache Software Foundation. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 4.3% (higher than 91% of all known vulnerabilities). Ready-made attack tooling exists: public proof-of-concept code. Fixed versions are available - upgrade the affected package.
Official description
Improper Neutralization of Escape, Meta, or Control Sequences vulnerability in Apache Tomcat. For a subset of unlikely rewrite rule configurations, it was possible for a specially crafted request to bypass some rewrite rules. If those rewrite rules effectively enforced security constraints, those constraints could be bypassed. This issue affects Apache Tomcat: from 11.0.0-M1 through 11.0.5, from 10.1.0-M1 through 10.1.39, from 9.0.0.M1 through 9.0.102. The following versions were EOL at the time the CVE was created but are known to be affected: 8.5.0 though 8.5.100. Other, older, EOL versions may also be affected. Users are recommended to upgrade to version [FIXED_VERSION], which fixes the issue.
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| AlmaLinux:10 | tomcat | 1:10.1.36-3.el10_1.1 | ALSA-2025:23050 |
| AlmaLinux:8 | tomcat | 1:9.0.87-1.el8_10.7 | ALSA-2025:23048 |
| AlmaLinux:9 | tomcat | 1:9.0.87-6.el9_7.1 | ALSA-2025:23049 |
| AlmaLinux:10 | tomcat-admin-webapps | 1:10.1.36-3.el10_1.1 | ALSA-2025:23050 |
| AlmaLinux:8 | tomcat-admin-webapps | 1:9.0.87-1.el8_10.7 | ALSA-2025:23048 |
| AlmaLinux:9 | tomcat-admin-webapps | 1:9.0.87-6.el9_7.1 | ALSA-2025:23049 |
| AlmaLinux:10 | tomcat-docs-webapp | 1:10.1.36-3.el10_1.1 | ALSA-2025:23050 |
| AlmaLinux:8 | tomcat-docs-webapp | 1:9.0.87-1.el8_10.7 | ALSA-2025:23048 |
| AlmaLinux:9 | tomcat-docs-webapp | 1:9.0.87-6.el9_7.1 | ALSA-2025:23049 |
| AlmaLinux:8 | tomcat-el-3.0-api | 1:9.0.87-1.el8_10.7 | ALSA-2025:23048 |
| AlmaLinux:9 | tomcat-el-3.0-api | 1:9.0.87-6.el9_7.1 | ALSA-2025:23049 |
| AlmaLinux:10 | tomcat-el-5.0-api | 1:10.1.36-3.el10_1.1 | ALSA-2025:23050 |
| AlmaLinux:8 | tomcat-jsp-2.3-api | 1:9.0.87-1.el8_10.7 | ALSA-2025:23048 |
| AlmaLinux:9 | tomcat-jsp-2.3-api | 1:9.0.87-6.el9_7.1 | ALSA-2025:23049 |
| AlmaLinux:10 | tomcat-jsp-3.1-api | 1:10.1.36-3.el10_1.1 | ALSA-2025:23050 |
| AlmaLinux:10 | tomcat-lib | 1:10.1.36-3.el10_1.1 | ALSA-2025:23050 |
| AlmaLinux:8 | tomcat-lib | 1:9.0.87-1.el8_10.7 | ALSA-2025:23048 |
| AlmaLinux:9 | tomcat-lib | 1:9.0.87-6.el9_7.1 | ALSA-2025:23049 |
| AlmaLinux:8 | tomcat-servlet-4.0-api | 1:9.0.87-1.el8_10.7 | ALSA-2025:23048 |
| AlmaLinux:9 | tomcat-servlet-4.0-api | 1:9.0.87-6.el9_7.1 | ALSA-2025:23049 |
| AlmaLinux:10 | tomcat-servlet-6.0-api | 1:10.1.36-3.el10_1.1 | ALSA-2025:23050 |
| AlmaLinux:10 | tomcat-webapps | 1:10.1.36-3.el10_1.1 | ALSA-2025:23050 |
| AlmaLinux:8 | tomcat-webapps | 1:9.0.87-1.el8_10.7 | ALSA-2025:23048 |
| AlmaLinux:9 | tomcat-webapps | 1:9.0.87-6.el9_7.1 | ALSA-2025:23049 |
| AlmaLinux:10 | tomcat9 | 1:9.0.87-8.el10_1.1 | ALSA-2025:23052 |
| AlmaLinux:10 | tomcat9-admin-webapps | 1:9.0.87-8.el10_1.1 | ALSA-2025:23052 |
| AlmaLinux:10 | tomcat9-docs-webapp | 1:9.0.87-8.el10_1.1 | ALSA-2025:23052 |
| AlmaLinux:10 | tomcat9-el-3.0-api | 1:9.0.87-8.el10_1.1 | ALSA-2025:23052 |
| AlmaLinux:10 | tomcat9-jsp-2.3-api | 1:9.0.87-8.el10_1.1 | ALSA-2025:23052 |
| AlmaLinux:10 | tomcat9-lib | 1:9.0.87-8.el10_1.1 | ALSA-2025:23052 |
| AlmaLinux:10 | tomcat9-servlet-4.0-api | 1:9.0.87-8.el10_1.1 | ALSA-2025:23052 |
| AlmaLinux:10 | tomcat9-webapps | 1:9.0.87-8.el10_1.1 | ALSA-2025:23052 |
| Debian:12 | tomcat10 | 10.1.40-1 | DEBIAN-CVE-2025-31651 |
| Debian:13 | tomcat10 | 10.1.40-1 | DEBIAN-CVE-2025-31651 |
| Debian:14 | tomcat10 | 10.1.40-1 | DEBIAN-CVE-2025-31651 |
| Debian:13 | tomcat11 | 11.0.6-1 | DEBIAN-CVE-2025-31651 |
| Debian:14 | tomcat11 | 11.0.6-1 | DEBIAN-CVE-2025-31651 |
| Debian:12 | tomcat9 | 9.0.70-2 | DEBIAN-CVE-2025-31651 |
| Debian:13 | tomcat9 | 9.0.70-2 | DEBIAN-CVE-2025-31651 |
| Debian:14 | tomcat9 | 9.0.70-2 | DEBIAN-CVE-2025-31651 |
| Maven | org.apache.tomcat.embed:tomcat-embed-core | 9.0.104 | GHSA-ff77-26x5-69cr |
| Maven | org.apache.tomcat.embed:tomcat-embed-core | 11.0.6 | GHSA-ff77-26x5-69cr |
| Maven | org.apache.tomcat.embed:tomcat-embed-core | 10.1.40 | GHSA-ff77-26x5-69cr |
| Maven | org.apache.tomcat.embed:tomcat-embed-core | no fix listed | GHSA-ff77-26x5-69cr |
| Maven | org.apache.tomcat:tomcat-catalina | 10.1.40 | GHSA-ff77-26x5-69cr |
| Maven | org.apache.tomcat:tomcat-catalina | no fix listed | GHSA-ff77-26x5-69cr |
| Maven | org.apache.tomcat:tomcat-catalina | 11.0.6 | GHSA-ff77-26x5-69cr |
| Maven | org.apache.tomcat:tomcat-catalina | 9.0.104 | GHSA-ff77-26x5-69cr |
| Rocky Linux:10 | tomcat | 1:10.1.36-3.el10_1.1 | RLSA-2025:23050 |
| Rocky Linux:8 | tomcat | 1:9.0.87-1.el8_10.7 | RLSA-2025:23048 |
| Rocky Linux:9 | tomcat | 1:9.0.87-6.el9_7.1 | RLSA-2025:23049 |
| Rocky Linux:10 | tomcat9 | 1:9.0.87-8.el10_1.1 | RLSA-2025:23052 |
Affected products (as reported)
| Vendor | Product | Versions |
|---|---|---|
| Apache Software Foundation | Apache Tomcat | 11.0.0-M1 – through 11.0.510.1.0-M1 – through 10.1.399.0.0.M1 – through 9.0.1028.5.0 – through 8.5.100 |
Weakness: CWE-116 · Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H