2 * Copyright (c) 1990, 1991, 1993
3 * The Regents of the University of California. All rights reserved.
5 * This code is derived from the Stanford/CMU enet packet filter,
6 * (net/enet.c) distributed as part of 4.3BSD, and code contributed
7 * to Berkeley by Steven McCanne and Van Jacobson both of Lawrence
10 * Redistribution and use in source and binary forms, with or without
11 * modification, are permitted provided that the following conditions
13 * 1. Redistributions of source code must retain the above copyright
14 * notice, this list of conditions and the following disclaimer.
15 * 2. Redistributions in binary form must reproduce the above copyright
16 * notice, this list of conditions and the following disclaimer in the
17 * documentation and/or other materials provided with the distribution.
18 * 3. Neither the name of the University nor the names of its contributors
19 * may be used to endorse or promote products derived from this software
20 * without specific prior written permission.
22 * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
23 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
24 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
25 * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
26 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
27 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
28 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
29 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
30 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
31 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
34 * @(#)bpf.h 8.1 (Berkeley) 6/10/93
35 * @(#)bpf.h 1.34 (LBL) 6/16/96
37 * @(#) $Header: /tcpdump/master/libpcap/pcap-bpf.h,v 1.34.2.24 2007/09/19 02:52:12 guy Exp $ (LBL)
39 * $FreeBSD: src/sys/net/bpf.h,v 1.21.2.4 2002/07/05 14:40:00 fenner Exp $
40 * $DragonFly: src/sys/net/bpf.h,v 1.12 2008/03/14 09:52:10 matthias Exp $
47 * Data-link level type codes.
49 #define DLT_NULL 0 /* no link-layer encapsulation */
50 #define DLT_EN10MB 1 /* Ethernet (10Mb) */
51 #define DLT_EN3MB 2 /* Experimental Ethernet (3Mb) */
52 #define DLT_AX25 3 /* Amateur Radio AX.25 */
53 #define DLT_PRONET 4 /* Proteon ProNET Token Ring */
54 #define DLT_CHAOS 5 /* Chaos */
55 #define DLT_IEEE802 6 /* 802.5 Token Ring */
56 #define DLT_ARCNET 7 /* ARCNET */
57 #define DLT_SLIP 8 /* Serial Line IP */
58 #define DLT_PPP 9 /* Point-to-point Protocol */
59 #define DLT_FDDI 10 /* FDDI */
60 #define DLT_ATM_RFC1483 11 /* LLC/SNAP encapsulated atm */
61 #define DLT_RAW 12 /* raw IP */
65 #define DLT_SLIP_BSDOS 15 /* BSD/OS Serial Line IP */
66 #define DLT_PPP_BSDOS 16 /* BSD/OS Point-to-point Protocol */
67 #define DLT_PFSYNC 18 /* Packet filter state syncing */
68 #define DLT_ATM_CLIP 19 /* Linux Classical-IP over ATM */
72 #define DLT_REDBACK_SMARTEDGE 32 /* Redback SmartEdge 400/800 */
76 #define DLT_PPP_SERIAL 50 /* PPP over serial with HDLC encapsulation */
77 #define DLT_PPP_ETHER 51 /* PPP over Ethernet */
81 #define DLT_SYMANTEC_FIREWALL 99 /* Symantec Enterprise Firewall */
84 * Values starting with 104 are used for newly-assigned link-layer
85 * header type values; for those link-layer header types, the DLT_
86 * value returned by pcap_datalink() and passed to pcap_open_dead(),
87 * and the LINKTYPE_ value that appears in capture files, are the
90 * DLT_MATCHING_MIN is the lowest such value; DLT_MATCHING_MAX is
91 * the highest such value.
93 #define DLT_MATCHING_MIN 104
95 /* 100 - 103 unused */
97 #define DLT_C_HDLC 104 /* Cisco HDLC */
98 #define DLT_CHDLC DLT_C_HDLC
99 #define DLT_IEEE802_11 105 /* IEEE 802.11 wireless */
100 #define DLT_FRELAY 107 /* Q.922 Frame Relay */
101 #define DLT_LOOP 108 /* loopback */
102 #define DLT_ENC 109 /* Encapsulated packets for IPsec */
104 /* 110 - 112 unused */
106 #define DLT_LINUX_SLL 113 /* Linux cooked sockets */
107 #define DLT_LTALK 114 /* Apple LocalTalk hardware */
108 #define DLT_ECONET 115 /* Acorn Econet */
109 #define DLT_IPFILTER 116 /* OpenBSD ipfilter */
110 #define DLT_PFLOG 117 /* Packet filter logging */
111 #define DLT_CISCO_IOS 118 /* Cisco-internal use */
112 #define DLT_PRISM_HEADER 119 /* 802.11 plus Prism II radio header */
113 #define DLT_AIRONET_HEADER 120 /* 802.11 plus Aironet radio header */
114 #define DLT_HHDLC 121 /* Siemens HiPath HDLC */
115 #define DLT_IP_OVER_FC 122 /* RFC2625 IP-over-Fibre Channel */
116 #define DLT_SUNATM 123 /* Solaris+SunATM */
117 #define DLT_RIO 124 /* RapidIO */
118 #define DLT_PCI_EXP 125 /* PCI Express */
119 #define DLT_AURORA 126 /* Xilinx Aurora link layer */
120 #ifndef DLT_IEEE802_11_RADIO
121 #define DLT_IEEE802_11_RADIO 127 /* 802.11 plus radiotap radio header */
123 #define DLT_TZSP 128 /* Tazmen Sniffer Protocol */
124 #define DLT_ARCNET_LINUX 129 /* Linux ARCNET */
125 #define DLT_JUNIPER_MLPPP 130 /* Juniper private */
126 #define DLT_JUNIPER_MLFR 131 /* Juniper private */
127 #define DLT_JUNIPER_ES 132 /* Juniper private */
128 #define DLT_JUNIPER_GGSN 133 /* Juniper private */
129 #define DLT_JUNIPER_MFR 134 /* Juniper private */
130 #define DLT_JUNIPER_ATM2 135 /* Juniper private */
131 #define DLT_JUNIPER_SERVICES 136 /* Juniper private */
132 #define DLT_JUNIPER_ATM1 137 /* Juniper private */
133 #define DLT_APPLE_IP_OVER_IEEE1394 138 /* Apple IP-over-IEEE 1394 */
134 #define DLT_MTP2_WITH_PHDR 139 /* pseudo-header with various info,
135 * followed by MTP2 */
136 #define DLT_MTP2 140 /* MTP2, w/o pseudo-header */
137 #define DLT_MTP3 141 /* MTP3, w/o pseudo-header or MTP2 */
138 #define DLT_SCCP 142 /* SCCP, w/o pseudo-header or MTP2
140 #define DLT_DOCSIS 143 /* DOCSIS MAC frames */
141 #define DLT_LINUX_IRDA 144 /* Linux IrDA */
142 #define DLT_IBM_SP 145 /* IBM SP switch */
143 #define DLT_IBM_SN 146 /* IBM Next Federation switch */
145 /* 147 - 162 unused */
147 #define DLT_IEEE802_11_RADIO_AVS 163 /* 802.11 plus AVS radio header */
148 #define DLT_JUNIPER_MONITOR 164 /* Juniper private */
149 #define DLT_BACNET_MS_TP 165 /* BACnet MS/TP */
150 #define DLT_PPP_PPPD 166 /* Linux PPP variant */
151 #define DLT_JUNIPER_PPPOE 167 /* Juniper private */
152 #define DLT_JUNIPER_PPPOE_ATM 168 /* Juniper private */
153 #define DLT_GPRS_LLC 169 /* GPRS LLC */
154 #define DLT_GPF_T 170 /* GPF-T (ITU-T G.7041/Y.1303) */
155 #define DLT_GPF_F 171 /* GPF-F (ITU-T G.7041/Y.1303) */
156 #define DLT_GCOM_T1E1 172 /* Gcom's T1/E1 */
157 #define DLT_GCOM_SERIAL 173 /* Gcom's T1/E1 */
158 #define DLT_JUNIPER_PIC_PEER 174 /* Juniper private */
159 #define DLT_ERF_ETH 175 /* Ethernet plus ERF header */
160 #define DLT_ERF_POS 176 /* Packet-over-SONET plus ERF header */
161 #define DLT_LINUX_LAPD 177 /* raw LAPD plus addition info */
162 #define DLT_JUNIPER_ETHER 178 /* Juniper private */
163 #define DLT_JUNIPER_PPP 179 /* Juniper private */
164 #define DLT_JUNIPER_FRELAY 180 /* Juniper private */
165 #define DLT_JUNIPER_CHDLC 181 /* Juniper private */
166 #define DLT_MFR 182 /* Multi Link Frame Relay (FRF.16) */
167 #define DLT_JUNIPER_VP 183 /* Juniper private */
168 #define DLT_A429 184 /* Arinc 429 frames */
169 #define DLT_A653_ICM 185 /* Arinc 653 Interpartition
170 * Communication messages */
172 * This used to be "USB packets, beginning with a USB setup header;
173 * requested by Paolo Abeni <paolo.abeni@email.it>."
175 * However, that header didn't work all that well - it left out some
176 * useful information - and was abandoned in favor of the DLT_USB_LINUX
179 * This is now used by FreeBSD for its BPF taps for USB; that has its
180 * own headers. So it is written, so it is done.
182 * For source-code compatibility, we also define DLT_USB to have this
183 * value. We do it numerically so that, if code that includes this
184 * file (directly or indirectly) also includes an OS header that also
185 * defines DLT_USB as 186, we don't get a redefinition warning.
186 * (NetBSD 7 does that.)
188 #define DLT_USB_FREEBSD 186
191 #define DLT_BLUETOOTH_HCI_H4 187 /* Bluetooth HCI UART transport layer
193 #define DLT_IEEE802_16_MAC_CPS 188 /* IEEE 802.16 MAC Common Part
195 #define DLT_USB_LINUX 189 /* USB packets plus Linux USB header */
196 #define DLT_CAN20B 190 /* Controller Area Network (CAN)
198 #define DLT_IEEE802_15_4_LINUX 191 /* IEEE 802.15.4, with address fields
200 #define DLT_PPI 192 /* Per Packet Information encapsulated
202 #define DLT_IEEE802_16_MAC_CPS_RADIO 193 /* 802.16 MAC Common Part Sublayer
203 * plus a radiotap radio header */
204 #define DLT_JUNIPER_ISM 194 /* Juniper private */
205 #define DLT_IEEE802_15_4 195 /* IEEE 802.15.4 */
206 #define DLT_SITA 196 /* SITA plus a pseudo-header */
207 #define DLT_ERF 197 /* Endace ERF records plus
209 #define DLT_RAIF1 198 /* Ethernet plus special header */
210 #define DLT_IPMB 199 /* IPMB packet for IPMI */
211 #define DLT_JUNIPER_ST 200 /* Juniper private */
212 #define DLT_BLUETOOTH_HCI_H4_WITH_PHDR 201 /* Bluetooth HCI UART transport
213 * layer (part H:4) plus
215 #define DLT_AX25_KISS 202 /* AX.25 packet with a 1-byte KISS
217 #define DLT_LAPD 203 /* LAPD packets from an ISDN channel,
218 * starting with the address field,
219 * with no pseudo-header */
220 #define DLT_PPP_WITH_DIR 204 /* PPP */
221 #define DLT_C_HDLC_WITH_DIR 205 /* Cisco HDLC */
222 #define DLT_FRELAY_WITH_DIR 206 /* Frame Relay */
223 #define DLT_LAPB_WITH_DIR 207 /* LAPB */
227 #define DLT_IPMB_LINUX 209 /* IPMB with a Linux-specific
229 #define DLT_FLEXRAY 210 /* FlexRay automotive bus */
230 #define DLT_MOST 211 /* Media Oriented Systems Transport
232 #define DLT_LIN 212 /* Local Interconnect Network
234 #define DLT_X2E_SERIAL 213 /* X2E-private */
235 #define DLT_X2E_XORAYA 214 /* X2E-private */
236 #define DLT_IEEE802_15_4_NONASK_PHY 215 /* IEEE 802.15.4, with the PHY-level
237 * data for non-ASK PHYs */
238 #define DLT_IEEE802_15_4_NONASK_PHY 215
241 * David Gibson <david@gibson.dropbear.id.au> requested this for
242 * captures from the Linux kernel /dev/input/eventN devices. This
243 * is used to communicate keystrokes and mouse movements from the
244 * Linux kernel to display systems, such as Xorg.
246 #define DLT_LINUX_EVDEV 216
249 * GSM Um and Abis interfaces, preceded by a "gsmtap" header.
251 * Requested by Harald Welte <laforge@gnumonks.org>.
253 #define DLT_GSMTAP_UM 217
254 #define DLT_GSMTAP_ABIS 218
257 * MPLS, with an MPLS label as the link-layer header.
258 * Requested by Michele Marchetto <michele@openbsd.org> on behalf
264 * USB packets, beginning with a Linux USB header, with the USB header
265 * padded to 64 bytes; required for memory-mapped access.
267 #define DLT_USB_LINUX_MMAPPED 220
270 * DECT packets, with a pseudo-header; requested by
271 * Matthias Wenzel <tcpdump@mazzoo.de>.
276 * From: "Lidwa, Eric (GSFC-582.0)[SGT INC]" <eric.lidwa-1@nasa.gov>
277 * Date: Mon, 11 May 2009 11:18:30 -0500
279 * DLT_AOS. We need it for AOS Space Data Link Protocol.
280 * I have already written dissectors for but need an OK from
281 * legal before I can submit a patch.
287 * Wireless HART (Highway Addressable Remote Transducer)
288 * From the HART Communication Foundation
291 * Requested by Sam Roberts <vieuxtech@gmail.com>.
293 #define DLT_WIHART 223
296 * Fibre Channel FC-2 frames, beginning with a Frame_Header.
297 * Requested by Kahou Lei <kahou82@gmail.com>.
302 * Fibre Channel FC-2 frames, beginning with an encoding of the
303 * SOF, and ending with an encoding of the EOF.
305 * The encodings represent the frame delimiters as 4-byte sequences
306 * representing the corresponding ordered sets, with K28.5
307 * represented as 0xBC, and the D symbols as the corresponding
308 * byte values; for example, SOFi2, which is K28.5 - D21.5 - D1.2 - D21.2,
309 * is represented as 0xBC 0xB5 0x55 0x55.
311 * Requested by Kahou Lei <kahou82@gmail.com>.
313 #define DLT_FC_2_WITH_FRAME_DELIMS 225
316 * Solaris ipnet pseudo-header; requested by Darren Reed <Darren.Reed@Sun.COM>.
318 * The pseudo-header starts with a one-byte version number; for version 2,
319 * the pseudo-header is:
321 * struct dl_ipnetinfo {
322 * u_int8_t dli_version;
323 * u_int8_t dli_family;
324 * u_int16_t dli_htype;
325 * u_int32_t dli_pktlen;
326 * u_int32_t dli_ifindex;
327 * u_int32_t dli_grifindex;
328 * u_int32_t dli_zsrc;
329 * u_int32_t dli_zdst;
332 * dli_version is 2 for the current version of the pseudo-header.
334 * dli_family is a Solaris address family value, so it's 2 for IPv4
337 * dli_htype is a "hook type" - 0 for incoming packets, 1 for outgoing
338 * packets, and 2 for packets arriving from another zone on the same
341 * dli_pktlen is the length of the packet data following the pseudo-header
342 * (so the captured length minus dli_pktlen is the length of the
343 * pseudo-header, assuming the entire pseudo-header was captured).
345 * dli_ifindex is the interface index of the interface on which the
348 * dli_grifindex is the group interface index number (for IPMP interfaces).
350 * dli_zsrc is the zone identifier for the source of the packet.
352 * dli_zdst is the zone identifier for the destination of the packet.
354 * A zone number of 0 is the global zone; a zone number of 0xffffffff
355 * means that the packet arrived from another host on the network, not
356 * from another zone on the same machine.
358 * An IPv4 or IPv6 datagram follows the pseudo-header; dli_family indicates
359 * which of those it is.
361 #define DLT_IPNET 226
364 * CAN (Controller Area Network) frames, with a pseudo-header as supplied
365 * by Linux SocketCAN, and with multi-byte numerical fields in that header
366 * in big-endian byte order.
368 * See Documentation/networking/can.txt in the Linux source.
370 * Requested by Felix Obenhuber <felix@obenhuber.de>.
372 #define DLT_CAN_SOCKETCAN 227
375 * Raw IPv4/IPv6; different from DLT_RAW in that the DLT_ value specifies
376 * whether it's v4 or v6. Requested by Darren Reed <Darren.Reed@Sun.COM>.
382 * IEEE 802.15.4, exactly as it appears in the spec (no padding, no
383 * nothing), and with no FCS at the end of the frame; requested by
384 * Jon Smirl <jonsmirl@gmail.com>.
386 #define DLT_IEEE802_15_4_NOFCS 230
391 * http://www.freedesktop.org/wiki/Software/dbus
395 * http://dbus.freedesktop.org/doc/dbus-specification.html#message-protocol-messages
397 * starting with the endianness flag, followed by the message type, etc.,
398 * but without the authentication handshake before the message sequence:
400 * http://dbus.freedesktop.org/doc/dbus-specification.html#auth-protocol
402 * Requested by Martin Vidner <martin@vidner.net>.
407 * Juniper-private data link type, as per request from
408 * Hannes Gredler <hannes@juniper.net>.
410 #define DLT_JUNIPER_VS 232
411 #define DLT_JUNIPER_SRX_E2E 233
412 #define DLT_JUNIPER_FIBRECHANNEL 234
415 * DVB-CI (DVB Common Interface for communication between a PC Card
416 * module and a DVB receiver). See
418 * http://www.kaiser.cx/pcap-dvbci.html
420 * for the specification.
422 * Requested by Martin Kaiser <martin@kaiser.cx>.
424 #define DLT_DVB_CI 235
427 * Variant of 3GPP TS 27.010 multiplexing protocol (similar to, but
428 * *not* the same as, 27.010). Requested by Hans-Christoph Schemmel
429 * <hans-christoph.schemmel@cinterion.com>.
431 #define DLT_MUX27010 236
434 * STANAG 5066 D_PDUs. Requested by M. Baris Demiray
435 * <barisdemiray@gmail.com>.
437 #define DLT_STANAG_5066_D_PDU 237
440 * Juniper-private data link type, as per request from
441 * Hannes Gredler <hannes@juniper.net>.
443 #define DLT_JUNIPER_ATM_CEMIC 238
446 * NetFilter LOG messages
447 * (payload of netlink NFNL_SUBSYS_ULOG/NFULNL_MSG_PACKET packets)
449 * Requested by Jakub Zawadzki <darkjames-ws@darkjames.pl>
451 #define DLT_NFLOG 239
454 * Hilscher Gesellschaft fuer Systemautomation mbH link-layer type
455 * for Ethernet packets with a 4-byte pseudo-header and always
456 * with the payload including the FCS, as supplied by their
457 * netANALYZER hardware and software.
459 * Requested by Holger P. Frommer <HPfrommer@hilscher.com>
461 #define DLT_NETANALYZER 240
464 * Hilscher Gesellschaft fuer Systemautomation mbH link-layer type
465 * for Ethernet packets with a 4-byte pseudo-header and FCS and
466 * with the Ethernet header preceded by 7 bytes of preamble and
467 * 1 byte of SFD, as supplied by their netANALYZER hardware and
470 * Requested by Holger P. Frommer <HPfrommer@hilscher.com>
472 #define DLT_NETANALYZER_TRANSPARENT 241
475 * IP-over-InfiniBand, as specified by RFC 4391.
477 * Requested by Petr Sumbera <petr.sumbera@oracle.com>.
479 #define DLT_IPOIB 242
482 * MPEG-2 transport stream (ISO 13818-1/ITU-T H.222.0).
484 * Requested by Guy Martin <gmsoft@tuxicoman.be>.
486 #define DLT_MPEG_2_TS 243
489 * ng4T GmbH's UMTS Iub/Iur-over-ATM and Iub/Iur-over-IP format as
490 * used by their ng40 protocol tester.
492 * Requested by Jens Grimmer <jens.grimmer@ng4t.com>.
497 * Pseudo-header giving adapter number and flags, followed by an NFC
498 * (Near-Field Communications) Logical Link Control Protocol (LLCP) PDU,
499 * as specified by NFC Forum Logical Link Control Protocol Technical
500 * Specification LLCP 1.1.
502 * Requested by Mike Wakerly <mikey@google.com>.
504 #define DLT_NFC_LLCP 245
507 * 246 is used as LINKTYPE_PFSYNC; do not use it for any other purpose.
509 * DLT_PFSYNC has different values on different platforms, and all of
510 * them collide with something used elsewhere. On platforms that
511 * don't already define it, define it as 246.
513 #if !defined(__FreeBSD__) && !defined(__OpenBSD__) && !defined(__NetBSD__) && !defined(__DragonFly__) && !defined(__APPLE__)
514 #define DLT_PFSYNC 246
518 * Raw InfiniBand packets, starting with the Local Routing Header.
520 * Requested by Oren Kladnitsky <orenk@mellanox.com>.
522 #define DLT_INFINIBAND 247
525 * SCTP, with no lower-level protocols (i.e., no IPv4 or IPv6).
527 * Requested by Michael Tuexen <Michael.Tuexen@lurchi.franken.de>.
532 * USB packets, beginning with a USBPcap header.
534 * Requested by Tomasz Mon <desowin@gmail.com>
536 #define DLT_USBPCAP 249
539 * Schweitzer Engineering Laboratories "RTAC" product serial-line
542 * Requested by Chris Bontje <chris_bontje@selinc.com>.
544 #define DLT_RTAC_SERIAL 250
547 * Bluetooth Low Energy air interface link-layer packets.
549 * Requested by Mike Kershaw <dragorn@kismetwireless.net>.
551 #define DLT_BLUETOOTH_LE_LL 251
554 * DLT type for upper-protocol layer PDU saves from wireshark.
556 * the actual contents are determined by two TAGs stored with each
558 * EXP_PDU_TAG_LINKTYPE the link type (LINKTYPE_ value) of the
561 * EXP_PDU_TAG_PROTO_NAME the name of the wireshark dissector
562 * that can make sense of the data stored.
564 #define DLT_WIRESHARK_UPPER_PDU 252
567 * DLT type for the netlink protocol (nlmon devices).
569 #define DLT_NETLINK 253
572 * Bluetooth Linux Monitor headers for the BlueZ stack.
574 #define DLT_BLUETOOTH_LINUX_MONITOR 254
577 * Bluetooth Basic Rate/Enhanced Data Rate baseband packets, as
578 * captured by Ubertooth.
580 #define DLT_BLUETOOTH_BREDR_BB 255
583 * Bluetooth Low Energy link layer packets, as captured by Ubertooth.
585 #define DLT_BLUETOOTH_LE_LL_WITH_PHDR 256
588 * PROFIBUS data link layer.
590 #define DLT_PROFIBUS_DL 257
593 * Apple's DLT_PKTAP headers.
595 * Sadly, the folks at Apple either had no clue that the DLT_USERn values
596 * are for internal use within an organization and partners only, and
597 * didn't know that the right way to get a link-layer header type is to
598 * ask tcpdump.org for one, or knew and didn't care, so they just
599 * used DLT_USER2, which causes problems for everything except for
600 * their version of tcpdump.
602 * So I'll just give them one; hopefully this will show up in a
603 * libpcap release in time for them to get this into 10.10 Big Sur
604 * or whatever Mavericks' successor is called. LINKTYPE_PKTAP
605 * will be 258 *even on OS X*; that is *intentional*, so that
606 * PKTAP files look the same on *all* OSes (different OSes can have
607 * different numerical values for a given DLT_, but *MUST NOT* have
608 * different values for what goes in a file, as files can be moved
611 * When capturing, on a system with a Darwin-based OS, on a device
612 * that returns 149 (DLT_USER2 and Apple's DLT_PKTAP) with this
613 * version of libpcap, the DLT_ value for the pcap_t will be DLT_PKTAP,
614 * and that will continue to be DLT_USER2 on Darwin-based OSes. That way,
615 * binary compatibility with Mavericks is preserved for programs using
616 * this version of libpcap. This does mean that if you were using
617 * DLT_USER2 for some capture device on OS X, you can't do so with
618 * this version of libpcap, just as you can't with Apple's libpcap -
619 * on OS X, they define DLT_PKTAP to be DLT_USER2, so programs won't
620 * be able to distinguish between PKTAP and whatever you were using
623 * If the program saves the capture to a file using this version of
624 * libpcap's pcap_dump code, the LINKTYPE_ value in the file will be
625 * LINKTYPE_PKTAP, which will be 258, even on Darwin-based OSes.
626 * That way, the file will *not* be a DLT_USER2 file. That means
627 * that the latest version of tcpdump, when built with this version
628 * of libpcap, and sufficiently recent versions of Wireshark will
629 * be able to read those files and interpret them correctly; however,
630 * Apple's version of tcpdump in OS X 10.9 won't be able to handle
631 * them. (Hopefully, Apple will pick up this version of libpcap,
632 * and the corresponding version of tcpdump, so that tcpdump will
633 * be able to handle the old LINKTYPE_USER2 captures *and* the new
634 * LINKTYPE_PKTAP captures.)
637 #define DLT_PKTAP DLT_USER2
639 #define DLT_PKTAP 258
643 * Ethernet packets preceded by a header giving the last 6 octets
644 * of the preamble specified by 802.3-2012 Clause 65, section
645 * 65.1.3.2 "Transmit".
650 * IPMI trace packets, as specified by Table 3-20 "Trace Data Block Format"
651 * in the PICMG HPM.2 specification.
653 #define DLT_IPMI_HPM_2 260
656 * per Joshua Wright <jwright@hasborg.com>, formats for Zwave captures.
658 #define DLT_ZWAVE_R1_R2 261
659 #define DLT_ZWAVE_R3 262
662 * per Steve Karg <skarg@users.sourceforge.net>, formats for Wattstopper
663 * Digital Lighting Management room bus serial protocol captures.
665 #define DLT_WATTSTOPPER_DLM 263
668 * ISO 14443 contactless smart card messages.
670 #define DLT_ISO_14443 264
673 * Radio data system (RDS) groups. IEC 62106.
674 * Per Jonathan Brucker <jonathan.brucke@gmail.com>.
679 * In case the code that includes this file (directly or indirectly)
680 * has also included OS files that happen to define DLT_MATCHING_MAX,
681 * with a different value (perhaps because that OS hasn't picked up
682 * the latest version of our DLT definitions), we undefine the
683 * previous value of DLT_MATCHING_MAX.
685 #ifdef DLT_MATCHING_MAX
686 #undef DLT_MATCHING_MAX
688 #define DLT_MATCHING_MAX 265 /* highest value in the "matching" range */
690 #endif /* !_NET_DLT_H_ */