Deleted Added
full compact
ng_pppoe.h (139823) ng_pppoe.h (151800)
1/*
2 * ng_pppoe.h
3 */
4
5/*-
6 * Copyright (c) 1996-1999 Whistle Communications, Inc.
7 * All rights reserved.
8 *

--- 23 unchanged lines hidden (view full) ---

32 * SERVICES, LOSS OF USE, DATA OR PROFITS, HOWEVER CAUSED AND UNDER ANY
33 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
34 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
35 * THIS SOFTWARE, EVEN IF WHISTLE COMMUNICATIONS IS ADVISED OF THE POSSIBILITY
36 * OF SUCH DAMAGE.
37 *
38 * Author: Julian Elischer <julian@freebsd.org>
39 *
1/*
2 * ng_pppoe.h
3 */
4
5/*-
6 * Copyright (c) 1996-1999 Whistle Communications, Inc.
7 * All rights reserved.
8 *

--- 23 unchanged lines hidden (view full) ---

32 * SERVICES, LOSS OF USE, DATA OR PROFITS, HOWEVER CAUSED AND UNDER ANY
33 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
34 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
35 * THIS SOFTWARE, EVEN IF WHISTLE COMMUNICATIONS IS ADVISED OF THE POSSIBILITY
36 * OF SUCH DAMAGE.
37 *
38 * Author: Julian Elischer <julian@freebsd.org>
39 *
40 * $FreeBSD: head/sys/netgraph/ng_pppoe.h 139823 2005-01-07 01:45:51Z imp $
40 * $FreeBSD: head/sys/netgraph/ng_pppoe.h 151800 2005-10-28 14:41:28Z ru $
41 * $Whistle: ng_pppoe.h,v 1.7 1999/10/16 10:16:43 julian Exp $
42 */
43
44#ifndef _NETGRAPH_NG_PPPOE_H_
45#define _NETGRAPH_NG_PPPOE_H_
46
47/********************************************************************
48 * Netgraph hook constants etc.

--- 70 unchanged lines hidden (view full) ---

119 * The AC-NAme field is set from that given and a PADI
120 * packet is expected to arrive from the session control daemon, on the
121 * named hook. The session will then issue the appropriate PADO
122 * and begin negotiation.
123 */
124struct ngpppoe_init_data {
125 char hook[NG_HOOKSIZ]; /* hook to monitor on */
126 u_int16_t data_len; /* Length of the service name */
41 * $Whistle: ng_pppoe.h,v 1.7 1999/10/16 10:16:43 julian Exp $
42 */
43
44#ifndef _NETGRAPH_NG_PPPOE_H_
45#define _NETGRAPH_NG_PPPOE_H_
46
47/********************************************************************
48 * Netgraph hook constants etc.

--- 70 unchanged lines hidden (view full) ---

119 * The AC-NAme field is set from that given and a PADI
120 * packet is expected to arrive from the session control daemon, on the
121 * named hook. The session will then issue the appropriate PADO
122 * and begin negotiation.
123 */
124struct ngpppoe_init_data {
125 char hook[NG_HOOKSIZ]; /* hook to monitor on */
126 u_int16_t data_len; /* Length of the service name */
127 char data[0]; /* init data goes here */
127 char data[]; /* init data goes here */
128};
129
130/* Keep this in sync with the above structure definition */
131#define NG_PPPOE_INIT_DATA_TYPE_INFO { \
132 { "hook", &ng_parse_hookbuf_type }, \
133 { "data", &ng_parse_sizedstring_type }, \
134 { NULL } \
135}

--- 62 unchanged lines hidden (view full) ---

198#define ETHERTYPE_PPPOE_SESS 0x6488 /* pppoe session packets */
199#define ETHERTYPE_PPPOE_STUPID_DISC 0x123c /* pppoe discovery packets 3com? */
200#define ETHERTYPE_PPPOE_STUPID_SESS 0x133c /* pppoe session packets 3com? */
201#endif
202
203struct pppoe_tag {
204 u_int16_t tag_type;
205 u_int16_t tag_len;
128};
129
130/* Keep this in sync with the above structure definition */
131#define NG_PPPOE_INIT_DATA_TYPE_INFO { \
132 { "hook", &ng_parse_hookbuf_type }, \
133 { "data", &ng_parse_sizedstring_type }, \
134 { NULL } \
135}

--- 62 unchanged lines hidden (view full) ---

198#define ETHERTYPE_PPPOE_SESS 0x6488 /* pppoe session packets */
199#define ETHERTYPE_PPPOE_STUPID_DISC 0x123c /* pppoe discovery packets 3com? */
200#define ETHERTYPE_PPPOE_STUPID_SESS 0x133c /* pppoe session packets 3com? */
201#endif
202
203struct pppoe_tag {
204 u_int16_t tag_type;
205 u_int16_t tag_len;
206 char tag_data[0];
206 char tag_data[];
207}__packed;
208
209struct pppoe_hdr{
210 u_int8_t ver:4;
211 u_int8_t type:4;
212 u_int8_t code;
213 u_int16_t sid;
214 u_int16_t length;
207}__packed;
208
209struct pppoe_hdr{
210 u_int8_t ver:4;
211 u_int8_t type:4;
212 u_int8_t code;
213 u_int16_t sid;
214 u_int16_t length;
215 struct pppoe_tag tag[0];
215 struct pppoe_tag tag[];
216}__packed;
217
218
219struct pppoe_full_hdr {
220 struct ether_header eh;
221 struct pppoe_hdr ph;
222}__packed;
223

--- 36 unchanged lines hidden ---
216}__packed;
217
218
219struct pppoe_full_hdr {
220 struct ether_header eh;
221 struct pppoe_hdr ph;
222}__packed;
223

--- 36 unchanged lines hidden ---