Skip to content
KitploitKITPLOIT
ToolsExploitsBlog
Log in
Submit
ToolsExploitsBlog
Submit

Hacking, PenTest, and Cybersecurity Tools for Your Security Arsenal!

Kitploit is a directory of hacking, cybersecurity, and pentesting tools. Discover the latest project updates to find vulnerabilities, analyze systems, automate testing, and strengthen your security.

FeedsContactPrivacy© 2026 Kitploit

Tool Directory

Categories

View all categories
Loading categories
Tools/GitHubGitHub/googlesky/cve-2026-124552
Privilege EscalationVulnerability AnalysisExploitationWeb Application ExploitationWeb SecurityPayload DevelopmentLabs & Practice
GitHubgooglesky/cve-2026-124552

CVE-2026-124552

PoC lab for CVE-2026-124552: Webmin <=2.670 stored XSS in Shorewall list.cgi chained to root RCE, plus an unpatched path traversal arbitrary file write, with vulnerable and patched containers.

View Repository
9 days agoNot yet reviewed
Share

CVE-2026-124552

Webmin through 2.670 — stored XSS in the Shorewall and Shorewall6 modules' list.cgi (fixed post-2.670 by upstream commit 01b988dbf).

Any Webmin account that is granted the Shorewall module can persist arbitrary HTML/JavaScript into a firewall table (a comment via savecmt.cgi, or any rule field via save.cgi). When an administrator later opens list.cgi for that table, the stored values are rendered without html_escape(), so the payload executes in the administrator's browser session. Webmin runs as root, so the injected script can drive any Webmin endpoint with the admin's credentials — the PoC turns this into command execution as root via the Command Shell module.

Fix (commit 01b988dbf, webmin/webmin#2908): list.cgi in both modules now HTML-escapes every table cell and comment before rendering, and savecmt.cgi rejects carriage returns/NULs in the comment text.

Lab

Podman network cve124552lab; every container is bounded (--cpus 2 --memory 4g).

containerrole
webmin-vulnWebmin 2.670 + shorewall/shorewall6 (vulnerable)
webmin-fixedWebmin 2.670 with upstream patch 01b988dbf applied (control)
poc runner (ephemeral)Python + Playwright Chromium; drives the whole chain over the lab network

Default lab credentials: admin root / webminroot, unprivileged attacker / attackerpass (granted the Shorewall module only — the stand-in for an untrusted account).

Repro

make prepare      # build the three images
make up           # create the network + start webmin-vuln / webmin-fixed
make poc-vuln     # check + exploit against webmin-vuln   -> VULNERABLE / EXPLOIT SUCCESS
make poc-fixed    # same against webmin-fixed             -> NOT VULNERABLE / no marker
make 0day         # traversal write PoC against both      -> 0DAY CONFIRMED (both)
make down

PoC modes (poc/poc.py, run inside the poc runner container):

modewhat it doesproof
checkattacker stores an `` canary comment; admin fetches list.cgi?table=rulescanary rendered raw → VULNERABLE; only escaped → NOT VULNERABLE
exploitsame storage step, then headless Chromium logs in as admin and opens list.cgi — the stored JS firesJS POSTs a command to /shell/index.cgi; marker /tmp/pwned_by_cve_2026_124552 appears with uid=0(root)
0daysee belowarbitrary file created on the target as root via the Shorewall module

Evidence

  • evidence/check-vulnerable-run.txt — check against 2.670: payload rendered unescaped.
  • evidence/check-patched-run.txt — same against the patched build: payload HTML-escaped.
  • evidence/exploit-vulnerable-run.txt — full chain against 2.670: XSS fires, marker file contains uid=0(root) gid=0(root) groups=0(root).
  • evidence/exploit-patched-run.txt — same against the patched build: payload escaped, no marker.
  • evidence/0day-vulnerable-run.txt / evidence/0day-patched-run.txt — traversal write works on both builds.

Notes

Unpatched path traversal → arbitrary file write as root. (Fixed upstream by 1b899205 for the shorewall module and f918d37 for shorewall6 + comment validation; both verified against the PoC in this repo.) The table parameter of the Shorewall/Shorewall6 module was used verbatim in file paths (read_table_file, create_table_row, modify_table_row), while can_access() returned true for any value because the module's default ACL is files=*. savecmt.cgi never validated table and (before f918d37) only rejected \r/\0 in the message - a newline was accepted. Consequences for any account with Shorewall module access (Webmin runs as root):

  • savecmt.cgi with new=1 creates a new file anywhere: table=../../../../tmp/proof&msg=... → ?COMMENT ... written as root.
  • savecmt.cgi modify mode + %0a in msg replaces a line of any root-writable file, or splices in extra lines. Example against /etc/passwd: table=../../../../etc/passwd&idx=0&msg=x%0aroot::0:0:root:/root:/bin/bash appends a passwordless root line.
  • editcmt.cgi reads back files whose lines are whitespace-separated (the edit form shows fields 2..N of a line, HTML-escaped but intact).

The nochange ACL flag does not gate any of this — it is only consulted by the start/stop/restart/clear buttons (R4 of the disclosure; still open). The 0day mode of the PoC demonstrates the primitive safely: it creates /tmp/0day_124552_proof.txt as root, reads it back through editcmt.cgi, then deletes the inserted line.

Vendor timeline: reported 2026-11-09; 1b899205 (shorewall module guard) and f918d37 (shorewall6 guard + \n rejection in both savecmt.cgi) landed the same week; re-tested against 2.670 + 1b899205 + f918d37 - all vectors in this PoC are blocked ("Invalid table name" / newline rejected) with no regression on legitimate comments.

Exploit-chain details worth knowing:

  • Webmin login requires the JS-set testing=1 cookie (handle_login in miniserv-lib.pl) and same-origin Referer headers (referers_none=1 default; a missing referer yields the "Security Warning" interstitial). The PoC sets both.
  • /shell/index.cgi only parses multipart/form-data (ReadParseMime requires a boundary), so the injected script POSTs a FormData body; command output is HTML-escaped (uid&#61;0(root)), so the verifier unescapes before matching.
  • The Authentic Theme renders the module table into the admin page as-is; the stored `` fires onerror on parse.

Mitigation

  • Upgrade Webmin past 2.670 (the build containing 01b988dbf).
  • Do not grant the Shorewall/Shorewall6 modules to untrusted Webmin accounts on builds without 1b899205 + f918d37; on older releases, module access implies full root control.
  • As a stopgap, remove or rename the Shorewall module directories under /usr/share/webmin on hosts where the module is unused.

References

  • https://nvd.nist.gov/vuln/detail/CVE-2026-124552
  • https://webmin.com/security/
  • https://github.com/webmin/webmin/commit/01b988dbf1e8f9926eec4b041d913167e0cc280f
  • https://github.com/webmin/webmin/issues/2908
Download Tool

Most Popular

View all →

Discover the most used tools by our community.

  • 1

    OsintHunter

    letox4/osinthunter

    🎯 The ultimate OSINT toolkit: investigation graph, confidence scoring, alias families, map, timeline and reports. 49 modules, 400+ sites, no API keys required.

    936
  • 2

    ghostlock-app

    yukonga/ghostlock-app

    GhostLock One-Tap Execution App (CVE-2026-43499)

    555
  • 3

    redforge

    cybersecurity91/redforge

    Browser-side red team toolkit with 102 offline tools for recon, payload generation, credential attacks, crypto, encoding and engagement reporting.

    353
  • 4

    ARTEX

    baarai/artex

    LLM multi-agent autonomous penetration testing platform with planner/worker agents, asset and exploration graphs, MITM traffic recording, and vulnerability retesting.

    348
  • 5

    looking-glass

    anonghosty/looking-glass

    CSIRT platform that ingests Shadowserver reports into MongoDB and replays them as interactive maps, analysis, findings, advisories and executive dashboards.

    336
  • 6

    CyberStrikeAI

    ed1s0nz/cyberstrikeai

    The system of action for AI-native cybersecurity—where intent becomes governed execution, evidence becomes operational memory, and every operation improves the next.

    288

Explore all tools

Browse our collection of tools

View all tools →