reconFTW is a tool designed to perform automated recon on a target domain by running the best set of tools to perform scanning and finding out vulnerabilities
Shell bug-bountybugbountybugbounty-tooldnshackingnucleiosintpenetration-testingpentestpentest-toolpentestingreconreconnaissancescannersecuritysecurity-toolssubdomainsubdomain-enumerationvulnerabilities
Nuclei random headers && proxify feature
six2dezfee2ed6912a9
diff --git a/reconftw.cfg b/reconftw.cfgindex 8fdbfad..c185541 100644--- a/reconftw.cfg+++ b/reconftw.cfg@@ -14,11 +14,11 @@ reset='\033[0m'# General valuestools=~/Tools-NPROC=$(nproc || echo -n 1)SCRIPTPATH="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )"profile_shell=".$(basename $(echo $SHELL))rc"reconftw_version=$(git branch --show-current)-$(git describe --tags)update_resolvers=true+proxy_url="http://127.0.0.1:8080/"#dir_output=/custom/output/path# Golang Vars (Comment or change on your own)@@ -106,6 +106,7 @@ NOTIFICATION=falseDEEP=falseDIFF=falseREMOVETMP=false+PROXY=false# HTTP optionsHEADER="User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:72.0) Gecko/20100101 Firefox/72.0"diff --git a/reconftw.sh b/reconftw.shindex 7703ae3..06e10dd 100755--- a/reconftw.sh+++ b/reconftw.sh@@ -320,26 +320,27 @@ function sub_passive(){if [ ! -f "$called_fn_dir/.${FUNCNAME[0]}" ] || [ "$DIFF" = true ]thenstart_subfunc "Running : Passive Subdomain Enumeration"- eval subfinder -d $domain -o .tmp/subfinder_psub.txt $DEBUG_STD- eval assetfinder --subs-only $domain $DEBUG_ERROR | anew -q .tmp/assetfinder_psub.txt- eval amass enum -passive -d $domain -config $AMASS_CONFIG -o .tmp/amass_psub.txt $DEBUG_STD- eval findomain --quiet -t $domain -u .tmp/findomain_psub.txt $DEBUG_STD- eval crobat -s $domain $DEBUG_ERROR | anew -q .tmp/crobat_psub.txt+ eval subfinder -d $domain -o .tmp/subfinder_psub.txt $DEBUG_STD &+ eval assetfinder --subs-only $domain $DEBUG_ERROR | anew -q .tmp/assetfinder_psub.txt &+ eval amass enum -passive -d $domain -config $AMASS_CONFIG -o .tmp/amass_psub.txt $DEBUG_STD &+ eval findomain --quiet -t $domain -u .tmp/findomain_psub.txt $DEBUG_STD &+ eval crobat -s $domain $DEBUG_ERROR | anew -q .tmp/crobat_psub.txt &if [ -s "${GITHUB_TOKENS}" ];thenif [ "$DEEP" = true ] ; then- eval github-subdomains -d $domain -t $GITHUB_TOKENS -o .tmp/github_subdomains_psub.txt $DEBUG_STD+ eval github-subdomains -d $domain -t $GITHUB_TOKENS -o .tmp/github_subdomains_psub.txt $DEBUG_STD &else- eval github-subdomains -d $domain -k -q -t $GITHUB_TOKENS -o .tmp/github_subdomains_psub.txt $DEBUG_STD+ eval github-subdomains -d $domain -k -q -t $GITHUB_TOKENS -o .tmp/github_subdomains_psub.txt $DEBUG_STD &fifi- eval curl -s "https://jldc.me/anubis/subdomains/${domain}" $DEBUG_ERROR | grep -Po "((http|https):\/\/)?(([\w.-]*)\.([\w]*)\.([A-z]))\w+" | sed '/^\./d' | anew -q .tmp/jldc_psub.txt- timeout 10m waybackurls $domain | unfurl --unique domains | anew -q .tmp/waybackurls_psub.txt- timeout 10m gauplus -t $GAUPLUS_THREADS -random-agent -subs $domain | unfurl --unique domains | anew -q .tmp/gau_psub.txt+ eval curl -s "https://jldc.me/anubis/subdomains/${domain}" $DEBUG_ERROR | grep -Po "((http|https):\/\/)?(([\w.-]*)\.([\w]*)\.([A-z]))\w+" | sed '/^\./d' | anew -q .tmp/jldc_psub.txt &+ timeout 10m waybackurls $domain | unfurl --unique domains | anew -q .tmp/waybackurls_psub.txt &+ timeout 10m gauplus -t $GAUPLUS_THREADS -random-agent -subs $domain | unfurl --unique domains | anew -q .tmp/gau_psub.txt &if echo $domain | grep -q ".mil$"; thenmildewmv mildew.out .tmp/mildew.outcat .tmp/mildew.out | grep ".$domain$" | anew -q .tmp/mil_psub.txtfi+ wait $(jobs -rp)NUMOFLINES=$(eval cat .tmp/*_psub.txt $DEBUG_ERROR | sed "s/*.//" | anew .tmp/passive_subs.txt | wc -l)end_subfunc "${NUMOFLINES} new subs (passive)" ${FUNCNAME[0]}else@@ -553,7 +554,7 @@ function subtakeover(){thenstart_func "Looking for possible subdomain takeover"touch .tmp/tko.txt- cat webs/webs.txt | nuclei -silent -H "${HEADER}" -t ~/nuclei-templates/takeovers/ -r $resolvers_trusted -o .tmp/tko.txt+ cat webs/webs.txt | nuclei -silent -t ~/nuclei-templates/takeovers/ -r $resolvers_trusted -o .tmp/tko.txtNUMOFLINES=$(eval cat .tmp/tko.txt $DEBUG_ERROR | anew webs/takeover.txt | wc -l)if [ "$NUMOFLINES" -gt 0 ]; thennotification "${NUMOFLINES} new possible takeovers found" info@@ -621,7 +622,15 @@ function webprobe_simple(){deleteOutScoped $outOfScope_file .tmp/probed_tmp.txtNUMOFLINES=$(eval cat .tmp/probed_tmp.txt $DEBUG_ERROR | anew webs/webs.txt | wc -l)+end_subfunc "${NUMOFLINES} new websites resolved" ${FUNCNAME[0]}++ if [ "$PROXY" = true ] && [ ! -z "$proxy_url" ]+ then+ notification "Sending websites to proxy" info+ eval ffuf -mc all -w webs/webs.txt -u FUZZ -replay-proxy $proxy_url $DEBUG_STD+ fi+elseif [ "$WEBPROBESIMPLE" = false ]; thenprintf "\n${yellow} ${FUNCNAME[0]} skipped in this mode or defined in reconftw.cfg ${reset}\n"@@ -640,6 +649,11 @@ function webprobe_full(){notification "Uncommon web ports: ${NUMOFLINES} new websites" goodeval cat webs/webs_uncommon_ports.txt $DEBUG_ERRORend_func "Results are saved in webs/webs_uncommon_ports.txt" ${FUNCNAME[0]}+ if [ "$PROXY" = true ] && [ ! -z "$proxy_url" ]+ then+ notification "Sending websites uncommon ports to proxy" info+ eval ffuf -mc all -w webs/webs_uncommon_ports.txt -u FUZZ -replay-proxy $proxy_url $DEBUG_STD+ fielseif [ "$WEBPROBEFULL" = false ]; thenprintf "\n${yellow} ${FUNCNAME[0]} skipped in this mode or defined in reconftw.cfg ${reset}\n"@@ -779,23 +793,23 @@ function nuclei_check(){eval nuclei -update-templates $DEBUG_STDmkdir -p nuclei_outputprintf "${yellow}\n Running : Nuclei Technologies${reset}\n\n"- cat webs/webs.txt | nuclei -silent -H "${HEADER}" -t ~/nuclei-templates/technologies/ -r $resolvers_trusted -o nuclei_output/technologies.txt+ cat webs/webs.txt | nuclei -silent -t ~/nuclei-templates/technologies/ -r $resolvers_trusted -o nuclei_output/technologies.txtprintf "${yellow}\n\n Running : Nuclei Tokens${reset}\n\n"- cat webs/webs.txt | nuclei -silent -H "${HEADER}" -t ~/nuclei-templates/exposed-tokens/ -r $resolvers_trusted -o nuclei_output/tokens.txt+ cat webs/webs.txt | nuclei -silent -t ~/nuclei-templates/exposed-tokens/ -r $resolvers_trusted -o nuclei_output/tokens.txtprintf "${yellow}\n\n Running : Nuclei Exposures${reset}\n\n"- cat webs/webs.txt | nuclei -silent -H "${HEADER}" -t ~/nuclei-templates/exposures/ -r $resolvers_trusted -o nuclei_output/exposures.txt+ cat webs/webs.txt | nuclei -silent -t ~/nuclei-templates/exposures/ -r $resolvers_trusted -o nuclei_output/exposures.txtprintf "${yellow}\n\n Running : Nuclei CVEs ${reset}\n\n"- cat webs/webs.txt | nuclei -silent -H "${HEADER}" -t ~/nuclei-templates/cves/ -r $resolvers_trusted -o nuclei_output/cves.txt+ cat webs/webs.txt | nuclei -silent -t ~/nuclei-templates/cves/ -r $resolvers_trusted -o nuclei_output/cves.txtprintf "${yellow}\n\n Running : Nuclei Default Creds ${reset}\n\n"- cat webs/webs.txt | nuclei -silent -H "${HEADER}" -t ~/nuclei-templates/default-logins/ -r $resolvers_trusted -o nuclei_output/default_creds.txt+ cat webs/webs.txt | nuclei -silent -t ~/nuclei-templates/default-logins/ -r $resolvers_trusted -o nuclei_output/default_creds.txtprintf "${yellow}\n\n Running : Nuclei DNS ${reset}\n\n"- cat webs/webs.txt | nuclei -silent -H "${HEADER}" -t ~/nuclei-templates/dns/ -r $resolvers_trusted -o nuclei_output/dns.txt+ cat webs/webs.txt | nuclei -silent -t ~/nuclei-templates/dns/ -r $resolvers_trusted -o nuclei_output/dns.txtprintf "${yellow}\n\n Running : Nuclei Panels ${reset}\n\n"- cat webs/webs.txt | nuclei -silent -H "${HEADER}" -t ~/nuclei-templates/exposed-panels/ -r $resolvers_trusted -o nuclei_output/panels.txt+ cat webs/webs.txt | nuclei -silent -t ~/nuclei-templates/exposed-panels/ -r $resolvers_trusted -o nuclei_output/panels.txtprintf "${yellow}\n\n Running : Nuclei Security Misconfiguration ${reset}\n\n"- cat webs/webs.txt | nuclei -silent -H "${HEADER}" -t ~/nuclei-templates/misconfiguration/ -r $resolvers_trusted -o nuclei_output/misconfigurations.txt+ cat webs/webs.txt | nuclei -silent -t ~/nuclei-templates/misconfiguration/ -r $resolvers_trusted -o nuclei_output/misconfigurations.txtprintf "${yellow}\n\n Running : Nuclei Vulnerabilites ${reset}\n\n"- cat webs/webs.txt | nuclei -silent -H "${HEADER}" -t ~/nuclei-templates/vulnerabilities/ -r $resolvers_trusted -o nuclei_output/vulnerabilities.txt+ cat webs/webs.txt | nuclei -silent -t ~/nuclei-templates/vulnerabilities/ -r $resolvers_trusted -o nuclei_output/vulnerabilities.txtprintf "\n\n"end_func "Results are saved in nuclei_output folder" ${FUNCNAME[0]}else@@ -917,6 +931,11 @@ function urlchecks(){NUMOFLINES=$(eval cat .tmp/url_extract_uddup.txt $DEBUG_ERROR | anew webs/url_extract.txt | wc -l)notification "${NUMOFLINES} new urls with params" infoend_func "Results are saved in webs/url_extract.txt" ${FUNCNAME[0]}+ if [ "$PROXY" = true ] && [ ! -z "$proxy_url" ] && [[ $(cat webs/url_extract.txt | wc -l) -le 1000 ]]+ then+ notification "Sending urls to proxy" info+ eval ffuf -mc all -w webs/url_extract.txt -u FUZZ -replay-proxy $proxy_url $DEBUG_STD+ fielseprintf "${yellow} ${FUNCNAME[0]} is already processed, to force executing ${FUNCNAME[0]} delete $called_fn_dir/.${FUNCNAME[0]} ${reset}\n\n"fi