Dirb

Directory Brute Forcing Tool

📁 Dirb क्या है?

Dirb एक CLI-based web directory brute-forcing tool है जो web server पर hidden directories और files को find करने के लिए use होता है। इसका काम है wordlist के साथ directories को brute-force करके detect करना।

👉 Web discovery और recon phase में यह बहुत useful tool है।

🔍 Dirb क्या-क्या कर सकता है

Directory Discovery

Hidden directories find करना

File Discovery

Hidden files find करना

Custom Wordlists

अपनी wordlist use करना

Response Analysis

HTTP status codes check करना

Extension Filter

Specific extensions search करना

Multi-threading

Fast scanning support

⚙️ Kali NetHunter / Termux में Dirb install

aptInstallation Commands

System Update

apt update

Install Dirb

apt install dirb

Verify Installation

dirb

💻 Basic Commands (Use)

👉 Commands को एक-एक करके use कर सकते हो:

Basic Scan

dirb http://example.com

Custom Wordlist

dirb http://example.com /path/to/wordlist.txt

Specific Extensions

dirb http://example.com /usr/share/wordlists/dirb/common.txt -X .php,.html,.js

Ignore 404 Responses

dirb http://example.com /usr/share/wordlists/dirb/common.txt -N 404

Verbose Mode

dirb http://example.com -v

🔥 Real Example (Practical समझ)

Example🎯 Directory Discovery

Command

dirb http://example.com /usr/share/wordlists/dirb/common.txt

👉 Dirb wordlist में से हर directory/filename को try करता है → HTTP response देखकर confirm करता है

📊 Output समझो

👉 मान लो output कुछ ऐसा आता है:

-----------------
/admin (Status: 200)
/backup (Status: 301)
/config.php (Status: 200)
/uploads (Status: 403)
-----------------
Scanned: 5000 items
Found: 4 items
Time: 12.5s

🧠 इसका मतलब:

200

/admin, /config.php

Success! Page exists → Admin panel और config file accessible

301

/backup

Redirect → Backup directory है, investigation चाहिए

403

/uploads

Forbidden → Directory exists लेकिन access denied

👉 /admin panel को exploit करके आप admin access प्राप्त कर सकते हो → /config.php में database credentials हो सकते हैं

📚 Popular Wordlists

👉 Kali/Termux में built-in wordlists available हैं:

Common directories

/usr/share/wordlists/dirb/common.txt

Big wordlist (comprehensive)

/usr/share/wordlists/dirb/big.txt

Vuln scanners specific

/usr/share/wordlists/dirb/vulns.txt
⚠️ Important Warning

बिना permission किसी भी website को brute force करना illegal है

Practice के लिए use करो:

  • अपना local web server
  • Authorized testing environments
  • Bug bounty programs

🧩 Related Tools

Gobuster

Modern alternative to Dirb

WhatWeb

Web technology identification

💡 Simple समझ

Dirb = "Hidden Door Finder"

Website में जो directories/filenames hidden हैं या manually ढूंढना मुश्किल है, Dirb उन्हें brute-force करके पकड़ लेता है।