CVE-2026-73259: Mongoose reflected cross-site scripting in directory listing

CVE-2026-73259 · Severity: medium · CVSS 5.4 · Published 2026-08-20

Mongoose is an embedded web server library used to build web-based interfaces into applications and devices. When directory listing is enabled, attackers can craft malicious URLs containing JavaScript code that executes in users' browsers with the server's privileges, potentially stealing session data or performing unauthorized actions.

Quick answers

Is CVE-2026-73259 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2026-73259 being exploited in the wild.
How severe is CVE-2026-73259?
Medium severity, with a CVSS score of 5.4, published 20 August 2026.
Which products and versions are affected?
Cesanta Mongoose prior to 7.22.
Is there a fix for CVE-2026-73259?
A patch was published on 2026-06-23: Fix merged in commit a9df523 on 2026-06-23; version 7.22 contains the patch Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
How is CVE-2026-73259 attacked?
It is attacked over the network, in a software library.
Am I affected by CVE-2026-73259?
Check whether anything you run is named in the advisory. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

Technical details

Mongoose versions prior to 7.22 are vulnerable to reflected cross-site scripting (XSS) in the directory listing feature (MG_ENABLE_DIRLIST). The vulnerability exists in the mg_http_serve_dir() and listdir() functions in src/http.c, which fail to HTML-encode user-supplied percent-encoded request paths before inserting them into HTML title and h1 elements. An attacker can send a crafted URL containing JavaScript payloads that execute in the context of the Mongoose origin when a victim visits the link. No authentication is required; the attack requires network access to the Mongoose server and victim interaction (clicking a malicious link). The vulnerability is fixed in Mongoose 7.22 and later.

Affected products

  • Cesanta Mongoose prior to 7.22

Timeline

  • 2026-08-20: disclosed
  • 2026-06-23: patched: Fix merged in commit a9df523 on 2026-06-23; version 7.22 contains the patch

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.