refactor: packet module (split to parse/build/layer/tunnel/utils)
This commit is contained in:
@@ -3,14 +3,19 @@
|
||||
#include <sys/queue.h>
|
||||
#include <assert.h>
|
||||
|
||||
#include "packet_priv.h"
|
||||
#include "log.h"
|
||||
#include "packet_def.h"
|
||||
#include "packet_utils.h"
|
||||
#include "packet_parse.h"
|
||||
#include "crc32_hash.h"
|
||||
#include "checksum.h"
|
||||
#include "ipv4_utils.h"
|
||||
#include "ipv6_utils.h"
|
||||
#include "ip_reassembly.h"
|
||||
|
||||
#define IP_REASSEMBLE_DEBUG(format, ...) LOG_DEBUG("ip_reassembly", format, ##__VA_ARGS__)
|
||||
#define IP_REASSEMBLE_ERROR(format, ...) LOG_ERROR("ip_reassembly", format, ##__VA_ARGS__)
|
||||
|
||||
#define IPV4_KEYLEN 1
|
||||
#define IPV6_KEYLEN 4
|
||||
#define PRIME_VALUE 0xeaad8405
|
||||
|
||||
@@ -5,12 +5,6 @@ extern "C"
|
||||
{
|
||||
#endif
|
||||
|
||||
#include "packet_priv.h"
|
||||
#include "log.h"
|
||||
|
||||
#define IP_REASSEMBLE_DEBUG(format, ...) LOG_DEBUG("ip_reassembly", format, ##__VA_ARGS__)
|
||||
#define IP_REASSEMBLE_ERROR(format, ...) LOG_ERROR("ip_reassembly", format, ##__VA_ARGS__)
|
||||
|
||||
struct ip_reassembly_options
|
||||
{
|
||||
uint8_t enable;
|
||||
|
||||
@@ -12,8 +12,10 @@ extern "C"
|
||||
#include "ipv4_utils.h"
|
||||
#include "ipv6_utils.h"
|
||||
#include "ip_reassembly.h"
|
||||
#include "packet_priv.h"
|
||||
#include "packet_def.h"
|
||||
#include "packet_utils.h"
|
||||
#include "packet_parse.h"
|
||||
#include "packet_layer.h"
|
||||
|
||||
static inline void packet_set_ipv4_src_addr(struct packet *pkt, uint32_t saddr)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user