Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 15 Jul 2005 01:30:24 GMT
From:      Sam Leffler <sam@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 80223 for review
Message-ID:  <200507150130.j6F1UOFR048894@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=80223

Change 80223 by sam@sam_ebb on 2005/07/15 01:29:47

	IFC

Affected files ...

.. //depot/projects/wifi/sbin/dhclient/alloc.c#2 integrate
.. //depot/projects/wifi/sbin/dhclient/bpf.c#3 integrate
.. //depot/projects/wifi/sbin/dhclient/clparse.c#2 integrate
.. //depot/projects/wifi/sbin/dhclient/conflex.c#2 integrate
.. //depot/projects/wifi/sbin/dhclient/convert.c#2 integrate
.. //depot/projects/wifi/sbin/dhclient/dhclient-script#6 integrate
.. //depot/projects/wifi/sbin/dhclient/dhclient-script.8#2 integrate
.. //depot/projects/wifi/sbin/dhclient/dhclient.8#2 integrate
.. //depot/projects/wifi/sbin/dhclient/dhclient.c#7 integrate
.. //depot/projects/wifi/sbin/dhclient/dhclient.conf#2 integrate
.. //depot/projects/wifi/sbin/dhclient/dhclient.conf.5#2 integrate
.. //depot/projects/wifi/sbin/dhclient/dhclient.leases.5#2 integrate
.. //depot/projects/wifi/sbin/dhclient/dhcp-options.5#2 integrate
.. //depot/projects/wifi/sbin/dhclient/dhcp.h#2 integrate
.. //depot/projects/wifi/sbin/dhclient/dhcpd.h#2 integrate
.. //depot/projects/wifi/sbin/dhclient/dhctoken.h#2 integrate
.. //depot/projects/wifi/sbin/dhclient/dispatch.c#2 integrate
.. //depot/projects/wifi/sbin/dhclient/errwarn.c#2 integrate
.. //depot/projects/wifi/sbin/dhclient/hash.c#2 integrate
.. //depot/projects/wifi/sbin/dhclient/inet.c#2 integrate
.. //depot/projects/wifi/sbin/dhclient/options.c#2 integrate
.. //depot/projects/wifi/sbin/dhclient/packet.c#2 integrate
.. //depot/projects/wifi/sbin/dhclient/parse.c#3 integrate
.. //depot/projects/wifi/sbin/dhclient/privsep.c#2 integrate
.. //depot/projects/wifi/sbin/dhclient/privsep.h#2 integrate
.. //depot/projects/wifi/sbin/dhclient/tables.c#2 integrate
.. //depot/projects/wifi/sbin/dhclient/tree.c#2 integrate
.. //depot/projects/wifi/sbin/dhclient/tree.h#2 integrate

Differences ...

==== //depot/projects/wifi/sbin/dhclient/alloc.c#2 (text+ko) ====


==== //depot/projects/wifi/sbin/dhclient/bpf.c#3 (text+ko) ====


==== //depot/projects/wifi/sbin/dhclient/clparse.c#2 (text+ko) ====


==== //depot/projects/wifi/sbin/dhclient/conflex.c#2 (text+ko) ====


==== //depot/projects/wifi/sbin/dhclient/convert.c#2 (text+ko) ====


==== //depot/projects/wifi/sbin/dhclient/dhclient-script#6 (text+ko) ====

@@ -1,6 +1,7 @@
 #!/bin/sh
 #
 # $OpenBSD: dhclient-script,v 1.6 2004/05/06 18:22:41 claudio Exp $
+# $FreeBSD: src/sbin/dhclient/dhclient-script,v 1.4 2005/06/10 03:41:18 brooks Exp $
 #
 # Copyright (c) 2003 Kenneth R Westerback <krw@openbsd.org>
 #
@@ -171,10 +172,31 @@
 	return 1
 }
 
+# Must be used on exit.   Invokes the local dhcp client exit hooks, if any.
+exit_with_hooks() {
+	exit_status=$1
+	if [ -f /etc/dhclient-exit-hooks ]; then
+		. /etc/dhclient-exit-hooks
+	fi
+	# probably should do something with exit status of the local script
+	exit $exit_status
+}
+
 #
 # Start of active code.
 #
 
+# Invoke the local dhcp client enter hooks, if they exist.
+if [ -f /etc/dhclient-enter-hooks ]; then
+	exit_status=0
+	. /etc/dhclient-enter-hooks
+	# allow the local script to abort processing of this state
+	# local script must set exit_status variable to nonzero.
+	if [ $exit_status -ne 0 ]; then
+		exit $exit_status
+	fi
+fi
+
 if [ -x $NETSTAT ]; then
 	if_defaulroute=`$NETSTAT -rn | $GREP "^default" | $AWK '{print $6}'`
 else
@@ -246,14 +268,14 @@
 			fi
 			add_new_routes
 			if add_new_resolv_conf; then
-				exit 0
+				exit_with_hooks 0
 			fi
 		fi
 	fi
 	ifconfig $interface inet -alias $new_ip_address $medium
 	delete_old_routes
-	exit 1
+	exit_with_hooks 1
 	;;
 esac
 
-exit 0
+exit_with_hooks 0

==== //depot/projects/wifi/sbin/dhclient/dhclient-script.8#2 (text+ko) ====

@@ -36,6 +36,8 @@
 .\" see ``http://www.isc.org/isc''.  To learn more about Vixie
 .\" Enterprises, see ``http://www.vix.com''.
 .\"
+.\" $FreeBSD: src/sbin/dhclient/dhclient-script.8,v 1.2 2005/06/22 14:55:59 ru Exp $
+.\"
 .Dd January 1, 1997
 .Dt DHCLIENT-SCRIPT 8
 .Os
@@ -65,21 +67,23 @@
 .Xr dhclient 8
 needs to invoke the client configuration script, it sets up a number of
 environment variables and runs
-.Nm dhclient-script .
+.Nm .
 In all cases,
 .Va $reason
 is set to the name of the reason why the script has been invoked.
 The following reasons are currently defined:
-MEDIUM, PREINIT, ARPCHECK, ARPSEND, BOUND, RENEW, REBIND, REBOOT,
-EXPIRE, FAIL and TIMEOUT.
-.Bl -tag -width "ARPCHECK"
-.It MEDIUM
+.Li MEDIUM , PREINIT , ARPCHECK , ARPSEND , BOUND , RENEW , REBIND , REBOOT ,
+.Li EXPIRE , FAIL
+and
+.Li TIMEOUT .
+.Bl -tag -width ".Li ARPCHECK"
+.It Li MEDIUM
 The DHCP client is requesting that an interface's media type be set.
 The interface name is passed in
 .Va $interface ,
 and the media type is passed in
 .Va $medium .
-.It PREINIT
+.It Li PREINIT
 The DHCP client is requesting that an interface be configured as
 required in order to send packets prior to receiving an actual address.
 .\" For clients which use the BSD socket library,
@@ -98,25 +102,29 @@
 .Va $alias_ip_address ,
 and that IP alias should be deleted from the interface,
 along with any routes to it.
-.It ARPSEND
+.It Li ARPSEND
 The DHCP client is requesting that an address that has been offered to
 it be checked to see if somebody else is using it, by sending an ARP
 request for that address.
-It's not clear how to implement this, so no examples exist yet.
+It is not clear how to implement this, so no examples exist yet.
 The IP address to check is passed in
 .Va $new_ip_address ,
 and the interface name is passed in
 .Va $interface .
-.It ARPCHECK
+.It Li ARPCHECK
 The DHCP client wants to know if a response to the ARP request sent
-using ARPSEND has been received.
+using
+.Li ARPSEND
+has been received.
 If one has, the script should exit with a nonzero status, indicating that
 the offered address has already been requested and should be declined.
+The
 .Va $new_ip_address
 and
 .Va $interface
-are set as with ARPSEND.
-.It BOUND
+variables are set as with
+.Li ARPSEND .
+.It Li BOUND
 The DHCP client has done an initial binding to a new address.
 The new IP address is passed in
 .Va $new_ip_address ,
@@ -128,10 +136,11 @@
 described in
 .Xr dhcp-options 5 ,
 except that dashes
-.Pq Sq -
+.Pq Ql -
 are replaced by underscores
-.Pq Sq _
-in order to make valid shell variables, and the variable names start with new_.
+.Pq Ql _
+in order to make valid shell variables, and the variable names start with
+.Dq Li new_ .
 So for example, the new subnet mask would be passed in
 .Va $new_subnet_mask .
 .Pp
@@ -154,48 +163,63 @@
 .Va $alias_ip_address ,
 and other DHCP options that are set for the alias (e.g., subnet mask)
 will be passed in variables named as described previously except starting with
-$alias_ instead of $new_.
+.Dq Li $alias_
+instead of
+.Dq Li $new_ .
 Care should be taken that the alias IP address not be used if it is identical
 to the bound IP address
 .Pq Va $new_ip_address ,
 since the other alias parameters may be incorrect in this case.
-.It RENEW
-When a binding has been renewed, the script is called as in BOUND,
-except that in addition to all the variables starting with $new_,
-there is another set of variables starting with $old_.
-Persistent settings that may have changed need to be deleted \- for example,
+.It Li RENEW
+When a binding has been renewed, the script is called as in
+.Li BOUND ,
+except that in addition to all the variables starting with
+.Dq Li $new_ ,
+there is another set of variables starting with
+.Dq Li $old_ .
+Persistent settings that may have changed need to be deleted - for example,
 if a local route to the bound address is being configured, the old local
 route should be deleted.
 If the default route has changed, the old default route should be deleted.
 If the static routes have changed, the old ones should be deleted.
-Otherwise, processing can be done as with BOUND.
-.It REBIND
+Otherwise, processing can be done as with
+.Li BOUND .
+.It Li REBIND
 The DHCP client has rebound to a new DHCP server.
-This can be handled as with RENEW, except that if the IP address has changed,
+This can be handled as with
+.Li RENEW ,
+except that if the IP address has changed,
 the ARP table should be cleared.
-.It REBOOT
+.It Li REBOOT
 The DHCP client has successfully reacquired its old address after a reboot.
-This can be processed as with BOUND.
-.It EXPIRE
+This can be processed as with
+.Li BOUND .
+.It Li EXPIRE
 The DHCP client has failed to renew its lease or acquire a new one,
 and the lease has expired.
 The IP address must be relinquished, and all related parameters should be
-deleted, as in RENEW and REBIND.
-.It FAIL
+deleted, as in
+.Li RENEW
+and
+.Li REBIND .
+.It Li FAIL
 The DHCP client has been unable to contact any DHCP servers, and any
 leases that have been tested have not proved to be valid.
 The parameters from the last lease tested should be deconfigured.
-This can be handled in the same way as EXPIRE.
-.It TIMEOUT
+This can be handled in the same way as
+.Li EXPIRE .
+.It Li TIMEOUT
 The DHCP client has been unable to contact any DHCP servers.
 However, an old lease has been identified, and its parameters have
-been passed in as with BOUND.
+been passed in as with
+.Li BOUND .
 The client configuration script should test these parameters and,
 if it has reason to believe they are valid, should exit with a value of zero.
 If not, it should exit with a nonzero value.
 .El
 .Pp
-The usual way to test a lease is to set up the network as with REBIND
+The usual way to test a lease is to set up the network as with
+.Li REBIND
 (since this may be called to test more than one lease) and then ping
 the first router defined in
 .Va $routers .
@@ -221,6 +245,7 @@
 .Xr dhcpd 8 ,
 .Xr dhcrelay 8
 .Sh AUTHORS
+.An -nosplit
 The original version of
 .Nm
 was written for the Internet Software Consortium by
@@ -234,13 +259,15 @@
 was written by
 .An Kenneth R. Westerback Aq krw@openbsd.org .
 .Sh BUGS
-If more than one interface is being used, there's no obvious way to
-avoid clashes between server-supplied configuration parameters \- for
-example, the stock dhclient-script rewrites
+If more than one interface is being used, there is no obvious way to
+avoid clashes between server-supplied configuration parameters - for
+example, the stock
+.Nm
+rewrites
 .Pa /etc/resolv.conf .
 If more than one interface is being configured,
 .Pa /etc/resolv.conf
 will be repeatedly initialized to the values provided by one server, and then
 the other.
-Assuming the information provided by both servers is valid, this shouldn't
+Assuming the information provided by both servers is valid, this should not
 cause any real problems, but it could be confusing.

==== //depot/projects/wifi/sbin/dhclient/dhclient.8#2 (text+ko) ====

@@ -35,12 +35,15 @@
 .\" Enterprises.  To learn more about the Internet Software Consortium,
 .\" see ``http://www.isc.org/isc''.  To learn more about Vixie
 .\" Enterprises, see ``http://www.vix.com''.
+.\"
+.\" $FreeBSD: src/sbin/dhclient/dhclient.8,v 1.2 2005/06/22 14:55:59 ru Exp $
+.\"
 .Dd April 7, 2004
 .Dt DHCLIENT 8
 .Os
 .Sh NAME
 .Nm dhclient
-.Nd Dynamic Host Configuration Protocol (DHCP) Client
+.Nd "Dynamic Host Configuration Protocol (DHCP) client"
 .Sh SYNOPSIS
 .Nm
 .Op Fl dqu
@@ -59,7 +62,7 @@
 configure must be specified on the command line.
 .Pp
 The options are as follows:
-.Bl -tag -width "-p port"
+.Bl -tag -width ".Fl c Ar file"
 .It Fl c Ar file
 Specify an alternate location,
 .Ar file ,
@@ -110,11 +113,12 @@
 restarts,
 .Nm
 keeps a list of leases it has been assigned in the
-.Pa /var/db/dhclient.leases.IFNAME
+.Pa /var/db/dhclient.leases. Ns Ar IFNAME
 file.
-.Qq IFNAME
+.Ar IFNAME
 represents the network interface of the DHCP client
-.Pq e.g. em0 ,
+(e.g.,
+.Li em0 ) ,
 one for each interface.
 On startup, after reading the
 .Xr dhclient.conf 5
@@ -128,7 +132,7 @@
 is first invoked (generally during the initial system boot
 process).
 In that event, old leases from the
-.Pa dhclient.leases.IFNAME
+.Pa dhclient.leases. Ns Ar IFNAME
 file which have not yet expired are tested, and if they are determined to
 be valid, they are used until either they expire or the DHCP server
 becomes available.
@@ -149,18 +153,20 @@
 than cycling through the list of old leases.
 .Sh NOTES
 You must have the Berkeley Packet Filter (BPF) configured in your kernel.
+The
 .Nm
+utility
 requires at least one
 .Pa /dev/bpf*
-file for each broadcast network interface that is attached to your system.
+device for each broadcast network interface that is attached to your system.
 See
 .Xr bpf 4
 for more information.
 .Sh FILES
-.Bl -tag -width /var/db/dhclient.leases.IFNAME~ -compact
+.Bl -tag -width ".Pa /var/db/dhclient.leases. Ns Ar IFNAME" -compact
 .It Pa /etc/dhclient.conf
 DHCP client configuration file
-.It Pa /var/db/dhclient.leases.IFNAME
+.It Pa /var/db/dhclient.leases. Ns Ar IFNAME
 database of acquired leases
 .El
 .Sh SEE ALSO
@@ -171,7 +177,10 @@
 .Xr dhcpd 8 ,
 .Xr dhcrelay 8
 .Sh AUTHORS
+.An -nosplit
+The
 .Nm
+utility
 was written by
 .An Ted Lemon Aq mellon@fugue.com
 and

==== //depot/projects/wifi/sbin/dhclient/dhclient.c#7 (text+ko) ====

@@ -1,4 +1,5 @@
-/*	$OpenBSD: dhclient.c,v 1.61 2004/11/25 11:05:10 claudio Exp $	*/
+/*	$OpenBSD: dhclient.c,v 1.63 2005/02/06 17:10:13 krw Exp $	*/
+/*	$FreeBSD: src/sbin/dhclient/dhclient.c,v 1.6 2005/06/30 05:50:52 brooks Exp $	*/
 
 /*
  * Copyright 2004 Henning Brauer <henning@openbsd.org>
@@ -226,7 +227,7 @@
 			break;
 		if (findproto((char *)(ifam + 1), ifam->ifam_addrs) != AF_INET)
 			break;
-		if (scripttime == 0 || t < scripttime + 3)
+		if (scripttime == 0 || t < scripttime + 10)
 			break;
 		goto die;
 	case RTM_IFINFO:
@@ -256,12 +257,15 @@
 			 * state and then wait for either a link down
 			 * notification or an associate event.
 			 */
-			script_init("EXPIRE", NULL);
-			script_write_params("old_", ifi->client->active);
-			if (ifi->client->alias)
-				script_write_params("alias_",
-					ifi->client->alias);
-			script_go();
+			if (ifi->client->active != NULL) {
+				script_init("EXPIRE", NULL);
+				script_write_params("old_",
+				    ifi->client->active);
+				if (ifi->client->alias)
+					script_write_params("alias_",
+						ifi->client->alias);
+				script_go();
+			}
 			ifi->client->state = S_INIT;
 			break;
 		}
@@ -346,7 +350,7 @@
 	read_client_conf();
 
 	if (!interface_link_status(ifi->name)) {
-		fprintf(stderr, "%s: no link ", ifi->name);
+		fprintf(stderr, "%s: no link ...", ifi->name);
 		fflush(stderr);
 		sleep(1);
 		while (!interface_link_status(ifi->name)) {
@@ -358,7 +362,7 @@
 			}
 			sleep(1);
 		}
-		fprintf(stderr, "got link\n");
+		fprintf(stderr, " got link\n");
 	}
 
 	if ((nullfd = open(_PATH_DEVNULL, O_RDWR, 0)) == -1)
@@ -723,7 +727,7 @@
 
 	note("bound to %s -- renewal in %d seconds.",
 	    piaddr(ip->client->active->address),
-	    ip->client->active->renewal - cur_time);
+	    (int)(ip->client->active->renewal - cur_time));
 	ip->client->state = S_BOUND;
 	reinitialize_interfaces();
 	go_daemon();
@@ -1144,7 +1148,8 @@
 
 	note("DHCPDISCOVER on %s to %s port %d interval %d",
 	    ip->name, inet_ntoa(sockaddr_broadcast.sin_addr),
-	    ntohs(sockaddr_broadcast.sin_port), ip->client->interval);
+	    ntohs(sockaddr_broadcast.sin_port),
+	    (int)ip->client->interval);
 
 	/* Send out a packet. */
 	(void)send_packet(ip, &ip->client->packet, ip->client->packet_length,
@@ -1195,8 +1200,8 @@
 				    ip->client->active->renewal) {
 					ip->client->state = S_BOUND;
 					note("bound: renewal in %d seconds.",
-					    ip->client->active->renewal -
-					    cur_time);
+					    (int)(ip->client->active->renewal -
+					    cur_time));
 					add_timeout(
 					    ip->client->active->renewal,
 					    state_bound, ip);
@@ -2223,13 +2228,18 @@
 	case DHO_NETBIOS_DD_SERVER:
 	case DHO_FONT_SERVERS:
 	case DHO_DHCP_SERVER_IDENTIFIER:
+	case DHO_SMTP_SERVER:
+	case DHO_POP_SERVER:
+	case DHO_NNTP_SERVER:
+	case DHO_WWW_SERVER:
+	case DHO_FINGER_SERVER:
+	case DHO_IRC_SERVER:
 		if (!ipv4addrs(opbuf)) {
 			warning("Invalid IP address in option: %s", opbuf);
 			return (0);
 		}
 		return (1)  ;
 	case DHO_HOST_NAME:
-	case DHO_DOMAIN_NAME:
 	case DHO_NIS_DOMAIN:
 		if (!res_hnok(sbuf)) {
 			warning("Bogus Host Name option %d: %s (%s)", option,
@@ -2237,6 +2247,7 @@
 			return (0);
 		}
 		return (1);
+	case DHO_DOMAIN_NAME:
 	case DHO_PAD:
 	case DHO_TIME_OFFSET:
 	case DHO_BOOT_SIZE:

==== //depot/projects/wifi/sbin/dhclient/dhclient.conf#2 (text+ko) ====


==== //depot/projects/wifi/sbin/dhclient/dhclient.conf.5#2 (text+ko) ====

@@ -36,6 +36,8 @@
 .\" see ``http://www.isc.org/isc''.  To learn more about Vixie
 .\" Enterprises, see ``http://www.vix.com''.
 .\"
+.\" $FreeBSD: src/sbin/dhclient/dhclient.conf.5,v 1.2 2005/06/22 14:55:59 ru Exp $
+.\"
 .Dd January 1, 1997
 .Dt DHCLIENT.CONF 5
 .Os
@@ -58,7 +60,7 @@
 Keywords in the file are case-insensitive.
 Comments may be placed anywhere within the file (except within quotes).
 Comments begin with the
-.Sq #
+.Ql #
 character and end at the end of the line.
 .Pp
 The
@@ -70,23 +72,23 @@
 the server, or values to prepend or append to information provided by the
 server.
 The configuration file can also be preinitialized with addresses to
-use on networks that don't have DHCP servers.
+use on networks that do not have DHCP servers.
 .Sh PROTOCOL TIMING
 The timing behaviour of the client need not be configured by the user.
 If no timing configuration is provided by the user, a fairly
-reasonable timing behaviour will be used by default \- one which
+reasonable timing behaviour will be used by default - one which
 results in fairly timely updates without placing an inordinate load on
 the server.
 .Pp
 The following statements can be used to adjust the timing behaviour of
 the DHCP client if required, however:
-.Bl -tag -width Ds
+.Bl -tag -width indent
 .It Ic timeout Ar time ;
 The
 .Ic timeout
 statement determines the amount of time that must pass between the
 time that the client begins to try to determine its address and the
-time that it decides that it's not going to be able to contact a server.
+time that it decides that it is not going to be able to contact a server.
 By default, this timeout is sixty seconds.
 After the timeout has passed, if there are any static leases defined in the
 configuration file, or any leases remaining in the lease database that
@@ -122,7 +124,7 @@
 .Pp
 By default, the
 .Ic select-timeout
-is zero seconds \- that is, the client will take the first offer it sees.
+is zero seconds - that is, the client will take the first offer it sees.
 .It Ic reboot Ar time ;
 When the client is restarted, it first tries to reacquire the last
 address it had.
@@ -151,7 +153,9 @@
 server and the second attempt to reach a server.
 Each time a message is sent, the interval between messages is incremented by
 twice the current interval multiplied by a random number between zero and one.
-If it is greater than the backoff-cutoff amount, it is set to that
+If it is greater than the
+.Ic backoff-cutoff
+amount, it is set to that
 amount.
 It defaults to ten seconds.
 .El
@@ -160,7 +164,7 @@
 specific information, and not send it other information that it is not
 prepared to accept.
 The protocol also allows the client to reject offers from servers if they
-don't contain information the client needs, or if the information provided
+do not contain information the client needs, or if the information provided
 is not satisfactory.
 .Pp
 There is a variety of data contained in offers that DHCP servers send
@@ -169,29 +173,20 @@
 .Em DHCP Options .
 DHCP Options are defined in
 .Xr dhcp-options 5 .
-.Bl -tag -width Ds
-.It Xo
-.Ic request Op Ar option
-.Oo , Ar ... option Oc ;
-.Xc
+.Bl -tag -width indent
+.It Ic request Oo Ar option Oc Oo , Ar ... option Oc ;
 The
 .Ic request
 statement causes the client to request that any server responding to the
 client send the client its values for the specified options.
-Only the option names should be specified in the request statement \- not
+Only the option names should be specified in the request statement - not
 option parameters.
-.It Xo
-.Ic require Op Ar option
-.Oo , Ar ... option Oc ;
-.Xc
+.It Ic require Oo Ar option Oc Oo , Ar ... option Oc ;
 The
 .Ic require
 statement lists options that must be sent in order for an offer to be accepted.
 Offers that do not contain all the listed options will be ignored.
-.It Xo
-.Ic send No { Op Ar option declaration
-.Oo , Ar ... option declaration Oc }
-.Xc
+.It Ic send No { Oo Ar option declaration Oc Oo , Ar ... option declaration Oc }
 The
 .Ic send
 statement causes the client to send the specified options to the server with
@@ -213,7 +208,7 @@
 It may also receive information which is useful, but which needs to be
 supplemented with local information.
 To handle these needs, several option modifiers are available.
-.Bl -tag -width Ds
+.Bl -tag -width indent
 .It Xo
 .Ic default No { Op Ar option declaration
 .Oo , Ar ... option declaration Oc }
@@ -245,7 +240,7 @@
 .Ic prepend
 statement can only be used for options which allow more than one value to
 be given.
-This restriction is not enforced \- if violated, the results are unpredictable.
+This restriction is not enforced - if violated, the results are unpredictable.
 .It Xo
 .Ic append No { Op Ar option declaration
 .Oo , Ar ... option declaration Oc }
@@ -259,16 +254,13 @@
 .Ic append
 statement can only be used for options which allow more than one value to
 be given.
-This restriction is not enforced \- if you ignore it,
+This restriction is not enforced - if you ignore it,
 the behaviour will be unpredictable.
 .El
 .Sh LEASE DECLARATIONS
 The lease declaration:
 .Pp
-.Xo
-.Ic \	\& lease No { Ar lease-declaration
-.Oo Ar ... lease-declaration Oc }
-.Xc
+.D1 Ic lease No { Ar lease-declaration Oo Ar ... lease-declaration Oc }
 .Pp
 The DHCP client may decide after some period of time (see
 .Sx PROTOCOL TIMING )
@@ -293,11 +285,13 @@
 file.
 Such syntax is documented here for completeness.
 .Pp
-A lease statement consists of the lease keyword, followed by a left
+A lease statement consists of the
+.Ic lease
+keyword, followed by a left
 curly brace, followed by one or more lease declaration statements,
 followed by a right curly brace.
 The following lease declarations are possible:
-.Bl -tag -width Ds
+.Bl -tag -width indent
 .It Ic bootp ;
 The
 .Ic bootp
@@ -305,7 +299,7 @@
 BOOTP protocol rather than the DHCP protocol.
 It is never necessary to specify this in the client configuration file.
 The client uses this syntax in its lease database file.
-.It Ic interface Ar \&"string\&" ;
+.It Ic interface Qq Ar string ;
 The
 .Ic interface
 lease statement is used to indicate the interface on which the lease is valid.
@@ -320,14 +314,15 @@
 .Ic fixed-address
 statement is used to set the IP address of a particular lease.
 This is required for all lease statements.
-The IP address must be specified as a dotted quad (e.g., 12.34.56.78).
-.It Ic filename Ar \&"string\&" ;
+The IP address must be specified as a dotted quad (e.g.,
+.Li 12.34.56.78 ) .
+.It Ic filename Qq Ar string ;
 The
 .Ic filename
 statement specifies the name of the boot filename to use.
 This is not used by the standard client configuration script, but is
 included for completeness.
-.It Ic server-name Ar \&"string\&" ;
+.It Ic server-name Qq Ar string ;
 The
 .Ic server-name
 statement specifies the name of the boot server name to use.
@@ -337,10 +332,10 @@
 .Ic option
 statement is used to specify the value of an option supplied by the server,
 or, in the case of predefined leases declared in
-.Nm dhclient.conf ,
+.Nm ,
 the value that the user wishes the client configuration script to use if the
 predefined lease is used.
-.It Ic script Ar \&"script-name\&" ;
+.It Ic script Qq Ar script-name ;
 The
 .Ic script
 statement is used to specify the pathname of the DHCP client configuration
@@ -353,16 +348,22 @@
 any, and also called once if no valid lease can be identified.
 For more information, see
 .Xr dhclient.leases 5 .
-.It Ic medium Ar \&"media setup\&" ;
+.It Ic medium Qq Ar "media setup" ;
 The
 .Ic medium
 statement can be used on systems where network interfaces cannot
 automatically determine the type of network to which they are connected.
-The media setup string is a system-dependent parameter which is passed
+The
+.Ar "media setup"
+string is a system-dependent parameter which is passed
 to the DHCP client configuration script when initializing the interface.
 On
 .Ux
-and UNIX-like systems, the argument is passed on the ifconfig command line
+and
+.Ux Ns -like
+systems, the argument is passed on the
+.Xr ifconfig 8
+command line
 when configuring the interface.
 .Pp
 The DHCP client automatically declares this parameter if it used a
@@ -391,20 +392,21 @@
 .El
 .Pp
 These declarations are automatically set in leases acquired by the
-DHCP client, but must also be configured in predefined leases \- a
+DHCP client, but must also be configured in predefined leases - a
 predefined lease whose expiry time has passed will not be used by the
 DHCP client.
 .Pp
 Dates are specified as follows:
-.Pp
-.Ar \	\&<weekday>
+.Bd -ragged -offset indent
+.Ar <weekday>
 .Sm off
 .Ar <year> No / Ar <month> No / Ar <day>
 .Ar <hour> : <minute> : <second>
 .Sm on
+.Ed
 .Pp
 The weekday is present to make it easy for a human to tell when a
-lease expires \- it's specified as a number from zero to six, with zero
+lease expires - it is specified as a number from zero to six, with zero
 being Sunday.
 When declaring a predefined lease, it can always be specified as zero.
 The year is specified with the century, so it should generally be four
@@ -421,7 +423,7 @@
 addition to the lease they may acquire via DHCP, their interface also
 be configured with a predefined IP alias so that they can have a
 permanent IP address even while roaming.
-The Internet Software Consortium DHCP client doesn't support roaming with
+The Internet Software Consortium DHCP client does not support roaming with
 fixed addresses directly, but in order to facilitate such experimentation,
 the DHCP client can be set up to configure an IP alias using the
 .Ic alias
@@ -436,19 +438,16 @@
 declaration for the IP alias address, and a subnet-mask option declaration.
 A medium statement should never be included in an alias declaration.
 .Sh OTHER DECLARATIONS
-.Bl -tag -width Ds
+.Bl -tag -width indent
 .It Ic reject Ar ip-address ;
 The
 .Ic reject
 statement causes the DHCP client to reject offers from servers who use
 the specified address as a server identifier.
 This can be used to avoid being configured by rogue or misconfigured DHCP
-servers, although it should be a last resort \- better to track down
+servers, although it should be a last resort - better to track down
 the bad DHCP server and fix it.
-.It Xo
-.Ic interface Ar \&"name\&" No { Ar declarations
-.Ar ... No }
-.Xc
+.It Ic interface Qo Ar name Qc { Ar declarations ... No }
 A client with more than one network interface may require different
 behaviour depending on which interface is being configured.
 All timing parameters and declarations other than lease and alias
@@ -458,10 +457,7 @@
 Interfaces for which there is no interface declaration will use the
 parameters declared outside of any interface declaration,
 or the default settings.
-.It Xo
-.Ic media Ar \&"media setup\&"
-.Oo , Ar \&"media setup\&" , ... Oc ;
-.Xc
+.It Ic media Qo Ar "media setup" Qc Oo , Qo Ar "media setup" Qc , Ar ... Oc ;
 The
 .Ic media
 statement defines one or more media configuration parameters which may
@@ -469,8 +465,8 @@
 The DHCP client will cycle through each media setup string on the list,
 configuring the interface using that setup and attempting to boot,
 and then trying the next one.
-This can be used for network interfaces which aren't capable of sensing
-the media type unaided \- whichever media type succeeds in getting a request
+This can be used for network interfaces which are not capable of sensing
+the media type unaided - whichever media type succeeds in getting a request
 to the server and hearing the reply is probably right (no guarantees).
 .Pp
 The media setup is only used for the initial phase of address
@@ -483,8 +479,11 @@
 .El
 .Sh EXAMPLES
 The following configuration file is used on a laptop
-which has an IP alias of 192.5.5.213, and has one interface,
-ep0 (a 3Com 3C589C).
+which has an IP alias of
+.Li 192.5.5.213 ,
+and has one interface,
+.Li ep0
+(a 3Com 3C589C).
 Booting intervals have been shortened somewhat from the default, because
 the client is known to spend most of its time on networks with little DHCP
 activity.
@@ -519,20 +518,24 @@
 .Pp
 This is a very complicated
 .Nm
-file \- in general, yours should be much simpler.
-In many cases, it's sufficient to just create an empty
+file - in general, yours should be much simpler.
+In many cases, it is sufficient to just create an empty
 .Nm
-file \- the defaults are usually fine.
+file - the defaults are usually fine.
 .Sh SEE ALSO
 .Xr dhclient.leases 5 ,
+.Xr dhcpd.conf 5 ,
 .Xr dhcp-options 5 ,
-.Xr dhcpd.conf 5 ,
 .Xr dhclient 8 ,
 .Xr dhcpd 8
-.Pp
-RFC 2132, RFC 2131.
+.Rs
+.%R "RFC 2132, RFC 2131"
+.Re
 .Sh AUTHORS
+.An -nosplit
+The
 .Xr dhclient 8
+utility
 was written by
 .An Ted Lemon Aq mellon@vix.com
 under a contract with Vixie Labs.

==== //depot/projects/wifi/sbin/dhclient/dhclient.leases.5#2 (text+ko) ====

@@ -36,6 +36,8 @@
 .\" see ``http://www.isc.org/isc''.  To learn more about Vixie
 .\" Enterprises, see ``http://www.vix.com''.
 .\"
+.\" $FreeBSD: src/sbin/dhclient/dhclient.leases.5,v 1.2 2005/06/22 14:55:59 ru Exp $
+.\"
 .Dd January 1, 1997
 .Dt DHCLIENT.LEASES 5
 .Os
@@ -52,33 +54,39 @@
 The file is written as a log, so this is not an unusual occurrence.
 .Pp
 The lease file is named
-.Qq dhclient.leases.IFNAME ,
+.Pa dhclient.leases. Ns Ar IFNAME ,
 where
-.Qq IFNAME
+.Ar IFNAME
 represents the network interface the DHCP client acquired the lease on.
 For example, if
 .Xr dhclient 8
-is configured for the em0 network device,
+is configured for the
+.Li em0
+network device,
 the lease file will be named
-.Qq dhclient.leases.em0 .
+.Pa dhclient.leases.em0 .
 .Pp
 The format of the lease declarations is described in
 .Xr dhclient.conf 5 .
 .Sh FILES
-.Bl -tag -width "/var/db/dhclient.leases.IFNAME   "
-.It /var/db/dhclient.leases.IFNAME
+.Bl -tag -width ".Pa /var/db/dhclient.leases. Ns Ar IFNAME"
+.It Pa /var/db/dhclient.leases. Ns Ar IFNAME
 Current lease file.
 .El
 .Sh SEE ALSO
 .Xr dhclient.conf 5 ,
+.Xr dhcpd.conf 5 ,
 .Xr dhcp-options 5 ,
-.Xr dhcpd.conf 5 ,
 .Xr dhclient 8 ,
 .Xr dhcpd 8
-.Pp
-RFC 2132, RFC 2131.
+.Rs
+.%R "RFC 2132, RFC 2131"
+.Re
 .Sh AUTHORS
+.An -nosplit
+The
 .Xr dhclient 8
+utility
 was written by
 .An Ted Lemon Aq mellon@vix.com
 under a contract with Vixie Labs.

==== //depot/projects/wifi/sbin/dhclient/dhcp-options.5#2 (text+ko) ====

@@ -1,4 +1,4 @@
-.\"	$OpenBSD: dhcp-options.5,v 1.4 2004/04/15 08:59:47 jmc Exp $
+.\"	$OpenBSD: dhcp-options.5,v 1.5 2005/03/02 15:30:42 jmc Exp $
 .\"
 .\" Copyright (c) 1995, 1996, 1997, 1998 The Internet Software Consortium.
 .\" All rights reserved.
@@ -36,6 +36,8 @@
 .\" see ``http://www.isc.org/isc''.  To learn more about Vixie
 .\" Enterprises, see ``http://www.vix.com''.
 .\"
+.\" $FreeBSD: src/sbin/dhclient/dhcp-options.5,v 1.2 2005/06/22 14:55:59 ru Exp $
+.\"
 .Dd January 1, 1995
 .Dt DHCP-OPTIONS 5
 .Os
@@ -61,7 +63,7 @@
 .Ic option
 keyword, followed by an option name, followed by option data.
 The option names and data formats are described below.
-It is not necessary to exhaustively specify all DHCP options \-
+It is not necessary to exhaustively specify all DHCP options -
 only those options which are needed by clients must be specified.
 .Pp
 Option data comes in a variety of formats, as defined below:
@@ -69,7 +71,10 @@
 The
 .Ar ip-address
 data type can be entered either as an explicit IP address
-(e.g., 239.254.197.10) or as a domain name (e.g., haagen.isc.org).
+(e.g.,
+.Li 239.254.197.10 )
+or as a domain name (e.g.,
+.Li haagen.isc.org ) .
 A domain name must resolve to a single IP address.
 .Pp
 The
@@ -96,16 +101,23 @@
 .Tn NVT
 .Pq Network Virtual Terminal
 .Tn ASCII
-string, which must be enclosed in double quotes \- for example,
+string, which must be enclosed in double quotes - for example,
 to specify a domain-name option, the syntax would be
 .Pp
-.Dl option domain-name \&"isc.org\&";
+.Dl option domain-name \&"isc.org";
 .Pp
 The
 .Ar flag
 data type specifies a boolean value.
-Booleans can be either true or false
-(or on or off, if that makes more sense to you).
+Booleans can be either

>>> TRUNCATED FOR MAIL (1000 lines) <<<



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200507150130.j6F1UOFR048894>