Hack Forums
[Tutorial] Find hidden web directories and files with dirsearch - Printable Version

+- Hack Forums (https://hackforums.net)
+-- Forum: Hacks, Exploits, and Various Discussions (https://hackforums.net/forumdisplay.php?fid=45)
+--- Forum: Grayhat • Purple Team • Hybrid Security (https://hackforums.net/forumdisplay.php?fid=449)
+---- Forum: Beginner Hacking (https://hackforums.net/forumdisplay.php?fid=4)
+----- Forum: Hacking Tutorials (https://hackforums.net/forumdisplay.php?fid=47)
+----- Thread: [Tutorial] Find hidden web directories and files with dirsearch (/showthread.php?tid=6130211)

Pages: Pages 1 2


[Tutorial] Find hidden web directories and files with dirsearch - guardian - Dec 29, 2020

Dirsearch is a powerful tool that automatically checks for the existence of directories/files on a server
It might discover admin logins, configuration files the admin forgot to remove and more!
When attacking a site during a penetration test, I used this tool numerous times and have also had success based on the things I found with it

Dirsearch does not only output files it found, but also files it got a 403 (Forbidden Access) or other interesting response codes from
This makes the tool even more powerful to me

You can find it's Github Repository here

To use it on Linux, first install Git

Code
apt -y install git

Then clone into the repository

Code
git clone https://github.com/maurosoria/dirsearch

A folder named dirsearch will appear within the directory you executed this command in
Switch into the directory by using
Code
cd dirsearch

You will need pip3 to install the requirements listed in requirements.txt
To install pip3 and afterwards install all the requirements using pip3 do

Code
apt install python3-pip
pip3 install -r requirements.txt

A basic usage of dirsearch could look like this

Code
python3 dirsearch.py -u https://example.com -e php,js,txt,conf

-u specifies the URL that you want to check for the files
-e specifies the file extensions that will be looked for, in this case: php,js,txt and .conf

In addition to that, there are some other useful flags you can use:
--cidr scans all hosts in the given cidr
-X Excludes specified extensions
-r Search directories recursively
--proxy Proxy your requests; good for circumventing IP blocks and privacy

As it is a tool I find myself using pretty often, I thought I would share that as well, hope you enjoyed this and learned something new


RE: [Tutorial] Find hidden web directories and files with dirsearch - ghostwalker47 - Jan 5, 2021

tysm, just used dirsearch on a website and found some very cool stuff.


RE: [Tutorial] Find hidden web directories and files with dirsearch - guardian - Jan 5, 2021

(Jan 5, 2021 04:00 PM)ghostwalker47 Wrote:  tysm, just used dirsearch on a website and found some very cool stuff.

You're welcome bud, thanks for the feedback!


RE: [Tutorial] Find hidden web directories and files with dirsearch - Choom - Jan 7, 2021

thanks dude awesome stuff


RE: [Tutorial] Find hidden web directories and files with dirsearch - guardian - Jan 7, 2021

(Jan 7, 2021 01:47 AM)Choom Wrote:  thanks dude awesome stuff

Yw mate, thanks for the feedback


RE: [Tutorial] Find hidden web directories and files with dirsearch - HOMODIN - Jan 7, 2021

Thanks for sharing this, there's a few sites that I need to dig trough, gonna see if this helps out :3


RE: [Tutorial] Find hidden web directories and files with dirsearch - guardian - Jan 7, 2021

(Jan 7, 2021 02:03 AM)HOMODIN Wrote:  Thanks for sharing this, there's a few sites that I need to dig trough, gonna see if this helps out :3

Np, you find something cool on 80% of websites I tried it on, sometimes even open stats panels lmao


RE: [Tutorial] Find hidden web directories and files with dirsearch - martigo333 - Jan 7, 2021

I want to see how this works.


RE: [Tutorial] Find hidden web directories and files with dirsearch - seraphzero - Jan 7, 2021

Thank you very much !! Very useful!!


RE: [Tutorial] Find hidden web directories and files with dirsearch - Thoth - Jan 7, 2021

Thanks for the guide mate, you gave a pretty good tutorial! Keep up the good work man!


RE: [Tutorial] Find hidden web directories and files with dirsearch - Hacker_eN - Apr 3, 2022

Dirsearch is very useful, i have tried it several times, its a powerful tool


RE: [Tutorial] Find hidden web directories and files with dirsearch - cokecaine - Apr 3, 2022

Thanks for this! Almost exactly what I needed!


RE: [Tutorial] Find hidden web directories and files with dirsearch - editing101 - Apr 7, 2022

Thanks for this! Precisely what I needed


RE: [Tutorial] Find hidden web directories and files with dirsearch - SIM-5382664 - Jul 2, 2023

thanks sir apreciate it


RE: [Tutorial] Find hidden web directories and files with dirsearch - naturewizard69 - Jul 2, 2023

This is great thank you so much for sharing!