dns/probe: check that a request has at least one query

Ticket: 7279
This commit is contained in:
Philippe Antoine
2024-12-20 07:55:46 +01:00
committed by Victor Julien
parent 9b40446bea
commit 5da2b5d7a4
+3
View File
@@ -789,6 +789,9 @@ fn probe_header_validity(header: &DNSHeader, rlen: usize) -> (bool, bool, bool)
}
let is_request = header.flags & 0x8000 == 0;
if is_request && header.questions == 0 {
return (false, false, false);
}
return (true, is_request, false);
}