CVE-2025-27111 Escape Sequence Injection vulnerability in Rack lead to Possible Log Injection

Medium 6.9 Published Updated

Attackers can inject escape sequences into logs via the X-Sendfile-Type header in Rack, potentially corrupting log files.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Over the internet
Victim action needed
Not needed
Fix
Available

What is CVE-2025-27111?

CVE-2025-27111 is a medium-severity vulnerability in rack, published on 4 Mar 2025. An attacker can exploit it over the internet without logging in, with no action from the victim.

Official description

Rack is a modular Ruby web server interface. The Rack::Sendfile middleware logs unsanitised header values from the X-Sendfile-Type header. An attacker can exploit this by injecting escape sequences (such as newline characters) into the header, resulting in log injection. This vulnerability is fixed in 2.2.12, 3.0.13, and 3.1.11.

Weakness: CWE-93, CWE-117

Which versions are affected by CVE-2025-27111?

6 open source packages ship an affected version, including rack. It affects 1 product.

PackageAffectedFixed in
rack RubyGemsAll versions2.2.12
rack RubyGemsAll versions2.2.12
rack RubyGemsFrom 3.03.0.13
rack RubyGemsFrom 3.03.0.13
rack RubyGemsFrom 3.13.1.11
rack RubyGemsFrom 3.13.1.11
Linux distribution packages (2)
rubygem-rack-1_6 openSUSE:Leap 15.6All versions1.6.8-150000.3.6.1
rubygem-rack-2.2 openSUSE:TumbleweedAll versions2.2.12-1.1

Products include Rack Rack.

How do I fix CVE-2025-27111?

Upgrade rack to a fixed version for your release line: 2.2.12, 3.0.13 or 3.1.11.

Is CVE-2025-27111 being exploited?

There is no known exploitation of CVE-2025-27111 in the wild and no public exploit code.

Sources

Also known as DEBIAN-CVE-2025-27111, GHSA-8cgq-6mh2-7j6v, MINI-jfh5-32v2-f832, MINI-rm59-v5p9-c6cf, SUSE-SU-2025:1492-1, UBUNTU-CVE-2025-27111 and 1 more.

Is CVE-2025-27111 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free