Inefficient Regular Expression Complexity in rails-html-sanitizer
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- None
- Attack complexity
- Low
- Impact type
- Denial of service
- Confidentiality · integrity · availability
- None · None · High
- Fix status
- Partial Red Hat: 1 fixed, 2 without a fix
Attack profile from CVSS 3.1 · CNA. Fix status from CNA, GitHub and Red Hat. Impact type from CWE-1333.
Summary
rails-html-sanitizer is responsible for sanitizing HTML fragments in Rails applications. Certain configurations of rails-html-sanitizer < 1.4.4 use an inefficient regular expression that is susceptible to excessive backtracking when attempting to sanitize certain SVG attributes. This may lead to a denial of service through CPU resource consumption. This issue has been patched in version 1.4.4.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- None
- Automatable
- Yes
- Technical impact
- Partial
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| Rails | rails-html-sanitizer | before 1.4.4 | 1.4.4 | Patch available | CNA |
| — | rails-html-sanitizer (RubyGems) | before 1.4.4 | 1.4.4 | Patch available | GHSA-5x79-w82f-gw8w |
- rails-html-sanitizer VendorRails Affected before 1.4.4 Fixed in 1.4.4 Patch available CNA
- rails-html-sanitizer (RubyGems) Vendor— Affected before 1.4.4 Fixed in 1.4.4 Patch available GHSA-5x79-w82f-gw8w
Remediation
- Fix · CNA rails-html-sanitizer (rails) Fixed in 1.4.4
- Fix · GHSA-5x79-w82f-gw8w rails-html-sanitizer (RubyGems) Fixed in 1.4.4 Advisory →
Red Hat 1 advisory
- RHSA-2023:2097 Released 2023-05-03 · Red Hat rating ImportantSatellite 6.13 Release
- Red Hat Satellite 6.13 for RHEL 8 ansible-collection-redhat-satellite-3.9.0-2.el8sat, ansible-collection-redhat-satellite_operations-1.3.0-2.el8sat, ansible-lint-5.0.8-4.el8pc +47
Vendor assessments
Red Hat
Red Hat rating: Moderate. Red Hat's page for this CVE →
| Product | Status | Plan or fix |
|---|---|---|
| Red Hat 3scale API Management Platform 2 | Affected | No fix planned: Will not fix |
| Red Hat Satellite 6 | Affected | No fix yet |
| Red Hat Satellite 6.13 for RHEL 8 | Fixed | RHSA-2023:2097 |
Not affected: 1 product
- Red Hat Satellite 6.13 for RHEL 8
Timeline
- 2026-10-02 Threatist record created from CVE-2022-23517
- 2026-10-03 Alias added: GHSA-5x79-w82f-gw8w
References
Patch 1
Advisory 4
More Rails Html Sanitizers vulnerabilities
- TI-2022-13919 Cross-site scripting in https://github.com/rails/rails-html-sanitizer CVSS 3.1MEDIUM 6.1
- TI-2024-36144 Possible XSS vulnerability with certain configurations of rails-html-sanitizer 1.6.0 CVSS 4.0LOW 2.3
- TI-2022-07578 Possible XSS vulnerability with certain configurations of rails-html-sanitizer CVSS 3.1HIGH 7.2
- TI-2022-07579 rails-html-sanitizer contains an incomplete fix for an XSS vulnerability CVSS 3.1MEDIUM 6.1
- TI-2022-07577 Improper neutralization of data URIs allows XSS in rails-html-sanitizer CVSS 3.1MEDIUM 6.1
- TI-2024-36148 Possible XSS vulnerability with certain configurations of rails-html-sanitizer 1.6.0 CVSS 4.0LOW 2.3
Sources
- CVE-2022-23517 · CVE Program
- CVE-2022-23517 · NVD
- FIRST EPSS
- GHSA-5x79-w82f-gw8w · GitHub Advisory Database · CC BY 4.0
- CVE-2022-23517 · Red Hat security data · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences