leebaird / discover

Custom bash scripts used to automate various penetration testing tasks including recon, scanning, enumeration, and malicious payload creation using Metasploit. For use with Kali Linux.
MIT License
3.41k stars 819 forks source link

Running a Passive scan deletes passive.sh #146

Closed M-Associates closed 4 years ago

M-Associates commented 4 years ago

Everytime I run a passive scan from the latest pull, it completes then when I go to run another the passive.sh file has been deleted somehow. The only way round this is to create a new passive.sh file and chmod after each run.

3levated-Kn0wledge commented 4 years ago

Hey,

Hope this helps, did a bit of a workaround for this issue which I've copied below.

Step 1: copy passive.sh file to root folder

Step 2: open domain.sh file and replace 1) $discover/passive.sh && exit;;

With

1) cd; cp passive.sh /root/discover; cd /root/discover; chmod +x passive.sh; $discover/passive.sh && exit;;

Hope that makes sense :)

leebaird commented 4 years ago

Found the mistake, changed line 788 in passive.sh mv passive* $home/data/$domain/tools/recon-ng/ to mv passive.rc passive2.rc $home/data/$domain/tools/recon-ng/