|
1 | 1 | # enumdb
|
2 | 2 | Enumdb is a brute force and post exploitation tool for MySQL and MSSQL databases. When provided a list of usernames and/or passwords, it will cycle through each targeted host looking for valid credentials. By default, enumdb will use newly discovered credentials to search for sensitive information in the host's databases via keyword searches on the table or column names. This information can then be extracted and reported to a .csv or .xlsx output file. See the Usage and All Options sections for more detailed usage and examples.
|
3 | 3 |
|
4 |
| -To make the tool more adaptable on larger environments, Threading has been added to expedite brute forcing and enumeration when targeting multiple servers. Additionally, enumdb will not generate a report by default allowing users to get a quick preview of the target database. To extract data, specify a report type in the command line arguments, with either: ```-r csv``` or ```-r xlsx```. The first 100 rows of each identified table or column will be selected in the output report. |
| 4 | +To make the tool more adaptable on larger environments, Threading has been added to expedite brute forcing and enumeration when targeting multiple servers. Additionally, enumdb will *not* generate reports by default, allowing users to get a quick preview of the target database. To extract data, specify a report type in the command line arguments, with either: ```-r csv``` or ```-r xlsx```. The first 100 rows of each identified table or column will be extracted in the output report. |
5 | 5 |
|
6 |
| -The number of rows captured in reports, blacklisted databases & tables, and keywords for table & column searches can be modified at: ```enumdb/config.py```. |
| 6 | +Rows captured, blacklisted databases & tables, and keywords searches can all be modified at: ```enumdb/config.py```. |
7 | 7 |
|
8 | 8 | ## Installation
|
9 |
| -Enumdb was designed and testing using Python3 on the Kali Linux operating system. However, backwards compatibility has recently been added for Python2.7. |
| 9 | +Enumdb was designed and tested using Python3 for Debian based Linux systems. However, the tool is also compatible with Python2.7, and on other Linux distributions. |
10 | 10 |
|
11 |
| -*Use the requirements file to install the necessary Python packages. If you still experience import issues, try the setup.sh file* |
12 | 11 | ```bash
|
13 | 12 | git clone https://github.com/m8r0wn/enumdb
|
14 | 13 | cd enumdb
|
15 |
| -pip3 install -r requirements.txt |
| 14 | +python3 setup.py install |
16 | 15 | ``````
|
17 | 16 |
|
| 17 | +If experiencing issues with the [MySQLdb](https://github.com/PyMySQL/mysqlclient-python), additional MySQL development resources may |
| 18 | +need to be installed: |
| 19 | + |
| 20 | +* Debian / Ubuntu: |
| 21 | +``` |
| 22 | +sudo apt-get install python3-dev default-libmysqlclient-dev build-essential |
| 23 | +``` |
| 24 | +
|
| 25 | +* Red Hat / CentOS: |
| 26 | +``` |
| 27 | +sudo yum install python3-devel mysql-devel |
| 28 | +``` |
| 29 | +
|
18 | 30 | ## Usage
|
19 | 31 | * Connect to a MySQL database and search for data via key word in table name (no report)<br>
|
20 |
| -`python3 enumdb.py -u root -p '' -t mysql 10.11.1.30` |
| 32 | +```enumdb -u root -p '' -t mysql 10.11.1.30``` |
21 | 33 |
|
22 | 34 | * Connect to a MSSQL database using a domain username and search for data via keyword in column name writing output to csv file:<br>
|
23 |
| -`python3 enumdb.py -u 'domain\\user' -p Winter2018! -t mssql -columns -report csv 10.11.1.30` |
| 35 | +```enumdb -u 'domain\\user' -p Winter2018! -t mssql -columns -report csv 10.11.1.30``` |
24 | 36 |
|
25 | 37 | * Brute force multiple MySQL servers looking for default credentials, no data enumeration:<br>
|
26 |
| -`python3 enumdb.py -u root -p '' -t mysql -brute 10.11.1.0-30` |
| 38 | +```enumdb -u root -p '' -t mysql -brute 10.11.1.0-30``` |
27 | 39 |
|
28 | 40 | * Brute force MSSQL sa account login. Once valid credentials are found, enumerate data by column name writing output to xlsx:<br>
|
29 |
| -`python3 enumdb.py -u sa -P passwords.txt -t mssql -columns -report xlsx 192.168.10.10` |
| 41 | +```enumdb -u sa -P passwords.txt -t mssql -columns -report xlsx 192.168.10.10``` |
30 | 42 |
|
31 | 43 | * Brute force MSSQL sa account on a single server, no data enumeration:<br>
|
32 |
| -`python3 enumdb.py -u sa -P passwords.txt -t mssql -brute 192.168.10.10` |
| 44 | +```enumdb -u sa -P passwords.txt -t mssql -brute 192.168.10.10``` |
33 | 45 |
|
34 | 46 | 
|
35 | 47 |
|
36 | 48 | ## All Options
|
37 |
| - -h, --help show help message and exit |
38 |
| - -u USERS Single username |
39 |
| - -U USERS Users.txt file |
40 |
| - -p PASSWORDS Single password |
41 |
| - -P PASSWORDS Password.txt file |
42 |
| - -threads MAX_THREADS Max threads (Default: 3) |
43 |
| - -port PORT Specify non-standard port |
44 |
| - -r REPORT, -report REPORT Output Report: csv, xlsx (Default: None) |
45 |
| - -t DBTYPE Database types currently supported: mssql, mysql |
46 |
| - -c, -columns Search for key words in column names (Default: table names) |
47 |
| - -v Show failed login notices & keyword matches with Empty data sets |
48 |
| - -brute Brute force only, do not enumerate |
49 |
| - |
50 |
| - |
| 49 | +```html |
| 50 | + -u USERS Single username |
| 51 | + -U USERS Users.txt file |
| 52 | + -p PASSWORDS Single password |
| 53 | + -P PASSWORDS Password.txt file |
| 54 | + -threads MAX_THREADS Max threads (Default: 3) |
| 55 | + -port PORT Specify non-standard port |
| 56 | + -r REPORT, -report REPORT Output Report: csv, xlsx (Default: None) |
| 57 | + -t {mysql,mssql} Database type |
| 58 | + -c, -columns Search for key words in column names (Default: table names) |
| 59 | + -v Show failed login notices & keyword matches with Empty data sets |
| 60 | + -brute Brute force only, do not enumerate |
| 61 | +
|
| 62 | +``` |
0 commit comments