Skip to content

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

Fixes prints and status

six2dez67dbbc7efe12
diff --git a/modules/osint.sh b/modules/osint.sh
index 58f6c5d..ac8b489 100644
--- a/modules/osint.sh
+++ b/modules/osint.sh
@@ -109,7 +109,7 @@ function github_repos() {
if [[ -s ".tmp/github_repos_folders.txt" ]]; then
if ! interlace -tL .tmp/github_repos_folders.txt -threads "$INTERLACE_THREADS" -c "gitleaks detect --source .tmp/github_repos/_target_ --no-banner --no-color -r .tmp/github/gh_secret_cleantarget_.json" 2>>"$LOGFILE" >/dev/null; then
_print_error "interlace gitleaks command failed"
- end_func "Results are saved in $domain/osint/github_company_secrets.json" "${FUNCNAME[0]}"
+ end_func "Results are saved in $domain/osint/github_company_secrets.json" "${FUNCNAME[0]}" FAIL
return 1
fi
else
@@ -335,11 +335,11 @@ function apileaks() {
end_func "Results are saved in $domain/osint/[postman_leaks_trufflehog.json, swagger_leaks_trufflehog.json]" "${FUNCNAME[0]}"
else
if [[ $API_LEAKS == false ]] || [[ $OSINT == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or configuration settings."
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
return
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
}
@@ -384,11 +384,11 @@ function emails() {
end_func "Results are saved in $domain/osint/emails.txt and passwords.txt" "${FUNCNAME[0]}"
else
if [[ $EMAILS == false ]] || [[ $OSINT == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or configuration settings."
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
return
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
}
@@ -415,11 +415,11 @@ function domain_info() {
else
if [[ $DOMAIN_INFO == false ]] || [[ $OSINT == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or configuration settings."
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
return
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
}
@@ -461,11 +461,11 @@ function third_party_misconfigs() {
else
if [[ $THIRD_PARTIES == false ]] || [[ $OSINT == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or configuration settings."
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
return
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
}
@@ -501,11 +501,11 @@ function spoof() {
else
if [[ $SPOOF == false ]] || [[ $OSINT == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or configuration settings."
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
return
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
}
@@ -528,11 +528,11 @@ function mail_hygiene() {
end_func "Results are saved in $domain/osint/mail_hygiene.txt" "${FUNCNAME[0]}"
else
if [[ $MAIL_HYGIENE == false ]] || [[ $OSINT == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or configuration settings."
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
return
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
}
@@ -544,17 +544,21 @@ function cloud_enum_scan() {
&& [[ $CLOUD_ENUM == true ]] && [[ $OSINT == true ]] \
&& ! [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
+ if ! command -v cloud_enum >/dev/null 2>&1; then
+ _print_msg WARN "${FUNCNAME[0]}: cloud_enum not found in PATH"
+ return 0
+ fi
start_func "${FUNCNAME[0]}" "Cloud storage enumeration"
company_name=$(unfurl format %r <<<"$domain")
run_command cloud_enum -k "$company_name" -k "$domain" -k "${domain%%.*}" 2>>"$LOGFILE" | anew -q osint/cloud_enum.txt
end_func "Results are saved in $domain/osint/cloud_enum.txt" "${FUNCNAME[0]}"
else
if [[ $CLOUD_ENUM == false ]] || [[ $OSINT == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or configuration settings."
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
return
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
}
@@ -592,15 +596,16 @@ function ip_info() {
else
_print_msg WARN "WHOISXML_API variable is not defined. Skipping function."
+ end_func "WHOISXML_API not configured, ip_info skipped." "${FUNCNAME[0]}"
fi
else
if [[ $IP_INFO == false ]] || [[ $OSINT == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or configuration settings."
+ skip_notification "disabled"
elif ! [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
return
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
diff --git a/modules/subdomains.sh b/modules/subdomains.sh
index cd8952f..55b3616 100644
--- a/modules/subdomains.sh
+++ b/modules/subdomains.sh
@@ -490,9 +490,9 @@ function sub_asn() {
end_subfunc "${FUNCNAME[0]}" "${FUNCNAME[0]}" "${asn_status:-OK}"
else
if [[ $ASN_ENUM == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to configuration settings."
+ skip_notification "disabled"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
}
@@ -537,9 +537,9 @@ function sub_passive() {
else
if [[ $SUBPASSIVE == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or configuration settings."
+ skip_notification "disabled"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -617,9 +617,9 @@ function sub_crt() {
end_subfunc "${NUMOFLINES} new subs (cert transparency)" "${FUNCNAME[0]}"
else
if [[ $SUBCRT == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or defined in reconftw.cfg."
+ skip_notification "disabled"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
}
@@ -694,7 +694,7 @@ function sub_active() {
end_subfunc "${NUMOFLINES} subs DNS resolved from passive" "${FUNCNAME[0]}"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
}
@@ -772,7 +772,7 @@ function sub_tls() {
end_subfunc "${NUMOFLINES} new subs (tls active enum)" "${FUNCNAME[0]}"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
}
@@ -821,13 +821,14 @@ function sub_noerror() {
else
_print_msg WARN "Detected DNSSEC black lies, skipping this technique."
+ end_subfunc "DNSSEC black lies detected, sub_noerror skipped." "${FUNCNAME[0]}"
fi
else
if [[ $SUBNOERROR == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or defined in reconftw.cfg."
+ skip_notification "disabled"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -915,7 +916,7 @@ function sub_dns() {
end_subfunc "${NUMOFLINES} new subs (dns resolution)" "${FUNCNAME[0]}"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
}
@@ -982,9 +983,9 @@ function sub_brute() {
else
if [[ $SUBBRUTE == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or defined in reconftw.cfg."
+ skip_notification "disabled"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -1157,9 +1158,9 @@ function sub_scraping() {
else
if [[ $SUBSCRAPING == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or defined in reconftw.cfg."
+ skip_notification "disabled"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -1226,9 +1227,9 @@ function sub_analytics() {
else
if [[ $SUBANALYTICS == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or defined in reconftw.cfg."
+ skip_notification "disabled"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
}
@@ -1378,9 +1379,9 @@ function sub_permut() {
else
if [[ $SUBPERMUTE == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or defined in reconftw.cfg."
+ skip_notification "disabled"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -1465,9 +1466,9 @@ function sub_regex_permut() {
else
if [[ $SUBREGEXPERMUTE == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or defined in reconftw.cfg."
+ skip_notification "disabled"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -1533,9 +1534,9 @@ function sub_ia_permut() {
else
if [[ $SUBIAPERMUTE == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or defined in reconftw.cfg."
+ skip_notification "disabled"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -1622,11 +1623,11 @@ function sub_recursive_passive() {
else
if [[ $SUB_RECURSIVE_PASSIVE == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or defined in reconftw.cfg."
+ skip_notification "disabled"
elif [[ ! -s "subdomains/subdomains.txt" ]]; then
- _print_msg WARN "No subdomains to process."
+ skip_notification "noinput"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -1769,11 +1770,11 @@ function sub_recursive_brute() {
else
if [[ $SUB_RECURSIVE_BRUTE == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or defined in reconftw.cfg."
+ skip_notification "disabled"
elif [[ ! -s "subdomains/subdomains.txt" ]]; then
- _print_msg WARN "No subdomains to process."
+ skip_notification "noinput"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
}
@@ -1789,6 +1790,20 @@ function subtakeover() {
# Check if the function should run
if { [[ ! -f "$called_fn_dir/.${FUNCNAME[0]}" ]] || [[ $DIFF == true ]]; } && [[ $SUBTAKEOVER == true ]]; then
+ if [[ $AXIOM != true ]]; then
+ if ! command -v nuclei >/dev/null 2>&1; then
+ _print_msg WARN "${FUNCNAME[0]}: nuclei binary not found in PATH - install nuclei first"
+ return 0
+ fi
+ if [[ ! -d "${NUCLEI_TEMPLATES_PATH:-}" ]]; then
+ _print_msg WARN "${FUNCNAME[0]}: nuclei templates not found at '${NUCLEI_TEMPLATES_PATH}'"
+ return 0
+ fi
+ fi
+ if ! command -v dnstake >/dev/null 2>&1; then
+ _print_msg WARN "${FUNCNAME[0]}: dnstake binary not found in PATH - install dnstake first"
+ return 0
+ fi
start_func "${FUNCNAME[0]}" "Looking for possible subdomain and DNS takeover"
# Initialize takeover file
@@ -1859,9 +1874,9 @@ function subtakeover() {
else
if [[ $SUBTAKEOVER == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or defined in reconftw.cfg."
+ skip_notification "disabled"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -1901,11 +1916,11 @@ function zonetransfer() {
else
if [[ $ZONETRANSFER == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or defined in reconftw.cfg."
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
- _print_msg WARN "Domain is an IP address; skipping zone transfer."
+ skip_notification "noinput"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -2082,12 +2097,12 @@ function s3buckets() {
end_func "Results are saved in subdomains/s3buckets.txt, subdomains/cloud_assets.txt, subdomains/s3buckets_trufflehog.txt, and subdomains/cloudhunter_buckets_trufflehog.txt" "${FUNCNAME[0]}"
else
if [[ $S3BUCKETS == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or defined in reconftw.cfg."
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
- _print_msg WARN "Domain is an IP address; skipping S3 buckets search."
+ skip_notification "noinput"
return 0
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
}
@@ -2146,9 +2161,9 @@ function geo_info() {
end_func "Results are saved in hosts/ipinfo.txt" "${FUNCNAME[0]}"
else
if [[ $GEO_INFO == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or defined in reconftw.cfg."
+ skip_notification "disabled"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
diff --git a/modules/vulns.sh b/modules/vulns.sh
index 88dc053..0766649 100644
--- a/modules/vulns.sh
+++ b/modules/vulns.sh
@@ -201,6 +201,10 @@ function crlf_checks() {
if { [[ ! -f "$called_fn_dir/.${FUNCNAME[0]}" ]] || [[ $DIFF == true ]]; } && [[ $CRLF_CHECKS == true ]] \
&& ! [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
+ if ! command -v crlfuzz >/dev/null 2>&1; then
+ _print_msg WARN "${FUNCNAME[0]}: crlfuzz not found in PATH"
+ return 0
+ fi
start_func "${FUNCNAME[0]}" "CRLF Checks"
# Combine webs.txt and webs_uncommon_ports.txt into webs_all.txt if it doesn't exist
@@ -438,13 +442,12 @@ function test_ssl() {
end_func "Results are saved in vulns/testssl.txt" "${FUNCNAME[0]}"
else
- # Handle cases where TEST_SSL is false, no vulnerable URLs, or already processed
if [[ $TEST_SSL == false ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped due to configuration"
+ skip_notification "disabled"
elif [[ ! -s "vulns/testssl.txt" ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped: no candidate targets for SSL tests"
+ skip_notification "noinput"
else
- pt_msg_warn "${FUNCNAME[0]} already processed. To force, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -459,6 +462,10 @@ function spraying() {
if { [[ ! -f "$called_fn_dir/.${FUNCNAME[0]}" ]] || [[ $DIFF == true ]]; } && [[ $SPRAY == true ]] \
&& [[ -s "$dir/hosts/portscan_active.gnmap" ]] && ! [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
+ if ! command -v brutespray >/dev/null 2>&1; then
+ _print_msg WARN "${FUNCNAME[0]}: brutespray not found in PATH"
+ return 0
+ fi
start_func "${FUNCNAME[0]}" "Password Spraying"
# Ensure portscan_active.gnmap exists and is not empty
@@ -476,13 +483,12 @@ function spraying() {
end_func "Results are saved in vulns/brutespray folder" "${FUNCNAME[0]}"
else
- # Handle cases where SPRAY is false, required files are missing, or already processed
if [[ $SPRAY == false ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped due to configuration"
+ skip_notification "disabled"
elif [[ ! -s "$dir/hosts/portscan_active.gnmap" ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped: missing active port scan"
+ skip_notification "noinput"
else
- pt_msg_warn "${FUNCNAME[0]} already processed. To force, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -548,14 +554,14 @@ function 4xxbypass() {
&& ! [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
# Extract relevant URLs starting with 4xx but not 404
- _print_msg INFO "Running: 403 Bypass"
grep -E '^4' "fuzzing/fuzzing_full.txt" 2>/dev/null | grep -Ev '^404' | awk '{print $3}' | anew -q ".tmp/403test.txt"
# Count the number of URLs to process
URL_COUNT=$(wc -l <".tmp/403test.txt")
- if [[ $DEEP == true ]] || [[ $URL_COUNT -le $DEEP_LIMIT ]]; then
- start_func "${FUNCNAME[0]}" "403 Bypass"
+ start_func "${FUNCNAME[0]}" "403 Bypass"
+
+ if [[ $DEEP == true ]] || [[ $URL_COUNT -le $DEEP_LIMIT ]]; then
# Navigate to nomore403 tool directory
if ! pushd "${tools}/nomore403" >/dev/null; then
@@ -587,13 +593,12 @@ function 4xxbypass() {
fi
else
- # Handle cases where BYPASSER4XX is false, no vulnerable URLs, or already processed
if [[ $BYPASSER4XX == false ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped due to configuration"
+ skip_notification "disabled"
elif [[ ! -s "fuzzing/fuzzing_full.txt" ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped: no candidate URLs for 4xx bypass"
+ skip_notification "noinput"
else
- pt_msg_warn "${FUNCNAME[0]} already processed. To force, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -608,6 +613,10 @@ function smuggling() {
if { [[ ! -f "$called_fn_dir/.${FUNCNAME[0]}" ]] || [[ $DIFF == true ]]; } && [[ $SMUGGLING == true ]] \
&& ! [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
+ if ! command -v smugglex >/dev/null 2>&1; then
+ _print_msg WARN "${FUNCNAME[0]}: smugglex not found in PATH"
+ return 0
+ fi
start_func "${FUNCNAME[0]}" "HTTP Request Smuggling Checks"
# Combine webs.txt and webs_uncommon_ports.txt into webs_all.txt if it doesn't exist
@@ -637,13 +646,12 @@ function smuggling() {
fi
else
- # Handle cases where SMUGGLING is false, no vulnerable URLs, or already processed
if [[ $SMUGGLING == false ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped due to configuration"
+ skip_notification "disabled"
elif [[ ! -s "webs/webs_all.txt" ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped: no candidate URLs for HTTP request smuggling"
+ skip_notification "noinput"
else
- pt_msg_warn "${FUNCNAME[0]} already processed. To force, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -658,6 +666,10 @@ function webcache() {
if { [[ ! -f "$called_fn_dir/.${FUNCNAME[0]}" ]] || [[ $DIFF == true ]]; } && [[ $WEBCACHE == true ]] \
&& ! [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
+ if ! command -v Web-Cache-Vulnerability-Scanner >/dev/null 2>&1; then
+ _print_msg WARN "${FUNCNAME[0]}: Web-Cache-Vulnerability-Scanner not found in PATH"
+ return 0
+ fi
start_func "${FUNCNAME[0]}" "Web Cache Poisoning Checks"
# Combine webs.txt and webs_uncommon_ports.txt into webs_all.txt if it doesn't exist
@@ -710,13 +722,12 @@ function webcache() {
fi
else
- # Handle cases where WEBCACHE is false, no vulnerable URLs, or already processed
if [[ $WEBCACHE == false ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped due to configuration"
+ skip_notification "disabled"
elif [[ ! -s "fuzzing/fuzzing_full.txt" ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped: no candidate URLs for web cache tests"
+ skip_notification "noinput"
else
- pt_msg_warn "${FUNCNAME[0]} already processed. To force, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -731,6 +742,16 @@ function fuzzparams() {
if { [[ ! -f "$called_fn_dir/.${FUNCNAME[0]}" ]] || [[ $DIFF == true ]]; } && [[ $FUZZPARAMS == true ]] \
&& ! [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
+ if [[ $AXIOM != true ]]; then
+ if ! command -v nuclei >/dev/null 2>&1; then
+ _print_msg WARN "${FUNCNAME[0]}: nuclei binary not found in PATH - install nuclei first"
+ return 0
+ fi
+ if [[ ! -d "${NUCLEI_TEMPLATES_PATH:-}" ]]; then
+ _print_msg WARN "${FUNCNAME[0]}: nuclei templates not found at '${NUCLEI_TEMPLATES_PATH}'"
+ return 0
+ fi
+ fi
start_func "${FUNCNAME[0]}" "Fuzzing Parameters Values Checks"
if [[ ! -s "webs/url_extract_nodupes.txt" ]]; then
@@ -799,13 +820,12 @@ function fuzzparams() {
fi
else
- # Handle cases where FUZZPARAMS is false, no vulnerable URLs, or already processed
if [[ $FUZZPARAMS == false ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped due to configuration"
+ skip_notification "disabled"
elif [[ ! -s "webs/url_extract_nodupes.txt" ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped: no candidate URLs for parameter fuzzing"
+ skip_notification "noinput"
else
- pt_msg_warn "${FUNCNAME[0]} already processed. To force, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -847,6 +867,16 @@ function nuclei_dast() {
fi
if { [[ ! -f "$called_fn_dir/.${FUNCNAME[0]}" ]] || [[ $DIFF == true ]]; } && [[ "$dast_enabled" == true ]]; then
+ if [[ $AXIOM != true ]]; then
+ if ! command -v nuclei >/dev/null 2>&1; then
+ _print_msg WARN "${FUNCNAME[0]}: nuclei binary not found in PATH - install nuclei first"
+ return 0
+ fi
+ if [[ ! -d "${NUCLEI_TEMPLATES_PATH:-}" ]]; then
+ _print_msg WARN "${FUNCNAME[0]}: nuclei templates not found at '${NUCLEI_TEMPLATES_PATH}'"
+ return 0
+ fi
+ fi
start_func "${FUNCNAME[0]}" "Nuclei DAST Scanner"
maybe_update_nuclei
@@ -893,9 +923,9 @@ function nuclei_dast() {
end_func "Results are saved in nuclei_output/dast_json.txt and vulns/nuclei_dast.txt" "${FUNCNAME[0]}"
else
if [[ "$dast_enabled" == false ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped due to configuration"
+ skip_notification "disabled"
else
- pt_msg_warn "${FUNCNAME[0]} already processed. To force, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
}
diff --git a/modules/web.sh b/modules/web.sh
index 03b10bc..7253c7f 100644
--- a/modules/web.sh
+++ b/modules/web.sh
@@ -208,9 +208,9 @@ function webprobe_simple() {
else
if [[ $WEBPROBESIMPLE == false ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped due to configuration"
+ skip_notification "disabled"
else
- pt_msg_warn "${FUNCNAME[0]} already processed. To force, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -296,9 +296,9 @@ function webprobe_full() {
print_webs_summary
else
if [[ $WEBPROBEFULL == false ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped due to configuration"
+ skip_notification "disabled"
else
- pt_msg_warn "${FUNCNAME[0]} already processed. To force, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -311,6 +311,16 @@ function screenshot() {
# Check if the function should run
if { [[ ! -f "$called_fn_dir/.${FUNCNAME[0]}" ]] || [[ $DIFF == true ]]; } && [[ $WEBSCREENSHOT == true ]]; then
+ if [[ $AXIOM != true ]]; then
+ if ! command -v nuclei >/dev/null 2>&1; then
+ _print_msg WARN "${FUNCNAME[0]}: nuclei binary not found in PATH - install nuclei first"
+ return 0
+ fi
+ if [[ ! -d "${NUCLEI_TEMPLATES_PATH:-}" ]]; then
+ _print_msg WARN "${FUNCNAME[0]}: nuclei templates not found at '${NUCLEI_TEMPLATES_PATH}'"
+ return 0
+ fi
+ fi
start_func "${FUNCNAME[0]}" "Web Screenshots"
# Build/refresh webs_all.txt from current web targets.
@@ -329,9 +339,9 @@ function screenshot() {
end_func "Results are saved in $domain/screenshots" "${FUNCNAME[0]}"
else
if [[ $WEBSCREENSHOT == false ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped due to configuration"
+ skip_notification "disabled"
else
- pt_msg_warn "${FUNCNAME[0]} already processed. To force, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -344,18 +354,18 @@ function virtualhosts() {
# Check if the function should run
if { [[ ! -f "$called_fn_dir/.${FUNCNAME[0]}" ]] || [[ $DIFF == true ]]; } && [[ $VIRTUALHOSTS == true ]]; then
+ if ! command -v VhostFinder >/dev/null 2>&1; then
+ _print_msg WARN "${FUNCNAME[0]}: VhostFinder not found in PATH"
+ return 0
+ fi
start_func "${FUNCNAME[0]}" "Virtual Hosts Discovery"
# Build/refresh webs_all.txt from current web targets.
ensure_webs_all || true
- # Proceed only if webs_all.txt exists and is non-empty
+ # Proceed only if input files exist
if [[ -s "subdomains/subdomains.txt" ]] && [[ -s "hosts/ips.txt" ]]; then
VhostFinder -ips hosts/ips.txt -wordlist subdomains/subdomains.txt -verify | grep "+" | anew -q "$dir/webs/virtualhosts.txt"
- end_func "Results are saved in $domain/webs/virtualhosts.txt" "${FUNCNAME[0]}"
-
- else
- end_func "No subdomains or hosts file found, virtualhosts skipped." "${FUNCNAME[0]}"
fi
# Optionally send to proxy if conditions are met
@@ -364,11 +374,13 @@ function virtualhosts() {
run_command ffuf -mc all -w webs/webs_uncommon_ports.txt -u FUZZ -replay-proxy "$proxy_url" 2>>"$LOGFILE" >/dev/null
fi
+ end_func "Results are saved in $domain/webs/virtualhosts.txt" "${FUNCNAME[0]}"
+
else
if [[ $VIRTUALHOSTS == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped in this mode or defined in reconftw.cfg."
+ skip_notification "disabled"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -427,11 +439,11 @@ function favirecon_tech() {
else
if [[ ${FAVIRECON:-true} == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to configuration settings."
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
return
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
}
@@ -681,9 +693,9 @@ function portscan() {
else
if [[ $PORTSCANNER == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to mode or defined in reconftw.cfg."
+ skip_notification "disabled"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -719,12 +731,11 @@ function cdnprovider() {
else
if [[ $CDN_IP == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to configuration settings."
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
- # Domain is an IP, do nothing
return
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -741,6 +752,10 @@ function waf_checks() {
# Check if the function should run
if { [[ ! -f "$called_fn_dir/.${FUNCNAME[0]}" ]] || [[ $DIFF == true ]]; } && [[ $WAF_DETECTION == true ]]; then
+ if [[ $AXIOM != true ]] && ! command -v wafw00f >/dev/null 2>&1; then
+ _print_msg WARN "${FUNCNAME[0]}: wafw00f not found in PATH"
+ return 0
+ fi
start_func "${FUNCNAME[0]}" "Website's WAF Detection"
ensure_webs_all || true
@@ -780,14 +795,12 @@ function waf_checks() {
end_func "No websites to scan" "${FUNCNAME[0]}"
fi
else
- # Handle cases where WAF_DETECTION is false or the function has already been processed
if [[ $WAF_DETECTION == false ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped due to configuration"
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
- # Domain is an IP address; skip the function
return
else
- pt_msg_warn "${FUNCNAME[0]} already processed. To force, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -949,11 +962,11 @@ function nuclei_check() {
plugins_emit after_nuclei "$domain" "$dir"
else
if [[ $NUCLEICHECK == false ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped due to configuration"
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
return
else
- pt_msg_warn "${FUNCNAME[0]} already processed. To force, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -1001,9 +1014,9 @@ function graphql_scan() {
end_func "Results are saved in nuclei_output/graphql* and vulns/graphql" "${FUNCNAME[0]}"
else
if [[ $GRAPHQL_CHECK == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to configuration settings."
+ skip_notification "disabled"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
}
@@ -1012,6 +1025,10 @@ function param_discovery() {
ensure_dirs webs .tmp
if { [[ ! -f "$called_fn_dir/.${FUNCNAME[0]}" ]] || [[ $DIFF == true ]]; } && [[ $PARAM_DISCOVERY == true ]]; then
+ if ! command -v arjun >/dev/null 2>&1; then
+ _print_msg WARN "${FUNCNAME[0]}: arjun not found in PATH"
+ return 0
+ fi
start_func "${FUNCNAME[0]}" "Parameter discovery (arjun)"
local input_file="webs/url_extract_nodupes.txt"
[[ ! -s $input_file ]] && input_file="webs/webs_all.txt"
@@ -1025,9 +1042,9 @@ function param_discovery() {
end_func "Results are saved in webs/params_discovered.txt" "${FUNCNAME[0]}"
else
if [[ $PARAM_DISCOVERY == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to configuration settings."
+ skip_notification "disabled"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
}
@@ -1036,6 +1053,10 @@ function grpc_reflection() {
ensure_dirs hosts .tmp
if { [[ ! -f "$called_fn_dir/.${FUNCNAME[0]}" ]] || [[ $DIFF == true ]]; } && [[ $GRPC_SCAN == true ]]; then
+ if ! command -v grpcurl >/dev/null 2>&1; then
+ _print_msg WARN "${FUNCNAME[0]}: grpcurl not found in PATH"
+ return 0
+ fi
start_func "${FUNCNAME[0]}" "gRPC reflection probing"
# Build target IP list
local ips_file="hosts/ips.txt"
@@ -1056,9 +1077,9 @@ function grpc_reflection() {
end_func "Results are saved in hosts/grpc_reflection.txt" "${FUNCNAME[0]}"
else
if [[ $GRPC_SCAN == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to configuration settings."
+ skip_notification "disabled"
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
}
@@ -1161,9 +1182,9 @@ function fuzz() {
else
if [[ $FUZZ == false ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped due to configuration"
+ skip_notification "disabled"
else
- pt_msg_warn "${FUNCNAME[0]} already processed. To force, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -1204,14 +1225,12 @@ function iishortname() {
fi
end_func "Results are saved in vulns/iis-shortname/" "${FUNCNAME[0]}"
else
- # Handle cases where IIS_SHORTNAME is false or the function has already been processed
if [[ $IIS_SHORTNAME == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to configuration settings."
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
- # Domain is an IP address; skip the function
return
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -1284,14 +1303,12 @@ function cms_scanner() {
end_func "Results are saved in $domain/cms/*subdomain* folder" "${FUNCNAME[0]}"
else
- # Handle cases where CMS_SCANNER is false or the function has already been processed
if [[ $CMS_SCANNER == false ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped due to configuration"
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
- # Domain is an IP address; skip the function
return
else
- pt_msg_warn "${FUNCNAME[0]} already processed. To force, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
}
@@ -1502,9 +1519,9 @@ function urlchecks() {
fi
else
if [[ $URL_CHECK == false ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped due to configuration"
+ skip_notification "disabled"
else
- pt_msg_warn "${FUNCNAME[0]} already processed. To force, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -1522,6 +1539,10 @@ function url_gf() {
if { [[ ! -f "$called_fn_dir/.${FUNCNAME[0]}" ]] || [[ $DIFF == true ]]; } && [[ $URL_GF == true ]] \
&& ! [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
+ if ! command -v gf >/dev/null 2>&1; then
+ _print_msg WARN "${FUNCNAME[0]}: gf not found in PATH"
+ return 0
+ fi
start_func "${FUNCNAME[0]}" "Vulnerable Pattern Search"
# Ensure webs/url_extract.txt exists and is not empty
@@ -1568,14 +1589,12 @@ function url_gf() {
end_func "Results are saved in $domain/gf folder" "${FUNCNAME[0]}"
else
- # Handle cases where URL_GF is false or the function has already been processed
if [[ $URL_GF == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to configuration settings."
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
- # Domain is an IP address; skip the function
return
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -1632,14 +1651,12 @@ function url_ext() {
fi
else
- # Handle cases where URL_EXT is false or function already processed
if [[ $URL_EXT == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped in this mode or defined in reconftw.cfg."
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
- # Domain is an IP address; skip the function
return
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -1785,9 +1802,9 @@ function jschecks() {
fi
else
if [[ $JSCHECKS == false ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped due to configuration"
+ skip_notification "disabled"
else
- pt_msg_warn "${FUNCNAME[0]} already processed. To force, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -1836,7 +1853,7 @@ function websocket_checks() {
fi
end_func "Results are saved in vulns/websocket_misconfig.txt" "${FUNCNAME[0]}"
else
- _print_msg WARN "${FUNCNAME[0]} skipped or already processed."
+ skip_notification "processed"
fi
}
@@ -1870,14 +1887,12 @@ function wordlist_gen() {
end_func "Results are saved in $domain/webs/dict_[words|paths].txt" "${FUNCNAME[0]}"
else
- # Handle cases where WORDLIST is false or function already processed
if [[ $WORDLIST == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped in this mode or defined in reconftw.cfg."
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
- # Domain is an IP address; skip the function
return
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -1918,14 +1933,12 @@ function wordlist_gen_roboxtractor() {
fi
else
- # Handle cases where ROBOTSWORDLIST is false or function already processed
if [[ $ROBOTSWORDLIST == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to configuration settings."
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
- # Domain is an IP address; skip the function
return
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -2015,14 +2028,12 @@ function password_dict() {
touch "$called_fn_dir/.${FUNCNAME[0]}"
else
- # Handle cases where PASSWORD_DICT is false or function already processed
if [[ $PASSWORD_DICT == false ]]; then
- _print_msg WARN "${FUNCNAME[0]} skipped due to configuration settings."
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
- # Domain is an IP address; skip the function
return
else
- _print_msg WARN "${FUNCNAME[0]} already processed. To force execution, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi
@@ -2140,14 +2151,12 @@ function brokenLinks() {
return
fi
else
- # Handle cases where BROKENLINKS is false or function already processed
if [[ $BROKENLINKS == false ]]; then
- pt_msg_warn "${FUNCNAME[0]} skipped due to configuration"
+ skip_notification "disabled"
elif [[ $domain =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
- # Domain is an IP address; skip the function
return
else
- pt_msg_warn "${FUNCNAME[0]} already processed. To force, delete ${called_fn_dir}/.${FUNCNAME[0]}"
+ skip_notification "processed"
fi
fi