Name | CVE-2021-22881 |
Description | The Host Authorization middleware in Action Pack before 6.1.2.1, 6.0.3.5 suffers from an open redirect vulnerability. Specially crafted `Host` headers in combination with certain "allowed host" formats can cause the Host Authorization middleware in Action Pack to redirect users to a malicious website. Impacted applications will have allowed hosts with a leading dot. When an allowed host contains a leading dot, a specially crafted `Host` header can be used to redirect to a malicious website. |
Source | CVE (at NVD; CERT, LWN, oss-sec, fulldisc, Red Hat, Ubuntu, Gentoo, SUSE bugzilla/CVE, GitHub advisories/code/issues, web search, more) |
The table below lists information on source packages.
Source Package | Release | Version | Status |
---|---|---|---|
rails (PTS) | bullseye (security), bullseye | 2:6.0.3.7+dfsg-2+deb11u2 | fixed |
bookworm | 2:6.1.7.3+dfsg-2~deb12u1 | fixed | |
sid, trixie | 2:6.1.7.3+dfsg-4 | fixed |
The information below is based on the following data on fixed versions.
Package | Type | Release | Fixed Version | Urgency | Origin | Debian Bugs |
---|---|---|---|---|---|---|
rails | source | stretch | (not affected) | |||
rails | source | buster | (not affected) | |||
rails | source | (unstable) | 2:6.0.3.5+dfsg-1 |
[buster] - rails <not-affected> (Vulnerable code not present)
[stretch] - rails <not-affected> (host_authorization.rb added later)
https://discuss.rubyonrails.org/t/cve-2021-22881-possible-open-redirect-in-host-authorization-middleware/77130
https://hackerone.com/reports/1047447
https://github.com/rails/rails/commit/83a6ac3fee8fd538ce7e0088913ff54f0f9bcb6f (main)
https://github.com/rails/rails/commit/e33092740b3cc05f5abee197a5982eac31947e92 (v6.0.3.5)