CVE-2022-32209
Summary
| CVE | CVE-2022-32209 |
| State | PUBLIC |
| Assigner | [email protected] |
| Source Priority | CVE Program / NVD first with legacy fallback |
| Published | 2022-06-24 15:15:00 UTC |
| Updated | 2024-02-01 16:22:00 UTC |
| Description | # Possible XSS Vulnerability in Rails::Html::SanitizerThere is a possible XSS vulnerability with certain configurations of Rails::Html::Sanitizer.This vulnerability has been assigned the CVE identifier CVE-2022-32209.Versions Affected: ALLNot affected: NONEFixed Versions: v1.4.3## ImpactA possible XSS vulnerability with certain configurations of Rails::Html::Sanitizer may allow an attacker to inject content if the application developer has overridden the sanitizer's allowed tags to allow both `select` and `style` elements.Code is only impacted if allowed tags are being overridden. This may be done via application configuration:```ruby# In config/application.rbconfig.action_view.sanitized_allowed_tags = ["select", "style"]```see https://guides.rubyonrails.org/configuring.html#configuring-action-viewOr it may be done with a `:tags` option to the Action View helper `sanitize`:```<%= sanitize @comment.body, tags: ["select", "style"] %>```see https://api.rubyonrails.org/classes/ActionView/Helpers/SanitizeHelper.html#method-i-sanitizeOr it may be done with Rails::Html::SafeListSanitizer directly:```ruby# class-level optionRails::Html::SafeListSanitizer.allowed_tags = ["select", "style"]```or```ruby# instance-level optionRails::Html::SafeListSanitizer.new.sanitize(@article.body, tags: ["select", "style"])```All users overriding the allowed tags by any of the above mechanisms to include both "select" and "style" should either upgrade or use one of the workarounds immediately.## ReleasesThe FIXED releases are available at the normal locations.## WorkaroundsRemove either `select` or `style` from the overridden allowed tags.## CreditsThis vulnerability was responsibly reported by [windshock](https://hackerone.com/windshock?type=user). |
NVD Known Affected Configurations (CPE 2.3)
References
| Reference | Source | Link | Tags |
|---|
| [SECURITY] [DLA 3227-1] ruby-rails-html-sanitizer security update |
MLIST |
lists.debian.org |
|
| [SECURITY] Fedora 35 Update: rubygem-rails-html-sanitizer-1.4.3-1.fc35 - package-announce - Fedora Mailing-Lists |
FEDORA |
lists.fedoraproject.org |
|
| [SECURITY] Fedora 36 Update: rubygem-rails-html-sanitizer-1.4.3-1.fc36 - package-announce - Fedora Mailing-Lists |
FEDORA |
lists.fedoraproject.org |
|
| [SECURITY] Fedora 36 Update: rubygem-rails-html-sanitizer-1.4.3-1.fc36 - package-announce - Fedora Mailing-Lists |
|
lists.fedoraproject.org |
|
| [SECURITY] Fedora 35 Update: rubygem-rails-html-sanitizer-1.4.3-1.fc35 - package-announce - Fedora Mailing-Lists |
|
lists.fedoraproject.org |
|
| HackerOne |
MISC |
hackerone.com |
|
| CVE Program record |
CVE.ORG |
www.cve.org |
canonical |
| NVD vulnerability detail |
NVD |
nvd.nist.gov |
canonical, analysis |
No vendor comments have been submitted for this CVE.
Legacy QID Mappings
- 181302 Debian Security Update for ruby-rails-html-sanitizer (DLA 3227-1)
- 183584 Debian Security Update for ruby-rails-html-sanitizer (CVE-2022-32209)
- 240925 Red Hat Update for Satellite 6.12 (RHSA-2022:8506)
- 283037 Fedora Security Update for rubygem (FEDORA-2022-ce4719993c)
- 283038 Fedora Security Update for rubygem (FEDORA-2022-974fffb418)
- 6000139 Debian Security Update for ruby-rails-html-sanitizer (DLA 3566-1)
- 753434 SUSE Enterprise Linux Security Update for rubygem-rails-html-sanitizer (SUSE-SU-2022:2870-1)
- 960485 Rocky Linux Security Update for Satellite (RLSA-2022:8506)