CVE-2025-25184 Possible Log Injection in Rack::CommonLogger

Medium 5.7 Published Updated

Attackers can inject CRLF characters into log entries via crafted usernames, corrupting logs or hiding activity in Rack-based Ruby applications.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Over the internet
Victim action needed
Not needed
Fix
Available

What is CVE-2025-25184?

CVE-2025-25184 is a medium-severity vulnerability in rack, published on 12 Feb 2025. Any signed-in user can exploit it over the network, with no action from the victim.

Official description

Rack provides an interface for developing web applications in Ruby. Prior to versions 2.2.11, 3.0.12, and 3.1.10, Rack::CommonLogger can be exploited by crafting input that includes newline characters to manipulate log entries. The supplied proof-of-concept demonstrates injecting malicious content into logs. When a user provides the authorization credentials via Rack::Auth::Basic, if success, the username will be put in env['REMOTE_USER'] and later be used by Rack::CommonLogger for logging purposes. The issue occurs when a server intentionally or unintentionally allows a user creation with the username contain CRLF and white space characters, or the server just want to log every login attempts. If an attacker enters a username with CRLF character, the logger will log the malicious username with CRLF characters into the logfile. Attackers can break log formats or insert fraudulent entries, potentially obscuring real activity or injecting malicious data into log files. Versions 2.2.11, 3.0.12, and 3.1.10 contain a fix.

Weakness: CWE-93, CWE-117

Which versions are affected by CVE-2025-25184?

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

PackageAffectedFixed in
rack RubyGemsAll versions2.2.11
rack RubyGemsAll versions2.2.11
rack RubyGemsFrom 3.03.0.12
rack RubyGemsFrom 3.03.0.12
rack RubyGemsFrom 3.13.1.10
rack RubyGemsFrom 3.13.1.10
Linux distribution packages (4)
pcs Red Hat:enterprise_linux:9::highavailabilityAll versions0:0.11.9-2.el9
pcs-snmp Red Hat:enterprise_linux:9::highavailabilityAll versions0:0.11.9-2.el9
pcs Red Hat:enterprise_linux:9::resilientstorageAll versions0:0.11.9-2.el9
pcs-snmp Red Hat:enterprise_linux:9::resilientstorageAll versions0:0.11.9-2.el9

Products include Rack Rack.

How do I fix CVE-2025-25184?

Upgrade rack to a fixed version for your release line: 2.2.11, 3.0.12 or 3.1.10.

Is CVE-2025-25184 being exploited?

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

Sources

Also known as DEBIAN-CVE-2025-25184, GHSA-7g2v-jj9q-g3rg, MINI-qwwh-jr8r-c36v, MINI-vmwh-xc8q-88cc, RHSA-2025:7085, UBUNTU-CVE-2025-25184.

Is CVE-2025-25184 in your software?

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

Check your SBOMs for free