fix: leak
This commit is contained in:
@ -85,10 +85,13 @@ void icmp_response(const struct icmphdr *icmphdr, const struct scan *data)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (data->responses->service == NULL)
|
||||||
|
{
|
||||||
data->responses->service = get_service_name(data->port_start, "udp");
|
data->responses->service = get_service_name(data->port_start, "udp");
|
||||||
if (data->responses->service == NULL)
|
if (data->responses->service == NULL)
|
||||||
data->responses->service =
|
data->responses->service =
|
||||||
get_service_name(data->port_start, "tcp");
|
get_service_name(data->port_start, "tcp");
|
||||||
|
}
|
||||||
if (data->type & SCAN_SYN && icmphdr->type == 3)
|
if (data->type & SCAN_SYN && icmphdr->type == 3)
|
||||||
data->responses->states[type_index] = FILTERED;
|
data->responses->states[type_index] = FILTERED;
|
||||||
else if (data->type & SCAN_ACK && icmphdr->type == 3)
|
else if (data->type & SCAN_ACK && icmphdr->type == 3)
|
||||||
@ -117,10 +120,13 @@ void no_response(const struct scan *data)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (data->responses->service == NULL)
|
||||||
|
{
|
||||||
data->responses->service = get_service_name(data->port_start, "udp");
|
data->responses->service = get_service_name(data->port_start, "udp");
|
||||||
if (data->responses->service == NULL)
|
if (data->responses->service == NULL)
|
||||||
data->responses->service =
|
data->responses->service =
|
||||||
get_service_name(data->port_start, "tcp");
|
get_service_name(data->port_start, "tcp");
|
||||||
|
}
|
||||||
if (data->type & SCAN_SYN)
|
if (data->type & SCAN_SYN)
|
||||||
data->responses->states[type_index] = FILTERED;
|
data->responses->states[type_index] = FILTERED;
|
||||||
else if (data->type & SCAN_ACK)
|
else if (data->type & SCAN_ACK)
|
||||||
|
Reference in New Issue
Block a user