lanScan/scan_all.sh
2023-04-13 15:46:47 +02:00

15 lines
312 B
Bash
Executable File

#!/usr/bin/env bash
DIR="$(dirname -- "$0")"
mkdir -p "$DIR/scans"
mkdir -p "$DIR/site"
for conf in confs/*.yaml
do
site="$(basename ${conf/.yaml/})"
php "$DIR/to_xml.php" $conf > "$DIR/site/$site.xml"
php "$DIR/nmap_cmd.php" $conf | sh
mv "$DIR/scans/.~$site.xml" "$DIR/scans/$site.xml"
done