The goal of this project was to develop a passive Google dork script to collect potentially vulnerable web pages and applications on the Internet. There are 2 parts. The first is
ghdb_scraper.py
that retrieves Google Dorks and the second portion is pagodo.py
that leverages the information gathered by ghdb_scraper.py
.What are Google Dorks?
The awesome folks at Offensive Security maintain the Google Hacking Database (GHDB) found here: https://www.exploit-db.com/google-hacking-database. It is a collection of Google searches, called dorks, that can be used to find potentially vulnerable boxes or other juicy info that is picked up by Google's search bots.
Installation
Scripts are written for Python 3.6+. Clone the git repository and install the requirements.
git clone https://github.com/opsdisk/pagodo.git
cd pagodo
virtualenv -p python3 .venv # If using a virtual environment.
source .venv/bin/activate # If using a virtual environment.
pip install -r requirements.txt
Google is blocking me!
If you start getting HTTP 503 errors, Google has rightfully detected you as a bot and will block your IP for a set period of time. The solution is to use proxychains and a bank of proxies to round robin the lookups.
Install proxychains4
apt install proxychains4 -y
/etc/proxychains4.conf
configuration file to round robin the look ups through different proxy servers. In the example below, 2 different dynamic socks proxies have been set up with different local listening ports (9050 and 9051). Don't know how to utilize SSH and dynamic socks proxies? Do yourself a favor and pick up a copy of The Cyber Plumber's Handbook to learn all about Secure Shell (SSH) tunneling, port redirection, and bending traffic like a boss.vim /etc/proxychains4.conf
round_robin
chain_len = 1
proxy_dns
remote_dns_subnet 224
tcp_read_time_out 15000
tcp_connect_time_out 8000
[ProxyList]
socks4 127.0.0.1 9050
socks4 127.0.0.1 9051
proxychains4
in front of the Python script and each lookup will go through a different proxy (and thus source from a different IP). You could even tune down the -e
delay time because you will be leveraging different proxy boxes.proxychains4 python3 pagodo.py -g ALL_dorks.txt -s -e 17.0 -l 700 -j 1.1
ghdb_scraper.py
To start off,
pagodo.py
needs a list of all the current Google dorks. A datetimestamped file with the Google dorks and the indididual dork category dorks are also provided in the repo. Fortunately, the entire database can be pulled back with 1 GET request using ghdb_scraper.py
. You can dump all dorks to a file, the individual dork categories to separate dork files, or the entire json blob if you want more contextual data about the dork.To retrieve all dorks
python3 ghdb_scraper.py -j -s
python3 ghdb_scraper.py -i
categories = { 1: "Footholds", 2: "File Containing Usernames", 3: "Sensitives Directories", 4: "Web Server Detection", 5: "Vulnerable Files", 6: "Vulnerable Servers", 7: "Error Messages", 8: "File Containing Juicy Info", 9: "File Containing Passwords", 10: "Sensitive Online Shopping Info", 11: "Network or Vulnerability Data", 12: "Pages Containing Login Portals", 13: "Various Online devices", 14: "Advisories and Vulnerabilities", }
pagodo.py
Now that a file with the most recent Google dorks exists, it can be fed into
pagodo.py
using the -g
switch to start collecting potentially vulnerable public applications. pagodo.py
leverages the google
python library to search Google for sites with the Google dork, such as:intitle:"ListMail Login" admin -demo
The -d
switch can be used to specify a domain and functions as the Google search operator:site:example.com
Performing ~4600 search requests to Google as fast as possible will simply not work. Google will rightfully detect it as a bot and block your IP for a set period of time. In order to make the search queries appear more human, a couple of enhancements have been made. A pull request was made and accepted by the maintainer of the Python google
module to allow for User-Agent randomization in the Google search queries. This feature is available in 1.9.3 and allows you to randomize the different user agents used for each search. This emulates the different browsers used in a large corporate environment.The second enhancement focuses on randomizing the time between search queries. A minimum delay is specified using the
-e
option and a jitter factor is used to add time on to the minimum delay number. A list of 50 jitter times is created and one is randomly appended to the minimum delay time for each Google dork search.categories = {
1: "Footholds",
2: "File Containing Usernames",
3: "Sensitives Directories",
4: "Web Server Detection",
5: "Vulnerable Files",
6: "Vulnerable Servers",
7: "Error Messages",
8: "File Containing Juicy Info",
9: "File Containing Passwords",
10: "Sensitive Online Shopping Info",
11: "Network or Vulnerability Data",
12: "Pages Containing Login Portals",
13: "Various Online devices",
14: "Advisories and Vulnerabilities",
}
intitle:"ListMail Login" admin -demo
To run it:
site:example.com
Conclusion
Comments, suggestions, and improvements are always welcome. Be sure to follow @opsdisk on Twitter for the latest updates.
via KitPloit
Related word
- Hacker Hardware Tools
- Hacker Techniques Tools And Incident Handling
- Pentest Tools List
- Computer Hacker
- Pentest Tools For Mac
- Hack Tools Mac
- Pentest Tools Nmap
- Hacker Tools Mac
- Pentest Tools For Windows
- Pentest Tools Nmap
- Pentest Tools For Windows
- Hackers Toolbox
- Hacking App
- Hack App
- Pentest Tools For Windows
- Hacking Tools Kit
- Tools Used For Hacking
- Pentest Tools
- Pentest Tools Online
- Hacking Tools For Windows Free Download
- Hacker Techniques Tools And Incident Handling
- Pentest Tools Website
- Best Hacking Tools 2019
- Top Pentest Tools
- Hack Apps
- Hackrf Tools
- Pentest Tools Kali Linux
- Blackhat Hacker Tools
- Hack App
- Hacker Tools Hardware
- Hacker Tools Online
- Black Hat Hacker Tools
- Github Hacking Tools
- Hack Tools
- Hack Tools Online
- Tools For Hacker
- Tools 4 Hack
- Pentest Tools Windows
- Pentest Tools Github
- Pentest Box Tools Download
- Hack And Tools
- Pentest Tools For Ubuntu
- Pentest Tools Linux
- Hack Tools Mac
- Pentest Tools Subdomain
- Computer Hacker
- Pentest Tools Tcp Port Scanner
- Pentest Tools Website
- Best Hacking Tools 2020
- Hacker Security Tools
- World No 1 Hacker Software
- How To Make Hacking Tools
- Hack Apps
- Hack Website Online Tool
- How To Hack
- Tools For Hacker
- Ethical Hacker Tools
- Pentest Tools Website
- Pentest Tools Framework
- Tools For Hacker
- Github Hacking Tools
- Hacker Tools Free
- Hack Tools Github
- Hacker Tools Free
- Pentest Tools Subdomain
- Github Hacking Tools
- Hack Apps
- Hacking Tools For Beginners
- Hacker Tools List
- Hacker Tool Kit
- Wifi Hacker Tools For Windows
- Pentest Tools Github
- Pentest Tools For Windows
- Hacking Tools Name
- Hacker Tools For Ios
- Hack Tools For Ubuntu
- Hacker Tools Free Download
- Hak5 Tools
- How To Install Pentest Tools In Ubuntu
- Hack Tools For Mac
- Hacker Tools Online
- Hack Tools Mac
- Pentest Tools Kali Linux
- What Is Hacking Tools
- Blackhat Hacker Tools
- Hacking Apps
- Hacks And Tools
- Hack Tools
- Pentest Tools Windows
- How To Hack
- Hacker Tools For Windows
- Pentest Tools Port Scanner
- Pentest Tools Subdomain
- Hacker Tools Mac
- Pentest Tools Apk
- Github Hacking Tools
- Hack Rom Tools
- Best Hacking Tools 2019
- Hacking Tools Download
- Pentest Tools Download
- Hackers Toolbox
- New Hacker Tools
- Hack Tools For Pc
- Pentest Tools Github
- Hacking Tools For Kali Linux
- Hack Tools For Pc
- Pentest Tools For Ubuntu
- Hacker Tools For Pc
- Pentest Automation Tools
- Wifi Hacker Tools For Windows
- Usb Pentest Tools
- Nsa Hack Tools Download
- Hacker Tools Mac
- Pentest Tools Bluekeep
- Android Hack Tools Github
- Pentest Tools Review
- Pentest Tools Port Scanner
- Hacker Tools Github
- Pentest Tools For Android
- Hack Apps
- Hack App
- Hack App
- Hacking Tools Github
- Hacking Tools Name
- Hack Tools
- Hack Tools 2019
- Pentest Tools Find Subdomains
- Hacker Tools Free
- Hack Tools For Windows
- Hacker Tools Online
- Hack Tools Github
- Pentest Tools Github
- Best Hacking Tools 2020
- Hacking Tools Hardware
- Pentest Tools Website Vulnerability
- Hack Rom Tools
- Pentest Tools Free
- Hacking Tools For Games
- Pentest Tools Github
- Hacker Tools Linux
- Hacker Tool Kit
- Easy Hack Tools
- Hacking Tools For Pc
- Hack Tools Github
- Hacking Tools Windows 10
- Nsa Hack Tools
- Install Pentest Tools Ubuntu
- Pentest Tools Port Scanner
- Pentest Recon Tools
- Pentest Tools Bluekeep
- Underground Hacker Sites
- What Is Hacking Tools
- Hacker Tools Apk
- Hack Tools Pc
- Bluetooth Hacking Tools Kali
- Hacker Security Tools
- Hacking Tools Usb
- Hack Tools For Games
- How To Make Hacking Tools
- Hacker Search Tools
- Pentest Tools Tcp Port Scanner
- Hacking Tools For Windows
- Hacker Security Tools
- Hack Tools
- Pentest Tools Alternative
- Pentest Tools List
- New Hacker Tools
- Nsa Hack Tools
- Pentest Automation Tools
- Black Hat Hacker Tools
- Hack Tools For Pc
- Pentest Tools Nmap
- Pentest Tools Website
- Pentest Tools Website
- Hack Tool Apk No Root
- Pentest Tools Online
No comments:
Post a Comment