Add support for PCAP LINKTYPE_IPV4

pull/3017/head
Pierre Chifflier 7 years ago committed by Victor Julien
parent 223a38aeee
commit 5748df3eed

@ -1090,6 +1090,7 @@ void DecodeGlobalConfig(void);
/* http://www.tcpdump.org/linktypes.html defines DLT_RAW as 101, yet others don't. /* http://www.tcpdump.org/linktypes.html defines DLT_RAW as 101, yet others don't.
* Libpcap on at least OpenBSD returns 101 as datalink type for RAW pcaps though. */ * Libpcap on at least OpenBSD returns 101 as datalink type for RAW pcaps though. */
#define LINKTYPE_RAW2 101 #define LINKTYPE_RAW2 101
#define LINKTYPE_IPV4 228
#define PPP_OVER_GRE 11 #define PPP_OVER_GRE 11
#define VLAN_OVER_GRE 13 #define VLAN_OVER_GRE 13

@ -326,6 +326,7 @@ TmEcode ReceivePcapFileThreadInit(ThreadVars *tv, const void *initdata, void **d
case LINKTYPE_PPP: case LINKTYPE_PPP:
pcap_g.Decoder = DecodePPP; pcap_g.Decoder = DecodePPP;
break; break;
case LINKTYPE_IPV4:
case LINKTYPE_RAW: case LINKTYPE_RAW:
case LINKTYPE_RAW2: case LINKTYPE_RAW2:
pcap_g.Decoder = DecodeRaw; pcap_g.Decoder = DecodeRaw;

Loading…
Cancel
Save