From 0f33b636af16399198cc4935ba0845f8f30471b6 Mon Sep 17 00:00:00 2001 From: David Cantrell Date: Wed, 26 Sep 2007 19:39:59 +0000 Subject: [PATCH] - In dhcp.conf.5, explain that if no next-server statement applies to the requesting client, the address 0.0.0.0 is used (#184484). --- dhcp-3.0.6-manpages.patch | 368 ++++++++++++++++++++------------------ dhcp.spec | 6 +- 2 files changed, 194 insertions(+), 180 deletions(-) diff --git a/dhcp-3.0.6-manpages.patch b/dhcp-3.0.6-manpages.patch index bf7fd00..4e9d5a8 100644 --- a/dhcp-3.0.6-manpages.patch +++ b/dhcp-3.0.6-manpages.patch @@ -1,6 +1,194 @@ +diff -up dhcp-3.0.6/dhcpctl/dhcpctl.3.manpages dhcp-3.0.6/dhcpctl/dhcpctl.3 +--- dhcp-3.0.6/dhcpctl/dhcpctl.3.manpages 2004-09-24 17:08:38.000000000 -0400 ++++ dhcp-3.0.6/dhcpctl/dhcpctl.3 2007-09-26 15:22:12.000000000 -0400 +@@ -43,7 +43,7 @@ + .\" + .\" + .Sh SYNOPSIS +-.Fd #include ++.Fd #include + .Ft dhcpctl_status + .Fo dhcpctl_initialize + .Fa void +@@ -426,7 +426,7 @@ that most error checking has been ommitt + #include + + #include +-#include ++#include + + int main (int argc, char **argv) { + dhcpctl_data_string ipaddrstring = NULL; +diff -up dhcp-3.0.6/server/dhcpd.conf.5.manpages dhcp-3.0.6/server/dhcpd.conf.5 +--- dhcp-3.0.6/server/dhcpd.conf.5.manpages 2007-05-01 16:42:56.000000000 -0400 ++++ dhcp-3.0.6/server/dhcpd.conf.5 2007-09-26 15:24:18.000000000 -0400 +@@ -531,9 +531,9 @@ primary server might look like this: + failover peer "foo" { + primary; + address anthrax.rc.vix.com; +- port 519; ++ port 647; + peer address trantor.rc.vix.com; +- peer port 520; ++ peer port 847; + max-response-delay 60; + max-unacked-updates 10; + mclt 3600; +@@ -592,9 +592,7 @@ statement + .B port \fIport-number\fR\fB;\fR + .PP + The \fBport\fR statement declares the TCP port on which the server +-should listen for connections from its failover peer. This statement +-may not currently be omitted, because the failover protocol does not +-yet have a reserved TCP port number. ++should listen for connections from its failover peer. + .RE + .PP + The +@@ -606,10 +604,8 @@ statement + .PP + The \fBpeer port\fR statement declares the TCP port to which the + server should connect to reach its failover peer for failover +-messages. This statement may not be omitted because the failover +-protocol does not yet have a reserved TCP port number. The port +-number declared in the \fBpeer port\fR statement may be the same as +-the port number declared in the \fBport\fR statement. ++messages. The port number declared in the \fBpeer port\fR statement ++may be the same as the port number declared in the \fBport\fR statement. + .RE + .PP + The +@@ -1133,7 +1129,7 @@ the zone containing PTR records - for IS + .PP + .nf + key DHCP_UPDATER { +- algorithm HMAC-MD5.SIG-ALG.REG.INT; ++ algorithm hmac-md5; + secret pRP5FapFoJ95JEL06sv4PQ==; + }; + +@@ -1156,7 +1152,7 @@ dhcpd.conf file: + .PP + .nf + key DHCP_UPDATER { +- algorithm HMAC-MD5.SIG-ALG.REG.INT; ++ algorithm hmac-md5; + secret pRP5FapFoJ95JEL06sv4PQ==; + }; + +@@ -2114,7 +2110,8 @@ statement + The \fInext-server\fR statement is used to specify the host address of + the server from which the initial boot file (specified in the + \fIfilename\fR statement) is to be loaded. \fIServer-name\fR should +-be a numeric IP address or a domain name. ++be a numeric IP address or a domain name. If no \fInext-server\fR statement ++applies to a given client, the address 0.0.0.0 is used. + .RE + .PP + The +diff -up dhcp-3.0.6/common/dhcp-options.5.manpages dhcp-3.0.6/common/dhcp-options.5 +--- dhcp-3.0.6/common/dhcp-options.5.manpages 2006-04-26 11:12:43.000000000 -0400 ++++ dhcp-3.0.6/common/dhcp-options.5 2007-09-26 15:22:12.000000000 -0400 +@@ -834,6 +834,24 @@ classless IP routing - it does not inclu + classless IP routing is now the most widely deployed routing standard, + this option is virtually useless, and is not implemented by any of the + popular DHCP clients, for example the Microsoft DHCP client. ++.PP ++NOTE to Red Hat dhclient users: ++.br ++The RedHat dhclient-script interprets trailing 0 octets of the target ++as indicating the subnet class of the route - so for this ++static-routes value: ++.br ++ option static-routes 172.0.0.0 172.16.2.254, ++.br ++ 192.168.0.0 192.168.2.254; ++.br ++the Red Hat dhclient-script will create routes: ++.br ++ 172/8 via 172.16.2.254 dev $interface ++.br ++ 192.168/16 via 192.168.2.254 dev $interface ++.br ++which slightly increases the usefulness of the static-routes option. + .RE + .PP + .nf +diff -up dhcp-3.0.6/client/dhclient-script.8.manpages dhcp-3.0.6/client/dhclient-script.8 +--- dhcp-3.0.6/client/dhclient-script.8.manpages 2005-09-28 15:17:08.000000000 -0400 ++++ dhcp-3.0.6/client/dhclient-script.8 2007-09-26 15:22:12.000000000 -0400 +@@ -47,7 +47,7 @@ customizations are needed, they should b + exit hooks provided (see HOOKS for details). These hooks will allow the + user to override the default behaviour of the client in creating a + .B /etc/resolv.conf +-file. ++file, and to handle DHCP options not handled by default. + .PP + No standard client script exists for some operating systems, even though + the actual client may work, so a pioneering user may well need to create +@@ -91,6 +91,27 @@ present. The + .B ETCDIR/dhclient-exit-hooks + script can modify the valid of exit_status to change the exit status + of dhclient-script. ++.PP ++Immediately after dhclient brings an interface UP with a new IP address, ++subnet mask, and routes, in the REBOOT/BOUND states, it will check for the ++existence of an executable ++.B ETCDIR/dhclient-up-hooks ++script, and source it if found. This script can handle DHCP options in ++the environment that are not handled by default. A per-interface. ++.B ETCDIR/dhclient-${IF}-up-hooks ++script will override the generic script and be sourced when interface ++$IF has been brought up. ++.PP ++Immediately before dhclient brings an interface DOWN, removing its IP ++address, subnet mask, and routes, in the STOP/RELEASE states, it will ++check for the existence of an executable ++.B ETCDIR/dhclient-down-hooks ++script, and source it if found. This script can handle DHCP options in ++the environment that are not handled by default. A per-interface ++.B ETCDIR/dhclient-${IF}-down-hooks ++script will override the generic script and be sourced when interface ++$IF is about to be brought down. ++ + .SH OPERATION + When dhclient needs to invoke the client configuration script, it + defines a set of variables in the environment, and then invokes +diff -up dhcp-3.0.6/client/dhclient.conf.5.manpages dhcp-3.0.6/client/dhclient.conf.5 +--- dhcp-3.0.6/client/dhclient.conf.5.manpages 2007-05-01 16:42:55.000000000 -0400 ++++ dhcp-3.0.6/client/dhclient.conf.5 2007-09-26 15:22:12.000000000 -0400 +@@ -185,7 +185,8 @@ responding to the client send the client + options. Only the option names should be specified in the request + statement - not option parameters. By default, the DHCP server + requests the subnet-mask, broadcast-address, time-offset, routers, +-domain-name, domain-name-servers and host-name options. ++domain-name, domain-name-servers, host-name, nis-domain, nis-servers, ++and ntp-servers options. + .PP + In some cases, it may be desirable to send no parameter request list + at all. To do this, simply write the request statement but specify +@@ -581,6 +582,18 @@ database and will record the media type + Whenever the client tries to renew the lease, it will use that same + media type. The lease must expire before the client will go back to + cycling through media types. ++.PP ++ \fBbootp-broadcast-always;\fR ++.PP ++The ++.B bootp-broadcast-always ++statement instructs dhclient to always set the bootp broadcast flag in ++request packets, so that servers will always broadcast replies. ++This is equivalent to supplying the dhclient -B argument, and has ++the same effect as specifying 'always-broadcast' in the server's dhcpd.conf. ++This option is provided as a Red Hat extension to enable dhclient to work ++on IBM zSeries z/OS Linux guests. ++.PP + .SH SAMPLE + The following configuration file is used on a laptop running NetBSD + 1.3. The laptop has an IP alias of 192.5.5.213, and has one diff -up dhcp-3.0.6/client/dhclient.8.manpages dhcp-3.0.6/client/dhclient.8 --- dhcp-3.0.6/client/dhclient.8.manpages 2007-05-01 16:42:55.000000000 -0400 -+++ dhcp-3.0.6/client/dhclient.8 2007-08-15 12:08:48.000000000 -0400 ++++ dhcp-3.0.6/client/dhclient.8 2007-09-26 15:22:12.000000000 -0400 @@ -82,6 +82,28 @@ relay .B -w ] @@ -141,181 +329,3 @@ diff -up dhcp-3.0.6/client/dhclient.8.manpages dhcp-3.0.6/client/dhclient.8 .SH CONFIGURATION The syntax of the dhclient.conf(5) file is discussed separately. .SH OMAPI -diff -up dhcp-3.0.6/client/dhclient-script.8.manpages dhcp-3.0.6/client/dhclient-script.8 ---- dhcp-3.0.6/client/dhclient-script.8.manpages 2005-09-28 15:17:08.000000000 -0400 -+++ dhcp-3.0.6/client/dhclient-script.8 2007-08-15 11:55:11.000000000 -0400 -@@ -47,7 +47,7 @@ customizations are needed, they should b - exit hooks provided (see HOOKS for details). These hooks will allow the - user to override the default behaviour of the client in creating a - .B /etc/resolv.conf --file. -+file, and to handle DHCP options not handled by default. - .PP - No standard client script exists for some operating systems, even though - the actual client may work, so a pioneering user may well need to create -@@ -91,6 +91,27 @@ present. The - .B ETCDIR/dhclient-exit-hooks - script can modify the valid of exit_status to change the exit status - of dhclient-script. -+.PP -+Immediately after dhclient brings an interface UP with a new IP address, -+subnet mask, and routes, in the REBOOT/BOUND states, it will check for the -+existence of an executable -+.B ETCDIR/dhclient-up-hooks -+script, and source it if found. This script can handle DHCP options in -+the environment that are not handled by default. A per-interface. -+.B ETCDIR/dhclient-${IF}-up-hooks -+script will override the generic script and be sourced when interface -+$IF has been brought up. -+.PP -+Immediately before dhclient brings an interface DOWN, removing its IP -+address, subnet mask, and routes, in the STOP/RELEASE states, it will -+check for the existence of an executable -+.B ETCDIR/dhclient-down-hooks -+script, and source it if found. This script can handle DHCP options in -+the environment that are not handled by default. A per-interface -+.B ETCDIR/dhclient-${IF}-down-hooks -+script will override the generic script and be sourced when interface -+$IF is about to be brought down. -+ - .SH OPERATION - When dhclient needs to invoke the client configuration script, it - defines a set of variables in the environment, and then invokes -diff -up dhcp-3.0.6/client/dhclient.conf.5.manpages dhcp-3.0.6/client/dhclient.conf.5 ---- dhcp-3.0.6/client/dhclient.conf.5.manpages 2007-05-01 16:42:55.000000000 -0400 -+++ dhcp-3.0.6/client/dhclient.conf.5 2007-08-15 11:56:40.000000000 -0400 -@@ -185,7 +185,8 @@ responding to the client send the client - options. Only the option names should be specified in the request - statement - not option parameters. By default, the DHCP server - requests the subnet-mask, broadcast-address, time-offset, routers, --domain-name, domain-name-servers and host-name options. -+domain-name, domain-name-servers, host-name, nis-domain, nis-servers, -+and ntp-servers options. - .PP - In some cases, it may be desirable to send no parameter request list - at all. To do this, simply write the request statement but specify -@@ -581,6 +582,18 @@ database and will record the media type - Whenever the client tries to renew the lease, it will use that same - media type. The lease must expire before the client will go back to - cycling through media types. -+.PP -+ \fBbootp-broadcast-always;\fR -+.PP -+The -+.B bootp-broadcast-always -+statement instructs dhclient to always set the bootp broadcast flag in -+request packets, so that servers will always broadcast replies. -+This is equivalent to supplying the dhclient -B argument, and has -+the same effect as specifying 'always-broadcast' in the server's dhcpd.conf. -+This option is provided as a Red Hat extension to enable dhclient to work -+on IBM zSeries z/OS Linux guests. -+.PP - .SH SAMPLE - The following configuration file is used on a laptop running NetBSD - 1.3. The laptop has an IP alias of 192.5.5.213, and has one -diff -up dhcp-3.0.6/dhcpctl/dhcpctl.3.manpages dhcp-3.0.6/dhcpctl/dhcpctl.3 ---- dhcp-3.0.6/dhcpctl/dhcpctl.3.manpages 2004-09-24 17:08:38.000000000 -0400 -+++ dhcp-3.0.6/dhcpctl/dhcpctl.3 2007-08-15 12:59:06.000000000 -0400 -@@ -43,7 +43,7 @@ - .\" - .\" - .Sh SYNOPSIS --.Fd #include -+.Fd #include - .Ft dhcpctl_status - .Fo dhcpctl_initialize - .Fa void -@@ -426,7 +426,7 @@ that most error checking has been ommitt - #include - - #include --#include -+#include - - int main (int argc, char **argv) { - dhcpctl_data_string ipaddrstring = NULL; -diff -up dhcp-3.0.6/server/dhcpd.conf.5.manpages dhcp-3.0.6/server/dhcpd.conf.5 ---- dhcp-3.0.6/server/dhcpd.conf.5.manpages 2007-05-01 16:42:56.000000000 -0400 -+++ dhcp-3.0.6/server/dhcpd.conf.5 2007-08-15 13:00:35.000000000 -0400 -@@ -531,9 +531,9 @@ primary server might look like this: - failover peer "foo" { - primary; - address anthrax.rc.vix.com; -- port 519; -+ port 647; - peer address trantor.rc.vix.com; -- peer port 520; -+ peer port 847; - max-response-delay 60; - max-unacked-updates 10; - mclt 3600; -@@ -592,9 +592,7 @@ statement - .B port \fIport-number\fR\fB;\fR - .PP - The \fBport\fR statement declares the TCP port on which the server --should listen for connections from its failover peer. This statement --may not currently be omitted, because the failover protocol does not --yet have a reserved TCP port number. -+should listen for connections from its failover peer. - .RE - .PP - The -@@ -606,10 +604,8 @@ statement - .PP - The \fBpeer port\fR statement declares the TCP port to which the - server should connect to reach its failover peer for failover --messages. This statement may not be omitted because the failover --protocol does not yet have a reserved TCP port number. The port --number declared in the \fBpeer port\fR statement may be the same as --the port number declared in the \fBport\fR statement. -+messages. The port number declared in the \fBpeer port\fR statement -+may be the same as the port number declared in the \fBport\fR statement. - .RE - .PP - The -@@ -1133,7 +1129,7 @@ the zone containing PTR records - for IS - .PP - .nf - key DHCP_UPDATER { -- algorithm HMAC-MD5.SIG-ALG.REG.INT; -+ algorithm hmac-md5; - secret pRP5FapFoJ95JEL06sv4PQ==; - }; - -@@ -1156,7 +1152,7 @@ dhcpd.conf file: - .PP - .nf - key DHCP_UPDATER { -- algorithm HMAC-MD5.SIG-ALG.REG.INT; -+ algorithm hmac-md5; - secret pRP5FapFoJ95JEL06sv4PQ==; - }; - -diff -up dhcp-3.0.6/common/dhcp-options.5.manpages dhcp-3.0.6/common/dhcp-options.5 ---- dhcp-3.0.6/common/dhcp-options.5.manpages 2006-04-26 11:12:43.000000000 -0400 -+++ dhcp-3.0.6/common/dhcp-options.5 2007-08-15 12:10:12.000000000 -0400 -@@ -834,6 +834,24 @@ classless IP routing - it does not inclu - classless IP routing is now the most widely deployed routing standard, - this option is virtually useless, and is not implemented by any of the - popular DHCP clients, for example the Microsoft DHCP client. -+.PP -+NOTE to Red Hat dhclient users: -+.br -+The RedHat dhclient-script interprets trailing 0 octets of the target -+as indicating the subnet class of the route - so for this -+static-routes value: -+.br -+ option static-routes 172.0.0.0 172.16.2.254, -+.br -+ 192.168.0.0 192.168.2.254; -+.br -+the Red Hat dhclient-script will create routes: -+.br -+ 172/8 via 172.16.2.254 dev $interface -+.br -+ 192.168/16 via 192.168.2.254 dev $interface -+.br -+which slightly increases the usefulness of the static-routes option. - .RE - .PP - .nf diff --git a/dhcp.spec b/dhcp.spec index af0aaa3..4ee7437 100644 --- a/dhcp.spec +++ b/dhcp.spec @@ -13,7 +13,7 @@ Summary: DHCP (Dynamic Host Configuration Protocol) server and relay agent Name: dhcp Version: 3.0.6 -Release: 6%{?dist} +Release: 7%{?dist} Epoch: 12 License: ISC Group: System Environment/Daemons @@ -431,6 +431,10 @@ fi %{_libdir}/libdhcp4client.a %changelog +* Wed Sep 26 2007 David Cantrell - 12:3.0.6-7 +- In dhcp.conf.5, explain that if no next-server statement applies to the + requesting client, the address 0.0.0.0 is used (#184484). + * Wed Sep 26 2007 David Cantrell - 12:3.0.6-6 - Init script fixes for dhcpd and dhcrelay (#278601)