FreeBSD kernel netgraph code
ng_pppoe.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  ngpppoestat
 
struct  ngpppoe_init_data
 
struct  ngpppoe_sts
 
struct  ngpppoe_maxp
 
struct  ngpppoe_padm
 
struct  pppoe_tag
 
struct  pppoe_hdr
 
struct  pppoe_full_hdr
 
union  packet
 
struct  datatag
 
struct  maxptag
 

Macros

#define NG_PPPOE_NODE_TYPE   "pppoe"
 
#define NGM_PPPOE_COOKIE   1089893072
 
#define NGM_PPPOE_SETMAXP_COOKIE   1441624322
 
#define NGM_PPPOE_PADM_COOKIE   1488405822
 
#define PPPOE_SERVICE_NAME_SIZE   64 /* for now */
 
#define PPPOE_PADM_VALUE_SIZE   128 /* for now */
 
#define NG_PPPOE_HOOK_ETHERNET   "ethernet"
 
#define NG_PPPOE_HOOK_DEBUG   "debug"
 
#define NG_PPPOE_STANDARD   "standard"
 
#define NG_PPPOE_3COM   "3Com"
 
#define NG_PPPOE_NONSTANDARD   NG_PPPOE_3COM
 
#define NG_PPPOE_DLINK   "D-Link"
 
#define NG_PPPOESTAT_TYPE_INFO
 
#define NG_PPPOE_INIT_DATA_TYPE_INFO
 
#define NG_PPPOE_STS_TYPE_INFO
 
#define PPPOE_TIMEOUT_LIMIT   64
 
#define PPPOE_OFFER_TIMEOUT   16
 
#define PPPOE_INITIAL_TIMEOUT   2
 
#define PADI_CODE   0x09
 
#define PADO_CODE   0x07
 
#define PADR_CODE   0x19
 
#define PADS_CODE   0x65
 
#define PADT_CODE   0xa7
 
#define PADM_CODE   0xd3
 
#define PTT_EOL   (0x0000)
 
#define PTT_SRV_NAME   (0x0101)
 
#define PTT_AC_NAME   (0x0102)
 
#define PTT_HOST_UNIQ   (0x0103)
 
#define PTT_AC_COOKIE   (0x0104)
 
#define PTT_VENDOR   (0x0105)
 
#define PTT_RELAY_SID   (0x0110)
 
#define PTT_HURL   (0x0111) /* PPPoE Extensions (CARREL) */
 
#define PTT_MOTM   (0x0112) /* PPPoE Extensions (CARREL) */
 
#define PTT_MAX_PAYL   (0x0120) /* PPP-Max-Payload (RFC4638) */
 
#define PTT_SRV_ERR   (0x0201)
 
#define PTT_SYS_ERR   (0x0202)
 
#define PTT_GEN_ERR   (0x0203)
 
#define ETHERTYPE_PPPOE_DISC   0x8863 /* pppoe discovery packets */
 
#define ETHERTYPE_PPPOE_SESS   0x8864 /* pppoe session packets */
 
#define ETHERTYPE_PPPOE_3COM_DISC   0x3c12 /* pppoe discovery packets 3com? */
 
#define ETHERTYPE_PPPOE_3COM_SESS   0x3c13 /* pppoe session packets 3com? */
 
#define TAGI_SVC   0
 
#define TAGI_HUNIQ   1
 
#define TAGO_ACNAME   0
 
#define TAGO_SVC   1
 
#define TAGO_COOKIE   2
 
#define TAGO_HUNIQ   3
 
#define TAGR_SVC   0
 
#define TAGR_HUNIQ   1
 
#define TAGR_COOKIE   2
 
#define TAGS_ACNAME   0
 
#define TAGS_SVC   1
 
#define TAGS_COOKIE   2
 
#define TAGS_HUNIQ   3
 

Enumerations

enum  cmd {
  NGM_PPPOE_SET_FLAG = 1 , NGM_PPPOE_CONNECT = 2 , NGM_PPPOE_LISTEN = 3 , NGM_PPPOE_OFFER = 4 ,
  NGM_PPPOE_SUCCESS = 5 , NGM_PPPOE_FAIL = 6 , NGM_PPPOE_CLOSE = 7 , NGM_PPPOE_SERVICE = 8 ,
  NGM_PPPOE_ACNAME = 9 , NGM_PPPOE_GET_STATUS = 10 , NGM_PPPOE_SESSIONID = 11 , NGM_PPPOE_SETMODE = 12 ,
  NGM_PPPOE_GETMODE = 13 , NGM_PPPOE_SETENADDR = 14 , NGM_PPPOE_SETMAXP = 15 , NGM_PPPOE_SEND_HURL = 16 ,
  NGM_PPPOE_HURL = 17 , NGM_PPPOE_SEND_MOTM = 18 , NGM_PPPOE_MOTM = 19
}
 

Variables

struct pppoe_tag __packed
 

Macro Definition Documentation

◆ ETHERTYPE_PPPOE_3COM_DISC

#define ETHERTYPE_PPPOE_3COM_DISC   0x3c12 /* pppoe discovery packets 3com? */

Definition at line 207 of file ng_pppoe.h.

◆ ETHERTYPE_PPPOE_3COM_SESS

#define ETHERTYPE_PPPOE_3COM_SESS   0x3c13 /* pppoe session packets 3com? */

Definition at line 208 of file ng_pppoe.h.

◆ ETHERTYPE_PPPOE_DISC

#define ETHERTYPE_PPPOE_DISC   0x8863 /* pppoe discovery packets */

Definition at line 205 of file ng_pppoe.h.

◆ ETHERTYPE_PPPOE_SESS

#define ETHERTYPE_PPPOE_SESS   0x8864 /* pppoe session packets */

Definition at line 206 of file ng_pppoe.h.

◆ NG_PPPOE_3COM

#define NG_PPPOE_3COM   "3Com"

Definition at line 66 of file ng_pppoe.h.

◆ NG_PPPOE_DLINK

#define NG_PPPOE_DLINK   "D-Link"

Definition at line 68 of file ng_pppoe.h.

◆ NG_PPPOE_HOOK_DEBUG

#define NG_PPPOE_HOOK_DEBUG   "debug"

Definition at line 62 of file ng_pppoe.h.

◆ NG_PPPOE_HOOK_ETHERNET

#define NG_PPPOE_HOOK_ETHERNET   "ethernet"

Definition at line 61 of file ng_pppoe.h.

◆ NG_PPPOE_INIT_DATA_TYPE_INFO

#define NG_PPPOE_INIT_DATA_TYPE_INFO
Value:
{ \
{ "hook", &ng_parse_hookbuf_type }, \
{ "data", &ng_parse_sizedstring_type }, \
{ NULL } \
}
const struct ng_parse_type ng_parse_hookbuf_type
Definition: ng_parse.c:851
const struct ng_parse_type ng_parse_sizedstring_type
Definition: ng_parse.c:938

Definition at line 137 of file ng_pppoe.h.

◆ NG_PPPOE_NODE_TYPE

#define NG_PPPOE_NODE_TYPE   "pppoe"

Definition at line 51 of file ng_pppoe.h.

◆ NG_PPPOE_NONSTANDARD

#define NG_PPPOE_NONSTANDARD   NG_PPPOE_3COM

Definition at line 67 of file ng_pppoe.h.

◆ NG_PPPOE_STANDARD

#define NG_PPPOE_STANDARD   "standard"

Definition at line 65 of file ng_pppoe.h.

◆ NG_PPPOE_STS_TYPE_INFO

#define NG_PPPOE_STS_TYPE_INFO
Value:
{ \
{ "hook", &ng_parse_hookbuf_type }, \
{ NULL } \
}

Definition at line 153 of file ng_pppoe.h.

◆ NG_PPPOESTAT_TYPE_INFO

#define NG_PPPOESTAT_TYPE_INFO
Value:
{ \
{ "packets_in", &ng_parse_uint_type }, \
{ "packets_out", &ng_parse_uint_type }, \
{ NULL } \
}

Definition at line 106 of file ng_pppoe.h.

◆ NGM_PPPOE_COOKIE

#define NGM_PPPOE_COOKIE   1089893072

Definition at line 53 of file ng_pppoe.h.

◆ NGM_PPPOE_PADM_COOKIE

#define NGM_PPPOE_PADM_COOKIE   1488405822

Definition at line 55 of file ng_pppoe.h.

◆ NGM_PPPOE_SETMAXP_COOKIE

#define NGM_PPPOE_SETMAXP_COOKIE   1441624322

Definition at line 54 of file ng_pppoe.h.

◆ PADI_CODE

#define PADI_CODE   0x09

Definition at line 182 of file ng_pppoe.h.

◆ PADM_CODE

#define PADM_CODE   0xd3

Definition at line 187 of file ng_pppoe.h.

◆ PADO_CODE

#define PADO_CODE   0x07

Definition at line 183 of file ng_pppoe.h.

◆ PADR_CODE

#define PADR_CODE   0x19

Definition at line 184 of file ng_pppoe.h.

◆ PADS_CODE

#define PADS_CODE   0x65

Definition at line 185 of file ng_pppoe.h.

◆ PADT_CODE

#define PADT_CODE   0xa7

Definition at line 186 of file ng_pppoe.h.

◆ PPPOE_INITIAL_TIMEOUT

#define PPPOE_INITIAL_TIMEOUT   2

Definition at line 179 of file ng_pppoe.h.

◆ PPPOE_OFFER_TIMEOUT

#define PPPOE_OFFER_TIMEOUT   16

Definition at line 178 of file ng_pppoe.h.

◆ PPPOE_PADM_VALUE_SIZE

#define PPPOE_PADM_VALUE_SIZE   128 /* for now */

Definition at line 58 of file ng_pppoe.h.

◆ PPPOE_SERVICE_NAME_SIZE

#define PPPOE_SERVICE_NAME_SIZE   64 /* for now */

Definition at line 57 of file ng_pppoe.h.

◆ PPPOE_TIMEOUT_LIMIT

#define PPPOE_TIMEOUT_LIMIT   64

Definition at line 177 of file ng_pppoe.h.

◆ PTT_AC_COOKIE

#define PTT_AC_COOKIE   (0x0104)

Definition at line 195 of file ng_pppoe.h.

◆ PTT_AC_NAME

#define PTT_AC_NAME   (0x0102)

Definition at line 193 of file ng_pppoe.h.

◆ PTT_EOL

#define PTT_EOL   (0x0000)

Definition at line 191 of file ng_pppoe.h.

◆ PTT_GEN_ERR

#define PTT_GEN_ERR   (0x0203)

Definition at line 203 of file ng_pppoe.h.

◆ PTT_HOST_UNIQ

#define PTT_HOST_UNIQ   (0x0103)

Definition at line 194 of file ng_pppoe.h.

◆ PTT_HURL

#define PTT_HURL   (0x0111) /* PPPoE Extensions (CARREL) */

Definition at line 198 of file ng_pppoe.h.

◆ PTT_MAX_PAYL

#define PTT_MAX_PAYL   (0x0120) /* PPP-Max-Payload (RFC4638) */

Definition at line 200 of file ng_pppoe.h.

◆ PTT_MOTM

#define PTT_MOTM   (0x0112) /* PPPoE Extensions (CARREL) */

Definition at line 199 of file ng_pppoe.h.

◆ PTT_RELAY_SID

#define PTT_RELAY_SID   (0x0110)

Definition at line 197 of file ng_pppoe.h.

◆ PTT_SRV_ERR

#define PTT_SRV_ERR   (0x0201)

Definition at line 201 of file ng_pppoe.h.

◆ PTT_SRV_NAME

#define PTT_SRV_NAME   (0x0101)

Definition at line 192 of file ng_pppoe.h.

◆ PTT_SYS_ERR

#define PTT_SYS_ERR   (0x0202)

Definition at line 202 of file ng_pppoe.h.

◆ PTT_VENDOR

#define PTT_VENDOR   (0x0105)

Definition at line 196 of file ng_pppoe.h.

◆ TAGI_HUNIQ

#define TAGI_HUNIQ   1

Definition at line 269 of file ng_pppoe.h.

◆ TAGI_SVC

#define TAGI_SVC   0

Definition at line 268 of file ng_pppoe.h.

◆ TAGO_ACNAME

#define TAGO_ACNAME   0

Definition at line 271 of file ng_pppoe.h.

◆ TAGO_COOKIE

#define TAGO_COOKIE   2

Definition at line 273 of file ng_pppoe.h.

◆ TAGO_HUNIQ

#define TAGO_HUNIQ   3

Definition at line 274 of file ng_pppoe.h.

◆ TAGO_SVC

#define TAGO_SVC   1

Definition at line 272 of file ng_pppoe.h.

◆ TAGR_COOKIE

#define TAGR_COOKIE   2

Definition at line 278 of file ng_pppoe.h.

◆ TAGR_HUNIQ

#define TAGR_HUNIQ   1

Definition at line 277 of file ng_pppoe.h.

◆ TAGR_SVC

#define TAGR_SVC   0

Definition at line 276 of file ng_pppoe.h.

◆ TAGS_ACNAME

#define TAGS_ACNAME   0

Definition at line 280 of file ng_pppoe.h.

◆ TAGS_COOKIE

#define TAGS_COOKIE   2

Definition at line 282 of file ng_pppoe.h.

◆ TAGS_HUNIQ

#define TAGS_HUNIQ   3

Definition at line 283 of file ng_pppoe.h.

◆ TAGS_SVC

#define TAGS_SVC   1

Definition at line 281 of file ng_pppoe.h.

Enumeration Type Documentation

◆ cmd

enum cmd
Enumerator
NGM_PPPOE_SET_FLAG 
NGM_PPPOE_CONNECT 
NGM_PPPOE_LISTEN 
NGM_PPPOE_OFFER 
NGM_PPPOE_SUCCESS 
NGM_PPPOE_FAIL 
NGM_PPPOE_CLOSE 
NGM_PPPOE_SERVICE 
NGM_PPPOE_ACNAME 
NGM_PPPOE_GET_STATUS 
NGM_PPPOE_SESSIONID 
NGM_PPPOE_SETMODE 
NGM_PPPOE_GETMODE 
NGM_PPPOE_SETENADDR 
NGM_PPPOE_SETMAXP 
NGM_PPPOE_SEND_HURL 
NGM_PPPOE_HURL 
NGM_PPPOE_SEND_MOTM 
NGM_PPPOE_MOTM 

Definition at line 74 of file ng_pppoe.h.

Variable Documentation

◆ __packed

struct pppoe_full_hdr __packed