summaryrefslogtreecommitdiffstats
path: root/contrib/isc-dhcp/client
diff options
context:
space:
mode:
authormurray <murray@FreeBSD.org>2003-01-15 10:31:26 +0000
committermurray <murray@FreeBSD.org>2003-01-15 10:31:26 +0000
commit017255e081bcbadf47f5affc7eea7c047e38a70f (patch)
treecf39c38365a0b53bd8bc09fd59f38b2eee8a01cf /contrib/isc-dhcp/client
parenta0b500f866e54d9ce8def00d72daac852505461e (diff)
downloadFreeBSD-src-017255e081bcbadf47f5affc7eea7c047e38a70f.zip
FreeBSD-src-017255e081bcbadf47f5affc7eea7c047e38a70f.tar.gz
Import ISC DHCP 3.0.1 RC10 client.
Diffstat (limited to 'contrib/isc-dhcp/client')
-rw-r--r--contrib/isc-dhcp/client/dhclient-script.83
-rw-r--r--contrib/isc-dhcp/client/dhclient.85
-rw-r--r--contrib/isc-dhcp/client/dhclient.c29
-rw-r--r--contrib/isc-dhcp/client/dhclient.conf.513
-rw-r--r--contrib/isc-dhcp/client/dhclient.leases.53
-rwxr-xr-xcontrib/isc-dhcp/client/scripts/freebsd12
6 files changed, 42 insertions, 23 deletions
diff --git a/contrib/isc-dhcp/client/dhclient-script.8 b/contrib/isc-dhcp/client/dhclient-script.8
index acf7edc..948f963 100644
--- a/contrib/isc-dhcp/client/dhclient-script.8
+++ b/contrib/isc-dhcp/client/dhclient-script.8
@@ -34,6 +34,9 @@
.\" ``http://www.isc.org/''. To learn more about Vixie Enterprises,
.\" see ``http://www.vix.com''. To learn more about Nominum, Inc., see
.\" ``http://www.nominum.com''.
+.\"
+.\" $Id: dhclient-script.8,v 1.8.2.3 2002/05/27 04:18:41 murray Exp $
+.\"
.TH dhclient-script 8
.SH NAME
dhclient-script - DHCP client network configuration script
diff --git a/contrib/isc-dhcp/client/dhclient.8 b/contrib/isc-dhcp/client/dhclient.8
index 3213b87..a996a02 100644
--- a/contrib/isc-dhcp/client/dhclient.8
+++ b/contrib/isc-dhcp/client/dhclient.8
@@ -15,6 +15,9 @@
.\"
.\" Support and other services are available for ISC products - see
.\" http://www.isc.org for more information.
+.\"
+.\" $Id: dhclient.8,v 1.12.2.6 2002/06/08 08:23:28 murray Exp $
+.\"
.TH dhclient 8
.SH NAME
dhclient - Dynamic Host Configuration Protocol Client
@@ -135,7 +138,7 @@ than cycling through the list of old leases.
The names of the network interfaces that dhclient should attempt to
configure may be specified on the command line. If no interface names
are specified on the command line dhclient will normally identify all
-network interfaces, elimininating non-broadcast interfaces if
+network interfaces, eliminating non-broadcast interfaces if
possible, and attempt to configure each interface.
.PP
It is also possible to specify interfaces by name in the
diff --git a/contrib/isc-dhcp/client/dhclient.c b/contrib/isc-dhcp/client/dhclient.c
index 39edb87..d2e1342 100644
--- a/contrib/isc-dhcp/client/dhclient.c
+++ b/contrib/isc-dhcp/client/dhclient.c
@@ -41,7 +41,7 @@
#ifndef lint
static char ocopyright[] =
-"$Id: dhclient.c,v 1.129.2.10 2002/04/26 23:33:05 murray Exp $ Copyright (c) 1995-2001 Internet Software Consortium. All rights reserved.\n";
+"$Id: dhclient.c,v 1.129.2.12 2002/11/07 23:26:38 dhankins Exp $ Copyright (c) 1995-2002 Internet Software Consortium. All rights reserved.\n";
#endif /* not lint */
#include "dhcpd.h"
@@ -71,19 +71,19 @@ struct in_addr giaddr;
assert (state_is == state_shouldbe). */
#define ASSERT_STATE(state_is, state_shouldbe) {}
-static char copyright[] = "Copyright 1995-2001 Internet Software Consortium.";
+static char copyright[] = "Copyright 1995-2002 Internet Software Consortium.";
static char arr [] = "All rights reserved.";
static char message [] = "Internet Software Consortium DHCP Client";
static char url [] = "For info, please visit http://www.isc.org/products/DHCP";
-u_int16_t local_port;
-u_int16_t remote_port;
-int no_daemon;
-struct string_list *client_env;
-int client_env_count;
-int onetry;
-int quiet;
-int nowait;
+u_int16_t local_port=0;
+u_int16_t remote_port=0;
+int no_daemon=0;
+struct string_list *client_env=NULL;
+int client_env_count=0;
+int onetry=0;
+int quiet=0;
+int nowait=0;
static void usage PROTO ((void));
@@ -289,8 +289,10 @@ int main (argc, argv, envp)
/* Default to the DHCP/BOOTP port. */
if (!local_port) {
+ /* If we're faking a relay agent, and we're not using loopback,
+ use the server port, not the client port. */
if (relay && giaddr.s_addr != htonl (INADDR_LOOPBACK)) {
- local_port = htons (67);
+ local_port = htons(67);
} else {
ent = getservbyname ("dhcpc", "udp");
if (!ent)
@@ -304,13 +306,12 @@ int main (argc, argv, envp)
}
/* If we're faking a relay agent, and we're not using loopback,
- use the server port, not the client port. */
+ we're using the server port, not the client port. */
if (relay && giaddr.s_addr != htonl (INADDR_LOOPBACK)) {
- local_port = htons (ntohs (local_port) - 1);
remote_port = local_port;
} else
remote_port = htons (ntohs (local_port) - 1); /* XXX */
-
+
/* Get the current time... */
GET_TIME (&cur_time);
diff --git a/contrib/isc-dhcp/client/dhclient.conf.5 b/contrib/isc-dhcp/client/dhclient.conf.5
index f08b6ae..595dae6 100644
--- a/contrib/isc-dhcp/client/dhclient.conf.5
+++ b/contrib/isc-dhcp/client/dhclient.conf.5
@@ -34,6 +34,9 @@
.\" ``http://www.isc.org/''. To learn more about Vixie Enterprises,
.\" see ``http://www.vix.com''. To learn more about Nominum, Inc., see
.\" ``http://www.nominum.com''.
+.\"
+.\" $Id: dhclient.conf.5,v 1.12.2.7 2002/11/04 00:41:30 dhankins Exp $
+.\"
.TH dhclient.conf 5
.SH NAME
dhclient.conf - DHCP client configuration file
@@ -249,19 +252,19 @@ updated. The \fIfqdn.encoded\fR option may need to be set to
\fIon\fR or \fIoff\fR, depending on the DHCP server you are using.
.PP
.I The
-.B no-client-updates
+.B do-forward-updates
.I statement
.PP
- \fBno-client-updates [ \fIflag\fR ] \fB;\fR
+ \fBdo-forward-updates [ \fIflag\fR ] \fB;\fR
.PP
If you want to do DNS updates in the DHCP client
script (see \fBdhclient-script(8)\fR) rather than having the
DHCP client do the update directly (for example, if you want to
use SIG(0) authentication, which is not supported directly by the
DHCP client, you can instruct the client not to do the update using
-the \fBno-client-updates\fR statement. \fIFlag\fR should be \fBtrue\fR
-if you don't want the DHCP client to do the update, and \fBfalse\fR if
-you want the DHCP client to do the update. By default, the DHCP
+the \fBdo-forward-updates\fR statement. \fIFlag\fR should be \fBtrue\fR
+if you want the DHCP client to do the update, and \fBfalse\fR if
+you don't want the DHCP client to do the update. By default, the DHCP
client will do the DNS update.
.SH OPTION MODIFIERS
In some cases, a client may receive option data from the server which
diff --git a/contrib/isc-dhcp/client/dhclient.leases.5 b/contrib/isc-dhcp/client/dhclient.leases.5
index 5f1418e..afa8e02 100644
--- a/contrib/isc-dhcp/client/dhclient.leases.5
+++ b/contrib/isc-dhcp/client/dhclient.leases.5
@@ -35,6 +35,9 @@
.\" 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''.
+.\"
+.\" $Id: dhclient.leases.5,v 1.2.4.2 2002/05/27 04:18:44 murray Exp $
+.\"
.TH dhclient.leases 5
.SH NAME
dhclient.leases - DHCP client lease database
diff --git a/contrib/isc-dhcp/client/scripts/freebsd b/contrib/isc-dhcp/client/scripts/freebsd
index 23eb302..f9d61b5 100755
--- a/contrib/isc-dhcp/client/scripts/freebsd
+++ b/contrib/isc-dhcp/client/scripts/freebsd
@@ -1,5 +1,7 @@
#!/bin/sh
-
+#
+# $Id: freebsd,v 1.13.2.4 2002/06/09 22:37:55 murray Exp $
+#
# $FreeBSD$
if [ -x /usr/bin/logger ]; then
@@ -9,8 +11,12 @@ else
fi
make_resolv_conf() {
- if [ "x$new_domain_name" != x ] && [ x"$new_domain_name_servers" != x ]; then
- echo search $new_domain_name >/etc/resolv.conf
+ if [ x"$new_domain_name_servers" != x ]; then
+ if [ "x$new_domain_name" != x ]; then
+ echo search $new_domain_name >/etc/resolv.conf
+ else
+ rm /etc/resolv.conf
+ fi
for nameserver in $new_domain_name_servers; do
echo nameserver $nameserver >>/etc/resolv.conf
done
OpenPOWER on IntegriCloud