Incomplete List of Disallowed Inputs Affecting loofah package, versions >=2.25.0, <2.25.3


Severity

Recommended
0.0
low
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
0.44% (41st percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk IDSNYK-RUBY-LOOFAH-22840520
  • published24 Nov 2026
  • disclosed12 Nov 2026
  • credit@manus-pi

Introduced: 12 Nov 2026

NewCVE-2026-126209  (opens in a new tab)
CWE-184  (opens in a new tab)
CWE-79  (opens in a new tab)

How to fix?

Upgrade loofah to version 2.25.3 or higher.

Overview

loofah is a general library for manipulating and transforming HTML/XML documents and fragments, built on top of Nokogiri.

Affected versions of this package are vulnerable to Incomplete List of Disallowed Inputs via the allowed_uri? function in Loofah::HTML5::Scrub. An attacker can cause cross-site scripting by supplying a URL such as javascript&#x3a alert(1) that the helper approves, then having the application render it in an href or another browser-interpreted URI attribute; the browser interprets it as a javascript: URL and executes the script. This affects callers that pass HTML-encoded, user-controlled strings to the public helper; Loofah’s default sanitize() path is not affected.

Notes

  • Entry point: Rails::HTML::Sanitizer.allowed_uri? re-exports the same helper, so applications using that Rails API are also affected.

CVSS Base Scores

version 4.0
version 3.1