diff options
author | Radoslav Bodo <bodik@cesnet.cz> | 2018-06-19 21:57:37 +0200 |
---|---|---|
committer | Tobias Klauser <tklauser@distanz.ch> | 2018-06-20 13:23:07 +0200 |
commit | 76bd307a8ce82d839037c7437c0d181890adde02 (patch) | |
tree | 86aac927b81d8a034f4ed535f5c4059282c2c77b /trafgen.c | |
parent | 50f8f250563c4f9e740f63b324e40a051230c68f (diff) |
trafgen: support ICMPv6 checksums
Usage: csumicmp6(14, 54)
Signed-off-by: Radoslav Bodo <bodik@cesnet.cz>
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Diffstat (limited to 'trafgen.c')
-rw-r--r-- | trafgen.c | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -376,6 +376,12 @@ static void apply_csum16(int id) (packets[id].len - csum->to), IPPROTO_TCP); break; + case CSUM_ICMP6: + sum = p6_csum((void *) packets[id].payload + csum->from, + packets[id].payload + csum->to, + (packets[id].len - csum->to), + IPPROTO_ICMPV6); + break; default: bug(); break; |