Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.sbin/dhcp Resolve conflicts from Patchlevel 25 import.
details: https://anonhg.NetBSD.org/src/rev/ef2512771bd5
branches: trunk
changeset: 471737:ef2512771bd5
user: mellon <mellon%NetBSD.org@localhost>
date: Fri Apr 09 17:55:01 1999 +0000
description:
Resolve conflicts from Patchlevel 25 import.
diffstat:
usr.sbin/dhcp/README | 90 ++++++++++++++++++++++++++++++++----
usr.sbin/dhcp/RELNOTES | 30 +++++++++++-
usr.sbin/dhcp/client/dhclient.c | 4 +-
usr.sbin/dhcp/common/dhcp-options.5 | 4 +-
usr.sbin/dhcp/includes/dhcpd.h | 1 +
usr.sbin/dhcp/server/bootp.c | 25 ++++++++-
usr.sbin/dhcp/server/dhcp.c | 19 ++++--
usr.sbin/dhcp/server/dhcpd.c | 4 +-
usr.sbin/dhcp/server/dhcpd.conf.5 | 19 +++++++
9 files changed, 165 insertions(+), 31 deletions(-)
diffs (truncated from 386 to 300 lines):
diff -r 7d815e65b3b3 -r ef2512771bd5 usr.sbin/dhcp/README
--- a/usr.sbin/dhcp/README Fri Apr 09 17:52:05 1999 +0000
+++ b/usr.sbin/dhcp/README Fri Apr 09 17:55:01 1999 +0000
@@ -1,7 +1,7 @@
Internet Software Consortium
Dynamic Host Configuration Protocol Distribution
- Version 2, Beta 1, Patchlevel 22
- March 29, 1998
+ Version 2, Beta 1, Patchlevel 25
+ April 9, 1999
Documentation for this software includes this README file, the
RELNOTES file, and the manual pages, which are in the server, common,
@@ -53,14 +53,12 @@
November of 1996.
In this release, the server and relay agent currently work well on
-NetBSD, Linux, FreeBSD, BSD/OS, Ultrix, Digital Alpha OSF/1, and SunOS
-4.1.4. They can also be run usefully on Solaris as long as only one
-broadcast network interface is configured. They also runs on QNX as
-long as only one broadcast network interface is configured and a host
-route is added from that interface to the 255.255.255.255 broadcast
-address. If you are running a Linux 2.0.30 or previous kernel, the
-DHCP daemons will only be able to operate on machines with a single
-network interface.
+NetBSD, Linux after kernel version 2.0.30, FreeBSD, BSD/OS, Ultrix,
+Digital Alpha OSF/1, Solaris and SunOS 4.1.4. They run on AIX, HPUX,
+IRIX and Linux 2.0.30 and earlier kernels but support only a single
+broadcast network interface. They also runs on QNX as long as only
+one broadcast network interface is configured and a host route is
+added from that interface to the 255.255.255.255 broadcast address.
The DHCP client currently only knows how to configure the network on
NetBSD, FreeBSD, BSD/os, Linux, Solaris and NextStep. The client
@@ -88,9 +86,12 @@
To build the DHCP Distribution, unpack the compressed tar file using
the tar utility and the gzip command - type something like:
- zcat dhcp-2.0b1pl22.tar.gz |tar xvf -
+ zcat dhcp-2.0b1pl25.tar.gz |tar xvf -
-Now, cd to the dhcp-2.0b1pl22 subdirectory that you've just created and
+On BSD/OS, you have to type gzcat, not zcat, and you may run into
+similar problems on other operating systems.
+
+Now, cd to the dhcp-2.0b1pl25 subdirectory that you've just created and
configure the source tree by typing:
./configure
@@ -321,9 +322,74 @@
If you are going to use dhcpd, you should probably subscribe to the
dhcp-server and dhcp-announce mailing lists. If you will be using
dhclient, you should subscribe to the dhcp-client mailing list.
+
+If you need help, you should ask on the dhcp-server or dhcp-client
+mailing list (or both) - whichever is appropriate to your
+application. This includes reporting bugs. Please do not report
+bugs in old software releases - fetch the latest release and see if
+the bug is still in that copy of the software, and if it's not, _then_
+report it. It's okay to report bugs in the latest patchlevel of a
+major version that's not the most recent major version, though - for
+example, if you're running 2.0, you don't have to upgrade to 3.0
+before you can report bugs.
+
+PLEASE READ THIS README FILE CAREFULLY BEFORE REPORTING BUGS!
+
+When you report bugs, please provide us complete information. A list
+of information we need follows. Please read it carefully, and put
+all the information you can into your initial bug report, so that we
+don't have to ask you any questions in order to figure out your
+problem.
+
+ - The specific operating system name and version of the
+ machine on which the DHCP server or client is running.
+ - The specific operating system name and version of the
+ machine on which the client is running, if you are having
+ trouble getting a client working with the server.
+ - If you're running Linux, the version number we care about is
+ the kernel version and maybe the library version, not the
+ distribution version - e.g., while we don't mind knowing
+ that you're running Redhat version mumble.foo, we must know
+ what kernel version you're running, and it helps if you can
+ tell us what version of the C library you're running,
+ although if you don't know that off the top of your head it
+ may be hard for you to figure it out, so don't go crazy
+ trying.
+ - The specific version of the DHCP distribution you're
+ running, for example 2.0b1pl19, not 2.0.
+ - Please explain the problem carefully, thinking through what
+ you're saying to ensure that you don't assume we know
+ something about your situation that we don't know.
+ - Include your dhcpd.conf and dhcpd.leases file if they're not
+ huge (if they are huge, we may need them anyway, but don't
+ send them until you're asked).
+ - Include a log of your server or client running until it
+ encounters the problem - for example, if you are having
+ trouble getting some client to get an address, restart the
+ server with the -d flag and then restart the client, and
+ send us what the server prints. Likewise, with the client,
+ include the output of the client as it fails to get an
+ address or otherwise does the wrong thing. Do not leave
+ out parts of the output that you think aren't interesting.
+ - If the client or server is dumping core, please run the
+ debugger and get a stack trace, and include that in your
+ bug report. For example, if your debugger is gdb, do the
+ following:
+
+ gdb dhcpd dhcpd.core
+ (gdb) where
+ [...]
+ (gdb) quit
+
+ This assumes that it's the dhcp server you're debugging, and
+ that the core file is in dhcpd.core.
+
PLEASE DO NOT send queries about non-isc clients to the dhcp-client
mailing list. If you're asking about them on an ISC mailing list,
it's probably because you're using the ISC DHCP server, so ask there.
+If you are having problems with a client whose executable is called
+dhcpcd, this is _not_ the ISC DHCP client, and we probably can't help
+you with it.
Please see http://www.fugue.com/dhcp/lists for details on how to
subscribe. If you don't have WorldWide Web access, you can send mail
diff -r 7d815e65b3b3 -r ef2512771bd5 usr.sbin/dhcp/RELNOTES
--- a/usr.sbin/dhcp/RELNOTES Fri Apr 09 17:52:05 1999 +0000
+++ b/usr.sbin/dhcp/RELNOTES Fri Apr 09 17:55:01 1999 +0000
@@ -1,7 +1,7 @@
Internet Software Consortium
Dynamic Host Configuration Protocol Distribution
- Version 2, Beta 1, Patchlevel 22
- March 29, 1998
+ Version 2, Beta 1, Patchlevel 25
+ April 9, 1999
Release Notes
@@ -53,6 +53,32 @@
the near future, and is intended for sites that are in a position to
experiment, or for sites that desperately need the new features.
+ CHANGES FROM VERSION 2.0 BETA 1 PATCHLEVEL 24
+
+- D'oh! Fix a really stupid mistake in hash.c.
+
+ CHANGES FROM VERSION 2.0 BETA 1 PATCHLEVEL 23
+
+- Support an always-reply-rfc1048 flag, which says to reply with an
+ RFC1048-style vendor extensions buffer even if the client didn't
+ send an RFC1048-style magic number.
+
+- Fix a null pointer dereference.
+
+- Use netmask from subnet if no netmask option specified.
+
+- IRIX support (thanks to Don Badrak).
+
+- Install unformatted manual pages on Linux.
+
+- Add note in README about zcat vs. gzcat on BSD/os.
+
+ CHANGES FROM VERSION 2.0 BETA 1 PATCHLEVEL 22
+
+- Test for lease before dereferencing it in dhcprequest.
+
+- Free the client parameter request list in dhcpnak if there is one.
+
CHANGES FROM VERSION 2.0 BETA 1 PATCHLEVEL 21
- Fix a pasto in options.c that will cause a core dump whenever a
diff -r 7d815e65b3b3 -r ef2512771bd5 usr.sbin/dhcp/client/dhclient.c
--- a/usr.sbin/dhcp/client/dhclient.c Fri Apr 09 17:52:05 1999 +0000
+++ b/usr.sbin/dhcp/client/dhclient.c Fri Apr 09 17:55:01 1999 +0000
@@ -56,7 +56,7 @@
#ifndef lint
static char ocopyright[] =
-"$Id: dhclient.c,v 1.20 1999/03/30 03:12:28 mellon Exp $ Copyright (c) 1995, 1996, 1997, 1998, 1999 The Internet Software Consortium. All rights reserved.\n";
+"$Id: dhclient.c,v 1.21 1999/04/09 17:55:01 mellon Exp $ Copyright (c) 1995, 1996, 1997, 1998, 1999 The Internet Software Consortium. All rights reserved.\n";
#endif /* not lint */
#include "dhcpd.h"
@@ -95,7 +95,7 @@
static char copyright[] =
"Copyright 1995, 1996, 1997, 1998, 1999 The Internet Software Consortium.";
static char arr [] = "All rights reserved.";
-static char message [] = "Internet Software Consortium DHCP Client V2.0b1pl22";
+static char message [] = "Internet Software Consortium DHCP Client V2.0b1pl25";
static char contrib [] = "Please contribute if you find this software useful.";
static char url [] = "For info, please visit http://www.isc.org/dhcp-contrib.html";
diff -r 7d815e65b3b3 -r ef2512771bd5 usr.sbin/dhcp/common/dhcp-options.5
--- a/usr.sbin/dhcp/common/dhcp-options.5 Fri Apr 09 17:52:05 1999 +0000
+++ b/usr.sbin/dhcp/common/dhcp-options.5 Fri Apr 09 17:55:01 1999 +0000
@@ -103,9 +103,9 @@
hexadecimal, seperated by colons. For example:
.nf
.sp 1
- option client-identifier "CLIENT-FOO";
+ option dhcp-client-identifier "CLIENT-FOO";
or
- option client-identifier 43:4c:49:45:54:2d:46:4f:4f;
+ option dhcp-client-identifier 43:4c:49:45:54:2d:46:4f:4f;
.fi
.PP
The documentation for the various options mentioned below is taken
diff -r 7d815e65b3b3 -r ef2512771bd5 usr.sbin/dhcp/includes/dhcpd.h
--- a/usr.sbin/dhcp/includes/dhcpd.h Fri Apr 09 17:52:05 1999 +0000
+++ b/usr.sbin/dhcp/includes/dhcpd.h Fri Apr 09 17:55:01 1999 +0000
@@ -213,6 +213,7 @@
int use_host_decl_names;
int use_lease_addr_for_default_route;
int authoritative;
+ int always_reply_rfc1048;
struct tree_cache *options [256];
};
diff -r 7d815e65b3b3 -r ef2512771bd5 usr.sbin/dhcp/server/bootp.c
--- a/usr.sbin/dhcp/server/bootp.c Fri Apr 09 17:52:05 1999 +0000
+++ b/usr.sbin/dhcp/server/bootp.c Fri Apr 09 17:55:01 1999 +0000
@@ -42,7 +42,7 @@
#ifndef lint
static char copyright[] =
-"$Id: bootp.c,v 1.7 1999/03/26 20:15:01 drochner Exp $ Copyright (c) 1995, 1996, 1998, 1999 The Internet Software Consortium. All rights reserved.\n";
+"$Id: bootp.c,v 1.8 1999/04/09 17:55:02 mellon Exp $ Copyright (c) 1995, 1996, 1998, 1999 The Internet Software Consortium. All rights reserved.\n";
#endif /* not lint */
#include "dhcpd.h"
@@ -67,13 +67,14 @@
if (packet -> raw -> op != BOOTREQUEST)
return;
- note ("BOOTREQUEST from %s via %s",
+ note ("BOOTREQUEST from %s via %s%s",
print_hw_addr (packet -> raw -> htype,
packet -> raw -> hlen,
packet -> raw -> chaddr),
packet -> raw -> giaddr.s_addr
? inet_ntoa (packet -> raw -> giaddr)
- : packet -> interface -> name);
+ : packet -> interface -> name,
+ packet -> options_valid ? "" : " (non-rfc1048)");
@@ -232,11 +233,15 @@
/* If we didn't get a known vendor magic number on the way in,
just copy the input options to the output. */
- if (!packet -> options_valid) {
+ if (!packet -> options_valid &&
+ !subnet -> group -> always_reply_rfc1048 &&
+ (!hp || !hp -> group -> always_reply_rfc1048)) {
memcpy (outgoing.raw -> options,
packet -> raw -> options, DHCP_OPTION_LEN);
outgoing.packet_length = BOOTP_MIN_LEN;
} else {
+ struct tree_cache netmask_tree; /* -- RBF */
+
/* Come up with a list of options that we want to send
to this client. Start with the per-subnet options,
and then override those with client-specific
@@ -249,6 +254,18 @@
options [i] = hp -> group -> options [i];
}
+ /* Use the subnet mask from the subnet declaration if no other
+ mask has been provided. */
+ if (!options [DHO_SUBNET_MASK]) {
+ options [DHO_SUBNET_MASK] = &netmask_tree;
+ netmask_tree.flags = TC_TEMPORARY;
+ netmask_tree.value = lease -> subnet -> netmask.iabuf;
+ netmask_tree.len = lease -> subnet -> netmask.len;
+ netmask_tree.buf_size = lease -> subnet -> netmask.len;
+ netmask_tree.timeout = 0xFFFFFFFF;
+ netmask_tree.tree = (struct tree *)0;
+ }
+
/* Pack the options into the buffer. Unlike DHCP, we
can't pack options into the filename and server
name buffers. */
diff -r 7d815e65b3b3 -r ef2512771bd5 usr.sbin/dhcp/server/dhcp.c
--- a/usr.sbin/dhcp/server/dhcp.c Fri Apr 09 17:52:05 1999 +0000
+++ b/usr.sbin/dhcp/server/dhcp.c Fri Apr 09 17:55:01 1999 +0000
@@ -42,7 +42,7 @@
#ifndef lint
static char copyright[] =
-"$Id: dhcp.c,v 1.8 1999/03/29 23:08:23 mellon Exp $ Copyright (c) 1995, 1996, 1997, 1998, 1999 The Internet Software Consortium. All rights reserved.\n";
+"$Id: dhcp.c,v 1.9 1999/04/09 17:55:02 mellon Exp $ Copyright (c) 1995, 1996, 1997, 1998, 1999 The Internet Software Consortium. All rights reserved.\n";
#endif /* not lint */
#include "dhcpd.h"
@@ -314,15 +314,16 @@
}
/* If we're not allowed to serve this client anymore, don't. */
- if (!lease -> host &&
+ if (lease &&
Home |
Main Index |
Thread Index |
Old Index