diff --git a/CHANGELOG b/CHANGELOG index 05d5d446e..3a6ceb1a0 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,5 +1,9 @@ # Nmap Changelog ($Id$); -*-text-*- +o The --open option now implies --defeat-rst-ratelimit. This may result in + inaccuracies in the numbers of "Not shown:" closed and filtered ports, but + only in situations where it also speeds up scan times. [Daniel Miller] + o Fix reverse DNS on Windows which was failing with the message "mass_dns: warning: Unable to determine any DNS servers." This was because the interface GUID comparison needed to be done case-insensitive. [Robert Croteau] diff --git a/nmap.cc b/nmap.cc index 2ca0f295a..af0d51b74 100644 --- a/nmap.cc +++ b/nmap.cc @@ -769,6 +769,8 @@ void parse_options(int argc, char **argv) { error("Warning: You specified a highly aggressive --min-hostgroup."); } else if (strcmp(long_options[option_index].name, "open") == 0) { o.setOpenOnly(true); + // If they only want open, don't spend extra time (potentially) distinguishing closed from filtered. + o.defeat_rst_ratelimit = 1; } else if (strcmp(long_options[option_index].name, "scanflags") == 0) { o.scanflags = parse_scanflags(optarg); if (o.scanflags < 0) { diff --git a/output.cc b/output.cc index fd8ce3098..69f7a81ce 100644 --- a/output.cc +++ b/output.cc @@ -655,8 +655,12 @@ void printportoutput(Target *currenths, PortList *plist) { prevstate = istate; } - if (prevstate != PORT_UNKNOWN) + if (prevstate != PORT_UNKNOWN) { log_write(LOG_PLAIN, "\n"); + if (o.defeat_rst_ratelimit) { + log_write(LOG_PLAIN, "Some closed ports may be reported as filtered due to --defeat-rst-ratelimit\n"); + } + } if (o.reason) print_state_summary(plist, STATE_REASON_FULL);