1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-26 01:19:03 +00:00

Respect --max-retries in UDP scan even when some payloads haven't been sent.

This commit is contained in:
dmiller
2021-01-19 19:57:37 +00:00
parent 6310b7d9e3
commit a20fda6480

View File

@@ -2457,6 +2457,8 @@ static void doAnyOutstandingRetransmits(UltraScanInfo *USI) {
(maxtries > probe->tryno ||
// We may exceed maxtries if this is UDP...
((USI->udp_scan || (USI->ping_scan && USI->ptech.rawudpscan))
// ...and we haven't exceeded the manually-set max_retries
&& USI->perf.tryno_cap > probe->tryno
// ...and there are more payloads we haven't tried.
&& udp_payload_count(probe->dport()) > probe->tryno)
) && !probe->isPing()) {