diff --git a/MANIFEST b/MANIFEST index d6cae1d0a39e684fec59e5cecdd4dded8f494fe9..78ea03f4e30115acb4d4e9753b4a6042a2391e41 100644 --- a/MANIFEST +++ b/MANIFEST @@ -1,3 +1,3 @@ -VERSION=v1.4.3 +VERSION=v1.4.4 SERVICE=vat-genscan diff --git a/README.md b/README.md index 4e350fb296ce80da73d8f28138d16b70ea9c8fdd..10b9196a567f0ec40c70c96b96d08d6fc4277319 100644 --- a/README.md +++ b/README.md @@ -30,6 +30,10 @@ Supported scanners and their profiles: * `basic`: no parameters * `nmap` * `basic_discovery`: no parameters + * `basic_discovery_ports`: provide port parameter (nmap -sV -p xxx) + * ports + * `custom`: provide all command line parameters (nmap xxxxxx) + * parameters *See example config files in `config-examples` folder.* diff --git a/config-examples/nmap-custom.json b/config-examples/nmap-custom.json new file mode 100644 index 0000000000000000000000000000000000000000..6cbcea31e2f705c8ca2ac39522ff7d7a97911646 --- /dev/null +++ b/config-examples/nmap-custom.json @@ -0,0 +1,13 @@ +{ + "target": { + "ip": "192.168.1.0/24" + }, + "config": { + "nmap": { + "profile": "custom_parameters", + "parameters": { + "parameters": "-sV -p 22" + } + } + } +} diff --git a/config-examples/nmap-ports.json b/config-examples/nmap-ports.json new file mode 100644 index 0000000000000000000000000000000000000000..8ff4529b9677c89f33bf242bba0f5d3715b4a78a --- /dev/null +++ b/config-examples/nmap-ports.json @@ -0,0 +1,13 @@ +{ + "target": { + "ip": "192.168.1.0/24" + }, + "config": { + "nmap": { + "profile": "basic_discovery_ports", + "parameters": { + "ports": "22,80,443" + } + } + } +} diff --git a/config-examples/nmap.json b/config-examples/nmap.json new file mode 100644 index 0000000000000000000000000000000000000000..fe55d2abf966f8354106fc682165a466b5e51356 --- /dev/null +++ b/config-examples/nmap.json @@ -0,0 +1,10 @@ +{ + "target": { + "ip": "192.168.1.0/24" + }, + "config": { + "nmap": { + "profile": "basic_discovery" + } + } +} diff --git a/configure.py b/configure.py index 5b6337844d59166eedae78643c9c8131ca397d86..f7606ef0555c6a38cfceddbdfcc7f4f5dce2d30b 100644 --- a/configure.py +++ b/configure.py @@ -62,6 +62,10 @@ def configure(): cscan_config["NMAP"] = {"CS_NMAP": "nmap"} if profile == "basic_discovery": cscan_config["NMAP"]["CS_NMAP_ARGS"] = "-sV" + if profile == "basic_discovery_ports": + cscan_config["NMAP"]["CS_NMAP_ARGS"] = "-sV -p " + config["config"][scanner]["parameters"]["ports"] + if profile == "custom_parameters": + cscan_config["NMAP"]["CS_NMAP_ARGS"] = config["config"][scanner]["parameters"]["parameters"] else: raise UnsupportedProfileException() cs_scripts.append("nmap.sh")