First version of Hosts Up ready and working

This commit is contained in:
2014-06-03 19:11:13 +02:00
parent 2f2e8d9185
commit df0d784126
11 changed files with 206 additions and 60 deletions

22
scan.php Normal file
View File

@@ -0,0 +1,22 @@
<?php
include("htmlblock.html");
print "<h1>Open ports on $_GET[host]</h1>\n";
print "<pre>\n";
$portscan = shell_exec("nmap $_GET[host]");
preg_match_all('/[0-9]{1,5}\/..p.*/', $portscan, $openports);
foreach ($openports[0] as $out)
{
print "$out\n";
}
?>
</pre>
</div>
</body>
</html>