Cockpit before 0.6.1 allows an attacker to inject custom PHP code and achieve Remote Command Execution via registerCriteriaFunction in lib/MongoLite/Database.php, as demonstrated by values in JSON data to the /auth/check or /auth/requestreset URI.
{
"cpe": "cpe:2.3:a:agentejo:cockpit:*:*:*:*:*:*:*:*",
"extracted_events": [
{
"introduced": "0"
},
{
"fixed": "0.6.1"
}
],
"source": [
"CPE_RANGE",
"REFERENCES"
]
}