我想在我的webapp(滲透測試)中創建一個表單,要求一個目標和一些選項,然後採用這些參數並執行一個運行ruby文件的系統命令在同一個目錄中。按以下格式「紅寶石file.rb -u $目標$選項」,並輸出結果,謝謝 這是我創建並dident工作在webform(系統命令)中的php post問題
<html>
<body>
<form action="test.php" method="post">
Target: <input type="text" name="target"><br>
<input type="submit">
<select name="taskOption">
<option>First</option>
<option>Second</option>
<option>Third</option>
</select>
</form>
的形式,這是test.php的
<?php
echo '<pre>';
$last_line = system('ruby file.rb -u $target $option', $retval);
// Printing additional info
echo "$retval"
?>
去吧。如果你在這個過程中遇到了問題,請回過頭來問一下,但我們不是在這裏爲你做的。 – aynber
告訴我們你發佈了什麼代碼 –
其實我的朋友,我做過 –