test: add imitate_tcp_packet test case (TCP over GREv0: GRE enable checksum)

This commit is contained in:
luwenpeng
2024-07-15 15:07:38 +08:00
parent d31cfd02fd
commit 07ce636f64
13 changed files with 408 additions and 150 deletions

View File

@@ -7,7 +7,7 @@ extern "C"
#include <stdint.h>
uint16_t checksum(const char *data, uint16_t len);
uint16_t checksum(const void *data, int len);
uint16_t checksum_v4(const void *l4_hdr_ptr, uint16_t l4_total_len, uint8_t l4_proto, struct in_addr *src_addr, struct in_addr *dst_addr);
uint16_t checksum_v6(const void *l4_hdr_ptr, uint16_t l4_total_len, uint8_t l4_proto, struct in6_addr *src_addr, struct in6_addr *dst_addr);