mirror of
https://github.com/zeek/zeek.git
synced 2025-10-04 15:48:19 +00:00
Fix potential crash TCP headers were captured incompletely.
Test case provided by Jonathan Ganz. BIT-1425 #close
This commit is contained in:
parent
d88e6b3f1a
commit
1b9ee38e69
4 changed files with 33 additions and 1 deletions
|
@ -442,7 +442,7 @@ const struct tcphdr* TCP_Analyzer::ExtractTCP_Header(const u_char*& data,
|
|||
}
|
||||
|
||||
if ( tcp_hdr_len > uint32(len) ||
|
||||
sizeof(struct tcphdr) > uint32(caplen) )
|
||||
tcp_hdr_len > uint32(caplen) )
|
||||
{
|
||||
// This can happen even with the above test, due to TCP
|
||||
// options.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue