From 69130efed36ca6d3554ff81664a4985b27d352acc2ab2c7926f01aee15f21f43 Mon Sep 17 00:00:00 2001 From: Marius Tomaschewski Date: Tue, 27 Jul 2010 13:34:34 +0000 Subject: [PATCH 1/3] - Fixed ldap option number conflicting with new options (bnc#625358) OBS-URL: https://build.opensuse.org/package/show/network:dhcp/dhcp?expand=0&rev=33 --- ...4.1.1-ldap-patch-mt-01_option-numbers.diff | 57 +++++++++++++++++++ dhcp.changes | 5 ++ dhcp.spec | 4 +- 3 files changed, 65 insertions(+), 1 deletion(-) create mode 100644 dhcp-4.1.1-ldap-patch-mt-01_option-numbers.diff diff --git a/dhcp-4.1.1-ldap-patch-mt-01_option-numbers.diff b/dhcp-4.1.1-ldap-patch-mt-01_option-numbers.diff new file mode 100644 index 0000000..09dafb9 --- /dev/null +++ b/dhcp-4.1.1-ldap-patch-mt-01_option-numbers.diff @@ -0,0 +1,57 @@ +From 68249388d6974933059023eea4cf750688e8a11d Mon Sep 17 00:00:00 2001 +From: Marius Tomaschewski +Date: Tue, 27 Jul 2010 15:27:28 +0200 +Subject: [PATCH] Fixed ldap option numbers conflict + + +diff --git dhcp/includes/dhcpd.h dhcp/includes/dhcpd.h +index 6792497..95c2786 100644 +--- dhcp/includes/dhcpd.h ++++ dhcp/includes/dhcpd.h +@@ -677,25 +677,25 @@ struct lease_state { + #endif + + #if defined(LDAP_CONFIGURATION) +-# define SV_LDAP_SERVER 57 +-# define SV_LDAP_PORT 58 +-# define SV_LDAP_USERNAME 59 +-# define SV_LDAP_PASSWORD 60 +-# define SV_LDAP_BASE_DN 61 +-# define SV_LDAP_METHOD 62 +-# define SV_LDAP_DEBUG_FILE 63 +-# define SV_LDAP_DHCP_SERVER_CN 64 +-# define SV_LDAP_REFERRALS 65 ++# define SV_LDAP_SERVER 60 ++# define SV_LDAP_PORT 61 ++# define SV_LDAP_USERNAME 62 ++# define SV_LDAP_PASSWORD 63 ++# define SV_LDAP_BASE_DN 64 ++# define SV_LDAP_METHOD 65 ++# define SV_LDAP_DEBUG_FILE 66 ++# define SV_LDAP_DHCP_SERVER_CN 67 ++# define SV_LDAP_REFERRALS 68 + #if defined (USE_SSL) +-# define SV_LDAP_SSL 66 +-# define SV_LDAP_TLS_REQCERT 67 +-# define SV_LDAP_TLS_CA_FILE 68 +-# define SV_LDAP_TLS_CA_DIR 69 +-# define SV_LDAP_TLS_CERT 70 +-# define SV_LDAP_TLS_KEY 71 +-# define SV_LDAP_TLS_CRLCHECK 72 +-# define SV_LDAP_TLS_CIPHERS 73 +-# define SV_LDAP_TLS_RANDFILE 74 ++# define SV_LDAP_SSL 69 ++# define SV_LDAP_TLS_REQCERT 70 ++# define SV_LDAP_TLS_CA_FILE 71 ++# define SV_LDAP_TLS_CA_DIR 72 ++# define SV_LDAP_TLS_CERT 73 ++# define SV_LDAP_TLS_KEY 74 ++# define SV_LDAP_TLS_CRLCHECK 75 ++# define SV_LDAP_TLS_CIPHERS 76 ++# define SV_LDAP_TLS_RANDFILE 77 + #endif + #endif + +-- +1.7.1 + diff --git a/dhcp.changes b/dhcp.changes index 37dd6b4..b5ba6e4 100644 --- a/dhcp.changes +++ b/dhcp.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Tue Jul 27 13:31:09 UTC 2010 - mt@suse.de + +- Fixed ldap option number conflicting with new options (bnc#625358) + ------------------------------------------------------------------- Fri Jul 2 10:48:21 UTC 2010 - mt@suse.de diff --git a/dhcp.spec b/dhcp.spec index 9a58221..4bbabbd 100644 --- a/dhcp.spec +++ b/dhcp.spec @@ -33,7 +33,7 @@ License: BSD3c(or similar) Group: Productivity/Networking/Boot/Servers AutoReqProv: on Version: 4.1.1.P1 -Release: 2 +Release: 3 Summary: Common Files Used by ISC DHCP Software Url: http://www.isc.org/software/dhcp Source0: dhcp-%{isc_version}.tar.bz2 @@ -78,6 +78,7 @@ Patch21: dhcp-4.1.1-dhclient-send-hostname-rml.diff ## patch lives here: http://www.suse.de/~mt/git/dhcp-ldap.git/ %if 0%{?with_ldap:1} Patch30: dhcp-4.1.1-ldap-patch-mt-01.diff.bz2 +Patch31: dhcp-4.1.1-ldap-patch-mt-01_option-numbers.diff %else Patch30: dhcp-4.1.1-dhclient-no-libcrypto.diff %endif @@ -201,6 +202,7 @@ Authors: %patch21 -p1 %if 0%{?with_ldap:%with_ldap} %patch30 -p1 +%patch31 -p1 %else %patch30 -p1 %endif From 31ec3f5c01abe532dcc5b69389e93ce38cef508b75b94c3b9a8a5d67cf3757db Mon Sep 17 00:00:00 2001 From: Marius Tomaschewski Date: Tue, 10 Aug 2010 08:05:28 +0000 Subject: [PATCH 2/3] OBS-URL: https://build.opensuse.org/package/show/network:dhcp/dhcp?expand=0&rev=35 --- dhclient-script | 18 +++++++++--------- dhclient.conf | 4 ++-- dhcp.changes | 8 ++++++++ 3 files changed, 19 insertions(+), 11 deletions(-) diff --git a/dhclient-script b/dhclient-script index 60363c8..c86e069 100644 --- a/dhclient-script +++ b/dhclient-script @@ -78,7 +78,7 @@ netconfig_modify() { (new_network_number) k='NETWORK' ;; (new_broadcast_address) k='BROADCAST' ;; (new_interface_mtu) k='MTU' ;; - (new_rfc3442_classless_static_routes) + (new_rfc3442_classless_static_routes_formatted) k='ROUTES' ;; # (new_static_routes) k='ROUTES' ;; (new_routers) k='GATEWAYS' ;; @@ -195,9 +195,9 @@ set_ipv4_route() } get_ipv4_default_gw() { - if [ "x$new_rfc3442_classless_static_routes" != x ] ; then + if [ "x$new_rfc3442_classless_static_routes_formatted" != x ] ; then local r route=() gw=() - for r in $new_rfc3442_classless_static_routes ; do + for r in $new_rfc3442_classless_static_routes_formatted ; do route=(${r//,/ }) case ${route[0]}/${route[1]} in 0.0.0.0/0.0.0.0) @@ -213,10 +213,10 @@ get_ipv4_default_gw() } set_ipv4_routes() { - if [ "x$new_rfc3442_classless_static_routes" != x ] ; then + if [ "x$new_rfc3442_classless_static_routes_formatted" != x ] ; then local r route=() # TODO: multiple gw's to one dest as in $new_routers? - for r in $new_rfc3442_classless_static_routes ; do + for r in $new_rfc3442_classless_static_routes_formatted ; do route=(${r//,/ }) case ${route[0]}/${route[1]} in 0.0.0.0/0.0.0.0) @@ -323,12 +323,12 @@ dhclient) '^[[:space:]]*DHCLIENT_SET_\(HOSTNAME\|DEFAULT_ROUTE\)=' \ "$SYSCONFIG_CFG_DIR/dhcp" 2>/dev/null` fi - if [ "x$new_rfc3442_classless_static_routes_raw" != x ] ; then - new_rfc3442_classless_static_routes=$( - parse_ipv4_classless_routes $new_rfc3442_classless_static_routes_raw + if [ "x$new_rfc3442_classless_static_routes" != x ] ; then + new_rfc3442_classless_static_routes_formatted=$( + parse_ipv4_classless_routes $new_rfc3442_classless_static_routes ) else - unset new_rfc3442_classless_static_routes + unset new_rfc3442_classless_static_routes_formatted fi if [ x$new_broadcast_address != x ] ; then new_broadcast_arg="brd $new_broadcast_address" diff --git a/dhclient.conf b/dhclient.conf index 5bff1d6..2497fa1 100644 --- a/dhclient.conf +++ b/dhclient.conf @@ -30,11 +30,11 @@ # # define classless static route option # -option rfc3442-classless-static-routes_raw code 121 = array of unsigned integer 8; +option rfc3442-classless-static-routes code 121 = array of unsigned integer 8; # Request several well known/usefull dhcp options. request subnet-mask, broadcast-address, routers, - rfc3442-classless-static-routes_raw, + rfc3442-classless-static-routes, interface-mtu, host-name, domain-name, domain-name-servers, nis-domain, nis-servers, nds-context, nds-servers, nds-tree-name, diff --git a/dhcp.changes b/dhcp.changes index b5ba6e4..3d2938e 100644 --- a/dhcp.changes +++ b/dhcp.changes @@ -1,3 +1,11 @@ +------------------------------------------------------------------- +Wed Aug 4 12:52:03 UTC 2010 - mt@suse.de + +- Renamed rfc3442-classless-static-routes_raw in /etc/dhclient.conf + to rfc3442-classless-static-routes for compatibility with the + NetworkManager making use of /etc/dhclient.conf now and adopted + /sbin/dhclient-script (bnc#625770). + ------------------------------------------------------------------- Tue Jul 27 13:31:09 UTC 2010 - mt@suse.de From 8fb0bb9168579c86e4b7311c4fde6ece7eb160dafad5abaf4814b27ccf38510c Mon Sep 17 00:00:00 2001 From: OBS User autobuild Date: Tue, 10 Aug 2010 10:21:53 +0000 Subject: [PATCH 3/3] Accepting request 45247 from network:dhcp checked in (request 45247) OBS-URL: https://build.opensuse.org/request/show/45247 OBS-URL: https://build.opensuse.org/package/show/network:dhcp/dhcp?expand=0&rev=36 --- dhcp.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dhcp.spec b/dhcp.spec index 4bbabbd..d3fdb66 100644 --- a/dhcp.spec +++ b/dhcp.spec @@ -33,7 +33,7 @@ License: BSD3c(or similar) Group: Productivity/Networking/Boot/Servers AutoReqProv: on Version: 4.1.1.P1 -Release: 3 +Release: 6 Summary: Common Files Used by ISC DHCP Software Url: http://www.isc.org/software/dhcp Source0: dhcp-%{isc_version}.tar.bz2