From c46cc50bc9489cd052c24c7afaf5e89379936327 Mon Sep 17 00:00:00 2001 From: bellma101 Date: Mon, 11 Mar 2019 12:46:51 -0500 Subject: [PATCH] Removed extra sudo that was hanging the script. --- chomp-scan.sh | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/chomp-scan.sh b/chomp-scan.sh index 42b34c7..355f370 100755 --- a/chomp-scan.sh +++ b/chomp-scan.sh @@ -1080,14 +1080,13 @@ function run_masscan() { if [[ "$NOTICA" != "" ]]; then run_notica_sudo; fi - sudo "$MASSCAN" -p1-65535 -iL "$WORKING_DIR"/$ALL_IP --rate=7000 -oL "$WORKING_DIR"/masscan-output.txt; + sudo "$MASSCAN" -p1-65535 -iL "$WORKING_DIR"/$ALL_IP --rate=7000 -oL "$WORKING_DIR"/root-masscan-output.txt; END=$(date +%s); DIFF=$(( END - START )); echo -e "$GREEN""[i]$BLUE Masscan took $DIFF seconds to run.""$NC"; # Trim # from first and last lines of output - grep -v '#' "$WORKING_DIR"/masscan-output.txt > "$WORKING_DIR"/temp; - sudo mv "$WORKING_DIR"/temp "$WORKING_DIR"/masscan-output.txt; + grep -v '#' "$WORKING_DIR"/root-masscan-output.txt > "$WORKING_DIR"/masscan-output.txt; fi }