> For the complete documentation index, see [llms.txt](https://dthomsen.gitbook.io/mcsi/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://dthomsen.gitbook.io/mcsi/security-tools/brute-force-web-directories-and-files-using-dirb-wfuzz.md).

# Brute Force Web Directories And Files Using DIRB/WFUZZ

Using DIRB to find webpages that may have been unknown.

## Background

The WFUZZ/Dirbuster tools are used for brute forcing directories. They can be configured to use a variety of methods for guessing the names of directories, including dictionary attacks and brute force attacks. This makes them  powerful tools for discovering hidden files and directories on a system.

This simple concept allows any input to be injected in any field of an HTTP request, allowing to perform complex web security attacks in different web application components such as: parameters, authentication, forms, directories/files, headers, etc.

## Exercise

Brute force web directories and files using DIRB.

## Example:

`dirb [HOST_ADDR] -r`

<figure><img src="https://1305929913-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FlapqrpN4sXz7jqsMPRUD%2Fuploads%2FdTF12NYwXW7VPSaeljj5%2Fimage.png?alt=media&amp;token=9a165980-d34d-419b-971d-5970f19bea9e" alt=""><figcaption><p>Shows the multiple hidden directories on this server</p></figcaption></figure>

These hidden directories can often be used to exploit the server if they are not well protected/secured.&#x20;

`wfuzz -w [WORDLIST] [WEBPAGE]` is the basic command. I had used `grep` in order to filter the results to only the 200 responses meaning it was a successful connection.&#x20;

<figure><img src="https://1305929913-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FlapqrpN4sXz7jqsMPRUD%2Fuploads%2Fgif7ImcvJOaqN5zZN4zZ%2Fimage.png?alt=media&amp;token=00d55832-88c0-4ffd-ac88-7a6216fb5ac9" alt=""><figcaption><p>The WFUZZ in action</p></figcaption></figure>
