scan_all in bash script
This commit is contained in:
@ -1,4 +1,6 @@
|
||||
<?php
|
||||
set_time_limit(0);
|
||||
|
||||
if (! function_exists('str_ends_with')) {
|
||||
function str_ends_with(string $haystack, string $needle): bool {
|
||||
$needle_len = strlen($needle);
|
||||
@ -49,7 +51,7 @@ XML
|
||||
$targets = join(array_keys($targets), " ");
|
||||
$services = join(array_keys($services), ",");
|
||||
|
||||
`nmap -v -Pn -p $services --script smb-enum-shares,'$__DIR__/nmap' -oX '$__DIR__/scans/.~$site.xml' $targets && mv '$__DIR__/scans/.~$site.xml' '$__DIR__/scans/$site.xml'`;
|
||||
`nmap -v -Pn -p $services --script smb-enum-shares,"$__DIR__/nmap" -oX "$__DIR__/scans/.~$site.xml" $targets && mv "$__DIR__/scans/.~$site.xml" "$__DIR__/scans/$site.xml"`;
|
||||
|
||||
$xml->asXML("$__DIR__/site/$site.xml");
|
||||
}
|
||||
|
Reference in New Issue
Block a user