From 3d3c18eabc43033cfb787a65ea752cf12fce0dbc Mon Sep 17 00:00:00 2001 From: Menzo Wijmenga Date: Mon, 12 Jun 2017 09:41:57 +0700 Subject: [PATCH] When running Sn1per in NUKE mode the $TARGET is used for report name and target list path. By using $(basename $TARGET) for the report name and $(realpath $TARGET) for a absolute path to the target list we limit r/w conflicts --- sniper | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sniper b/sniper index 856230e..1bd1fb1 100644 --- a/sniper +++ b/sniper @@ -662,10 +662,10 @@ fi if [ "$MODE" = "nuke" ]; then if [ "$OPT1" = "report" ]; then - sniper $TARGET $MODE | tee $LOOT_DIR/sniper-$TARGET-$MODE-`date +%Y%m%d%H%M`.txt 2>&1 + sniper $(realpath $TARGET) $MODE | tee $LOOT_DIR/sniper-$(basename $TARGET)-$MODE-`date +%Y%m%d%H%M`.txt 2>&1 exit fi - for a in `cat $TARGET`; do + for a in `cat $(realpath $TARGET)`; do echo -e "$OKRED " echo -e "$OKRED ____" echo -e "$OKRED __,-~~/~ \`---."