Home | History | Annotate | Line # | Download | only in net
dlt.h revision 1.12
      1  1.12  christos /*	$NetBSD: dlt.h,v 1.12 2011/12/21 19:04:18 christos Exp $	*/
      2   1.1   thorpej 
      3   1.1   thorpej /*
      4   1.1   thorpej  * Copyright (c) 1990, 1991, 1993
      5   1.1   thorpej  *	The Regents of the University of California.  All rights reserved.
      6   1.1   thorpej  *
      7   1.1   thorpej  * This code is derived from the Stanford/CMU enet packet filter,
      8   1.1   thorpej  * (net/enet.c) distributed as part of 4.3BSD, and code contributed
      9   1.1   thorpej  * to Berkeley by Steven McCanne and Van Jacobson both of Lawrence
     10   1.1   thorpej  * Berkeley Laboratory.
     11   1.1   thorpej  *
     12   1.1   thorpej  * Redistribution and use in source and binary forms, with or without
     13   1.1   thorpej  * modification, are permitted provided that the following conditions
     14   1.1   thorpej  * are met:
     15   1.1   thorpej  * 1. Redistributions of source code must retain the above copyright
     16   1.1   thorpej  *    notice, this list of conditions and the following disclaimer.
     17   1.1   thorpej  * 2. Redistributions in binary form must reproduce the above copyright
     18   1.1   thorpej  *    notice, this list of conditions and the following disclaimer in the
     19   1.1   thorpej  *    documentation and/or other materials provided with the distribution.
     20   1.6       agc  * 3. Neither the name of the University nor the names of its contributors
     21   1.1   thorpej  *    may be used to endorse or promote products derived from this software
     22   1.1   thorpej  *    without specific prior written permission.
     23   1.1   thorpej  *
     24   1.1   thorpej  * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
     25   1.1   thorpej  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
     26   1.1   thorpej  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
     27   1.1   thorpej  * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
     28   1.1   thorpej  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
     29   1.1   thorpej  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
     30   1.1   thorpej  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
     31   1.1   thorpej  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
     32   1.1   thorpej  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
     33   1.1   thorpej  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
     34   1.1   thorpej  * SUCH DAMAGE.
     35   1.1   thorpej  *
     36   1.1   thorpej  *	@(#)bpf.h	8.2 (Berkeley) 1/9/95
     37   1.1   thorpej  * @(#) Header: bpf.h,v 1.36 97/06/12 14:29:53 leres Exp  (LBL)
     38   1.1   thorpej  */
     39   1.1   thorpej 
     40   1.1   thorpej #ifndef _NET_DLT_H_
     41   1.1   thorpej #define _NET_DLT_H_
     42   1.1   thorpej 
     43   1.1   thorpej /*
     44   1.1   thorpej  * Data-link level type codes.
     45   1.1   thorpej  */
     46   1.1   thorpej #define DLT_NULL	0	/* no link-layer encapsulation */
     47   1.1   thorpej #define DLT_EN10MB	1	/* Ethernet (10Mb) */
     48   1.1   thorpej #define DLT_EN3MB	2	/* Experimental Ethernet (3Mb) */
     49   1.1   thorpej #define DLT_AX25	3	/* Amateur Radio AX.25 */
     50   1.1   thorpej #define DLT_PRONET	4	/* Proteon ProNET Token Ring */
     51   1.1   thorpej #define DLT_CHAOS	5	/* Chaos */
     52   1.1   thorpej #define DLT_IEEE802	6	/* IEEE 802 Networks */
     53   1.1   thorpej #define DLT_ARCNET	7	/* ARCNET */
     54   1.1   thorpej #define DLT_SLIP	8	/* Serial Line IP */
     55   1.1   thorpej #define DLT_PPP		9	/* Point-to-point Protocol */
     56   1.1   thorpej #define DLT_FDDI	10	/* FDDI */
     57   1.1   thorpej #define DLT_ATM_RFC1483	11	/* LLC/SNAP encapsulated atm */
     58   1.1   thorpej #define DLT_RAW		12	/* raw IP */
     59   1.1   thorpej #define DLT_SLIP_BSDOS	13	/* BSD/OS Serial Line IP */
     60   1.1   thorpej #define DLT_PPP_BSDOS	14	/* BSD/OS Point-to-point Protocol */
     61   1.1   thorpej #define DLT_HIPPI	15	/* HIPPI */
     62   1.1   thorpej #define DLT_HDLC	16	/* HDLC framing */
     63   1.1   thorpej 
     64   1.8    itojun #define DLT_PFSYNC	18	/* Packet filter state syncing */
     65   1.9    dyoung #define DLT_ATM_CLIP	19	/* Linux Classical-IP over ATM */
     66   1.9    dyoung #define DLT_ENC		109	/* Encapsulated packets for IPsec */
     67   1.9    dyoung #define DLT_LINUX_SLL	113	/* Linux cooked sockets */
     68   1.9    dyoung #define DLT_LTALK	114	/* Apple LocalTalk hardware */
     69   1.8    itojun #define DLT_PFLOG	117	/* Packet filter logging, by pcap people */
     70   1.9    dyoung #define DLT_CISCO_IOS	118	/* Registered for Cisco-internal use */
     71   1.8    itojun 
     72   1.1   thorpej /* NetBSD-specific types */
     73   1.1   thorpej #define	DLT_PPP_SERIAL	50	/* PPP over serial (async and sync) */
     74   1.5      salo #define	DLT_PPP_ETHER	51	/* XXX - deprecated! PPP over Ethernet; session only, w/o ether header */
     75   1.3     bjh21 
     76   1.9    dyoung /* Axent Raptor / Symantec Enterprise Firewall */
     77   1.9    dyoung #define DLT_SYMANTEC_FIREWALL	99
     78   1.9    dyoung 
     79   1.9    dyoung #define DLT_C_HDLC		104	/* Cisco HDLC */
     80   1.4      onoe #define DLT_IEEE802_11		105	/* IEEE 802.11 wireless */
     81   1.9    dyoung #define DLT_FRELAY		107	/* Frame Relay */
     82   1.9    dyoung #define DLT_LOOP		108	/* OpenBSD DLT_LOOP */
     83   1.4      onoe #define DLT_ECONET		115	/* Acorn Econet */
     84   1.4      onoe #define DLT_PRISM_HEADER	119	/* 802.11 header plus Prism II info. */
     85   1.4      onoe #define DLT_AIRONET_HEADER 	120	/* 802.11 header plus Aironet info. */
     86   1.9    dyoung #define DLT_HHDLC		121	/* Reserved for Siemens HiPath HDLC */
     87   1.9    dyoung #define DLT_IP_OVER_FC		122	/* RFC 2625 IP-over-Fibre Channel */
     88   1.9    dyoung #define DLT_SUNATM		123	/* Solaris+SunATM */
     89   1.9    dyoung #define DLT_RIO                 124     /* RapidIO */
     90   1.9    dyoung #define DLT_PCI_EXP             125     /* PCI Express */
     91   1.9    dyoung #define DLT_AURORA              126     /* Xilinx Aurora link layer */
     92   1.7    dyoung #define DLT_IEEE802_11_RADIO 	127	/* 802.11 header plus radio info. */
     93   1.9    dyoung #define DLT_TZSP                128     /* Tazmen Sniffer Protocol */
     94   1.9    dyoung #define DLT_ARCNET_LINUX	129	/* ARCNET */
     95   1.9    dyoung #define DLT_JUNIPER_MLPPP       130	/* Juniper-private data link types. */
     96   1.9    dyoung #define DLT_JUNIPER_MLFR        131
     97   1.9    dyoung #define DLT_JUNIPER_ES          132
     98   1.9    dyoung #define DLT_JUNIPER_GGSN        133
     99   1.9    dyoung #define DLT_JUNIPER_MFR         134
    100   1.9    dyoung #define DLT_JUNIPER_ATM2        135
    101   1.9    dyoung #define DLT_JUNIPER_SERVICES    136
    102   1.9    dyoung #define DLT_JUNIPER_ATM1        137
    103   1.9    dyoung #define DLT_APPLE_IP_OVER_IEEE1394	138	/* Apple IP-over-IEEE 1394 */
    104   1.9    dyoung 
    105  1.11  drochner /* Various SS7 encapsulations */
    106  1.11  drochner #define DLT_MTP2_WITH_PHDR	139 /* pseudo-header with various info,
    107  1.11  drochner 				       followed by MTP2 */
    108  1.11  drochner #define DLT_MTP2		140 /* MTP2, without pseudo-header */
    109  1.11  drochner #define DLT_MTP3		141 /* MTP3, without pseudo-header or MTP2 */
    110  1.11  drochner #define DLT_SCCP		142 /* SCCP, without pseudo-header or MTP2
    111  1.11  drochner 				       or MTP3 */
    112   1.9    dyoung 
    113   1.9    dyoung #define DLT_DOCSIS		143	/* Reserved for DOCSIS MAC frames. */
    114   1.9    dyoung #define DLT_LINUX_IRDA		144	/* Linux-IrDA packets */
    115   1.9    dyoung 
    116   1.9    dyoung /* Reserved for IBM SP switch and IBM Next Federation switch. */
    117   1.9    dyoung #define DLT_IBM_SP		145
    118   1.9    dyoung #define DLT_IBM_SN		146
    119   1.9    dyoung 
    120   1.9    dyoung #define DLT_IEEE802_11_RADIO_AVS	163	/* 802.11 plus AVS header */
    121   1.9    dyoung #define DLT_JUNIPER_MONITOR     164	/* Juniper-private data link type */
    122  1.11  drochner #define DLT_BACNET_MS_TP	165
    123  1.11  drochner #define DLT_PPP_PPPD		166	/* Another PPP variant (Linux? */
    124  1.11  drochner 
    125  1.11  drochner #define DLT_JUNIPER_PPPOE	167
    126  1.11  drochner #define DLT_JUNIPER_PPPOE_ATM	168
    127  1.11  drochner #define DLT_JUNIPER_PIC_PEER	174
    128  1.11  drochner #define DLT_JUNIPER_ETHER	178
    129  1.11  drochner #define DLT_JUNIPER_PPP		179
    130  1.11  drochner #define DLT_JUNIPER_FRELAY	180
    131  1.11  drochner #define DLT_JUNIPER_CHDLC	181
    132  1.11  drochner 
    133  1.11  drochner #define DLT_GPRS_LLC		169	/* GPRS LLC */
    134  1.11  drochner #define DLT_GPF_T		170	/* GPF-T (ITU-T G.7041/Y.1303) */
    135  1.11  drochner #define DLT_GPF_F		171	/* GPF-F (ITU-T G.7041/Y.1303) */
    136  1.11  drochner 
    137  1.11  drochner #define DLT_GCOM_T1E1		172
    138  1.11  drochner #define DLT_GCOM_SERIAL		173
    139  1.11  drochner 
    140  1.11  drochner /* "EndaceRecordFormat" */
    141  1.11  drochner #define DLT_ERF_ETH		175	/* Ethernet */
    142  1.11  drochner #define DLT_ERF_POS		176	/* Packet-over-SONET */
    143  1.11  drochner 
    144  1.11  drochner #define DLT_LINUX_LAPD		177	/* Raw LAPD for vISDN */
    145   1.1   thorpej 
    146   1.1   thorpej /*
    147  1.12  christos  * Juniper-private data link type, as per request from
    148  1.12  christos  * Hannes Gredler <hannes (at) juniper.net>.
    149  1.12  christos  * The DLT_ are used for prepending meta-information
    150  1.12  christos  * like interface index, interface name
    151  1.12  christos  * before standard Ethernet, PPP, Frelay & C-HDLC Frames
    152  1.12  christos  */
    153  1.12  christos #define DLT_JUNIPER_ETHER       178
    154  1.12  christos #define DLT_JUNIPER_PPP         179
    155  1.12  christos #define DLT_JUNIPER_FRELAY      180
    156  1.12  christos #define DLT_JUNIPER_CHDLC       181
    157  1.12  christos 
    158  1.12  christos /*
    159  1.12  christos  * Multi Link Frame Relay (FRF.16)
    160  1.12  christos  */
    161  1.12  christos #define DLT_MFR                 182
    162  1.12  christos 
    163  1.12  christos /*
    164  1.12  christos  * Juniper-private data link type, as per request from
    165  1.12  christos  * Hannes Gredler <hannes (at) juniper.net>.
    166  1.12  christos  * The DLT_ is used for internal communication with a
    167  1.12  christos  * voice Adapter Card (PIC)
    168  1.12  christos  */
    169  1.12  christos #define DLT_JUNIPER_VP          183
    170  1.12  christos 
    171  1.12  christos /*
    172  1.12  christos  * Arinc 429 frames.
    173  1.12  christos  * DLT_ requested by Gianluca Varenni <gianluca.varenni (at) cacetech.com>.
    174  1.12  christos  * Every frame contains a 32bit A429 label.
    175  1.12  christos  * More documentation on Arinc 429 can be found at
    176  1.12  christos  * http://www.condoreng.com/support/downloads/tutorials/ARINCTutorial.pdf
    177  1.12  christos  */
    178  1.12  christos #define DLT_A429                184
    179  1.12  christos 
    180  1.12  christos /*
    181  1.12  christos  * Arinc 653 Interpartition Communication messages.
    182  1.12  christos  * DLT_ requested by Gianluca Varenni <gianluca.varenni (at) cacetech.com>.
    183  1.12  christos  * Please refer to the A653-1 standard for more information.
    184  1.12  christos  */
    185  1.12  christos #define DLT_A653_ICM            185
    186  1.12  christos 
    187  1.12  christos /*
    188  1.12  christos  * USB packets, beginning with a USB setup header; requested by
    189  1.12  christos  * Paolo Abeni <paolo.abeni (at) email.it>.
    190  1.12  christos  */
    191  1.12  christos #define DLT_USB			186
    192  1.12  christos 
    193  1.12  christos /*
    194  1.12  christos  * Bluetooth HCI UART transport layer (part H:4); requested by
    195  1.12  christos  * Paolo Abeni.
    196  1.12  christos  */
    197  1.12  christos #define DLT_BLUETOOTH_HCI_H4	187
    198  1.12  christos 
    199  1.12  christos /*
    200  1.12  christos  * IEEE 802.16 MAC Common Part Sublayer; requested by Maria Cruz
    201  1.12  christos  * <cruz_petagay (at) bah.com>.
    202  1.12  christos  */
    203  1.12  christos #define DLT_IEEE802_16_MAC_CPS	188
    204  1.12  christos 
    205  1.12  christos /*
    206  1.12  christos  * USB packets, beginning with a Linux USB header; requested by
    207  1.12  christos  * Paolo Abeni <paolo.abeni (at) email.it>.
    208  1.12  christos  */
    209  1.12  christos #define DLT_USB_LINUX		189
    210  1.12  christos 
    211  1.12  christos /*
    212  1.12  christos  * Controller Area Network (CAN) v. 2.0B packets.
    213  1.12  christos  * DLT_ requested by Gianluca Varenni <gianluca.varenni (at) cacetech.com>.
    214  1.12  christos  * Used to dump CAN packets coming from a CAN Vector board.
    215  1.12  christos  * More documentation on the CAN v2.0B frames can be found at
    216  1.12  christos  * http://www.can-cia.org/downloads/?269
    217  1.12  christos  */
    218  1.12  christos #define DLT_CAN20B              190
    219  1.12  christos 
    220  1.12  christos /*
    221  1.12  christos  * IEEE 802.15.4, with address fields padded, as is done by Linux
    222  1.12  christos  * drivers; requested by Juergen Schimmer.
    223  1.12  christos  */
    224  1.12  christos #define DLT_IEEE802_15_4_LINUX	191
    225  1.12  christos 
    226  1.12  christos /*
    227  1.12  christos  * Per Packet Information encapsulated packets.
    228  1.12  christos  * DLT_ requested by Gianluca Varenni <gianluca.varenni (at) cacetech.com>.
    229  1.12  christos  */
    230  1.12  christos #define DLT_PPI			192
    231  1.12  christos 
    232  1.12  christos /*
    233  1.12  christos  * Header for 802.16 MAC Common Part Sublayer plus a radiotap radio header;
    234  1.12  christos  * requested by Charles Clancy.
    235  1.12  christos  */
    236  1.12  christos #define DLT_IEEE802_16_MAC_CPS_RADIO	193
    237  1.12  christos 
    238  1.12  christos /*
    239  1.12  christos  * Juniper-private data link type, as per request from
    240  1.12  christos  * Hannes Gredler <hannes (at) juniper.net>.
    241  1.12  christos  * The DLT_ is used for internal communication with a
    242  1.12  christos  * integrated service module (ISM).
    243  1.12  christos  */
    244  1.12  christos #define DLT_JUNIPER_ISM         194
    245  1.12  christos 
    246  1.12  christos /*
    247  1.12  christos  * IEEE 802.15.4, exactly as it appears in the spec (no padding, no
    248  1.12  christos  * nothing); requested by Mikko Saarnivala <mikko.saarnivala (at) sensinode.com>.
    249  1.12  christos  */
    250  1.12  christos #define DLT_IEEE802_15_4	195
    251  1.12  christos 
    252  1.12  christos /*
    253  1.12  christos  * Various link-layer types, with a pseudo-header, for SITA
    254  1.12  christos  * (http://www.sita.aero/); requested by Fulko Hew (fulko.hew (at) gmail.com).
    255  1.12  christos  */
    256  1.12  christos #define DLT_SITA		196
    257  1.12  christos 
    258  1.12  christos /*
    259  1.12  christos  * Various link-layer types, with a pseudo-header, for Endace DAG cards;
    260  1.12  christos  * encapsulates Endace ERF records.  Requested by Stephen Donnelly
    261  1.12  christos  * <stephen (at) endace.com>.
    262  1.12  christos  */
    263  1.12  christos #define DLT_ERF			197
    264  1.12  christos 
    265  1.12  christos /*
    266  1.12  christos  * Special header prepended to Ethernet packets when capturing from a
    267  1.12  christos  * u10 Networks board.  Requested by Phil Mulholland
    268  1.12  christos  * <phil (at) u10networks.com>.
    269  1.12  christos  */
    270  1.12  christos #define DLT_RAIF1		198
    271  1.12  christos 
    272  1.12  christos /*
    273  1.12  christos  * IPMB packet for IPMI, beginning with the I2C slave address, followed
    274  1.12  christos  * by the netFn and LUN, etc..  Requested by Chanthy Toeung
    275  1.12  christos  * <chanthy.toeung (at) ca.kontron.com>.
    276  1.12  christos  */
    277  1.12  christos #define DLT_IPMB		199
    278  1.12  christos 
    279  1.12  christos /*
    280  1.12  christos  * Juniper-private data link type, as per request from
    281  1.12  christos  * Hannes Gredler <hannes (at) juniper.net>.
    282  1.12  christos  * The DLT_ is used for capturing data on a secure tunnel interface.
    283  1.12  christos  */
    284  1.12  christos #define DLT_JUNIPER_ST          200
    285  1.12  christos 
    286  1.12  christos /*
    287  1.12  christos  * Bluetooth HCI UART transport layer (part H:4), with pseudo-header
    288  1.12  christos  * that includes direction information; requested by Paolo Abeni.
    289  1.12  christos  */
    290  1.12  christos #define DLT_BLUETOOTH_HCI_H4_WITH_PHDR	201
    291  1.12  christos 
    292  1.12  christos /*
    293  1.12  christos  * AX.25 packet with a 1-byte KISS header; see
    294  1.12  christos  *
    295  1.12  christos  *	http://www.ax25.net/kiss.htm
    296  1.12  christos  *
    297  1.12  christos  * as per Richard Stearn <richard (at) rns-stearn.demon.co.uk>.
    298  1.12  christos  */
    299  1.12  christos #define DLT_AX25_KISS		202
    300  1.12  christos 
    301  1.12  christos /*
    302  1.12  christos  * LAPD packets from an ISDN channel, starting with the address field,
    303  1.12  christos  * with no pseudo-header.
    304  1.12  christos  * Requested by Varuna De Silva <varunax (at) gmail.com>.
    305  1.12  christos  */
    306  1.12  christos #define DLT_LAPD		203
    307  1.12  christos 
    308  1.12  christos /*
    309  1.12  christos  * Variants of various link-layer headers, with a one-byte direction
    310  1.12  christos  * pseudo-header prepended - zero means "received by this host",
    311  1.12  christos  * non-zero (any non-zero value) means "sent by this host" - as per
    312  1.12  christos  * Will Barker <w.barker (at) zen.co.uk>.
    313  1.12  christos  */
    314  1.12  christos #define DLT_PPP_WITH_DIR	204	/* PPP - don't confuse with DLT_PPP_WITH_DIRECTION */
    315  1.12  christos #define DLT_C_HDLC_WITH_DIR	205	/* Cisco HDLC */
    316  1.12  christos #define DLT_FRELAY_WITH_DIR	206	/* Frame Relay */
    317  1.12  christos #define DLT_LAPB_WITH_DIR	207	/* LAPB */
    318  1.12  christos 
    319  1.12  christos /*
    320  1.12  christos  * 208 is reserved for an as-yet-unspecified proprietary link-layer
    321  1.12  christos  * type, as requested by Will Barker.
    322  1.12  christos  */
    323  1.12  christos 
    324  1.12  christos /*
    325  1.12  christos  * IPMB with a Linux-specific pseudo-header; as requested by Alexey Neyman
    326  1.12  christos  * <avn (at) pigeonpoint.com>.
    327  1.12  christos  */
    328  1.12  christos #define DLT_IPMB_LINUX		209
    329  1.12  christos 
    330  1.12  christos /*
    331  1.12  christos  * FlexRay automotive bus - http://www.flexray.com/ - as requested
    332  1.12  christos  * by Hannes Kaelber <hannes.kaelber (at) x2e.de>.
    333  1.12  christos  */
    334  1.12  christos #define DLT_FLEXRAY		210
    335  1.12  christos 
    336  1.12  christos /*
    337  1.12  christos  * Media Oriented Systems Transport (MOST) bus for multimedia
    338  1.12  christos  * transport - http://www.mostcooperation.com/ - as requested
    339  1.12  christos  * by Hannes Kaelber <hannes.kaelber (at) x2e.de>.
    340  1.12  christos  */
    341  1.12  christos #define DLT_MOST		211
    342  1.12  christos 
    343  1.12  christos /*
    344  1.12  christos  * Local Interconnect Network (LIN) bus for vehicle networks -
    345  1.12  christos  * http://www.lin-subbus.org/ - as requested by Hannes Kaelber
    346  1.12  christos  * <hannes.kaelber (at) x2e.de>.
    347  1.12  christos  */
    348  1.12  christos #define DLT_LIN			212
    349  1.12  christos 
    350  1.12  christos /*
    351  1.12  christos  * X2E-private data link type used for serial line capture,
    352  1.12  christos  * as requested by Hannes Kaelber <hannes.kaelber (at) x2e.de>.
    353  1.12  christos  */
    354  1.12  christos #define DLT_X2E_SERIAL		213
    355  1.12  christos 
    356  1.12  christos /*
    357  1.12  christos  * X2E-private data link type used for the Xoraya data logger
    358  1.12  christos  * family, as requested by Hannes Kaelber <hannes.kaelber (at) x2e.de>.
    359  1.12  christos  */
    360  1.12  christos #define DLT_X2E_XORAYA		214
    361  1.12  christos 
    362  1.12  christos /*
    363  1.12  christos  * IEEE 802.15.4, exactly as it appears in the spec (no padding, no
    364  1.12  christos  * nothing), but with the PHY-level data for non-ASK PHYs (4 octets
    365  1.12  christos  * of 0 as preamble, one octet of SFD, one octet of frame length+
    366  1.12  christos  * reserved bit, and then the MAC-layer data, starting with the
    367  1.12  christos  * frame control field).
    368  1.12  christos  *
    369  1.12  christos  * Requested by Max Filippov <jcmvbkbc (at) gmail.com>.
    370  1.12  christos  */
    371  1.12  christos #define DLT_IEEE802_15_4_NONASK_PHY	215
    372  1.12  christos 
    373  1.12  christos /*
    374  1.12  christos  * David Gibson <david (at) gibson.dropbear.id.au> requested this for
    375  1.12  christos  * captures from the Linux kernel /dev/input/eventN devices. This
    376  1.12  christos  * is used to communicate keystrokes and mouse movements from the
    377  1.12  christos  * Linux kernel to display systems, such as Xorg.
    378  1.12  christos  */
    379  1.12  christos #define DLT_LINUX_EVDEV		216
    380  1.12  christos 
    381  1.12  christos /*
    382  1.12  christos  * GSM Um and Abis interfaces, preceded by a "gsmtap" header.
    383  1.12  christos  *
    384  1.12  christos  * Requested by Harald Welte <laforge (at) gnumonks.org>.
    385  1.12  christos  */
    386  1.12  christos #define DLT_GSMTAP_UM		217
    387  1.12  christos #define DLT_GSMTAP_ABIS		218
    388  1.12  christos 
    389  1.12  christos /*
    390  1.12  christos  * MPLS, with an MPLS label as the link-layer header.
    391  1.12  christos  * Requested by Michele Marchetto <michele (at) openbsd.org> on behalf
    392  1.12  christos  * of OpenBSD.
    393  1.12  christos  */
    394  1.12  christos #define DLT_MPLS		219
    395  1.12  christos 
    396  1.12  christos /*
    397  1.12  christos  * USB packets, beginning with a Linux USB header, with the USB header
    398  1.12  christos  * padded to 64 bytes; required for memory-mapped access.
    399  1.12  christos  */
    400  1.12  christos #define DLT_USB_LINUX_MMAPPED	220
    401  1.12  christos 
    402  1.12  christos /*
    403  1.12  christos  * DECT packets, with a pseudo-header; requested by
    404  1.12  christos  * Matthias Wenzel <tcpdump (at) mazzoo.de>.
    405  1.12  christos  */
    406  1.12  christos #define DLT_DECT		221
    407  1.12  christos 
    408  1.12  christos /*
    409  1.12  christos  * From: "Lidwa, Eric (GSFC-582.0)[SGT INC]" <eric.lidwa-1 (at) nasa.gov>
    410  1.12  christos  * Date: Mon, 11 May 2009 11:18:30 -0500
    411  1.12  christos  *
    412  1.12  christos  * DLT_AOS. We need it for AOS Space Data Link Protocol.
    413  1.12  christos  *   I have already written dissectors for but need an OK from
    414  1.12  christos  *   legal before I can submit a patch.
    415  1.12  christos  *
    416  1.12  christos  */
    417  1.12  christos #define DLT_AOS                 222
    418  1.12  christos 
    419  1.12  christos /*
    420  1.12  christos  * Wireless HART (Highway Addressable Remote Transducer)
    421  1.12  christos  * From the HART Communication Foundation
    422  1.12  christos  * IES/PAS 62591
    423  1.12  christos  *
    424  1.12  christos  * Requested by Sam Roberts <vieuxtech (at) gmail.com>.
    425  1.12  christos  */
    426  1.12  christos #define DLT_WIHART		223
    427  1.12  christos 
    428  1.12  christos /*
    429  1.12  christos  * Fibre Channel FC-2 frames, beginning with a Frame_Header.
    430  1.12  christos  * Requested by Kahou Lei <kahou82 (at) gmail.com>.
    431  1.12  christos  */
    432  1.12  christos #define DLT_FC_2		224
    433  1.12  christos 
    434  1.12  christos /*
    435  1.12  christos  * Fibre Channel FC-2 frames, beginning with an encoding of the
    436  1.12  christos  * SOF, and ending with an encoding of the EOF.
    437  1.12  christos  *
    438  1.12  christos  * The encodings represent the frame delimiters as 4-byte sequences
    439  1.12  christos  * representing the corresponding ordered sets, with K28.5
    440  1.12  christos  * represented as 0xBC, and the D symbols as the corresponding
    441  1.12  christos  * byte values; for example, SOFi2, which is K28.5 - D21.5 - D1.2 - D21.2,
    442  1.12  christos  * is represented as 0xBC 0xB5 0x55 0x55.
    443  1.12  christos  *
    444  1.12  christos  * Requested by Kahou Lei <kahou82 (at) gmail.com>.
    445  1.12  christos  */
    446  1.12  christos #define DLT_FC_2_WITH_FRAME_DELIMS	225
    447  1.12  christos 
    448  1.12  christos /*
    449  1.12  christos  * Solaris ipnet pseudo-header; requested by Darren Reed <Darren.Reed (at) Sun.COM>.
    450  1.12  christos  *
    451  1.12  christos  * The pseudo-header starts with a one-byte version number; for version 2,
    452  1.12  christos  * the pseudo-header is:
    453  1.12  christos  *
    454  1.12  christos  * struct dl_ipnetinfo {
    455  1.12  christos  *     u_int8_t   dli_version;
    456  1.12  christos  *     u_int8_t   dli_family;
    457  1.12  christos  *     u_int16_t  dli_htype;
    458  1.12  christos  *     u_int32_t  dli_pktlen;
    459  1.12  christos  *     u_int32_t  dli_ifindex;
    460  1.12  christos  *     u_int32_t  dli_grifindex;
    461  1.12  christos  *     u_int32_t  dli_zsrc;
    462  1.12  christos  *     u_int32_t  dli_zdst;
    463  1.12  christos  * };
    464  1.12  christos  *
    465  1.12  christos  * dli_version is 2 for the current version of the pseudo-header.
    466  1.12  christos  *
    467  1.12  christos  * dli_family is a Solaris address family value, so it's 2 for IPv4
    468  1.12  christos  * and 26 for IPv6.
    469  1.12  christos  *
    470  1.12  christos  * dli_htype is a "hook type" - 0 for incoming packets, 1 for outgoing
    471  1.12  christos  * packets, and 2 for packets arriving from another zone on the same
    472  1.12  christos  * machine.
    473  1.12  christos  *
    474  1.12  christos  * dli_pktlen is the length of the packet data following the pseudo-header
    475  1.12  christos  * (so the captured length minus dli_pktlen is the length of the
    476  1.12  christos  * pseudo-header, assuming the entire pseudo-header was captured).
    477  1.12  christos  *
    478  1.12  christos  * dli_ifindex is the interface index of the interface on which the
    479  1.12  christos  * packet arrived.
    480  1.12  christos  *
    481  1.12  christos  * dli_grifindex is the group interface index number (for IPMP interfaces).
    482  1.12  christos  *
    483  1.12  christos  * dli_zsrc is the zone identifier for the source of the packet.
    484  1.12  christos  *
    485  1.12  christos  * dli_zdst is the zone identifier for the destination of the packet.
    486  1.12  christos  *
    487  1.12  christos  * A zone number of 0 is the global zone; a zone number of 0xffffffff
    488  1.12  christos  * means that the packet arrived from another host on the network, not
    489  1.12  christos  * from another zone on the same machine.
    490  1.12  christos  *
    491  1.12  christos  * An IPv4 or IPv6 datagram follows the pseudo-header; dli_family indicates
    492  1.12  christos  * which of those it is.
    493  1.12  christos  */
    494  1.12  christos #define DLT_IPNET			226
    495  1.12  christos 
    496  1.12  christos /*
    497  1.12  christos  * CAN (Controller Area Network) frames, with a pseudo-header as supplied
    498  1.12  christos  * by Linux SocketCAN.  See Documentation/networking/can.txt in the Linux
    499  1.12  christos  * source.
    500  1.12  christos  *
    501  1.12  christos  * Requested by Felix Obenhuber <felix (at) obenhuber.de>.
    502  1.12  christos  */
    503  1.12  christos #define DLT_CAN_SOCKETCAN		227
    504  1.12  christos 
    505  1.12  christos /*
    506  1.12  christos  * Raw IPv4/IPv6; different from DLT_RAW in that the DLT_ value specifies
    507  1.12  christos  * whether it's v4 or v6.  Requested by Darren Reed <Darren.Reed (at) Sun.COM>.
    508  1.12  christos  */
    509  1.12  christos #define DLT_IPV4			228
    510  1.12  christos #define DLT_IPV6			229
    511  1.12  christos 
    512  1.12  christos /*
    513   1.1   thorpej  * NetBSD-specific generic "raw" link type.  The upper 16-bits indicate
    514   1.1   thorpej  * that this is the generic raw type, and the lower 16-bits are the
    515   1.1   thorpej  * address family we're dealing with.
    516   1.1   thorpej  */
    517   1.1   thorpej #define	DLT_RAWAF_MASK		0x02240000
    518   1.1   thorpej #define	DLT_RAWAF(af)		(DLT_RAWAF_MASK | (af))
    519   1.1   thorpej #define	DLT_RAWAF_AF(x)		((x) & 0x0000ffff)
    520   1.1   thorpej #define	DLT_IS_RAWAF(x)		(((x) & 0xffff0000) == DLT_RAWAF_MASK)
    521   1.1   thorpej 
    522  1.10      elad #endif /* !_NET_DLT_H_ */
    523