mirror of
https://github.com/wangyu-/udp2raw.git
synced 2025-04-07 04:29:34 +08:00
support linux cooked mode
This commit is contained in:
parent
7c1b34d5df
commit
7f848553f5
@ -346,6 +346,10 @@ int init_raw_socket()
|
|||||||
{
|
{
|
||||||
pcap_link_header_len=4;
|
pcap_link_header_len=4;
|
||||||
}
|
}
|
||||||
|
else if(ret==DLT_LINUX_SLL)
|
||||||
|
{
|
||||||
|
pcap_link_header_len=16;
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
mylog(log_fatal,"unknown pcap link type : %d\n",ret);
|
mylog(log_fatal,"unknown pcap link type : %d\n",ret);
|
||||||
|
@ -74,6 +74,7 @@ typedef unsigned char u_char;
|
|||||||
#define DLT_SLIP 8 /* Serial Line IP */
|
#define DLT_SLIP 8 /* Serial Line IP */
|
||||||
#define DLT_PPP 9 /* Point-to-point Protocol */
|
#define DLT_PPP 9 /* Point-to-point Protocol */
|
||||||
#define DLT_FDDI 10 /* FDDI */
|
#define DLT_FDDI 10 /* FDDI */
|
||||||
|
#define DLT_LINUX_SLL 113
|
||||||
|
|
||||||
#define PCAP_NETMASK_UNKNOWN 0xffffffff
|
#define PCAP_NETMASK_UNKNOWN 0xffffffff
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user