Mittel

Hono: Server-Side XSS via JSX Escaping Bypass in cx() Utility

  • Veröffentlicht: 21.07.2026
  • Aktualisiert: 11.10.2026 10:22

Summary

cx() in hono/css composes class names from plain strings but marks the result as already-escaped without HTML-escaping the input. When the result is used as a JSX class attribute during server-side rendering, the value is written into the attribute unescaped, so untrusted input can break out of the class attribute and inject arbitrary markup, leading to Cross-Site Scripting (XSS).

Details

Because the composed value is treated as pre-escaped, the HTML attribute escaping normally applied to interpolated values is skipped, and characters such as " pass through unescaped — allowing a value to terminate the attribute and add further attributes or elements. This arises when an application passes untrusted, user-controlled input as a class name to cx(), for example when merging a base class with an externally provided className.

Impact

During server-side rendering, an attacker who controls a value passed to cx() can inject arbitrary HTML into the page, resulting in stored or reflected XSS in the victim's browser.

This may lead to:

  • Execution of attacker-controlled script in the victim's browser session.
  • Session hijacking, credential theft, or actions performed on behalf of the victim.

Applications are affected only if they render JSX server-side and pass untrusted input as a class name to cx().

Betroffene Software

Klicken Sie auf eine Technologie, um alle zugehörigen Schwachstellen anzuzeigen.

PlattformPaketAnfällige VersionenBehoben in
npm-Paket hono >= 4.0.0, < 4.12.27 4.12.27

Verweise

CVSS-Wert 6.1/10
CVSS-Vektor
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
Schwäche (CWE)
CWE-116, CWE-79
Plattform
npm
Paket
hono
Veröffentlicht
21.07.2026
Aktualisiert
11.10.2026 10:22

Quellen und Lizenzen

OSV / GitHub Advisory Database - GHSA-w62v-xxxg-mg59 - CC BY 4.0

Schwachstellenhistorie: hono

Alle veröffentlichten Schwachstellen dieses Pakets (npm-Paket), neueste zuerst. Zeigt, ob es ein einmaliger Ausrutscher ist oder ein Paket, das man im Auge behalten muss.

Alle (52) im Archiv
Einträge insgesamt
52
Erste → letzte
12.2023 10.2026
Ohne Fix
0
In Angriffen ausgenutzt
0

Verteilung nach Schweregrad

  • Hoch 7
  • Mittel 41
  • Niedrig 4

Veröffentlichungen pro Jahr

  1. 2023: 1
  2. 2024: 3
  3. 2025: 4
  4. 2026: 44
Schweregrad:
  1. Hono: Server-Side XSS via JSX Escaping Bypass in cx() Utility dieser Eintrag
    Mittel · 6.1 CVE-2026-59895 >= 4.0.0, < 4.12.27 4.12.27
  2. Hoch · 8.1 CVE-2025-62610 >= 1.1.0, < 4.10.2 4.10.2
  3. Hoch · 7.5 CVE-2025-58362 >= 4.8.0, < 4.9.6 4.9.6

Erkennen Sie Schwachstellen in Ihrer Anwendung

Mit der DockRay-Integration und aktivierter Softwareinventarisierung prüft DockRay gemeldete Komponentenversionen auf bekannte Schwachstellen und benachrichtigt Sie über bestätigte Treffer. Die Abdeckung hängt von der unterstützten Technologie und den verfügbaren Meldungen ab.

Anwendung verbinden
DockRay Newsletter

Anwendungssicherheit in Ihrem Postfach

Wichtige Schwachstellen, konkrete Empfehlungen und praktische Tipps für Ihre Anwendungen. Wählen Sie Ihre Technologien und verfolgen Sie, was für Ihr Projekt relevant ist.

  • Eine tägliche Zusammenfassung neuer Schwachstellen, auch kritischer.
  • Benachrichtigungen über wichtige Updates.
  • Praktische Tipps zur Sicherheit und Überwachung von Anwendungen.

Leer lassen, um Meldungen zu allen Technologien zu erhalten.

Kostenlos anmelden. In jeder E-Mail mit einem Klick abmelden.