- Kali Linux Web Penetration Testing Cookbook
- Gilberto Nájera Gutiérrez
- 380字
- 2021-07-16 12:53:49
Finding files and folders with DirBuster
DirBuster is a tool created to discover, by brute force, the existing files and directories in a web server. We will use it in this recipe to search for a specific list of files and directories.
Getting ready
We will use a text file that contains the list of words that we will ask DirBuster to look for. Create a text file dictionary.txt
containing the following:
info server-status server-info cgi-bin robots.txt phpmyadmin admin login
How to do it...
- Navigate to Applications | Kali Linux | Web Applications | Web Crawlers | dirbuster:
- On the DirBuster's window, set the target URL to
http://192.168.56.102/
. - Set the number of threads to 20.
- Select List based brute force and click on Browse.
- In the browsing window, select the file we just created (
dictionary.txt
). - Uncheck the Be Recursive option.
- For this recipe, we will leave the rest of options at their defaults.
- Click on Start.
- If we go to the Results tab, we will see that DirBuster has found at least two of the files in our dictionary:
cgi-bin
andphpmyadmin
. The response code 200 means that the file or directory exists and can be read. PhpMyAdmin is a web-based MySQL database administrator; finding a directory with this name tells us that there is a DBMS in the server and it may contain relevant information about the application and its users.
How it works...
DirBuster is a mixture of crawler and brute forcer; it follows all links in the pages it finds but also tries different names for possible files. These names may be in a file similar to the one we used or may be automatically generated by DirBuster using the option of "pure brute force" and setting the character set and minimum and maximum lengths for the generated words.
To determine if a file exists or not, DirBuster uses the response codes from the server. The most common responses are listed, as follows:
- 200. OK: The file exists and the user can read it.
- 404. File not found: The file does not exist in the server.
- 301. Moved permanently: This is a redirect to a given URL.
- 401. Unauthorized: Authentication is required to access this file.
- 403. Forbidden: Request was valid but the server refuses to respond.
- Vue 3移動Web開發與性能調優實戰
- Design Principles for Process:driven Architectures Using Oracle BPM and SOA Suite 12c
- Learning Selenium Testing Tools with Python
- FFmpeg入門詳解:音視頻流媒體播放器原理及應用
- 機器人Python青少年編程開發實例
- Full-Stack Vue.js 2 and Laravel 5
- 人人都懂設計模式:從生活中領悟設計模式(Python實現)
- 量化金融R語言高級教程
- 搞定J2EE:Struts+Spring+Hibernate整合詳解與典型案例
- 零基礎學Python編程(少兒趣味版)
- GitHub入門與實踐
- Java EE Web應用開發基礎
- HTML5移動前端開發基礎與實戰(微課版)
- AI自動化測試:技術原理、平臺搭建與工程實踐
- HTML5移動Web開發