1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
|
diff -ur dhcpcd-1.3.22-pl4.orig/buildmsg.c dhcpcd-1.3.22-pl4/buildmsg.c
--- dhcpcd-1.3.22-pl4.orig/buildmsg.c 2004-11-27 13:59:31.745759928 +0100
+++ dhcpcd-1.3.22-pl4/buildmsg.c 2004-11-27 13:59:07.477449272 +0100
@@ -43,6 +43,10 @@
extern int BroadcastResp;
extern struct in_addr inform_ipaddr;
+#ifdef DRAFT_OPTION_FQDN
+extern int SetFQDNHostName;
+#endif
+
/*****************************************************************************/
void buildDhcpDiscover(xid)
unsigned xid;
@@ -107,7 +111,12 @@
*p++ = nisDomainName;
*p++ = nisServers;
*p++ = ntpServers;
+#ifdef DRAFT_OPTION_FQDN
+ /* FQDN option (81) replaces HostName option (12) if requested */
+ if (( HostName ) && ( SetFQDNHostName == FQDNdisable ))
+#else
if ( HostName )
+#endif
{
*p++ = hostName;
*p++ = HostName_len;
@@ -120,6 +129,25 @@
p += DhcpIface.class_len;
memcpy(p,DhcpIface.client_id,DhcpIface.client_len);
p += DhcpIface.client_len;
+#ifdef DRAFT_OPTION_FQDN
+ if (( HostName ) && ( SetFQDNHostName != FQDNdisable ))
+ {
+ /* Draft IETF DHC-FQDN option (81) */
+ *p++ = dhcpFQDNHostName;
+ *p++ = HostName_len + 3;
+ /* Flags: 0000NEOS
+ * S: 1 => Client requests Server to update A RR in DNS as well as PTR
+ * O: 1 => Server indicates to client that DNS has been updated regardless
+ * E: 1 => Name data is DNS format, i.e. <4>host<6>domain<4>com<0> not "host.domain.com"
+ * N: 1 => Client requests Server to not update DNS
+ */
+ *p++ = SetFQDNHostName & 0x9;
+ *p++ = 0; /* rcode1, response from DNS server to DHCP for PTR RR */
+ *p++ = 0; /* rcode2, response from DNS server to DHCP for A RR if S=1 */
+ memcpy(p,HostName,HostName_len);
+ p += HostName_len;
+ }
+#endif
*p = endOption;
/* build UDP/IP header */
@@ -194,7 +222,12 @@
*p++ = nisDomainName;
*p++ = nisServers;
*p++ = ntpServers;
+#ifdef DRAFT_OPTION_FQDN
+ /* FQDN option (81) replaces HostName option (12) if requested */
+ if (( HostName ) && ( SetFQDNHostName == FQDNdisable ))
+#else
if ( HostName )
+#endif
{
*p++ = hostName;
*p++ = HostName_len;
@@ -207,6 +240,25 @@
p += DhcpIface.class_len;
memcpy(p,DhcpIface.client_id,DhcpIface.client_len);
p += DhcpIface.client_len;
+#ifdef DRAFT_OPTION_FQDN
+ if (( HostName ) && ( SetFQDNHostName != FQDNdisable ))
+ {
+ /* Draft IETF DHC-FQDN option (81) */
+ *p++ = dhcpFQDNHostName;
+ *p++ = HostName_len + 3;
+ /* Flags: 0000NEOS
+ * S: 1 => Client requests Server to update A RR in DNS as well as PTR
+ * O: 1 => Server indicates to client that DNS has been updated regardless
+ * E: 1 => Name data is DNS format, i.e. <4>host<6>domain<4>com<0> not "host.domain.com"
+ * N: 1 => Client requests Server to not update DNS
+ */
+ *p++ = SetFQDNHostName & 0x9;
+ *p++ = 0; /* rcode1, response from DNS server to DHCP for PTR RR */
+ *p++ = 0; /* rcode2, response from DNS server to DHCP for A RR if S=1 */
+ memcpy(p,HostName,HostName_len);
+ p += HostName_len;
+ }
+#endif
*p = endOption;
/* build UDP/IP header */
@@ -269,7 +321,12 @@
*p++ = nisDomainName;
*p++ = nisServers;
*p++ = ntpServers;
+#ifdef DRAFT_OPTION_FQDN
+ /* FQDN option (81) replaces HostName option (12) if requested */
+ if (( HostName ) && ( SetFQDNHostName == FQDNdisable ))
+#else
if ( HostName )
+#endif
{
*p++ = hostName;
*p++ = HostName_len;
@@ -282,6 +339,25 @@
p += DhcpIface.class_len;
memcpy(p,DhcpIface.client_id,DhcpIface.client_len);
p += DhcpIface.client_len;
+#ifdef DRAFT_OPTION_FQDN
+ if (( HostName ) && ( SetFQDNHostName != FQDNdisable ))
+ {
+ /* Draft IETF DHC-FQDN option (81) */
+ *p++ = dhcpFQDNHostName;
+ *p++ = HostName_len + 3;
+ /* Flags: 0000NEOS
+ * S: 1 => Client requests Server to update A RR in DNS as well as PTR
+ * O: 1 => Server indicates to client that DNS has been updated regardless
+ * E: 1 => Name data is DNS format, i.e. <4>host<6>domain<4>com<0> not "host.domain.com"
+ * N: 1 => Client requests Server to not update DNS
+ */
+ *p++ = SetFQDNHostName & 0x9;
+ *p++ = 0; /* rcode1, response from DNS server to DHCP for PTR RR */
+ *p++ = 0; /* rcode2, response from DNS server to DHCP for A RR if S=1 */
+ memcpy(p,HostName,HostName_len);
+ p += HostName_len;
+ }
+#endif
*p = endOption;
udpipgen((udpiphdr *)UdpIpMsgSend.udpipmsg,
@@ -342,7 +418,12 @@
*p++ = nisDomainName;
*p++ = nisServers;
*p++ = ntpServers;
+#ifdef DRAFT_OPTION_FQDN
+ /* FQDN option (81) replaces HostName option (12) if requested */
+ if (( HostName ) && ( SetFQDNHostName == FQDNdisable ))
+#else
if ( HostName )
+#endif
{
*p++ = hostName;
*p++ = HostName_len;
@@ -355,6 +436,25 @@
p += DhcpIface.class_len;
memcpy(p,DhcpIface.client_id,DhcpIface.client_len);
p += DhcpIface.client_len;
+#ifdef DRAFT_OPTION_FQDN
+ if (( HostName ) && ( SetFQDNHostName != FQDNdisable ))
+ {
+ /* Draft IETF DHC-FQDN option (81) */
+ *p++ = dhcpFQDNHostName;
+ *p++ = HostName_len + 3;
+ /* Flags: 0000NEOS
+ * S: 1 => Client requests Server to update A RR in DNS as well as PTR
+ * O: 1 => Server indicates to client that DNS has been updated regardless
+ * E: 1 => Name data is DNS format, i.e. <4>host<6>domain<4>com<0> not "host.domain.com"
+ * N: 1 => Client requests Server to not update DNS
+ */
+ *p++ = SetFQDNHostName & 0x9;
+ *p++ = 0; /* rcode1, response from DNS server to DHCP for PTR RR */
+ *p++ = 0; /* rcode2, response from DNS server to DHCP for A RR if S=1 */
+ memcpy(p,HostName,HostName_len);
+ p += HostName_len;
+ }
+#endif
*p = endOption;
udpipgen((udpiphdr *)UdpIpMsgSend.udpipmsg,
@@ -423,7 +523,12 @@
*p++ = nisDomainName;
*p++ = nisServers;
*p++ = ntpServers;
+#ifdef DRAFT_OPTION_FQDN
+ /* FQDN option (81) replaces HostName option (12) if requested */
+ if (( HostName ) && ( SetFQDNHostName == FQDNdisable ))
+#else
if ( HostName )
+#endif
{
*p++ = hostName;
*p++ = HostName_len;
@@ -436,6 +541,25 @@
p += DhcpIface.class_len;
memcpy(p,DhcpIface.client_id,DhcpIface.client_len);
p += DhcpIface.client_len;
+#ifdef DRAFT_OPTION_FQDN
+ if (( HostName ) && ( SetFQDNHostName != FQDNdisable ))
+ {
+ /* Draft IETF DHC-FQDN option (81) */
+ *p++ = dhcpFQDNHostName;
+ *p++ = HostName_len + 3;
+ /* Flags: 0000NEOS
+ * S: 1 => Client requests Server to update A RR in DNS as well as PTR
+ * O: 1 => Server indicates to client that DNS has been updated regardless
+ * E: 1 => Name data is DNS format, i.e. <4>host<6>domain<4>com<0> not "host.domain.com"
+ * N: 1 => Client requests Server to not update DNS
+ */
+ *p++ = SetFQDNHostName & 0x9;
+ *p++ = 0; /* rcode1, response from DNS server to DHCP for PTR RR */
+ *p++ = 0; /* rcode2, response from DNS server to DHCP for A RR if S=1 */
+ memcpy(p,HostName,HostName_len);
+ p += HostName_len;
+ }
+#endif
*p = endOption;
udpipgen((udpiphdr *)UdpIpMsgSend.udpipmsg,0,INADDR_BROADCAST,
@@ -571,7 +695,12 @@
*p++ = nisDomainName;
*p++ = nisServers;
*p++ = ntpServers;
+#ifdef DRAFT_OPTION_FQDN
+ /* FQDN option (81) replaces HostName option (12) if requested */
+ if (( HostName ) && ( SetFQDNHostName == FQDNdisable ))
+#else
if ( HostName )
+#endif
{
*p++ = hostName;
*p++ = HostName_len;
@@ -584,6 +713,25 @@
p += DhcpIface.class_len;
memcpy(p,DhcpIface.client_id,DhcpIface.client_len);
p += DhcpIface.client_len;
+#ifdef DRAFT_OPTION_FQDN
+ if (( HostName ) && ( SetFQDNHostName != FQDNdisable ))
+ {
+ /* Draft IETF DHC-FQDN option (81) */
+ *p++ = dhcpFQDNHostName;
+ *p++ = HostName_len + 3;
+ /* Flags: 0000NEOS
+ * S: 1 => Client requests Server to update A RR in DNS as well as PTR
+ * O: 1 => Server indicates to client that DNS has been updated regardless
+ * E: 1 => Name data is DNS format, i.e. <4>host<6>domain<4>com<0> not "host.domain.com"
+ * N: 1 => Client requests Server to not update DNS
+ */
+ *p++ = SetFQDNHostName & 0x9;
+ *p++ = 0; /* rcode1, response from DNS server to DHCP for PTR RR */
+ *p++ = 0; /* rcode2, response from DNS server to DHCP for A RR if S=1 */
+ memcpy(p,HostName,HostName_len);
+ p += HostName_len;
+ }
+#endif
*p = endOption;
udpipgen((udpiphdr *)UdpIpMsgSend.udpipmsg,0,INADDR_BROADCAST,
diff -ur dhcpcd-1.3.22-pl4.orig/client.c dhcpcd-1.3.22-pl4/client.c
--- dhcpcd-1.3.22-pl4.orig/client.c 2004-11-27 13:59:31.754758560 +0100
+++ dhcpcd-1.3.22-pl4/client.c 2004-11-27 13:58:24.101043488 +0100
@@ -80,6 +80,10 @@
extern int ClientMACaddr_ind;
#endif
+#ifdef DRAFT_OPTION_FQDN
+extern int SetFQDNHostName;
+#endif
+
#ifdef ARPCHECK
int arpCheck();
#endif
@@ -187,6 +191,16 @@
fprintf(stderr,"i=%-2d len=%-2d option = %u\n",
i,DhcpOptions.len[i],*(unsigned char *)DhcpOptions.val[i]);
break;
+#ifdef DRAFT_OPTION_FQDN
+ case 81:/* dhcpFQDNHostName */
+ fprintf(stderr,"i=%-2d len=%-2d flags = %02X rcode1 = %02X rcode2 = %02X name = \"%s\"\n",
+ i,DhcpOptions.len[i],
+ ((unsigned char *)DhcpOptions.val[i])[0],
+ ((unsigned char *)DhcpOptions.val[i])[1],
+ ((unsigned char *)DhcpOptions.val[i])[2],
+ ((char *)DhcpOptions.val[i])+3);
+ break;
+#endif
default:
fprintf(stderr,"i=%-2d len=%-2d option = \"%s\"\n",
i,DhcpOptions.len[i],(char *)DhcpOptions.val[i]);
@@ -393,6 +407,23 @@
if ( DebugFlag )
syslog(LOG_DEBUG,"dhcpT2value is missing in DHCP server response. Assuming %u sec\n",t2);
}
+#ifdef DRAFT_OPTION_FQDN
+ if ( DhcpOptions.val[dhcpFQDNHostName] )
+ {
+ syslog(LOG_DEBUG,"dhcpFQDNHostName response flags = %02X rcode1 = %02X rcode2 = %02X name = \"%s\"\n",
+ ((unsigned char *)DhcpOptions.val[dhcpFQDNHostName])[0],
+ ((unsigned char *)DhcpOptions.val[dhcpFQDNHostName])[1],
+ ((unsigned char *)DhcpOptions.val[dhcpFQDNHostName])[2],
+ ((char *)DhcpOptions.val[dhcpFQDNHostName])+3);
+ }
+ else
+ {
+ if ( DebugFlag && (SetFQDNHostName != FQDNdisable) )
+ {
+ syslog(LOG_DEBUG,"dhcpFQDNHostName is missing in DHCP server response.\n");
+ }
+ }
+#endif
if ( DhcpOptions.val[dhcpMessageType] )
return *(unsigned char *)DhcpOptions.val[dhcpMessageType];
return 0;
diff -ur dhcpcd-1.3.22-pl4.orig/client.h dhcpcd-1.3.22-pl4/client.h
--- dhcpcd-1.3.22-pl4.orig/client.h 2004-11-27 13:59:31.754758560 +0100
+++ dhcpcd-1.3.22-pl4/client.h 2004-11-27 13:58:24.103043184 +0100
@@ -131,9 +131,25 @@
dhcpT2value = 59,
dhcpClassIdentifier = 60,
dhcpClientIdentifier = 61,
+#ifdef DRAFT_OPTION_FQDN
+ dhcpFQDNHostName = 81,
+#endif
endOption = 255
};
+#ifdef DRAFT_OPTION_FQDN
+/* SetFQDNHostName values - lsnybble used in flags
+ * byte (see buildmsg.c), hsnybble to create order
+ * and to allow 0x00 to mean disable
+ */
+enum {
+ FQDNdisable = 0x00,
+ FQDNnone = 0x18,
+ FQDNptr = 0x20,
+ FQDNboth = 0x31
+};
+#endif
+
typedef struct dhcpInterface
{
unsigned char version[11];
diff -ur dhcpcd-1.3.22-pl4.orig/dhcpcd.8 dhcpcd-1.3.22-pl4/dhcpcd.8
--- dhcpcd-1.3.22-pl4.orig/dhcpcd.8 2004-11-27 13:59:31.753758712 +0100
+++ dhcpcd-1.3.22-pl4/dhcpcd.8 2004-11-27 13:58:24.105042880 +0100
@@ -9,14 +9,15 @@
.in +.5i
.ti -.5i
dhcpcd
-\%[\-dknorzBCDHNRSTY]
+\%[\-dknorzBCDHNRSTY]
\%[\-t\ <timeout>]
\%[\-c\ <ExecFilePath>]
-\%[-h\ <hostname>]
-\%[-i\ <vendorClassID>]
-\%[-I\ <clientID>]
+\%[\-h\ <hostname>]
+\%[\-i\ <vendorClassID>]
+\%[\-I\ <clientID>]
\%[\-l\ <leasetime>]
\%[\-s\ [ipaddr]]
+\%[\-F\ none|ptr|both]
\%[\-G\ [gateway]]
\%[\-w\ <windowsize>]
\%[\-L\ <ConfigDir>]
@@ -28,7 +29,10 @@
.B RFC2131
(when -r option is not specified) and
.B RFC1541
-(when -r option is specified).
+(when -r option is specified). Support for
+.B draft-ietf-dhc-fqdn-option
+in use in many systems (particularly networks using Microsoft DHCP
+servers) is also provided.
It gets the host information (IP address, netmask, broadcast address,
etc.) from a DHCP server and configures the network interface of the
@@ -145,6 +149,31 @@
to set domainname of the host to the domainname option
supplied by DHCP server.
.TP
+.BI \-F \ none|ptr|both
+Forces
+.B dhcpcd
+to request the DHCP server update the DNS using the FQDN option
+instead of the Hostname option. The name used by this option
+is specified with the \fB-h\fP switch, which must be present. If
+the \fB-h\fP switch is not present, the FQDN option is ignored.
+The name should be fully qualified, although servers usually
+accept a simple name.
+.I both
+requests that the DHCP server update both the A and PTR
+records in the DNS.
+.I ptr
+requests that the DHCP server updates only the PTR record in
+the DNS.
+.I none
+requests that the DHCP server perform no updates.
+.B dhcpcd
+does not perform any DNS update, even when the server is
+requested to perform no updates. This can be easily
+implemented outside the client; all the necessary
+information is recorded in the
+.I <ConfigDir>/dhcpcd-<interface>.info
+file.
+.TP
.BI \-H
Forces
.B dhcpcd
@@ -249,6 +278,8 @@
sends DHCP messages. Some DHCP servers, notably those used by
@Home Networks, require the hostname option
field containing a specific string in the DHCP messages from clients.
+When combined with the -F switch, specifies the string used for the
+FQDN option field instead of the hostname option field.
.TP
.BI \-i \ <vendorClassID>
Specifies the vendor class identifier string.
@@ -413,10 +444,18 @@
is attached.
.SH SEE ALSO
+.BR dig (1),
+.BR nslookup (8),
+.BR nsupdate (8)
+.LP
.I Dynamic Host Configuration Protocol,
RFC2131 and RFC1541 (obsolete)
+.LP
.I DHCP Options and BOOTP Vendor Extensions,
RFC2132
+.LP
+.I Draft DHC FQDN Option specification,
+draft-ietf-dhc-fqdn-option
.SH BUGS
.PD 0
diff -ur dhcpcd-1.3.22-pl4.orig/dhcpcd.c dhcpcd-1.3.22-pl4/dhcpcd.c
--- dhcpcd-1.3.22-pl4.orig/dhcpcd.c 2004-11-27 13:59:31.753758712 +0100
+++ dhcpcd-1.3.22-pl4/dhcpcd.c 2004-11-27 13:58:24.107042576 +0100
@@ -75,6 +75,9 @@
unsigned char ClientMACaddr[ETH_ALEN];
int ClientMACaddr_ind = 0;
#endif
+#ifdef DRAFT_OPTION_FQDN
+int SetFQDNHostName = FQDNdisable;
+#endif
/*****************************************************************************/
void print_version()
{
@@ -109,6 +112,9 @@
int k = 1;
int i = 1;
int j;
+#ifdef DRAFT_OPTION_FQDN
+ char *FQDNOption = NULL;
+#endif
/*
* Ensure that fds 0, 1, 2 are open, to /dev/null if nowhere else.
@@ -262,6 +268,23 @@
fprintf(stderr,"**** %s: too long HostName string: strlen=%d\n",
argc[0],HostName_len);
break;
+#ifdef DRAFT_OPTION_FQDN
+ case 'F':
+ if ( argc[i][s+1] ) goto usage;
+ i++;
+ FQDNOption=argc[i++];
+ if ( FQDNOption == NULL || FQDNOption[0] == '-' ) goto usage;
+ if ( strcmp(FQDNOption,"none") == 0 )
+ SetFQDNHostName=FQDNnone;
+ else if ( strcmp(FQDNOption,"ptr") == 0 )
+ SetFQDNHostName=FQDNptr;
+ else if ( strcmp(FQDNOption,"both") == 0 )
+ SetFQDNHostName=FQDNboth;
+ else
+ goto usage;
+ s=1;
+ break;
+#endif
case 't':
if ( argc[i][s+1] ) goto usage;
i++;
@@ -373,11 +373,19 @@
break;
default:
usage: print_version();
+#ifndef DRAFT_OPTION_FQDN
fprintf(stderr,
"Usage: dhcpcd [-dknorzBCDHNRSTY] [-l leasetime] [-h hostname] [-t timeout]\n\
[-i vendorClassID] [-I ClientID] [-c filename] [-s [ipaddr]]\n\
[-w windowsize] [-L ConfigDir] [-G [gateway]] [-m routemetric]\n\
[interface]\n");
+#else
+ fprintf(stderr,
+"Usage: dhcpcd [-dknorzBCDHNRSTY] [-l leasetime] [-h hostname] [-t timeout]\n\
+ [-i vendorClassID] [-I ClientID] [-c filename] [-s [ipaddr]]\n\
+ [-w windowsize] [-L ConfigDir] [-G [gateway]] [-m routemetric]\n\
+ [-F none|ptr|both] [interface]\n");
+#endif
exit(1);
}
else
diff -ur dhcpcd-1.3.22-pl4.orig/dhcpconfig.c dhcpcd-1.3.22-pl4/dhcpconfig.c
--- dhcpcd-1.3.22-pl4.orig/dhcpconfig.c 2004-11-27 13:59:31.752758864 +0100
+++ dhcpcd-1.3.22-pl4/dhcpconfig.c 2004-11-27 13:58:24.261019168 +0100
@@ -61,6 +61,10 @@
extern dhcpOptions DhcpOptions;
extern const dhcpMessage *DhcpMsgRecv;
+#ifdef DRAFT_OPTION_FQDN
+extern int SetFQDNHostName;
+#endif
+
int arpInform();
char hostinfo_file[128];
@@ -735,6 +739,22 @@
fprintf(f,"CLIENTID=%02X:%02X:%02X:%02X:%02X:%02X\n",
DhcpIface.client_id[3],DhcpIface.client_id[4],DhcpIface.client_id[5],
DhcpIface.client_id[6],DhcpIface.client_id[7],DhcpIface.client_id[8]);
+#ifdef DRAFT_OPTION_FQDN
+ if ( SetFQDNHostName != FQDNdisable )
+ {
+ if ( DhcpOptions.len[dhcpFQDNHostName] )
+ {
+fprintf(f,"FQDNFLAGS=%u\n\
+FQDNRCODE1=%u\n\
+FQDNRCODE2=%u\n\
+FQDNHOSTNAME=%s\n",
+((unsigned char *)DhcpOptions.val[dhcpFQDNHostName])[0],
+((unsigned char *)DhcpOptions.val[dhcpFQDNHostName])[1],
+((unsigned char *)DhcpOptions.val[dhcpFQDNHostName])[2],
+(((char *)DhcpOptions.val[dhcpFQDNHostName])+3));
+ }
+ }
+#endif
fclose(f);
}
else
|