rpms/dhcp/devel dhcp-4.1.0-IFNAMSIZ.patch, NONE, 1.1 dhcp.spec, 1.253, 1.254

David Cantrell dcantrel at fedoraproject.org
Tue Apr 21 02:40:03 UTC 2009


Author: dcantrel

Update of /cvs/pkgs/rpms/dhcp/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv21555

Modified Files:
	dhcp.spec 
Added Files:
	dhcp-4.1.0-IFNAMSIZ.patch 
Log Message:
* Mon Apr 20 2009 David Cantrell <dcantrell at redhat.com> - 12:4.1.0-19
- Restrict interface names given on the dhcpd command line to length
  IFNAMSIZ or shorter (#441524)


dhcp-4.1.0-IFNAMSIZ.patch:

--- NEW FILE dhcp-4.1.0-IFNAMSIZ.patch ---
diff -up dhcp-4.1.0/server/dhcpd.c.ifnamsiz dhcp-4.1.0/server/dhcpd.c
--- dhcp-4.1.0/server/dhcpd.c.ifnamsiz	2009-04-20 16:35:30.000000000 -1000
+++ dhcp-4.1.0/server/dhcpd.c	2009-04-20 15:45:15.000000000 -1000
@@ -401,7 +401,7 @@ main(int argc, char **argv) {
 				log_fatal ("Insufficient memory to %s %s: %s",
 					   "record interface", argv [i],
 					   isc_result_totext (result));
-			strcpy (tmp -> name, argv [i]);
+			strncpy (tmp -> name, argv [i], sizeof (tmp -> name));
 			if (interfaces) {
 				interface_reference (&tmp -> next,
 						     interfaces, MDL);


Index: dhcp.spec
===================================================================
RCS file: /cvs/pkgs/rpms/dhcp/devel/dhcp.spec,v
retrieving revision 1.253
retrieving revision 1.254
diff -u -r1.253 -r1.254
--- dhcp.spec	21 Apr 2009 01:14:15 -0000	1.253
+++ dhcp.spec	21 Apr 2009 02:39:32 -0000	1.254
@@ -10,7 +10,7 @@
 Summary:  Dynamic host configuration protocol software
 Name:     dhcp
 Version:  4.1.0
-Release:  18%{?dist}
+Release:  19%{?dist}
 # NEVER CHANGE THE EPOCH on this package.  The previous maintainer (prior to
 # dcantrell maintaining the package) made incorrect use of the epoch and
 # that's why it is at 12 now.  It should have never been used, but it was.
@@ -45,6 +45,7 @@
 Patch16:  %{name}-4.1.0-port-validation.patch
 Patch17:  %{name}-4.1.0-invalid-dhclient-conf.patch
 Patch18:  %{name}-4.1.0-missing-ipv6-not-fatal.patch
+Patch19:  %{name}-4.1.0-IFNAMSIZ.patch
 
 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 BuildRequires: autoconf
@@ -187,6 +188,9 @@
 # (Submitted to dhcp-bugs at isc.org - [ISC-Bugs #19367]
 %patch18 -p1
 
+# Read only up to IFNAMSIZ characters for the interface name in dhcpd (#441524)
+%patch19 -p1
+
 # Copy in documentation and example scripts for LDAP patch to dhcpd
 %{__install} -p -m 0755 ldap-for-dhcp-%{ldappatchver}/dhcpd-conf-to-ldap contrib/
 
@@ -419,6 +423,10 @@
 %attr(0644,root,root) %{_mandir}/man3/omapi.3.gz
 
 %changelog
+* Mon Apr 20 2009 David Cantrell <dcantrell at redhat.com> - 12:4.1.0-19
+- Restrict interface names given on the dhcpd command line to length
+  IFNAMSIZ or shorter (#441524)
+
 * Mon Apr 20 2009 David Cantrell <dcantrell at redhat.com> - 12:4.1.0-18
 - Make dhclient-script work with pre-configured wireless interfaces (#491157)
 




More information about the fedora-extras-commits mailing list