1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-22 23:49:03 +00:00

Always begin with a TTL of at least 1 in traceroute, even if OS

detection calculated 0 (erroneous if not localhost). This caused an
assertion failure reported by Chris Clements in
http://seclists.org/nmap-dev/2009/q3/1054.html.
This commit is contained in:
david
2009-09-27 18:05:16 +00:00
parent a99b8e5e6b
commit 8fd7a0a46b

View File

@@ -332,7 +332,7 @@ static unsigned int hop_cache_size();
HostState::HostState(Target *target) { HostState::HostState(Target *target) {
this->target = target; this->target = target;
current_ttl = HostState::distance_guess(target); current_ttl = MAX(1, HostState::distance_guess(target));
state = HostState::COUNTING_DOWN; state = HostState::COUNTING_DOWN;
reached_target = 0; reached_target = 0;
pspec = HostState::get_probe(target); pspec = HostState::get_probe(target);