Skip to content

Commit 2e1c7f6

Browse files
authored
[CWS] Discard truncated DNS messages (#36822)
1 parent da1f35f commit 2e1c7f6

File tree

1 file changed

+2
-2
lines changed
  • pkg/security/ebpf/c/include/hooks/network

1 file changed

+2
-2
lines changed

pkg/security/ebpf/c/include/hooks/network/dns.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -152,8 +152,8 @@ TAIL_CALL_CLASSIFIER_FNC(dns_response, struct __sk_buff *skb) {
152152
return ACT_OK;
153153
}
154154

155-
if(!flags.qr) {
156-
// Stop processing if it's not a query response
155+
if(!flags.qr || flags.tc) {
156+
// Stop processing if it's not a query response or if the message is truncated
157157
return ACT_OK;
158158
}
159159

0 commit comments

Comments
 (0)