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

Added ip/cidr as target

six2dez2d038028eb9e
diff --git a/reconftw.sh b/reconftw.sh
index 53444e8..9798914 100755
--- a/reconftw.sh
+++ b/reconftw.sh
@@ -1419,15 +1419,22 @@ function ipcidr_detection(){
if [[ $1 =~ /[0-9]+$ ]]; then
prips $1 | hakrevdns
prips $1 | gdn
- # ./test.sh 199.120.48.0/24 | cut -d' ' -f3 | unfurl -u domains | sed 's/\.$//' | awk -F\. '{print $(NF-1) FS $NF}' | sort -u
else
echo $1 | hakrevdns
echo $1 | gdn
- # ./test.sh 199.120.48.0/24 | cut -d' ' -f3 | unfurl -u domains | sed 's/\.$//' | awk -F\. '{print $(NF-1) FS $NF}' | sort -u
fi
fi
}
+function ipcidr_target(){
+ ipcidr_detection $1 | cut -d' ' -f3 | unfurl -u domains | sed 's/\.$//' | sort -u > ./target_reconftw_ipcidr.txt
+ if [[ $(cat ./target_reconftw_ipcidr.txt | wc -l) -eq 1 ]]; then
+ domain=$(cat ./target_reconftw_ipcidr.txt)
+ elif [[ $(cat ./target_reconftw_ipcidr.txt | wc -l) -gt 1 ]]; then
+ list=${PWD}/target_reconftw_ipcidr.txt
+ fi
+}
+
function start(){
global_start=$(date +%s)
@@ -1441,7 +1448,7 @@ function start(){
echo "Recon succesfully started on $domain" | $NOTIFY
tools_installed
-# ipcidr_detection $domain
+ [[ -n "$domain" ]] && ipcidr_target $domain
if [ -z "$domain" ]; then
if [ -n "$list" ]; then
@@ -1575,6 +1582,8 @@ function multi_osint(){
NOTIFY=""
fi
+ [[ -n "$domain" ]] && ipcidr_target $domain
+
if [ -s "$list" ]; then
sed -i 's/\r$//' $list
targets=$(cat $list)
@@ -1646,6 +1655,8 @@ function multi_recon(){
NOTIFY=""
fi
+ [[ -n "$domain" ]] && ipcidr_target $domain
+
if [ -s "$list" ]; then
sed -i 's/\r$//' $list
targets=$(cat $list)
diff --git a/reconftw_axiom.sh b/reconftw_axiom.sh
index 943eafe..b3ee0fa 100755
--- a/reconftw_axiom.sh
+++ b/reconftw_axiom.sh
@@ -1420,6 +1420,27 @@ function resolvers_update(){
fi
}
+function ipcidr_detection(){
+ if [[ $1 =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9] ]]; then
+ if [[ $1 =~ /[0-9]+$ ]]; then
+ prips $1 | hakrevdns
+ prips $1 | gdn
+ else
+ echo $1 | hakrevdns
+ echo $1 | gdn
+ fi
+ fi
+}
+
+function ipcidr_target(){
+ ipcidr_detection $1 | cut -d' ' -f3 | unfurl -u domains | sed 's/\.$//' | sort -u > ./target_reconftw_ipcidr.txt
+ if [[ $(cat ./target_reconftw_ipcidr.txt | wc -l) -eq 1 ]]; then
+ domain=$(cat ./target_reconftw_ipcidr.txt)
+ elif [[ $(cat ./target_reconftw_ipcidr.txt | wc -l) -gt 1 ]]; then
+ list=${PWD}/target_reconftw_ipcidr.txt
+ fi
+}
+
function axiom_lauch(){
# let's fire up a FLEET!
if [ "$AXIOM_FLEET_LAUNCH" = true ] && [ -n "$AXIOM_FLEET_NAME" ] && [ -n "$AXIOM_FLEET_COUNT" ]; then
@@ -1495,6 +1516,8 @@ function start(){
echo "Recon succesfully started on $domain" | $NOTIFY
tools_installed
+ [[ -n "$domain" ]] && ipcidr_target $domain
+
if [ -z "$domain" ]; then
if [ -n "$list" ]; then
if [ -z "$domain" ]; then
@@ -1638,6 +1661,8 @@ function multi_osint(){
NOTIFY=""
fi
+ [[ -n "$domain" ]] && ipcidr_target $domain
+
if [ -s "$list" ]; then
sed -i 's/\r$//' $list
targets=$(cat $list)
@@ -1717,6 +1742,8 @@ function multi_recon(){
NOTIFY=""
fi
+ [[ -n "$domain" ]] && ipcidr_target $domain
+
if [ -s "$list" ]; then
sed -i 's/\r$//' $list
targets=$(cat $list)