Visit the Wiz Whimzical Shop at AWS re:Invent
Vulnerability DatabaseCVE-2026-141538

CVE-2026-141538: 
Ruby vulnerability analysis and mitigation

Overview

CVE-2026-141538 is a URI injection vulnerability in the Addressable Ruby gem (an alternative to Ruby's standard library URI implementation) that allows unescaped host-changing delimiters in userinfo fields to redirect serialized URIs to attacker-controlled hosts. It affects all versions from 2.0.0 through 2.9.2 (inclusive) and was published on November 23, 2026, with the advisory added to the GitHub Advisory Database on December 1, 2026. The vulnerability carries a CVSS v3.1 base score of 4.8 (Medium) (Github Advisory, GitHub Security Advisory).

Technical details

The root cause is an interpretation conflict (CWE-436) combined with improper neutralization of special elements (CWE-74): the Addressable::URI#user=, #password=, #userinfo=, and Addressable::URI.new methods store userinfo values verbatim without rejecting or percent-encoding URI structural delimiters (/, ?, #, [, ], \, or : in the user field). When #to_s serializes the URI, these raw delimiters terminate the userinfo component early, causing the serialized string to name a different host than the object's own #host and #origin accessors report — for example, setting user = "alice@evil.example/" produces the serialized form https://alice@evil.example/@api.example.com/…, which both Addressable and Ruby's URI parse as pointing to evil.example. An application that validates the URI object (which appears correct) but then passes the serialized string to an HTTP client will send the request to the attacker-chosen host. The #normalize method encodes these delimiters correctly and is not affected (Github Advisory, GitHub Security Advisory).

Impact

A successful exploit causes an application's outbound HTTP requests — including their headers and request bodies — to be sent to an attacker-controlled host instead of the intended trusted service. Sensitive data such as API tokens, session credentials, or other request payloads meant for a trusted backend can be disclosed to the attacker. Integrity is also affected because the application believes it is communicating with a legitimate host while actually interacting with an adversary-controlled endpoint. Availability is not impacted (Github Advisory).

Exploitability

There is no public proof-of-concept exploit and no evidence of in-the-wild exploitation at this time (Github Advisory). The EPSS score is 0.0, reflecting a very low current probability of exploitation (GitHub Security Advisory). The CVE is not listed in the CISA Known Exploited Vulnerabilities catalog. Attack complexity is rated High because exploitation requires the attacker to control userinfo values supplied to an application that builds URIs using the vulnerable setters and then passes the serialized string to an HTTP client.

Exploitation steps

  1. Identify a target application: Find a Ruby application that uses the Addressable gem (versions 2.0.0–2.9.2) and accepts attacker-supplied values that are placed into the user, password, or userinfo field of an Addressable::URI object for outbound HTTP requests.
  2. Craft a malicious userinfo value: Construct a value containing a host-changing delimiter, such as alice@evil.example/ for the user field or u:x@evil.example/ for the userinfo field (the latter required in 2.9.2 due to partial mitigation). The delimiter (/, ?, or #) terminates the userinfo component early during serialization.
  3. Supply the value to the application: Submit the crafted value through whatever input channel the application exposes (e.g., an API parameter, form field, or configuration input) that feeds into the URI construction.
  4. Bypass validation: The application validates the URI object using #host or #origin, which correctly report the intended trusted host — the validation passes because the object's accessors are unaffected by the raw delimiter.
  5. Trigger the redirect: The application calls uri.to_s and passes the serialized string to an HTTP client. The serialized URI now names evil.example as the host, so the HTTP request — including headers such as Authorization or Cookie and the full request body — is sent to the attacker-controlled server.
  6. Collect disclosed data: The attacker's server receives and logs the full HTTP request, capturing any sensitive headers or body content intended for the trusted service (Github Advisory, GitHub Security Advisory).

Indicators of compromise

  • Network: Unexpected outbound HTTP/HTTPS requests from the application server to unknown or external hosts not in the normal allow-list; requests to attacker-controlled domains carrying Authorization, Cookie, or other sensitive headers.
  • Logs: Application HTTP client logs showing requests to unexpected hostnames that differ from the configured trusted API endpoints; error logs referencing Addressable::URI::InvalidURIError after upgrading (indicating prior injection attempts that would have succeeded on older versions).
  • Application Behavior: Outbound requests that return unexpected responses (e.g., connection errors or unexpected content) from hosts that differ from the intended service, potentially surfacing as downstream API errors in application logs.

Mitigation and workarounds

Upgrade the addressable gem to version 2.10.0 or later, which raises InvalidURIError for /, ?, #, [, ], or \ in the user or password, and : in the user, preventing the injection entirely (Github Advisory, Release 2.10.0). If an immediate upgrade is not possible, apply one of the following workarounds: (1) serialize with uri.normalize.to_s instead of uri.to_s, which percent-encodes the delimiters; (2) pre-encode userinfo values using Addressable::URI.encode_component(value, Addressable::URI::CharacterClasses::UNRESERVED) before assignment; or (3) validate the host of the final serialized string via Addressable::URI.parse(uri.to_s).host rather than trusting the object's #host accessor. Additionally, review all code paths that accept user-supplied userinfo values for outbound requests (GitHub Security Advisory).

Community reactions

The vulnerability was discovered and reported by Bob Aman (@sporkmonger), the maintainer of the Addressable gem itself, and the fix was developed with assistance from Claude Opus 5.5 as noted in the patch commit (Patch Commit). The advisory was published on November 23, 2026, and added to the GitHub Advisory Database on December 1, 2026, with no significant public controversy or widespread media coverage observed at this time.

Additional resources

Linux Distribution fix status

Fix availability across major Linux distributions and their releases.

RHEL / CentOS

Affected

RHEL 9

Not Affected

RHEL 10

Not Affected

Source: This report was generated using AI

Related Ruby vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

GHSA-qrq6-rcpx-pmm6MEDIUM4.8
  • Ruby logoRuby
  • addressable
NoYesDec 01, 2026
GHSA-cwmp-x65r-27fvLOW3.7
  • Ruby logoRuby
  • addressable
NoYesDec 02, 2026
GHSA-qg8x-qm93-fw27LOW3.7
  • Ruby logoRuby
  • addressable
NoYesDec 01, 2026
GHSA-c7j3-jq7p-v3prLOW3.7
  • Ruby logoRuby
  • addressable
NoYesDec 01, 2026
GHSA-v6hg-69pc-4f3fLOW3.7
  • Ruby logoRuby
  • addressable
NoYesDec 01, 2026

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Additional Wiz resources

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management