Skip to content

ameihm0912/diffscan2

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

36 Commits
 
 
 
 
 
 
 
 

Repository files navigation

diffscan2

Overview

diffscan2 is a wrapper for nmap intended to automate processing scan results and generate reports detailing differences (differential reporting).

It has been tested with nmap 6.

Usage

Update nmap_scanoptions in diffscan.py with any additional options that are required to be sent to nmap.

Typical usage involves execution as follows:

	$ ./diffscan.py targets.txt [email protected] GroupName

where targets.txt is a list of subnets/hosts, [email protected] is the recipient address for the report, and GroupName is a string included in the mail subject to differentiate between different instances of diffscan2.

A state file (by default ./diffscan.state) is used between executions to keep state on previous scans. Additionally, the nmap output is saved in an output directory for future review if required (by default ./diffscan_out). The -s and -o flags can be used to change these defaults.

usage: diffscan.py [options] targets_file recipient groupname

options:

-h          usage information
-m num      top ports to scan (2000, see nmap --top-ports)
-n          no smtp, write output to stdout (recipient ignored)
-o path     directory to save nmap output (./diffscan_out)
-p spec     instead of top ports use port spec (see nmap -p)
-s path     path to state file (./diffscan.state)
-q          Don't send email if no changes

Reporting

An example report is shown below.

	diffscan2 results output

	New Open Service List
	---------------------
	STATUS HOST PORT PROTO OPREV CPREV DNS
	OPEN 10.0.2.100 22 tcp 0 3 unknown
	OPEN 10.0.2.100 111 tcp 0 3 unknown

	New Closed Service List
	---------------------
	STATUS HOST PORT PROTO OPREV CPREV DNS

	OPREV: number of times service was open in previous scans
	CPREV: number of times service was closed in previous scans
	maximum previous scans stored: 7
	current total services: 7
	previous total services: 5
	up trend: 6,5,5,4
	down trend: 506,507,507,252

About

nmap wrapper / differences and differential reporting

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages