Skip to content

Commit

Permalink
output: skip files logging for ICMP packets
Browse files Browse the repository at this point in the history
Ticket: OISF#5408
  • Loading branch information
catenacyber authored and benignbala committed Nov 12, 2022
1 parent 1d352ba commit d8dfa40
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/output-filedata.c
Original file line number Diff line number Diff line change
Expand Up @@ -229,6 +229,10 @@ static TmEcode OutputFiledataLog(ThreadVars *tv, Packet *p, void *thread_data)
if (f == NULL || f->alstate == NULL) {
SCReturnInt(TM_ECODE_OK);
}
/* do not log for ICMP packets related to a TCP/UDP flow */
if (p->proto != IPPROTO_TCP && p->proto != IPPROTO_UDP) {
SCReturnInt(TM_ECODE_OK);
}

const bool file_trunc = StreamTcpReassembleDepthReached(p);
if (p->flowflags & FLOW_PKT_TOSERVER) {
Expand Down

0 comments on commit d8dfa40

Please sign in to comment.