mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 06:38:20 +00:00
Merge remote-tracking branch 'origin/master' into topic/icmp6
This commit is contained in:
commit
0a659c0907
68 changed files with 634 additions and 343 deletions
|
@ -31,6 +31,13 @@ int ones_complement_checksum(const void* p, int b, uint32 sum)
|
|||
return sum;
|
||||
}
|
||||
|
||||
int ones_complement_checksum(const IPAddr& a, uint32 sum)
|
||||
{
|
||||
const uint32* bytes;
|
||||
int len = a.GetBytes(&bytes);
|
||||
return ones_complement_checksum(bytes, len*4, sum);
|
||||
}
|
||||
|
||||
int tcp_checksum(const struct ip* ip, const struct tcphdr* tp, int len)
|
||||
{
|
||||
// ### Note, this is only correct for IPv4. This routine is only
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue