packet.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2015 INRIA
3  *
4  * This file is subject to the terms and conditions of the GNU Lesser
5  * General Public License v2.1. See the file LICENSE in the top level
6  * directory for more details.
7  */
8 
9 #pragma once
10 
23 #ifdef __cplusplus
24 extern "C" {
25 #endif
26 
30 struct sockaddr_ll {
31  unsigned short sll_family;
32  unsigned short sll_protocol;
34  unsigned short sll_hatype;
35  unsigned char sll_pkttype;
36  unsigned char sll_halen;
37  unsigned char sll_addr[8];
38 };
39 
40 #ifdef __cplusplus
41 }
42 #endif
43 
Link-Layer socket descriptor.
Definition: packet.h:30
unsigned char sll_addr[8]
Physical-layer address.
Definition: packet.h:37
unsigned short sll_family
Always AF_PACKET.
Definition: packet.h:31
unsigned char sll_pkttype
Packet type.
Definition: packet.h:35
unsigned char sll_halen
Length of address.
Definition: packet.h:36
unsigned short sll_hatype
ARP hardware type.
Definition: packet.h:34
int sll_ifindex
Interface number.
Definition: packet.h:33
unsigned short sll_protocol
Physical-layer protocol.
Definition: packet.h:32