
Nmap Development mailing list archives
[RFC] Should --open override -v?
From: Daniel Miller <bonsaiviking () gmail com>
Date: Fri, 07 Feb 2014 16:14:28 -0600
List,A user on IRC was looking for a way to avoid showing "down" hosts in his output. The standard answer, `--open`, didn't work in this case because he was doing a `-sn` scan and using `-v`. I think perhaps `--open` should override `-v` in this case, instead of the other way around. Here's a table of when down hosts are shown:
Ping scan (-sn) Other scans (-s*) -v Yes Yes --open No No -v --open Yes No (neither) No NoI propose the following patch, which would make Ping scan (`-sn`) hide down hosts for Ping scan when `--open` and `-v` are used together:
--- a/nmap.cc +++ b/nmap.cc @@ -1826,7 +1826,7 @@ int nmap_main(int argc, char *argv[]) { #endif ) || o.listscan) { /* We're done with the hosts */ - if (currenths->flags & HOST_UP || o.verbose) { + if (currenths->flags & HOST_UP || (o.verbose && !o.openOnly())) { xml_start_tag("host"); write_host_header(currenths); printmacinfo(currenths); Thoughts? Dan _______________________________________________ Sent through the dev mailing list http://nmap.org/mailman/listinfo/dev Archived at http://seclists.org/nmap-dev/
Current thread:
- [RFC] Should --open override -v? Daniel Miller (Feb 07)
- Re: [RFC] Should --open override -v? Fyodor (Feb 12)