Advisory Database
  • Advisories
  • Dependency Scanning
  1. gem
  2. ›
  3. css_parser
  4. ›
  5. CVE-2026-53727

CVE-2026-53727: Ruby CSS Parser: SSRF and Local File Disclosure in `CssParser::Parser#read_remote_file`

July 9, 2026

CssParser::Parser#read_remote_file (and therefore load_uri!, and the @import-following branch of add_block!) issues HTTP/HTTPS requests against any host, port and URI it is handed, with no scheme allowlist, no host / IP filtering, and no protection against link-local, loopback or RFC‑1918 addresses. Location: redirects are followed recursively back into the same function, which also services file:// URIs, so a single attacker-controlled HTTP redirect upgrades the bug from SSRF to arbitrary local file disclosure.

In practice, any consumer of css_parser that hands it attacker‑influenced CSS together with a base_uri: option — Premailer being the canonical example — is exposed. The attacker only needs the ability to land one @import url(...) in the CSS that the host application parses.

References

  • github.com/advisories/GHSA-9pmc-p236-855h
  • github.com/premailer/css_parser/security/advisories/GHSA-9pmc-p236-855h
  • github.com/rubysec/ruby-advisory-db/blob/master/gems/css_parser/CVE-2026-53727.yml
  • nvd.nist.gov/vuln/detail/CVE-2026-53727
  • www.cve.org/CVERecord/SearchResults?query=CVE-2026-53727

Code Behaviors & Features

Detect and mitigate CVE-2026-53727 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 3.0.0

Fixed versions

  • 3.0.0

Solution

Upgrade to version 3.0.0 or above.

Impact 8.6 HIGH

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:N/A:N

Learn more about CVSS

Weakness

  • CWE-918: Server-Side Request Forgery (SSRF)

Source file

gem/css_parser/CVE-2026-53727.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Fri, 10 Jul 2026 00:19:00 +0000.