File: ethernet.h

package info (click to toggle)
ipgrab 0.5-3
  • links: PTS
  • area: main
  • in suites: slink
  • size: 268 kB
  • ctags: 169
  • sloc: sh: 1,507; ansic: 1,234; makefile: 56
file content (31 lines) | stat: -rw-r--r-- 696 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
/**************************************************************************** 
** File: ethernet.h
**
** Author: Mike Borella
**
** Comments: Generic ethernet structure - an attempt at OS independence
**
*****************************************************************************/

#define ETHERTYPE_IP            0x0800  /* IP protocol */
#define ETHERTYPE_ARP           0x0806  /* Addr. resolution protocol */
#define ETHERTYPE_REVARP        0x8035  /* reverse Addr. resolution protocol */
#define ETHERMTU                1500

/*
 * Ethernet header
 */

typedef struct _EtherHdr
{
  unsigned char  ether_dst[6];
  unsigned char  ether_src[6];
  unsigned short ether_type;
} EtherHdr;