Search for vulnerabilities
Vulnerability details: VCID-e2em-bwyc-uqgh
Vulnerability ID VCID-e2em-bwyc-uqgh
Aliases CVE-2022-23520
GHSA-rrfc-7g8p-99q8
GMS-2022-8301
Summary Possible XSS vulnerability with certain configurations of rails-html-sanitizer ## Summary There is a possible XSS vulnerability with certain configurations of Rails::Html::Sanitizer. This is due to an incomplete fix of CVE-2022-32209. - Versions affected: ALL - Not affected: NONE - Fixed versions: 1.4.4 ## Impact A 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 using either of the following two mechanisms: 1. Using the Rails configuration `config.action_view.sanitized_allow_tags=`: ```ruby # In config/application.rb config.action_view.sanitized_allowed_tags = ["select", "style"] ``` (see https://guides.rubyonrails.org/configuring.html#configuring-action-view) 2. Using the class method `Rails::Html::SafeListSanitizer.allowed_tags=`: ```ruby # class-level option Rails::Html::SafeListSanitizer.allowed_tags = ["select", "style"] ``` All users overriding the allowed tags by either of the above mechanisms to include both "select" and "style" should either upgrade or use one of the workarounds immediately. NOTE: Code is _not_ impacted if allowed tags are overridden using either of the following mechanisms: - the `:tags` option to the Action View helper method `sanitize`. - the `:tags` option to the instance method `SafeListSanitizer#sanitize`. ## Workarounds Remove either "select" or "style" from the overridden allowed tags.
Status Published
Exploitability 0.5
Weighted Severity 6.2
Risk 3.1
Affected and Fixed Packages Package Details
Weaknesses (3)
System Score Found at
cvssv3 6.1 https://access.redhat.com/hydra/rest/securitydata/cve/CVE-2022-23520.json
epss 0.00265 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00265 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00265 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00366 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00377 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
epss 0.00377 https://api.first.org/data/v1/epss?cve=CVE-2022-23520
cvssv3.1 6.1 https://ftp.suse.com/pub/projects/security/yaml/suse-cvss-scores.yaml
cvssv3.1_qr MODERATE https://github.com/advisories/GHSA-rrfc-7g8p-99q8
cvssv3.1 6.1 https://github.com/rails/rails-html-sanitizer
generic_textual MODERATE https://github.com/rails/rails-html-sanitizer
cvssv3 6.1 https://github.com/rails/rails-html-sanitizer/security/advisories/GHSA-rrfc-7g8p-99q8
cvssv3.1 6.1 https://github.com/rails/rails-html-sanitizer/security/advisories/GHSA-rrfc-7g8p-99q8
cvssv3.1_qr MODERATE https://github.com/rails/rails-html-sanitizer/security/advisories/GHSA-rrfc-7g8p-99q8
generic_textual MODERATE https://github.com/rails/rails-html-sanitizer/security/advisories/GHSA-rrfc-7g8p-99q8
cvssv3.1 6.1 https://github.com/rubysec/ruby-advisory-db/blob/master/gems/rails-html-sanitizer/CVE-2022-23520.yml
generic_textual MODERATE https://github.com/rubysec/ruby-advisory-db/blob/master/gems/rails-html-sanitizer/CVE-2022-23520.yml
cvssv3.1 6.1 https://hackerone.com/reports/1654310
generic_textual MODERATE https://hackerone.com/reports/1654310
cvssv3.1 6.1 https://lists.debian.org/debian-lts-announce/2023/09/msg00012.html
generic_textual MODERATE https://lists.debian.org/debian-lts-announce/2023/09/msg00012.html
cvssv3.1 6.1 https://nvd.nist.gov/vuln/detail/CVE-2022-23520
generic_textual MODERATE https://nvd.nist.gov/vuln/detail/CVE-2022-23520
No exploits are available.
Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N Found at https://access.redhat.com/hydra/rest/securitydata/cve/CVE-2022-23520.json
Attack Vector (AV) Attack Complexity (AC) Privileges Required (PR) User Interaction (UI) Scope (S) Confidentiality Impact (C) Integrity Impact (I) Availability Impact (A)

network

adjacent_network

local

physical

low

high

none

low

high

none

required

unchanged

changed

high

low

none

high

low

none

high

low

none

Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N Found at https://ftp.suse.com/pub/projects/security/yaml/suse-cvss-scores.yaml
Attack Vector (AV) Attack Complexity (AC) Privileges Required (PR) User Interaction (UI) Scope (S) Confidentiality Impact (C) Integrity Impact (I) Availability Impact (A)

network

adjacent_network

local

physical

low

high

none

low

high

none

required

unchanged

changed

high

low

none

high

low

none

high

low

none

Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N Found at https://github.com/rails/rails-html-sanitizer
Attack Vector (AV) Attack Complexity (AC) Privileges Required (PR) User Interaction (UI) Scope (S) Confidentiality Impact (C) Integrity Impact (I) Availability Impact (A)

network

adjacent_network

local

physical

low

high

none

low

high

none

required

unchanged

changed

high

low

none

high

low

none

high

low

none

Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N Found at https://github.com/rails/rails-html-sanitizer/security/advisories/GHSA-rrfc-7g8p-99q8
Attack Vector (AV) Attack Complexity (AC) Privileges Required (PR) User Interaction (UI) Scope (S) Confidentiality Impact (C) Integrity Impact (I) Availability Impact (A)

network

adjacent_network

local

physical

low

high

none

low

high

none

required

unchanged

changed

high

low

none

high

low

none

high

low

none

Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N Found at https://github.com/rubysec/ruby-advisory-db/blob/master/gems/rails-html-sanitizer/CVE-2022-23520.yml
Attack Vector (AV) Attack Complexity (AC) Privileges Required (PR) User Interaction (UI) Scope (S) Confidentiality Impact (C) Integrity Impact (I) Availability Impact (A)

network

adjacent_network

local

physical

low

high

none

low

high

none

required

unchanged

changed

high

low

none

high

low

none

high

low

none

Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N Found at https://hackerone.com/reports/1654310
Attack Vector (AV) Attack Complexity (AC) Privileges Required (PR) User Interaction (UI) Scope (S) Confidentiality Impact (C) Integrity Impact (I) Availability Impact (A)

network

adjacent_network

local

physical

low

high

none

low

high

none

required

unchanged

changed

high

low

none

high

low

none

high

low

none

Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N Found at https://lists.debian.org/debian-lts-announce/2023/09/msg00012.html
Attack Vector (AV) Attack Complexity (AC) Privileges Required (PR) User Interaction (UI) Scope (S) Confidentiality Impact (C) Integrity Impact (I) Availability Impact (A)

network

adjacent_network

local

physical

low

high

none

low

high

none

required

unchanged

changed

high

low

none

high

low

none

high

low

none

Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N Found at https://nvd.nist.gov/vuln/detail/CVE-2022-23520
Attack Vector (AV) Attack Complexity (AC) Privileges Required (PR) User Interaction (UI) Scope (S) Confidentiality Impact (C) Integrity Impact (I) Availability Impact (A)

network

adjacent_network

local

physical

low

high

none

low

high

none

required

unchanged

changed

high

low

none

high

low

none

high

low

none

Exploit Prediction Scoring System (EPSS)
Percentile 0.50049
EPSS Score 0.00265
Published At Aug. 1, 2025, 12:55 p.m.
Date Actor Action Source VulnerableCode Version
2025-07-31T08:04:53.196424+00:00 Ruby Importer Import https://github.com/rubysec/ruby-advisory-db/blob/master/gems/rails-html-sanitizer/CVE-2022-23520.yml 37.0.0