Skip to main content

A tool for parsing and dynamically querying nmap scan data

Project description

NMAP Query Tool

Post-processor for nmap output that allows fast, simple filtering of data both interactively and inline (i.e. via a bash pipe).

Usage: python nmap-query.py [-h] [-p PORTS] [-a IPS] [-os OS] [-d DEVICE_TYPE] [-c] [-i NMAP_SCAN_RESULTS_FILE] [-o OUTPUT_FILENAME] [-q]

        Note: the nmap scan results can be provided either through an input file or from STDIN (through a pipe)

        Example: nmap -sV 10.0.0.0/24 | python nmap-query.py -q



[-h | --help]: Will print the help/usage message

[-p | --ports] PORTS: specify one or more (open) ports to filter on. The following input formats are accepted:

        Single port number: -p 22
        Set of port numbers: -p 22,80,443

[-a | --ip-addrs] IPS: specify one or more IP addresses on which to filter. The following input formats are accepted:

        Single IP: -a 10.0.0.1
        Set of IPs: -a 10.0.0.1,10.0.0.2,10.0.0.3
        Single CIDR block: -a 10.0.0.0/24
        Set of CIDR blocks: -a 10.0.0.0/24,10.0.1.0/24
        Range of IPs: -a 10.0.0.1-4

[-os | --operating-system] OS: specify one or more operating systems on which to filter. The following input formats are accepted:

        Single operating system: -os Windws
        Set of operating systems: -os Windows,Linux

[-d | --device-type] DEVICE_TYPE: specify one or more device types on which to filter. The following input formats are accepted:

        Single device type: -d router
        Set of device types: -d router,switch

[-c | --output-csv]: use CSV as the output format

[-i | --input-file] NMAP_SCAN_RESULTS_FILE: specify the name of the input file (i.e. the file which contains the results of the Nmap scan)

[-o | --output-file] OUTPUT_FILENAME: specify the name of the output file

[-q | --query-mode]: enter the interactive query mode

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

nmap_query_tool-1.0.1.tar.gz (9.0 kB view details)

Uploaded Source

Built Distribution

nmap_query_tool-1.0.1-py2-none-any.whl (13.8 kB view details)

Uploaded Python 2

File details

Details for the file nmap_query_tool-1.0.1.tar.gz.

File metadata

  • Download URL: nmap_query_tool-1.0.1.tar.gz
  • Upload date:
  • Size: 9.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.21.0 setuptools/40.6.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/2.7.15+

File hashes

Hashes for nmap_query_tool-1.0.1.tar.gz
Algorithm Hash digest
SHA256 47da45cd8e8145d239cb4468a0e5209243e9d20e4b501be9c62ded9c41e3279d
MD5 8a2444a8263c37b328372494152fb907
BLAKE2b-256 0e7ea08f74465facc32d95b7615b56aa175c7ca9f53e95ed8270358da11d4b33

See more details on using hashes here.

File details

Details for the file nmap_query_tool-1.0.1-py2-none-any.whl.

File metadata

  • Download URL: nmap_query_tool-1.0.1-py2-none-any.whl
  • Upload date:
  • Size: 13.8 kB
  • Tags: Python 2
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.21.0 setuptools/40.6.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/2.7.15+

File hashes

Hashes for nmap_query_tool-1.0.1-py2-none-any.whl
Algorithm Hash digest
SHA256 95bd825a8c6e395cbff5c2c630209e2dac79c8128b04cf8b929d63b860a090ed
MD5 fee24471a20bfe724b9a6745a57ef1dc
BLAKE2b-256 ab19e414806f21a089e730ef677af1357e07a138f499a55edafe9b2197b4357d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page