All vulnerabilities

RubyGems

CVE-2026-126349

Addressable display_uri can show misleading hosts containing bidi and invisible characters

Severity
Low 3.1
Published
12 Nov 2026
Last changed
12 Nov 2026
Added to UpHeron
23 Nov 2026
Fixed in
2.9.1
Exploit chance
0.2% in the next 30 daysHigher than 15% of CVEs. EPSS by FIRST, 24 Nov 2026
Weakness
CWE-1007CWE-176CWE-451
Attack
Over the network · Only under certain conditions · No login needed · Needs someone to click or open something
Attacker can
Change some data
CVSS vector
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:N/I:L/A:N
Also known as
GHSA-539f-xcgw-2gjg
Sources
OSV.dev and GitHub

Description

Addressable::IDNA.to_unicode decodes Punycode labels (labels beginning with xn--) that contain characters which change how text is displayed without being visible themselves. These include bidirectional controls such as U+202E RIGHT-TO-LEFT OVERRIDE and U+2066–U+2069, zero-width characters, and other invisible format characters. Addressable::URI#display_uri uses to_unicode, so it can display a host whose characters appear reordered or which looks identical to a different host. For example, the host of http://xn--abcmoc-dm0c.com/ is displayed as abc, U+202E, moc.com, and the override makes everything after abc render right to left.

Parsing, host, normalized_host and any connection made from the URI are not affected. Only the displayed form is. Applications that show display_uri to users (link previews, chat and email clients, admin interfaces) can be used to make a malicious domain look like a trusted one.

From the GitHub Advisory Database, CC BY 4.0. Shortened; the full text is there.

Workarounds

  • Install libidn and the idn-ruby gem, so that Addressable uses the native IDNA implementation. This reduces the affected characters to those added since Unicode 3.2.
  • Check displayed hosts for bidirectional and invisible characters (e.g., /[\p{Cc}\p{Cf}\p{Default_Ignorable_Code_Point}]/) and fall back to normalized_host when one is present.
Workarounds as given by the GitHub Advisory Database, CC BY 4.0.

Affected software

SoftwareAffected versions
addressableRubyGems · osv:RubyGems:addressable
  • From 2.0.0 before 2.9.1

About addressable

Total downloads (RubyGems)
1,317,979,305RubyGems, 24 Nov 2026

References