-
Notifications
You must be signed in to change notification settings - Fork 1
/
fuzzmrco.sh
78 lines (68 loc) · 4.03 KB
/
fuzzmrco.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
#!/bin/bash
#colors
red=`tput setaf 1`
green=`tput setaf 2`
yellow=`tput setaf 3`
blue=`tput setaf 4`
magenta=`tput setaf 5`
reset=`tput sgr0`
read -p "Enter domain name : " domain
if [ -d /root/recon/$domain/Content_Discovery ]
then
echo " "
else
mkdir /root/recon/$domain/Content_Discovery
fi
echo "${blue} [+] Started Content Discovery Scanning ${reset}"
echo " "
#wordlist
echo "${yellow} ---------------------------------- xxxxxxxx ---------------------------------- ${reset}"
echo " "
if [ -f /root/wordlist/dicc.txt ]
then
echo " "
else
echo "${blue} [+] Downloading wordlists ${reset}"
wget https://raw.githubusercontent.com/v0re/dirb/master/wordlists/common.txt -P ~/Desktop/tools/
fi
#feroxbuster
if [ -f /usr/bin/feroxbuster ]
then
echo "${magenta} [+] Running Feroxbuster for content discovery${reset}"
for url in $(cat /root/recon/bitdefender.com/subdomain/good/active_subdomain.txt);do
reg=$(echo $url | sed -e 's;https\?://;;' | sed -e 's;/.*$;;')
feroxbuster --url $url -w /root/Tools/dicc.txt -x php asp aspx jsp py txt conf config bak backup swp old db zip sql --depth 3 --threads 300 --output /root/recon/$domain/Content_Discovery/content_discovery_result.txt
done
else
echo "${blue} [+] Installing Feroxbuster ${reset}"
wget https://github.com/epi052/feroxbuster/releases/download/v1.5.2/x86_64-linux-feroxbuster.zip -P ~/Desktop/tools/feroxbuster
unzip ~/Desktop/tools/feroxbuster/x86_64-linux-feroxbuster.zip -d ~/go/bin/
chmod 777 ~/go/bin/feroxbuster
echo "${magenta} [+] Running Feroxbuster for content discovery${reset}"
for url in $(cat /root/recon/bitdefender.com/subdomain/good/active_subdomain.txt);do
reg=$(echo $url | sed -e 's;https\?://;;' | sed -e 's;/.*$;;')
feroxbuster --url $url -w /root/Tools/dicc.txt -x php asp aspx jsp py txt conf config bak backup swp old db zip sql --depth 3 --threads 300 --output /root/recon/$domain/Content_Discovery/content_discovery_result.txt
done
fi
echo "${yellow} ---------------------------------- xxxxxxxx ---------------------------------- ${reset}"
echo " "
echo "${blue} [+] Succesfully saved as content_discovery_result.txt ${reset}"
echo " "
echo "${yellow} ---------------------------------- xxxxxxxx ---------------------------------- ${reset}"
echo " "
echo "${magenta} [+] Sorting According to Status Codes ${reset}"
cat /root/recon/$domain/Content_Discovery/content_discovery_result.txt | grep 200 | awk '{print $2}' > /root/recon/$domain/Content_Discovery/status_code_200.txt
cat /root/recon/$domain/Content_Discovery/content_discovery_result.txt | grep 204 | awk '{print $2}' > /root/recon/$domain/Content_Discovery/status_code_204.txt
cat /root/recon/$domain/Content_Discovery/content_discovery_result.txt | grep 301 | awk '{print $2}' > /root/recon/$domain/Content_Discovery/status_code_301.txt
cat /root/recon/$domain/Content_Discovery/content_discovery_result.txt | grep 302 | awk '{print $2}' > /root/recon/$domain/Content_Discovery/status_code_302.txt
cat /root/recon/$domain/Content_Discovery/content_discovery_result.txt | grep 307 | awk '{print $2}' > /root/recon/$domain/Content_Discovery/status_code_307.txt
cat /root/recon/$domain/Content_Discovery/content_discovery_result.txt | grep 308 | awk '{print $2}' > /root/recon/$domain/Content_Discovery/status_code_308.txt
cat /root/recon/$domain/Content_Discovery/content_discovery_result.txt | grep 401 | awk '{print $2}' > /root/recon/$domain/Content_Discovery/status_code_401.txt
cat /root/recon/$domain/Content_Discovery/content_discovery_result.txt | grep 403 | awk '{print $2}' > /root/recon/$domain/Content_Discovery/status_code_403.txt
cat /root/recon/$domain/Content_Discovery/content_discovery_result.txt | grep 405 | awk '{print $2}' > /root/recon/$domain/Content_Discovery/status_code_405.txt
echo " "
echo "${yellow} ---------------------------------- xxxxxxxx ---------------------------------- ${reset}"
echo " "
echo "${blue} [+] Succesfully saved the results according to their status codes ${reset}"
echo " "
echo "${yellow} ---------------------------------- xxxxxxxx ---------------------------------- ${reset}"