-
Notifications
You must be signed in to change notification settings - Fork 126
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Print per-second summary statistics detailing a scan, similar to ZMap #473
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think it's OK to make this not disable'able or not redirectable. I also don't think that it's OK to put these on stdout
since it precludes piping ZDNS into another program. These should be able to be turned on and off and should be printed to stderr or a file.
The most useful thing in ZMap to make sure a scan looks good is hitrate, which you can't actually quite get here. Can we get the same thing here. When calculating hitrate I would include both NOERROR
and NXDOMAIN
because both are a successful response from the DNS server.
Yep all seems reasonable! Will make those changes |
src/cli/iohandlers/status_handler.go
Outdated
case <-ticker.C: | ||
// print per-second summary | ||
timeSinceStart := time.Since(stats.scanStartTime) | ||
s := fmt.Sprintf("%02dh:%02dm:%02ds; %d domains scanned; %.02f domains/sec.; %.01f%% success rate; %s\n", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that should be names
not domains
. I also think you could get rid of the .
after sec.
src/cli/iohandlers/status_handler.go
Outdated
} | ||
} | ||
timeSinceStart := time.Since(stats.scanStartTime) | ||
s := fmt.Sprintf("%02dh:%02dm:%02ds; Scan Complete, no more input. %d domains scanned; %.02f domains/sec.; %.01f%% success rate; %s\n", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you can drop , no more input
. Would switch domain
to name
here.
Closes #472
Adds a per-second summary with the following:
A final summary is printed on scan completion
This is printed to stderr by default.
Two new CLI flags are available to modify this behavior:
Demo