5 * Common Development and Distribution License, Version 1.0 only
6 * (the "License"). You may not use this file except in compliance
7 * with the License.
8 *
9 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10 * or http://www.opensolaris.org/os/licensing.
11 * See the License for the specific language governing permissions
12 * and limitations under the License.
13 *
14 * When distributing Covered Code, include this CDDL HEADER in each
15 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16 * If applicable, add the following below this CDDL HEADER, with the
17 * fields enclosed by brackets "[]" replaced with your own identifying
18 * information: Portions Copyright [yyyy] [name of copyright owner]
19 *
20 * CDDL HEADER END
21 */
22 /*
23 * Copyright 1996-2003 Sun Microsystems, Inc. All rights reserved.
24 * Use is subject to license terms.
25 */
26
27 /*
28 * dhcp.h - Generic DHCP definitions, as per RFC's 2131 and 2132.
29 */
30
31 #ifndef _DHCP_H
32 #define _DHCP_H
33
34 #pragma ident "%Z%%M% %I% %E% SMI"
35
36 #ifdef __cplusplus
37 extern "C" {
38 #endif
39
40 #ifdef _REENTRANT
41 #include <thread.h>
42 #endif /* _REENTRANT */
43
44 /*
140 /* Additional server options */
141 #define CD_MOBILE_IP_AGENT 68
142 #define CD_SMTP_SERVS 69
143 #define CD_POP3_SERVS 70
144 #define CD_NNTP_SERVS 71
145 #define CD_WWW_SERVS 72
146 #define CD_FINGER_SERVS 73
147 #define CD_IRC_SERVS 74
148
149 /* Streettalk options */
150 #define CD_STREETTALK_SERVS 75
151 #define CD_STREETTALK_DA_SERVS 76
152
153 /* User class identifier */
154 #define CD_USER_CLASS_ID 77
155
156 /* Newer options */
157
158 #define CD_SLPDA 78
159 #define CD_SLPSS 79
160 #define CD_AGENTOPT 82
161 #define CD_FQDN 89
162 #define CD_PXEARCHi 93
163 #define CD_PXENIIi 94
164 #define CD_PXECID 95
165 #define CD_MULTICST 107
166
167 #define DHCP_FIRST_OPT CD_SUBNETMASK
168 #define DHCP_LAST_STD CD_MULTICST
169 #define DHCP_SITE_OPT 128 /* inclusive */
170 #define DHCP_END_SITE 254
171 #define DHCP_LAST_OPT DHCP_END_SITE /* last op code */
172
173 #define DHCP_MAX_OPT_SIZE 255 /* maximum option size in octets */
174
175 /*
176 * DHCP Packet. What will fit in a ethernet frame. We may use a smaller
177 * size, based on what our transport can handle.
178 */
179 #define DHCP_DEF_MAX_SIZE 576 /* as spec'ed in RFC 2131 */
180 #define PKT_BUFFER 1486 /* max possible size of pkt buffer */
181 #define BASE_PKT_SIZE 240 /* everything but the options */
|
5 * Common Development and Distribution License, Version 1.0 only
6 * (the "License"). You may not use this file except in compliance
7 * with the License.
8 *
9 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10 * or http://www.opensolaris.org/os/licensing.
11 * See the License for the specific language governing permissions
12 * and limitations under the License.
13 *
14 * When distributing Covered Code, include this CDDL HEADER in each
15 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16 * If applicable, add the following below this CDDL HEADER, with the
17 * fields enclosed by brackets "[]" replaced with your own identifying
18 * information: Portions Copyright [yyyy] [name of copyright owner]
19 *
20 * CDDL HEADER END
21 */
22 /*
23 * Copyright 1996-2003 Sun Microsystems, Inc. All rights reserved.
24 * Use is subject to license terms.
25 * Copyright (c) 2016, Chris Fraire <cfraire@me.com>.
26 */
27
28 /*
29 * dhcp.h - Generic DHCP definitions, as per RFC's 2131 and 2132.
30 */
31
32 #ifndef _DHCP_H
33 #define _DHCP_H
34
35 #pragma ident "%Z%%M% %I% %E% SMI"
36
37 #ifdef __cplusplus
38 extern "C" {
39 #endif
40
41 #ifdef _REENTRANT
42 #include <thread.h>
43 #endif /* _REENTRANT */
44
45 /*
141 /* Additional server options */
142 #define CD_MOBILE_IP_AGENT 68
143 #define CD_SMTP_SERVS 69
144 #define CD_POP3_SERVS 70
145 #define CD_NNTP_SERVS 71
146 #define CD_WWW_SERVS 72
147 #define CD_FINGER_SERVS 73
148 #define CD_IRC_SERVS 74
149
150 /* Streettalk options */
151 #define CD_STREETTALK_SERVS 75
152 #define CD_STREETTALK_DA_SERVS 76
153
154 /* User class identifier */
155 #define CD_USER_CLASS_ID 77
156
157 /* Newer options */
158
159 #define CD_SLPDA 78
160 #define CD_SLPSS 79
161 #define CD_CLIENTFQDN 81
162 #define CD_AGENTOPT 82
163
164 /*
165 * Per RFC 3679, option 89 was "Never published as standard and [is] not in
166 * general use". See active CD_CLIENTFQDN and RFC 4702.
167 */
168 #define CD_FQDN 89
169
170 #define CD_PXEARCHi 93
171 #define CD_PXENIIi 94
172 #define CD_PXECID 95
173 #define CD_MULTICST 107
174
175 #define DHCP_FIRST_OPT CD_SUBNETMASK
176 #define DHCP_LAST_STD CD_MULTICST
177 #define DHCP_SITE_OPT 128 /* inclusive */
178 #define DHCP_END_SITE 254
179 #define DHCP_LAST_OPT DHCP_END_SITE /* last op code */
180
181 #define DHCP_MAX_OPT_SIZE 255 /* maximum option size in octets */
182
183 /*
184 * DHCP Packet. What will fit in a ethernet frame. We may use a smaller
185 * size, based on what our transport can handle.
186 */
187 #define DHCP_DEF_MAX_SIZE 576 /* as spec'ed in RFC 2131 */
188 #define PKT_BUFFER 1486 /* max possible size of pkt buffer */
189 #define BASE_PKT_SIZE 240 /* everything but the options */
|