mirror of
https://github.com/unraid/webgui.git
synced 2026-01-20 16:40:17 -06:00
Plug Security Hole In Docker Template PostArgs
Hole allows arbitrary execution of bash commands on host
This commit is contained in:
@@ -441,7 +441,9 @@ function xmlToCommand($xml, $create_paths=false) {
|
||||
|
||||
function execCommand($command) {
|
||||
// $command should have all its args already properly run through 'escapeshellarg'
|
||||
|
||||
$cmdTmp = explode(";",$command);
|
||||
$command = $cmdTmp[0];
|
||||
|
||||
$descriptorspec = [
|
||||
0 => ["pipe", "r"], // stdin is a pipe that the child will read from
|
||||
1 => ["pipe", "w"], // stdout is a pipe that the child will write to
|
||||
|
||||
Reference in New Issue
Block a user