mirror of
https://github.com/zeek/zeek.git
synced 2025-10-05 16:18:19 +00:00
IP: Update packet->len with accumulated fragment size
With packet->len representing the wire length and other places relying on it, ensure it's updated for fragments as well. This assumes non-truncated fragments right now. Otherwise we'd need to teach the FragmentReassembler to somehow track this independently but it would be a mess.
This commit is contained in:
parent
2b9de839b0
commit
568946ec18
1 changed files with 2 additions and 0 deletions
|
@ -205,6 +205,8 @@ bool IPAnalyzer::AnalyzePacket(size_t len, const uint8_t* data, Packet* packet)
|
||||||
}
|
}
|
||||||
|
|
||||||
packet->cap_len = total_len + hdr_size;
|
packet->cap_len = total_len + hdr_size;
|
||||||
|
// Assumes reassembled packet has wire length == capture length.
|
||||||
|
packet->len = packet->cap_len;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue