]> git.ipfire.org Git - thirdparty/dhcp.git/blob - common/tables.c
Merge changes between 3.0rc7 and 3.0rc8pl2.
[thirdparty/dhcp.git] / common / tables.c
1 /* tables.c
2
3 Tables of information... */
4
5 /*
6 * Copyright (c) 1995-2001 Internet Software Consortium.
7 * All rights reserved.
8 *
9 * Redistribution and use in source and binary forms, with or without
10 * modification, are permitted provided that the following conditions
11 * are met:
12 *
13 * 1. Redistributions of source code must retain the above copyright
14 * notice, this list of conditions and the following disclaimer.
15 * 2. Redistributions in binary form must reproduce the above copyright
16 * notice, this list of conditions and the following disclaimer in the
17 * documentation and/or other materials provided with the distribution.
18 * 3. Neither the name of The Internet Software Consortium nor the names
19 * of its contributors may be used to endorse or promote products derived
20 * from this software without specific prior written permission.
21 *
22 * THIS SOFTWARE IS PROVIDED BY THE INTERNET SOFTWARE CONSORTIUM AND
23 * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
24 * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
25 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
26 * DISCLAIMED. IN NO EVENT SHALL THE INTERNET SOFTWARE CONSORTIUM OR
27 * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
28 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
29 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
30 * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
31 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
32 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
33 * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
34 * SUCH DAMAGE.
35 *
36 * This software has been written for the Internet Software Consortium
37 * by Ted Lemon in cooperation with Vixie Enterprises and Nominum, Inc.
38 * To learn more about the Internet Software Consortium, see
39 * ``http://www.isc.org/''. To learn more about Vixie Enterprises,
40 * see ``http://www.vix.com''. To learn more about Nominum, Inc., see
41 * ``http://www.nominum.com''.
42 */
43
44 #ifndef lint
45 static char copyright[] =
46 "$Id: tables.c,v 1.52 2001/06/27 00:29:58 mellon Exp $ Copyright (c) 1995-2001 The Internet Software Consortium. All rights reserved.\n";
47 #endif /* not lint */
48
49 #include "dhcpd.h"
50
51 /* XXXDPN: Moved here from hash.c, when it moved to libomapi. Not sure
52 where these really belong. */
53 HASH_FUNCTIONS (group, const char *, struct group_object)
54 HASH_FUNCTIONS (universe, const char *, struct universe)
55 HASH_FUNCTIONS (option, const char *, struct option)
56
57 /* DHCP Option names, formats and codes, from RFC1533.
58
59 Format codes:
60
61 I - IP address
62 l - 32-bit signed integer
63 L - 32-bit unsigned integer
64 s - 16-bit signed integer
65 S - 16-bit unsigned integer
66 b - 8-bit signed integer
67 B - 8-bit unsigned integer
68 t - ASCII text
69 f - flag (true or false)
70 A - array of whatever precedes (e.g., IA means array of IP addresses)
71 a - array of the preceding character (e.g., IIa means two or more IP
72 addresses)
73 U - name of an option space (universe)
74 F - implicit flag - the presence of the option indicates that the
75 flag is true.
76 o - the preceding value is optional.
77 E - encapsulation, string or colon-seperated hex list (the latter
78 two for parsing). E is followed by a text string containing
79 the name of the option space to encapsulate, followed by a '.'.
80 If the E is immediately followed by '.', the applicable vendor
81 option space is used if one is defined.
82 e - If an encapsulation directive is not the first thing in the string,
83 the option scanner requires an efficient way to find the encapsulation.
84 This is done by placing a 'e' at the beginning of the option. The
85 'e' has no other purpose, and is not required if 'E' is the first
86 thing in the option.
87 X - either an ASCII string or binary data. On output, the string is
88 scanned to see if it's printable ASCII and, if so, output as a
89 quoted string. If not, it's output as colon-seperated hex. On
90 input, the option can be specified either as a quoted string or as
91 a colon-seperated hex list.
92 N - enumeration. N is followed by a text string containing
93 the name of the set of enumeration values to parse or emit,
94 followed by a '.'. The width of the data is specified in the
95 named enumeration. Named enumerations are tracked in parse.c.
96 d - Domain name (i.e., FOO or FOO.BAR).
97 */
98
99 struct universe dhcp_universe;
100 struct option dhcp_options [256] = {
101 { "pad", "", &dhcp_universe, 0 },
102 { "subnet-mask", "I", &dhcp_universe, 1 },
103 { "time-offset", "l", &dhcp_universe, 2 },
104 { "routers", "IA", &dhcp_universe, 3 },
105 { "time-servers", "IA", &dhcp_universe, 4 },
106 { "ien116-name-servers", "IA", &dhcp_universe, 5 },
107 { "domain-name-servers", "IA", &dhcp_universe, 6 },
108 { "log-servers", "IA", &dhcp_universe, 7 },
109 { "cookie-servers", "IA", &dhcp_universe, 8 },
110 { "lpr-servers", "IA", &dhcp_universe, 9 },
111 { "impress-servers", "IA", &dhcp_universe, 10 },
112 { "resource-location-servers", "IA", &dhcp_universe, 11 },
113 { "host-name", "X", &dhcp_universe, 12 },
114 { "boot-size", "S", &dhcp_universe, 13 },
115 { "merit-dump", "t", &dhcp_universe, 14 },
116 { "domain-name", "t", &dhcp_universe, 15 },
117 { "swap-server", "I", &dhcp_universe, 16 },
118 { "root-path", "t", &dhcp_universe, 17 },
119 { "extensions-path", "t", &dhcp_universe, 18 },
120 { "ip-forwarding", "f", &dhcp_universe, 19 },
121 { "non-local-source-routing", "f", &dhcp_universe, 20 },
122 { "policy-filter", "IIA", &dhcp_universe, 21 },
123 { "max-dgram-reassembly", "S", &dhcp_universe, 22 },
124 { "default-ip-ttl", "B", &dhcp_universe, 23 },
125 { "path-mtu-aging-timeout", "L", &dhcp_universe, 24 },
126 { "path-mtu-plateau-table", "SA", &dhcp_universe, 25 },
127 { "interface-mtu", "S", &dhcp_universe, 26 },
128 { "all-subnets-local", "f", &dhcp_universe, 27 },
129 { "broadcast-address", "I", &dhcp_universe, 28 },
130 { "perform-mask-discovery", "f", &dhcp_universe, 29 },
131 { "mask-supplier", "f", &dhcp_universe, 30 },
132 { "router-discovery", "f", &dhcp_universe, 31 },
133 { "router-solicitation-address", "I", &dhcp_universe, 32 },
134 { "static-routes", "IIA", &dhcp_universe, 33 },
135 { "trailer-encapsulation", "f", &dhcp_universe, 34 },
136 { "arp-cache-timeout", "L", &dhcp_universe, 35 },
137 { "ieee802-3-encapsulation", "f", &dhcp_universe, 36 },
138 { "default-tcp-ttl", "B", &dhcp_universe, 37 },
139 { "tcp-keepalive-interval", "L", &dhcp_universe, 38 },
140 { "tcp-keepalive-garbage", "f", &dhcp_universe, 39 },
141 { "nis-domain", "t", &dhcp_universe, 40 },
142 { "nis-servers", "IA", &dhcp_universe, 41 },
143 { "ntp-servers", "IA", &dhcp_universe, 42 },
144 { "vendor-encapsulated-options", "E.", &dhcp_universe, 43 },
145 { "netbios-name-servers", "IA", &dhcp_universe, 44 },
146 { "netbios-dd-server", "IA", &dhcp_universe, 45 },
147 { "netbios-node-type", "B", &dhcp_universe, 46 },
148 { "netbios-scope", "t", &dhcp_universe, 47 },
149 { "font-servers", "IA", &dhcp_universe, 48 },
150 { "x-display-manager", "IA", &dhcp_universe, 49 },
151 { "dhcp-requested-address", "I", &dhcp_universe, 50 },
152 { "dhcp-lease-time", "L", &dhcp_universe, 51 },
153 { "dhcp-option-overload", "B", &dhcp_universe, 52 },
154 { "dhcp-message-type", "B", &dhcp_universe, 53 },
155 { "dhcp-server-identifier", "I", &dhcp_universe, 54 },
156 { "dhcp-parameter-request-list", "BA", &dhcp_universe, 55 },
157 { "dhcp-message", "t", &dhcp_universe, 56 },
158 { "dhcp-max-message-size", "S", &dhcp_universe, 57 },
159 { "dhcp-renewal-time", "L", &dhcp_universe, 58 },
160 { "dhcp-rebinding-time", "L", &dhcp_universe, 59 },
161 { "vendor-class-identifier", "X", &dhcp_universe, 60 },
162 { "dhcp-client-identifier", "X", &dhcp_universe, 61 },
163 { "nwip-domain", "X", &dhcp_universe, 62 },
164 { "nwip-suboptions", "Enwip.", &dhcp_universe, 63 },
165 { "nisplus-domain", "t", &dhcp_universe, 64 },
166 { "nisplus-servers", "IA", &dhcp_universe, 65 },
167 { "tftp-server-name", "t", &dhcp_universe, 66 },
168 { "bootfile-name", "t", &dhcp_universe, 67 },
169 { "mobile-ip-home-agent", "IA", &dhcp_universe, 68 },
170 { "smtp-server", "IA", &dhcp_universe, 69 },
171 { "pop-server", "IA", &dhcp_universe, 70 },
172 { "nntp-server", "IA", &dhcp_universe, 71 },
173 { "www-server", "IA", &dhcp_universe, 72 },
174 { "finger-server", "IA", &dhcp_universe, 73 },
175 { "irc-server", "IA", &dhcp_universe, 74 },
176 { "streettalk-server", "IA", &dhcp_universe, 75 },
177 { "streettalk-directory-assistance-server", "IA", &dhcp_universe, 76 },
178 { "user-class", "t", &dhcp_universe, 77 },
179 { "slp-directory-agent", "fIa", &dhcp_universe, 78 },
180 { "slp-service-scope", "fto", &dhcp_universe, 79 },
181 { "#80", "X", &dhcp_universe, 80 },
182 { "fqdn", "Efqdn.", &dhcp_universe, 81 },
183 { "relay-agent-information", "Eagent.", &dhcp_universe, 82 },
184 { "#83", "X", &dhcp_universe, 83 },
185 { "#84", "X", &dhcp_universe, 84 },
186 { "nds-servers", "IA", &dhcp_universe, 85 },
187 { "nds-tree-name", "X", &dhcp_universe, 86 },
188 { "nds-context", "X", &dhcp_universe, 87 },
189 { "#88", "X", &dhcp_universe, 88 },
190 { "#89", "X", &dhcp_universe, 89 },
191 { "#90", "X", &dhcp_universe, 90 },
192 { "#91", "X", &dhcp_universe, 91 },
193 { "#92", "X", &dhcp_universe, 92 },
194 { "#93", "X", &dhcp_universe, 93 },
195 { "#94", "X", &dhcp_universe, 94 },
196 { "#95", "X", &dhcp_universe, 95 },
197 { "#96", "X", &dhcp_universe, 96 },
198 { "#97", "X", &dhcp_universe, 97 },
199 { "uap-servers", "t", &dhcp_universe, 98 },
200 { "#99", "X", &dhcp_universe, 99 },
201 { "#100", "X", &dhcp_universe, 100 },
202 { "#101", "X", &dhcp_universe, 101 },
203 { "#102", "X", &dhcp_universe, 102 },
204 { "#103", "X", &dhcp_universe, 103 },
205 { "#104", "X", &dhcp_universe, 104 },
206 { "#105", "X", &dhcp_universe, 105 },
207 { "#106", "X", &dhcp_universe, 106 },
208 { "#107", "X", &dhcp_universe, 107 },
209 { "#108", "X", &dhcp_universe, 108 },
210 { "#109", "X", &dhcp_universe, 109 },
211 { "#110", "X", &dhcp_universe, 110 },
212 { "#111", "X", &dhcp_universe, 111 },
213 { "#112", "X", &dhcp_universe, 112 },
214 { "#113", "X", &dhcp_universe, 113 },
215 { "#114", "X", &dhcp_universe, 114 },
216 { "#115", "X", &dhcp_universe, 115 },
217 { "#116", "X", &dhcp_universe, 116 },
218 { "#117", "X", &dhcp_universe, 117 },
219 { "subnet-selection", "X", &dhcp_universe, 118 },
220 { "#119", "X", &dhcp_universe, 119 },
221 { "#120", "X", &dhcp_universe, 120 },
222 { "#121", "X", &dhcp_universe, 121 },
223 { "#122", "X", &dhcp_universe, 122 },
224 { "#123", "X", &dhcp_universe, 123 },
225 { "#124", "X", &dhcp_universe, 124 },
226 { "#125", "X", &dhcp_universe, 125 },
227 { "#126", "X", &dhcp_universe, 126 },
228 { "#127", "X", &dhcp_universe, 127 },
229 { "#128", "X", &dhcp_universe, 128 },
230 { "#129", "X", &dhcp_universe, 129 },
231 { "#130", "X", &dhcp_universe, 130 },
232 { "#131", "X", &dhcp_universe, 131 },
233 { "#132", "X", &dhcp_universe, 132 },
234 { "#133", "X", &dhcp_universe, 133 },
235 { "#134", "X", &dhcp_universe, 134 },
236 { "#135", "X", &dhcp_universe, 135 },
237 { "#136", "X", &dhcp_universe, 136 },
238 { "#137", "X", &dhcp_universe, 137 },
239 { "#138", "X", &dhcp_universe, 138 },
240 { "#139", "X", &dhcp_universe, 139 },
241 { "#140", "X", &dhcp_universe, 140 },
242 { "#141", "X", &dhcp_universe, 141 },
243 { "#142", "X", &dhcp_universe, 142 },
244 { "#143", "X", &dhcp_universe, 143 },
245 { "#144", "X", &dhcp_universe, 144 },
246 { "#145", "X", &dhcp_universe, 145 },
247 { "#146", "X", &dhcp_universe, 146 },
248 { "#147", "X", &dhcp_universe, 147 },
249 { "#148", "X", &dhcp_universe, 148 },
250 { "#149", "X", &dhcp_universe, 149 },
251 { "#150", "X", &dhcp_universe, 150 },
252 { "#151", "X", &dhcp_universe, 151 },
253 { "#152", "X", &dhcp_universe, 152 },
254 { "#153", "X", &dhcp_universe, 153 },
255 { "#154", "X", &dhcp_universe, 154 },
256 { "#155", "X", &dhcp_universe, 155 },
257 { "#156", "X", &dhcp_universe, 156 },
258 { "#157", "X", &dhcp_universe, 157 },
259 { "#158", "X", &dhcp_universe, 158 },
260 { "#159", "X", &dhcp_universe, 159 },
261 { "#160", "X", &dhcp_universe, 160 },
262 { "#161", "X", &dhcp_universe, 161 },
263 { "#162", "X", &dhcp_universe, 162 },
264 { "#163", "X", &dhcp_universe, 163 },
265 { "#164", "X", &dhcp_universe, 164 },
266 { "#165", "X", &dhcp_universe, 165 },
267 { "#166", "X", &dhcp_universe, 166 },
268 { "#167", "X", &dhcp_universe, 167 },
269 { "#168", "X", &dhcp_universe, 168 },
270 { "#169", "X", &dhcp_universe, 169 },
271 { "#170", "X", &dhcp_universe, 170 },
272 { "#171", "X", &dhcp_universe, 171 },
273 { "#172", "X", &dhcp_universe, 172 },
274 { "#173", "X", &dhcp_universe, 173 },
275 { "#174", "X", &dhcp_universe, 174 },
276 { "#175", "X", &dhcp_universe, 175 },
277 { "#176", "X", &dhcp_universe, 176 },
278 { "#177", "X", &dhcp_universe, 177 },
279 { "#178", "X", &dhcp_universe, 178 },
280 { "#179", "X", &dhcp_universe, 179 },
281 { "#180", "X", &dhcp_universe, 180 },
282 { "#181", "X", &dhcp_universe, 181 },
283 { "#182", "X", &dhcp_universe, 182 },
284 { "#183", "X", &dhcp_universe, 183 },
285 { "#184", "X", &dhcp_universe, 184 },
286 { "#185", "X", &dhcp_universe, 185 },
287 { "#186", "X", &dhcp_universe, 186 },
288 { "#187", "X", &dhcp_universe, 187 },
289 { "#188", "X", &dhcp_universe, 188 },
290 { "#189", "X", &dhcp_universe, 189 },
291 { "#190", "X", &dhcp_universe, 190 },
292 { "#191", "X", &dhcp_universe, 191 },
293 { "#192", "X", &dhcp_universe, 192 },
294 { "#193", "X", &dhcp_universe, 193 },
295 { "#194", "X", &dhcp_universe, 194 },
296 { "#195", "X", &dhcp_universe, 195 },
297 { "#196", "X", &dhcp_universe, 196 },
298 { "#197", "X", &dhcp_universe, 197 },
299 { "#198", "X", &dhcp_universe, 198 },
300 { "#199", "X", &dhcp_universe, 199 },
301 { "#200", "X", &dhcp_universe, 200 },
302 { "#201", "X", &dhcp_universe, 201 },
303 { "#202", "X", &dhcp_universe, 202 },
304 { "#203", "X", &dhcp_universe, 203 },
305 { "#204", "X", &dhcp_universe, 204 },
306 { "#205", "X", &dhcp_universe, 205 },
307 { "#206", "X", &dhcp_universe, 206 },
308 { "#207", "X", &dhcp_universe, 207 },
309 { "#208", "X", &dhcp_universe, 208 },
310 { "#209", "X", &dhcp_universe, 209 },
311 { "authenticate", "X", &dhcp_universe, 210 },
312 { "#211", "X", &dhcp_universe, 211 },
313 { "#212", "X", &dhcp_universe, 212 },
314 { "#213", "X", &dhcp_universe, 213 },
315 { "#214", "X", &dhcp_universe, 214 },
316 { "#215", "X", &dhcp_universe, 215 },
317 { "#216", "X", &dhcp_universe, 216 },
318 { "#217", "X", &dhcp_universe, 217 },
319 { "#218", "X", &dhcp_universe, 218 },
320 { "#219", "X", &dhcp_universe, 219 },
321 { "#220", "X", &dhcp_universe, 220 },
322 { "#221", "X", &dhcp_universe, 221 },
323 { "#222", "X", &dhcp_universe, 222 },
324 { "#223", "X", &dhcp_universe, 223 },
325 { "#224", "X", &dhcp_universe, 224 },
326 { "#225", "X", &dhcp_universe, 225 },
327 { "#226", "X", &dhcp_universe, 226 },
328 { "#227", "X", &dhcp_universe, 227 },
329 { "#228", "X", &dhcp_universe, 228 },
330 { "#229", "X", &dhcp_universe, 229 },
331 { "#230", "X", &dhcp_universe, 230 },
332 { "#231", "X", &dhcp_universe, 231 },
333 { "#232", "X", &dhcp_universe, 232 },
334 { "#233", "X", &dhcp_universe, 233 },
335 { "#234", "X", &dhcp_universe, 234 },
336 { "#235", "X", &dhcp_universe, 235 },
337 { "#236", "X", &dhcp_universe, 236 },
338 { "#237", "X", &dhcp_universe, 237 },
339 { "#238", "X", &dhcp_universe, 238 },
340 { "#239", "X", &dhcp_universe, 239 },
341 { "#240", "X", &dhcp_universe, 240 },
342 { "#241", "X", &dhcp_universe, 241 },
343 { "#242", "X", &dhcp_universe, 242 },
344 { "#243", "X", &dhcp_universe, 243 },
345 { "#244", "X", &dhcp_universe, 244 },
346 { "#245", "X", &dhcp_universe, 245 },
347 { "#246", "X", &dhcp_universe, 246 },
348 { "#247", "X", &dhcp_universe, 247 },
349 { "#248", "X", &dhcp_universe, 248 },
350 { "#249", "X", &dhcp_universe, 249 },
351 { "#250", "X", &dhcp_universe, 250 },
352 { "#251", "X", &dhcp_universe, 251 },
353 { "#252", "X", &dhcp_universe, 252 },
354 { "#253", "X", &dhcp_universe, 253 },
355 { "#254", "X", &dhcp_universe, 254 },
356 { "option-end", "e", &dhcp_universe, 255 },
357 };
358
359 struct universe nwip_universe;
360 struct option nwip_options [256] = {
361 { "pad", "", &nwip_universe, 0 },
362 { "illegal-1", "", &nwip_universe, 1 },
363 { "illegal-2", "", &nwip_universe, 2 },
364 { "illegal-3", "", &nwip_universe, 3 },
365 { "illegal-4", "", &nwip_universe, 4 },
366 { "nsq-broadcast", "f", &nwip_universe, 5 },
367 { "preferred-dss", "IA", &nwip_universe, 6 },
368 { "nearest-nwip-server", "IA", &nwip_universe, 7 },
369 { "autoretries", "B", &nwip_universe, 8 },
370 { "autoretry-secs", "B", &nwip_universe, 9 },
371 { "nwip-1-1", "f", &nwip_universe, 10 },
372 { "primary-dss", "I", &nwip_universe, 11 },
373 { "#12", "X", &nwip_universe, 12 },
374 { "#13", "X", &nwip_universe, 13 },
375 { "#14", "X", &nwip_universe, 14 },
376 { "#15", "X", &nwip_universe, 15 },
377 { "#16", "X", &nwip_universe, 16 },
378 { "#17", "X", &nwip_universe, 17 },
379 { "#18", "X", &nwip_universe, 18 },
380 { "#19", "X", &nwip_universe, 19 },
381 { "#20", "X", &nwip_universe, 20 },
382 { "#21", "X", &nwip_universe, 21 },
383 { "#22", "X", &nwip_universe, 22 },
384 { "#23", "X", &nwip_universe, 23 },
385 { "#24", "X", &nwip_universe, 24 },
386 { "#25", "X", &nwip_universe, 25 },
387 { "#26", "X", &nwip_universe, 26 },
388 { "#27", "X", &nwip_universe, 27 },
389 { "#28", "X", &nwip_universe, 28 },
390 { "#29", "X", &nwip_universe, 29 },
391 { "#30", "X", &nwip_universe, 30 },
392 { "#31", "X", &nwip_universe, 31 },
393 { "#32", "X", &nwip_universe, 32 },
394 { "#33", "X", &nwip_universe, 33 },
395 { "#34", "X", &nwip_universe, 34 },
396 { "#35", "X", &nwip_universe, 35 },
397 { "#36", "X", &nwip_universe, 36 },
398 { "#37", "X", &nwip_universe, 37 },
399 { "#38", "X", &nwip_universe, 38 },
400 { "#39", "X", &nwip_universe, 39 },
401 { "#40", "X", &nwip_universe, 40 },
402 { "#41", "X", &nwip_universe, 41 },
403 { "#42", "X", &nwip_universe, 42 },
404 { "#43", "X", &nwip_universe, 43 },
405 { "#44", "X", &nwip_universe, 44 },
406 { "#45", "X", &nwip_universe, 45 },
407 { "#46", "X", &nwip_universe, 46 },
408 { "#47", "X", &nwip_universe, 47 },
409 { "#48", "X", &nwip_universe, 48 },
410 { "#49", "X", &nwip_universe, 49 },
411 { "#50", "X", &nwip_universe, 50 },
412 { "#51", "X", &nwip_universe, 51 },
413 { "#52", "X", &nwip_universe, 52 },
414 { "#53", "X", &nwip_universe, 53 },
415 { "#54", "X", &nwip_universe, 54 },
416 { "#55", "X", &nwip_universe, 55 },
417 { "#56", "X", &nwip_universe, 56 },
418 { "#57", "X", &nwip_universe, 57 },
419 { "#58", "X", &nwip_universe, 58 },
420 { "#59", "X", &nwip_universe, 59 },
421 { "#60", "X", &nwip_universe, 60 },
422 { "#61", "X", &nwip_universe, 61 },
423 { "#62", "X", &nwip_universe, 62 },
424 { "#63", "X", &nwip_universe, 63 },
425 { "#64", "X", &nwip_universe, 64 },
426 { "#65", "X", &nwip_universe, 65 },
427 { "#66", "X", &nwip_universe, 66 },
428 { "#67", "X", &nwip_universe, 67 },
429 { "#68", "X", &nwip_universe, 68 },
430 { "#69", "X", &nwip_universe, 69 },
431 { "#70", "X", &nwip_universe, 70 },
432 { "#71", "X", &nwip_universe, 71 },
433 { "#72", "X", &nwip_universe, 72 },
434 { "#73", "X", &nwip_universe, 73 },
435 { "#74", "X", &nwip_universe, 74 },
436 { "#75", "X", &nwip_universe, 75 },
437 { "#76", "X", &nwip_universe, 76 },
438 { "#77", "X", &nwip_universe, 77 },
439 { "#78", "X", &nwip_universe, 78 },
440 { "#79", "X", &nwip_universe, 79 },
441 { "#80", "X", &nwip_universe, 80 },
442 { "#81", "X", &nwip_universe, 81 },
443 { "#82", "X", &nwip_universe, 82 },
444 { "#83", "X", &nwip_universe, 83 },
445 { "#84", "X", &nwip_universe, 84 },
446 { "#85", "X", &nwip_universe, 85 },
447 { "#86", "X", &nwip_universe, 86 },
448 { "#87", "X", &nwip_universe, 87 },
449 { "#88", "X", &nwip_universe, 88 },
450 { "#89", "X", &nwip_universe, 89 },
451 { "#90", "X", &nwip_universe, 90 },
452 { "#91", "X", &nwip_universe, 91 },
453 { "#92", "X", &nwip_universe, 92 },
454 { "#93", "X", &nwip_universe, 93 },
455 { "#94", "X", &nwip_universe, 94 },
456 { "#95", "X", &nwip_universe, 95 },
457 { "#96", "X", &nwip_universe, 96 },
458 { "#97", "X", &nwip_universe, 97 },
459 { "#98", "X", &nwip_universe, 98 },
460 { "#99", "X", &nwip_universe, 99 },
461 { "#100", "X", &nwip_universe, 100 },
462 { "#101", "X", &nwip_universe, 101 },
463 { "#102", "X", &nwip_universe, 102 },
464 { "#103", "X", &nwip_universe, 103 },
465 { "#104", "X", &nwip_universe, 104 },
466 { "#105", "X", &nwip_universe, 105 },
467 { "#106", "X", &nwip_universe, 106 },
468 { "#107", "X", &nwip_universe, 107 },
469 { "#108", "X", &nwip_universe, 108 },
470 { "#109", "X", &nwip_universe, 109 },
471 { "#110", "X", &nwip_universe, 110 },
472 { "#111", "X", &nwip_universe, 111 },
473 { "#112", "X", &nwip_universe, 112 },
474 { "#113", "X", &nwip_universe, 113 },
475 { "#114", "X", &nwip_universe, 114 },
476 { "#115", "X", &nwip_universe, 115 },
477 { "#116", "X", &nwip_universe, 116 },
478 { "#117", "X", &nwip_universe, 117 },
479 { "#118", "X", &nwip_universe, 118 },
480 { "#119", "X", &nwip_universe, 119 },
481 { "#120", "X", &nwip_universe, 120 },
482 { "#121", "X", &nwip_universe, 121 },
483 { "#122", "X", &nwip_universe, 122 },
484 { "#123", "X", &nwip_universe, 123 },
485 { "#124", "X", &nwip_universe, 124 },
486 { "#125", "X", &nwip_universe, 125 },
487 { "#126", "X", &nwip_universe, 126 },
488 { "#127", "X", &nwip_universe, 127 },
489 { "#128", "X", &nwip_universe, 128 },
490 { "#129", "X", &nwip_universe, 129 },
491 { "#130", "X", &nwip_universe, 130 },
492 { "#131", "X", &nwip_universe, 131 },
493 { "#132", "X", &nwip_universe, 132 },
494 { "#133", "X", &nwip_universe, 133 },
495 { "#134", "X", &nwip_universe, 134 },
496 { "#135", "X", &nwip_universe, 135 },
497 { "#136", "X", &nwip_universe, 136 },
498 { "#137", "X", &nwip_universe, 137 },
499 { "#138", "X", &nwip_universe, 138 },
500 { "#139", "X", &nwip_universe, 139 },
501 { "#140", "X", &nwip_universe, 140 },
502 { "#141", "X", &nwip_universe, 141 },
503 { "#142", "X", &nwip_universe, 142 },
504 { "#143", "X", &nwip_universe, 143 },
505 { "#144", "X", &nwip_universe, 144 },
506 { "#145", "X", &nwip_universe, 145 },
507 { "#146", "X", &nwip_universe, 146 },
508 { "#147", "X", &nwip_universe, 147 },
509 { "#148", "X", &nwip_universe, 148 },
510 { "#149", "X", &nwip_universe, 149 },
511 { "#150", "X", &nwip_universe, 150 },
512 { "#151", "X", &nwip_universe, 151 },
513 { "#152", "X", &nwip_universe, 152 },
514 { "#153", "X", &nwip_universe, 153 },
515 { "#154", "X", &nwip_universe, 154 },
516 { "#155", "X", &nwip_universe, 155 },
517 { "#156", "X", &nwip_universe, 156 },
518 { "#157", "X", &nwip_universe, 157 },
519 { "#158", "X", &nwip_universe, 158 },
520 { "#159", "X", &nwip_universe, 159 },
521 { "#160", "X", &nwip_universe, 160 },
522 { "#161", "X", &nwip_universe, 161 },
523 { "#162", "X", &nwip_universe, 162 },
524 { "#163", "X", &nwip_universe, 163 },
525 { "#164", "X", &nwip_universe, 164 },
526 { "#165", "X", &nwip_universe, 165 },
527 { "#166", "X", &nwip_universe, 166 },
528 { "#167", "X", &nwip_universe, 167 },
529 { "#168", "X", &nwip_universe, 168 },
530 { "#169", "X", &nwip_universe, 169 },
531 { "#170", "X", &nwip_universe, 170 },
532 { "#171", "X", &nwip_universe, 171 },
533 { "#172", "X", &nwip_universe, 172 },
534 { "#173", "X", &nwip_universe, 173 },
535 { "#174", "X", &nwip_universe, 174 },
536 { "#175", "X", &nwip_universe, 175 },
537 { "#176", "X", &nwip_universe, 176 },
538 { "#177", "X", &nwip_universe, 177 },
539 { "#178", "X", &nwip_universe, 178 },
540 { "#179", "X", &nwip_universe, 179 },
541 { "#180", "X", &nwip_universe, 180 },
542 { "#181", "X", &nwip_universe, 181 },
543 { "#182", "X", &nwip_universe, 182 },
544 { "#183", "X", &nwip_universe, 183 },
545 { "#184", "X", &nwip_universe, 184 },
546 { "#185", "X", &nwip_universe, 185 },
547 { "#186", "X", &nwip_universe, 186 },
548 { "#187", "X", &nwip_universe, 187 },
549 { "#188", "X", &nwip_universe, 188 },
550 { "#189", "X", &nwip_universe, 189 },
551 { "#190", "X", &nwip_universe, 190 },
552 { "#191", "X", &nwip_universe, 191 },
553 { "#192", "X", &nwip_universe, 192 },
554 { "#193", "X", &nwip_universe, 193 },
555 { "#194", "X", &nwip_universe, 194 },
556 { "#195", "X", &nwip_universe, 195 },
557 { "#196", "X", &nwip_universe, 196 },
558 { "#197", "X", &nwip_universe, 197 },
559 { "#198", "X", &nwip_universe, 198 },
560 { "#199", "X", &nwip_universe, 199 },
561 { "#200", "X", &nwip_universe, 200 },
562 { "#201", "X", &nwip_universe, 201 },
563 { "#202", "X", &nwip_universe, 202 },
564 { "#203", "X", &nwip_universe, 203 },
565 { "#204", "X", &nwip_universe, 204 },
566 { "#205", "X", &nwip_universe, 205 },
567 { "#206", "X", &nwip_universe, 206 },
568 { "#207", "X", &nwip_universe, 207 },
569 { "#208", "X", &nwip_universe, 208 },
570 { "#209", "X", &nwip_universe, 209 },
571 { "#210", "X", &nwip_universe, 210 },
572 { "#211", "X", &nwip_universe, 211 },
573 { "#212", "X", &nwip_universe, 212 },
574 { "#213", "X", &nwip_universe, 213 },
575 { "#214", "X", &nwip_universe, 214 },
576 { "#215", "X", &nwip_universe, 215 },
577 { "#216", "X", &nwip_universe, 216 },
578 { "#217", "X", &nwip_universe, 217 },
579 { "#218", "X", &nwip_universe, 218 },
580 { "#219", "X", &nwip_universe, 219 },
581 { "#220", "X", &nwip_universe, 220 },
582 { "#221", "X", &nwip_universe, 221 },
583 { "#222", "X", &nwip_universe, 222 },
584 { "#223", "X", &nwip_universe, 223 },
585 { "#224", "X", &nwip_universe, 224 },
586 { "#225", "X", &nwip_universe, 225 },
587 { "#226", "X", &nwip_universe, 226 },
588 { "#227", "X", &nwip_universe, 227 },
589 { "#228", "X", &nwip_universe, 228 },
590 { "#229", "X", &nwip_universe, 229 },
591 { "#230", "X", &nwip_universe, 230 },
592 { "#231", "X", &nwip_universe, 231 },
593 { "#232", "X", &nwip_universe, 232 },
594 { "#233", "X", &nwip_universe, 233 },
595 { "#234", "X", &nwip_universe, 234 },
596 { "#235", "X", &nwip_universe, 235 },
597 { "#236", "X", &nwip_universe, 236 },
598 { "#237", "X", &nwip_universe, 237 },
599 { "#238", "X", &nwip_universe, 238 },
600 { "#239", "X", &nwip_universe, 239 },
601 { "#240", "X", &nwip_universe, 240 },
602 { "#241", "X", &nwip_universe, 241 },
603 { "#242", "X", &nwip_universe, 242 },
604 { "#243", "X", &nwip_universe, 243 },
605 { "#244", "X", &nwip_universe, 244 },
606 { "#245", "X", &nwip_universe, 245 },
607 { "#246", "X", &nwip_universe, 246 },
608 { "#247", "X", &nwip_universe, 247 },
609 { "#248", "X", &nwip_universe, 248 },
610 { "#249", "X", &nwip_universe, 249 },
611 { "#250", "X", &nwip_universe, 250 },
612 { "#251", "X", &nwip_universe, 251 },
613 { "#252", "X", &nwip_universe, 252 },
614 { "#253", "X", &nwip_universe, 253 },
615 { "#254", "X", &nwip_universe, 254 },
616 { "#end", "e", &nwip_universe, 255 },
617 };
618
619 struct universe fqdn_universe;
620 struct option fqdn_options [256] = {
621 { "pad", "", &fqdn_universe, 0 },
622 { "no-client-update", "f", &fqdn_universe, 1 },
623 { "server-update", "f", &fqdn_universe, 2 },
624 { "encoded", "f", &fqdn_universe, 3 },
625 { "rcode1", "B", &fqdn_universe, 4 },
626 { "rcode2", "B", &fqdn_universe, 5 },
627 { "hostname", "t", &fqdn_universe, 6 },
628 { "domainname", "t", &fqdn_universe, 7 },
629 { "fqdn", "t", &fqdn_universe, 8 },
630 { "#9", "X", &fqdn_universe, 9 },
631 { "#10", "X", &fqdn_universe, 10 },
632 { "#11", "X", &fqdn_universe, 11 },
633 { "#12", "X", &fqdn_universe, 12 },
634 { "#13", "X", &fqdn_universe, 13 },
635 { "#14", "X", &fqdn_universe, 14 },
636 { "#15", "X", &fqdn_universe, 15 },
637 { "#16", "X", &fqdn_universe, 16 },
638 { "#17", "X", &fqdn_universe, 17 },
639 { "#18", "X", &fqdn_universe, 18 },
640 { "#19", "X", &fqdn_universe, 19 },
641 { "#20", "X", &fqdn_universe, 20 },
642 { "#21", "X", &fqdn_universe, 21 },
643 { "#22", "X", &fqdn_universe, 22 },
644 { "#23", "X", &fqdn_universe, 23 },
645 { "#24", "X", &fqdn_universe, 24 },
646 { "#25", "X", &fqdn_universe, 25 },
647 { "#26", "X", &fqdn_universe, 26 },
648 { "#27", "X", &fqdn_universe, 27 },
649 { "#28", "X", &fqdn_universe, 28 },
650 { "#29", "X", &fqdn_universe, 29 },
651 { "#30", "X", &fqdn_universe, 30 },
652 { "#31", "X", &fqdn_universe, 31 },
653 { "#32", "X", &fqdn_universe, 32 },
654 { "#33", "X", &fqdn_universe, 33 },
655 { "#34", "X", &fqdn_universe, 34 },
656 { "#35", "X", &fqdn_universe, 35 },
657 { "#36", "X", &fqdn_universe, 36 },
658 { "#37", "X", &fqdn_universe, 37 },
659 { "#38", "X", &fqdn_universe, 38 },
660 { "#39", "X", &fqdn_universe, 39 },
661 { "#40", "X", &fqdn_universe, 40 },
662 { "#41", "X", &fqdn_universe, 41 },
663 { "#42", "X", &fqdn_universe, 42 },
664 { "#43", "X", &fqdn_universe, 43 },
665 { "#44", "X", &fqdn_universe, 44 },
666 { "#45", "X", &fqdn_universe, 45 },
667 { "#46", "X", &fqdn_universe, 46 },
668 { "#47", "X", &fqdn_universe, 47 },
669 { "#48", "X", &fqdn_universe, 48 },
670 { "#49", "X", &fqdn_universe, 49 },
671 { "#50", "X", &fqdn_universe, 50 },
672 { "#51", "X", &fqdn_universe, 51 },
673 { "#52", "X", &fqdn_universe, 52 },
674 { "#53", "X", &fqdn_universe, 53 },
675 { "#54", "X", &fqdn_universe, 54 },
676 { "#55", "X", &fqdn_universe, 55 },
677 { "#56", "X", &fqdn_universe, 56 },
678 { "#57", "X", &fqdn_universe, 57 },
679 { "#58", "X", &fqdn_universe, 58 },
680 { "#59", "X", &fqdn_universe, 59 },
681 { "#60", "X", &fqdn_universe, 60 },
682 { "#61", "X", &fqdn_universe, 61 },
683 { "#62", "X", &fqdn_universe, 62 },
684 { "#63", "X", &fqdn_universe, 63 },
685 { "#64", "X", &fqdn_universe, 64 },
686 { "#65", "X", &fqdn_universe, 65 },
687 { "#66", "X", &fqdn_universe, 66 },
688 { "#67", "X", &fqdn_universe, 67 },
689 { "#68", "X", &fqdn_universe, 68 },
690 { "#69", "X", &fqdn_universe, 69 },
691 { "#70", "X", &fqdn_universe, 70 },
692 { "#71", "X", &fqdn_universe, 71 },
693 { "#72", "X", &fqdn_universe, 72 },
694 { "#73", "X", &fqdn_universe, 73 },
695 { "#74", "X", &fqdn_universe, 74 },
696 { "#75", "X", &fqdn_universe, 75 },
697 { "#76", "X", &fqdn_universe, 76 },
698 { "#77", "X", &fqdn_universe, 77 },
699 { "#78", "X", &fqdn_universe, 78 },
700 { "#79", "X", &fqdn_universe, 79 },
701 { "#80", "X", &fqdn_universe, 80 },
702 { "#81", "X", &fqdn_universe, 81 },
703 { "#82", "X", &fqdn_universe, 82 },
704 { "#83", "X", &fqdn_universe, 83 },
705 { "#84", "X", &fqdn_universe, 84 },
706 { "#85", "X", &fqdn_universe, 85 },
707 { "#86", "X", &fqdn_universe, 86 },
708 { "#87", "X", &fqdn_universe, 87 },
709 { "#88", "X", &fqdn_universe, 88 },
710 { "#89", "X", &fqdn_universe, 89 },
711 { "#90", "X", &fqdn_universe, 90 },
712 { "#91", "X", &fqdn_universe, 91 },
713 { "#92", "X", &fqdn_universe, 92 },
714 { "#93", "X", &fqdn_universe, 93 },
715 { "#94", "X", &fqdn_universe, 94 },
716 { "#95", "X", &fqdn_universe, 95 },
717 { "#96", "X", &fqdn_universe, 96 },
718 { "#97", "X", &fqdn_universe, 97 },
719 { "#98", "X", &fqdn_universe, 98 },
720 { "#99", "X", &fqdn_universe, 99 },
721 { "#100", "X", &fqdn_universe, 100 },
722 { "#101", "X", &fqdn_universe, 101 },
723 { "#102", "X", &fqdn_universe, 102 },
724 { "#103", "X", &fqdn_universe, 103 },
725 { "#104", "X", &fqdn_universe, 104 },
726 { "#105", "X", &fqdn_universe, 105 },
727 { "#106", "X", &fqdn_universe, 106 },
728 { "#107", "X", &fqdn_universe, 107 },
729 { "#108", "X", &fqdn_universe, 108 },
730 { "#109", "X", &fqdn_universe, 109 },
731 { "#110", "X", &fqdn_universe, 110 },
732 { "#111", "X", &fqdn_universe, 111 },
733 { "#112", "X", &fqdn_universe, 112 },
734 { "#113", "X", &fqdn_universe, 113 },
735 { "#114", "X", &fqdn_universe, 114 },
736 { "#115", "X", &fqdn_universe, 115 },
737 { "#116", "X", &fqdn_universe, 116 },
738 { "#117", "X", &fqdn_universe, 117 },
739 { "#118", "X", &fqdn_universe, 118 },
740 { "#119", "X", &fqdn_universe, 119 },
741 { "#120", "X", &fqdn_universe, 120 },
742 { "#121", "X", &fqdn_universe, 121 },
743 { "#122", "X", &fqdn_universe, 122 },
744 { "#123", "X", &fqdn_universe, 123 },
745 { "#124", "X", &fqdn_universe, 124 },
746 { "#125", "X", &fqdn_universe, 125 },
747 { "#126", "X", &fqdn_universe, 126 },
748 { "#127", "X", &fqdn_universe, 127 },
749 { "#128", "X", &fqdn_universe, 128 },
750 { "#129", "X", &fqdn_universe, 129 },
751 { "#130", "X", &fqdn_universe, 130 },
752 { "#131", "X", &fqdn_universe, 131 },
753 { "#132", "X", &fqdn_universe, 132 },
754 { "#133", "X", &fqdn_universe, 133 },
755 { "#134", "X", &fqdn_universe, 134 },
756 { "#135", "X", &fqdn_universe, 135 },
757 { "#136", "X", &fqdn_universe, 136 },
758 { "#137", "X", &fqdn_universe, 137 },
759 { "#138", "X", &fqdn_universe, 138 },
760 { "#139", "X", &fqdn_universe, 139 },
761 { "#140", "X", &fqdn_universe, 140 },
762 { "#141", "X", &fqdn_universe, 141 },
763 { "#142", "X", &fqdn_universe, 142 },
764 { "#143", "X", &fqdn_universe, 143 },
765 { "#144", "X", &fqdn_universe, 144 },
766 { "#145", "X", &fqdn_universe, 145 },
767 { "#146", "X", &fqdn_universe, 146 },
768 { "#147", "X", &fqdn_universe, 147 },
769 { "#148", "X", &fqdn_universe, 148 },
770 { "#149", "X", &fqdn_universe, 149 },
771 { "#150", "X", &fqdn_universe, 150 },
772 { "#151", "X", &fqdn_universe, 151 },
773 { "#152", "X", &fqdn_universe, 152 },
774 { "#153", "X", &fqdn_universe, 153 },
775 { "#154", "X", &fqdn_universe, 154 },
776 { "#155", "X", &fqdn_universe, 155 },
777 { "#156", "X", &fqdn_universe, 156 },
778 { "#157", "X", &fqdn_universe, 157 },
779 { "#158", "X", &fqdn_universe, 158 },
780 { "#159", "X", &fqdn_universe, 159 },
781 { "#160", "X", &fqdn_universe, 160 },
782 { "#161", "X", &fqdn_universe, 161 },
783 { "#162", "X", &fqdn_universe, 162 },
784 { "#163", "X", &fqdn_universe, 163 },
785 { "#164", "X", &fqdn_universe, 164 },
786 { "#165", "X", &fqdn_universe, 165 },
787 { "#166", "X", &fqdn_universe, 166 },
788 { "#167", "X", &fqdn_universe, 167 },
789 { "#168", "X", &fqdn_universe, 168 },
790 { "#169", "X", &fqdn_universe, 169 },
791 { "#170", "X", &fqdn_universe, 170 },
792 { "#171", "X", &fqdn_universe, 171 },
793 { "#172", "X", &fqdn_universe, 172 },
794 { "#173", "X", &fqdn_universe, 173 },
795 { "#174", "X", &fqdn_universe, 174 },
796 { "#175", "X", &fqdn_universe, 175 },
797 { "#176", "X", &fqdn_universe, 176 },
798 { "#177", "X", &fqdn_universe, 177 },
799 { "#178", "X", &fqdn_universe, 178 },
800 { "#179", "X", &fqdn_universe, 179 },
801 { "#180", "X", &fqdn_universe, 180 },
802 { "#181", "X", &fqdn_universe, 181 },
803 { "#182", "X", &fqdn_universe, 182 },
804 { "#183", "X", &fqdn_universe, 183 },
805 { "#184", "X", &fqdn_universe, 184 },
806 { "#185", "X", &fqdn_universe, 185 },
807 { "#186", "X", &fqdn_universe, 186 },
808 { "#187", "X", &fqdn_universe, 187 },
809 { "#188", "X", &fqdn_universe, 188 },
810 { "#189", "X", &fqdn_universe, 189 },
811 { "#190", "X", &fqdn_universe, 190 },
812 { "#191", "X", &fqdn_universe, 191 },
813 { "#192", "X", &fqdn_universe, 192 },
814 { "#193", "X", &fqdn_universe, 193 },
815 { "#194", "X", &fqdn_universe, 194 },
816 { "#195", "X", &fqdn_universe, 195 },
817 { "#196", "X", &fqdn_universe, 196 },
818 { "#197", "X", &fqdn_universe, 197 },
819 { "#198", "X", &fqdn_universe, 198 },
820 { "#199", "X", &fqdn_universe, 199 },
821 { "#200", "X", &fqdn_universe, 200 },
822 { "#201", "X", &fqdn_universe, 201 },
823 { "#202", "X", &fqdn_universe, 202 },
824 { "#203", "X", &fqdn_universe, 203 },
825 { "#204", "X", &fqdn_universe, 204 },
826 { "#205", "X", &fqdn_universe, 205 },
827 { "#206", "X", &fqdn_universe, 206 },
828 { "#207", "X", &fqdn_universe, 207 },
829 { "#208", "X", &fqdn_universe, 208 },
830 { "#209", "X", &fqdn_universe, 209 },
831 { "#210", "X", &fqdn_universe, 210 },
832 { "#211", "X", &fqdn_universe, 211 },
833 { "#212", "X", &fqdn_universe, 212 },
834 { "#213", "X", &fqdn_universe, 213 },
835 { "#214", "X", &fqdn_universe, 214 },
836 { "#215", "X", &fqdn_universe, 215 },
837 { "#216", "X", &fqdn_universe, 216 },
838 { "#217", "X", &fqdn_universe, 217 },
839 { "#218", "X", &fqdn_universe, 218 },
840 { "#219", "X", &fqdn_universe, 219 },
841 { "#220", "X", &fqdn_universe, 220 },
842 { "#221", "X", &fqdn_universe, 221 },
843 { "#222", "X", &fqdn_universe, 222 },
844 { "#223", "X", &fqdn_universe, 223 },
845 { "#224", "X", &fqdn_universe, 224 },
846 { "#225", "X", &fqdn_universe, 225 },
847 { "#226", "X", &fqdn_universe, 226 },
848 { "#227", "X", &fqdn_universe, 227 },
849 { "#228", "X", &fqdn_universe, 228 },
850 { "#229", "X", &fqdn_universe, 229 },
851 { "#230", "X", &fqdn_universe, 230 },
852 { "#231", "X", &fqdn_universe, 231 },
853 { "#232", "X", &fqdn_universe, 232 },
854 { "#233", "X", &fqdn_universe, 233 },
855 { "#234", "X", &fqdn_universe, 234 },
856 { "#235", "X", &fqdn_universe, 235 },
857 { "#236", "X", &fqdn_universe, 236 },
858 { "#237", "X", &fqdn_universe, 237 },
859 { "#238", "X", &fqdn_universe, 238 },
860 { "#239", "X", &fqdn_universe, 239 },
861 { "#240", "X", &fqdn_universe, 240 },
862 { "#241", "X", &fqdn_universe, 241 },
863 { "#242", "X", &fqdn_universe, 242 },
864 { "#243", "X", &fqdn_universe, 243 },
865 { "#244", "X", &fqdn_universe, 244 },
866 { "#245", "X", &fqdn_universe, 245 },
867 { "#246", "X", &fqdn_universe, 246 },
868 { "#247", "X", &fqdn_universe, 247 },
869 { "#248", "X", &fqdn_universe, 248 },
870 { "#249", "X", &fqdn_universe, 249 },
871 { "#250", "X", &fqdn_universe, 250 },
872 { "#251", "X", &fqdn_universe, 251 },
873 { "#252", "X", &fqdn_universe, 252 },
874 { "#253", "X", &fqdn_universe, 253 },
875 { "#254", "X", &fqdn_universe, 254 },
876 { "#end", "e", &fqdn_universe, 255 },
877 };
878
879 const char *hardware_types [] = {
880 "unknown-0",
881 "ethernet",
882 "unknown-2",
883 "unknown-3",
884 "unknown-4",
885 "unknown-5",
886 "token-ring",
887 "unknown-7",
888 "fddi",
889 "unknown-9",
890 "unknown-10",
891 "unknown-11",
892 "unknown-12",
893 "unknown-13",
894 "unknown-14",
895 "unknown-15",
896 "unknown-16",
897 "unknown-17",
898 "unknown-18",
899 "unknown-19",
900 "unknown-20",
901 "unknown-21",
902 "unknown-22",
903 "unknown-23",
904 "unknown-24",
905 "unknown-25",
906 "unknown-26",
907 "unknown-27",
908 "unknown-28",
909 "unknown-29",
910 "unknown-30",
911 "unknown-31",
912 "unknown-32",
913 "unknown-33",
914 "unknown-34",
915 "unknown-35",
916 "unknown-36",
917 "unknown-37",
918 "unknown-38",
919 "unknown-39",
920 "unknown-40",
921 "unknown-41",
922 "unknown-42",
923 "unknown-43",
924 "unknown-44",
925 "unknown-45",
926 "unknown-46",
927 "unknown-47",
928 "unknown-48",
929 "unknown-49",
930 "unknown-50",
931 "unknown-51",
932 "unknown-52",
933 "unknown-53",
934 "unknown-54",
935 "unknown-55",
936 "unknown-56",
937 "unknown-57",
938 "unknown-58",
939 "unknown-59",
940 "unknown-60",
941 "unknown-61",
942 "unknown-62",
943 "unknown-63",
944 "unknown-64",
945 "unknown-65",
946 "unknown-66",
947 "unknown-67",
948 "unknown-68",
949 "unknown-69",
950 "unknown-70",
951 "unknown-71",
952 "unknown-72",
953 "unknown-73",
954 "unknown-74",
955 "unknown-75",
956 "unknown-76",
957 "unknown-77",
958 "unknown-78",
959 "unknown-79",
960 "unknown-80",
961 "unknown-81",
962 "unknown-82",
963 "unknown-83",
964 "unknown-84",
965 "unknown-85",
966 "unknown-86",
967 "unknown-87",
968 "unknown-88",
969 "unknown-89",
970 "unknown-90",
971 "unknown-91",
972 "unknown-92",
973 "unknown-93",
974 "unknown-94",
975 "unknown-95",
976 "unknown-96",
977 "unknown-97",
978 "unknown-98",
979 "unknown-99",
980 "unknown-100",
981 "unknown-101",
982 "unknown-102",
983 "unknown-103",
984 "unknown-104",
985 "unknown-105",
986 "unknown-106",
987 "unknown-107",
988 "unknown-108",
989 "unknown-109",
990 "unknown-110",
991 "unknown-111",
992 "unknown-112",
993 "unknown-113",
994 "unknown-114",
995 "unknown-115",
996 "unknown-116",
997 "unknown-117",
998 "unknown-118",
999 "unknown-119",
1000 "unknown-120",
1001 "unknown-121",
1002 "unknown-122",
1003 "unknown-123",
1004 "unknown-124",
1005 "unknown-125",
1006 "unknown-126",
1007 "unknown-127",
1008 "unknown-128",
1009 "unknown-129",
1010 "unknown-130",
1011 "unknown-131",
1012 "unknown-132",
1013 "unknown-133",
1014 "unknown-134",
1015 "unknown-135",
1016 "unknown-136",
1017 "unknown-137",
1018 "unknown-138",
1019 "unknown-139",
1020 "unknown-140",
1021 "unknown-141",
1022 "unknown-142",
1023 "unknown-143",
1024 "unknown-144",
1025 "unknown-145",
1026 "unknown-146",
1027 "unknown-147",
1028 "unknown-148",
1029 "unknown-149",
1030 "unknown-150",
1031 "unknown-151",
1032 "unknown-152",
1033 "unknown-153",
1034 "unknown-154",
1035 "unknown-155",
1036 "unknown-156",
1037 "unknown-157",
1038 "unknown-158",
1039 "unknown-159",
1040 "unknown-160",
1041 "unknown-161",
1042 "unknown-162",
1043 "unknown-163",
1044 "unknown-164",
1045 "unknown-165",
1046 "unknown-166",
1047 "unknown-167",
1048 "unknown-168",
1049 "unknown-169",
1050 "unknown-170",
1051 "unknown-171",
1052 "unknown-172",
1053 "unknown-173",
1054 "unknown-174",
1055 "unknown-175",
1056 "unknown-176",
1057 "unknown-177",
1058 "unknown-178",
1059 "unknown-179",
1060 "unknown-180",
1061 "unknown-181",
1062 "unknown-182",
1063 "unknown-183",
1064 "unknown-184",
1065 "unknown-185",
1066 "unknown-186",
1067 "unknown-187",
1068 "unknown-188",
1069 "unknown-189",
1070 "unknown-190",
1071 "unknown-191",
1072 "unknown-192",
1073 "unknown-193",
1074 "unknown-194",
1075 "unknown-195",
1076 "unknown-196",
1077 "unknown-197",
1078 "unknown-198",
1079 "unknown-199",
1080 "unknown-200",
1081 "unknown-201",
1082 "unknown-202",
1083 "unknown-203",
1084 "unknown-204",
1085 "unknown-205",
1086 "unknown-206",
1087 "unknown-207",
1088 "unknown-208",
1089 "unknown-209",
1090 "unknown-210",
1091 "unknown-211",
1092 "unknown-212",
1093 "unknown-213",
1094 "unknown-214",
1095 "unknown-215",
1096 "unknown-216",
1097 "unknown-217",
1098 "unknown-218",
1099 "unknown-219",
1100 "unknown-220",
1101 "unknown-221",
1102 "unknown-222",
1103 "unknown-223",
1104 "unknown-224",
1105 "unknown-225",
1106 "unknown-226",
1107 "unknown-227",
1108 "unknown-228",
1109 "unknown-229",
1110 "unknown-230",
1111 "unknown-231",
1112 "unknown-232",
1113 "unknown-233",
1114 "unknown-234",
1115 "unknown-235",
1116 "unknown-236",
1117 "unknown-237",
1118 "unknown-238",
1119 "unknown-239",
1120 "unknown-240",
1121 "unknown-241",
1122 "unknown-242",
1123 "unknown-243",
1124 "unknown-244",
1125 "unknown-245",
1126 "unknown-246",
1127 "unknown-247",
1128 "unknown-248",
1129 "unknown-249",
1130 "unknown-250",
1131 "unknown-251",
1132 "unknown-252",
1133 "unknown-253",
1134 "unknown-254",
1135 "unknown-255" };
1136
1137 struct hash_table *universe_hash;
1138 struct universe **universes;
1139 int universe_count, universe_max;
1140
1141 /* Universe containing names of configuration options, which, rather than
1142 writing "option universe-name.option-name ...;", can be set by writing
1143 "option-name ...;". */
1144
1145 struct universe *config_universe;
1146
1147 void initialize_common_option_spaces()
1148 {
1149 int i;
1150
1151 universe_max = 10;
1152 universes = ((struct universe **)
1153 dmalloc (universe_max * sizeof (struct universe *), MDL));
1154 if (!universes)
1155 log_fatal ("Can't allocate option space table.");
1156 memset (universes, 0, universe_max * sizeof (struct universe *));
1157
1158 /* Set up the DHCP option universe... */
1159 dhcp_universe.name = "dhcp";
1160 dhcp_universe.lookup_func = lookup_hashed_option;
1161 dhcp_universe.option_state_dereference =
1162 hashed_option_state_dereference;
1163 dhcp_universe.save_func = save_hashed_option;
1164 dhcp_universe.delete_func = delete_hashed_option;
1165 dhcp_universe.encapsulate = hashed_option_space_encapsulate;
1166 dhcp_universe.foreach = hashed_option_space_foreach;
1167 dhcp_universe.decode = parse_option_buffer;
1168 dhcp_universe.length_size = 1;
1169 dhcp_universe.tag_size = 1;
1170 dhcp_universe.store_tag = putUChar;
1171 dhcp_universe.store_length = putUChar;
1172 dhcp_universe.index = universe_count++;
1173 universes [dhcp_universe.index] = &dhcp_universe;
1174 dhcp_universe.hash = new_hash (0, 0, 1, MDL);
1175 if (!dhcp_universe.hash)
1176 log_fatal ("Can't allocate dhcp option hash table.");
1177 for (i = 0; i < 256; i++) {
1178 dhcp_universe.options [i] = &dhcp_options [i];
1179 option_hash_add (dhcp_universe.hash,
1180 dhcp_options [i].name, 0,
1181 &dhcp_options [i], MDL);
1182 }
1183
1184 /* Set up the Novell option universe (for option 63)... */
1185 nwip_universe.name = "nwip";
1186 nwip_universe.lookup_func = lookup_linked_option;
1187 nwip_universe.option_state_dereference =
1188 linked_option_state_dereference;
1189 nwip_universe.save_func = save_linked_option;
1190 nwip_universe.delete_func = delete_linked_option;
1191 nwip_universe.encapsulate = nwip_option_space_encapsulate;
1192 nwip_universe.foreach = linked_option_space_foreach;
1193 nwip_universe.decode = parse_option_buffer;
1194 nwip_universe.length_size = 1;
1195 nwip_universe.tag_size = 1;
1196 nwip_universe.store_tag = putUChar;
1197 nwip_universe.store_length = putUChar;
1198 fqdn_universe.enc_opt = &dhcp_options [DHO_NWIP_SUBOPTIONS];
1199 nwip_universe.index = universe_count++;
1200 universes [nwip_universe.index] = &nwip_universe;
1201 nwip_universe.hash = new_hash (0, 0, 1, MDL);
1202 if (!nwip_universe.hash)
1203 log_fatal ("Can't allocate nwip option hash table.");
1204 for (i = 0; i < 256; i++) {
1205 nwip_universe.options [i] = &nwip_options [i];
1206 option_hash_add (nwip_universe.hash,
1207 nwip_options [i].name, 0,
1208 &nwip_options [i], MDL);
1209 }
1210
1211 /* Set up the FQDN option universe... */
1212 fqdn_universe.name = "fqdn";
1213 fqdn_universe.lookup_func = lookup_linked_option;
1214 fqdn_universe.option_state_dereference =
1215 linked_option_state_dereference;
1216 fqdn_universe.save_func = save_linked_option;
1217 fqdn_universe.delete_func = delete_linked_option;
1218 fqdn_universe.encapsulate = fqdn_option_space_encapsulate;
1219 fqdn_universe.foreach = linked_option_space_foreach;
1220 fqdn_universe.decode = fqdn_universe_decode;
1221 fqdn_universe.length_size = 1;
1222 fqdn_universe.tag_size = 1;
1223 fqdn_universe.store_tag = putUChar;
1224 fqdn_universe.store_length = putUChar;
1225 fqdn_universe.index = universe_count++;
1226 fqdn_universe.enc_opt = &dhcp_options [DHO_FQDN];
1227 universes [fqdn_universe.index] = &fqdn_universe;
1228 fqdn_universe.hash = new_hash (0, 0, 1, MDL);
1229 if (!fqdn_universe.hash)
1230 log_fatal ("Can't allocate fqdn option hash table.");
1231 for (i = 0; i < 256; i++) {
1232 fqdn_universe.options [i] = &fqdn_options [i];
1233 option_hash_add (fqdn_universe.hash,
1234 fqdn_options [i].name, 0,
1235 &fqdn_options [i], MDL);
1236 }
1237
1238 /* Set up the hash of universes. */
1239 universe_hash = new_hash (0, 0, 1, MDL);
1240 universe_hash_add (universe_hash,
1241 dhcp_universe.name, 0,
1242 &dhcp_universe, MDL);
1243 universe_hash_add (universe_hash,
1244 nwip_universe.name, 0,
1245 &nwip_universe, MDL);
1246 universe_hash_add (universe_hash,
1247 fqdn_universe.name, 0,
1248 &fqdn_universe, MDL);
1249 }