https://github.com/dogasantos/masstomap
A bridge between masscan and nmap - run fast masscan, parse output, execute nmap using masscan as input
https://github.com/dogasantos/masstomap
Last synced: 4 months ago
JSON representation
A bridge between masscan and nmap - run fast masscan, parse output, execute nmap using masscan as input
- Host: GitHub
- URL: https://github.com/dogasantos/masstomap
- Owner: dogasantos
- Created: 2018-12-09T23:35:07.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2024-07-02T18:18:47.000Z (over 1 year ago)
- Last Synced: 2024-11-21T19:38:44.100Z (12 months ago)
- Language: Python
- Homepage:
- Size: 63.5 KB
- Stars: 26
- Watchers: 4
- Forks: 10
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-hacking-lists - dogasantos/masstomap - A bridge between masscan and nmap - run fast masscan, parse output, execute nmap using masscan as input (Python)
README
# MASSTOMAP
masstomap is a simple python script that can be used to read masscan reports and execute nmap powerful service versioning and scripting tasks.
You need to specify a masscan standard report file (-oL) and a name for the nmap report file this tool should create.
A nmap grepable, text and xml report will be created.
### Pause and Resume scan
Masstomap creates a single nmap report per IP/target while it is running against a list of targets. The reason is that you can stop the scan and resume later. Soon as every target is scanned, masstomap will craft a single compliant nmap report using 3 different formats.
### NOTE ###
Again, this tool will create 3 report files per IP/target (text, grepable, xml). All those files will be merged automatically in the end. Don't freak out.
### FILES
This tool will generate 4 files:
```
.new - a new masscan report using different notation (ip:port1,port2,portN) so you can run your own (custom) nmap scanning whenever you need.
.nmap.grepable - a grepable nmap report
.nmap.text - a standard text nmap report
.nmap.xml - a xml formated nmap report
```
### Usage:
>$ python masstomap.py [-h] -m MASSCAN -o NMAP_OUTPUT [-sl SCRIPT_LIST] [-v [VERBOSE]]
-h, --help
show this help message and exit
-m MASSCAN, --masscan MASSCAN
masscan report file
-o NMAP_OUTPUT, --nmap-output NMAP_OUTPUT
nmap output file
-sl SCRIPT_LIST, --script-list SCRIPT_LIST
Comma separated list of nmap scripts to run
-v [VERBOSE], --verbose [VERBOSE]
Enable Verbosity
-t THREADS, --threads THREADS
number of nmap threads
### EXAMPLE:
First, masscan:
```
$ sudo masscan -p1-65535 --rate 1000 --open -oL output.masscan
```
Then masstomap:
```
$ python /usr/share/masstomap/masstomap.py -m output.masscan -o target.tcp
$ ls
output.masscan output.masscan.new target.tcp.nmap.grepable target.tcp.nmap.txt target.tcp.nmap.xml
$
```
### Requirements:
check requirements.txt file
Resolve requirements by running
```
pip install -p requirements.txt
```
### NMAP SCRIPTS:
This tool needs nmap in the $PATH so it can be executed, and by default, the following nmap scripts should be executed:
http-title
http-server-header
http-robots.txt
http-open-proxy
http-methods
http-headers
http-internal-ip-disclosure
#### NOTE:
Remove --privileged if you don't plan to execute nmap as root (won't be able to use synscan, just full tcp scan which is slower)
## RECOMMENDED TOOLS:
### EXCEL OUTPUT
Generate a XLSX (Excel) nmap report:
```
https://github.com/dogasantos/nmapxml-to-xlsx
```
### INTELIGENT WEB TARGETS
Generate a list of WEB targets (with protocol and port):
```
https://github.com/dogasantos/webmapper
```