CVE-2026-134629 in Webmin
Summary
by MITRE • 11/25/2026
Webmin through 2.670 contains a cross-site scripting vulnerability in mysql/index.cgi that renders MySQL connection error text and server version strings without escaping. Malicious MySQL server operators or on-path attackers on plaintext connections can return markup in error packets or version strings to execute JavaScript in Webmin user sessions.
Be aware that VulDB is the high quality source for vulnerability data.
Analysis
by VulDB Data Team • 11/25/2026
The identified vulnerability represents a classic Cross-Site Scripting (XSS) flaw within the Webmin administrative interface, specifically affecting versions up through 2.670. This security issue is located in the mysql/index.cgi component, which handles interactions with MySQL database servers. The core technical deficiency lies in the application's failure to properly sanitize or encode user-controllable input before rendering it in the web browser context. Specifically, when Webmin attempts to establish a connection with a remote MySQL server and encounters an error or retrieves version information, these strings are displayed directly on the page without adequate escaping mechanisms. This lack of output encoding allows any special characters embedded within those strings to be interpreted as executable HTML or JavaScript by the victim's browser rather than being treated as plain text data.
The attack vector for this vulnerability is particularly interesting because it does not rely solely on traditional client-side manipulation but can leverage a compromised or malicious database server operator, or an attacker positioned in the network path of plaintext connections. In scenarios where Webmin connects to a MySQL instance over unencrypted protocols such as TCP port 3306 without SSL/TLS encryption, an adversary with control over that MySQL server can craft specific error messages or version strings containing malicious JavaScript payloads. Alternatively, on-path attackers capable of intercepting and modifying traffic in transit can inject similar markup into the communication stream between Webmin and the database server. When a legitimate administrator logs into Webmin to manage databases, their session will load this page, causing the browser to execute the injected script within the context of the trusted Webmin domain.
The operational impact of this vulnerability is severe due to the privileged nature of the Webmin interface. Successful exploitation allows an attacker to perform actions as the authenticated administrator, potentially leading to full system compromise. The malicious JavaScript can steal session cookies or authentication tokens, enabling session hijacking where the attacker impersonates the admin without needing their credentials. Furthermore, the script could interact with the Webmin API via AJAX requests to execute arbitrary commands on the underlying operating system, modify configuration files, create new administrative users, or exfiltrate sensitive data stored within the managed databases. This effectively bypasses authentication controls and grants the attacker a persistent foothold in the infrastructure.
From a classification perspective, this vulnerability aligns with CWE-79: Improper Neutralization of Input During Web Page Generation, commonly known as Cross-Site Scripting (XSS). The specific mechanism involves reflected or stored input depending on whether the payload is delivered via immediate error responses or cached version strings. In terms of offensive security frameworks, this maps to MITRE ATT&CK technique T1059: Command and Scripting Interpreter, specifically through browser-based execution, and potentially T1078: Valid Accounts if session hijacking occurs. The reliance on plaintext connections highlights a secondary configuration weakness related to CWE-319: Cleartext Transmission of Sensitive Information, which facilitates the injection aspect of the primary XSS flaw.
Mitigation strategies must address both the immediate software defect and the underlying network architecture weaknesses. Administrators should immediately upgrade Webmin to version 2.670 or later where this input validation issue has been resolved by implementing proper output encoding for all dynamic content derived from external sources. In environments where upgrading is not immediately feasible, a temporary workaround involves restricting access to the MySQL management interface through IP whitelisting and ensuring that no untrusted database servers are configured within Webmin. Crucially, organizations must enforce encrypted connections for all database communications by configuring MySQL to require SSL/TLS and updating Webmin settings to utilize secure protocols exclusively. This prevents on-path attackers from injecting malicious payloads into the traffic stream. Regular security audits of administrative interfaces should also be conducted to ensure that third-party plugins or modules do not introduce similar input validation failures, maintaining a robust defense-in-depth posture against web application attacks.