/[gentoo-x86]/net-misc/selfdhcp/files/selfdhcp-0.2a-buffer-overflow.patch
Gentoo

Contents of /net-misc/selfdhcp/files/selfdhcp-0.2a-buffer-overflow.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (show annotations) (download)
Sat Mar 3 15:44:30 2012 UTC (2 years, 7 months ago) by pacho
Branch: MAIN
CVS Tags: HEAD
Fix overflow, bug #337520 by flameeyes and fix by Kevin McCarthy.

(Portage version: 2.1.10.49/cvs/Linux x86_64)

1 --- selfdhcp-0.2a.orig/src/selfdhcp_profiles.c 2004-08-02 18:10:36.000000000 -0400
2 +++ selfdhcp-0.2a/src/selfdhcp_profiles.c 2011-01-29 11:54:29.132199679 -0500
3 @@ -345,7 +345,7 @@
4 {
5 key = xmlNodeListGetString (doc, cur->xmlChildrenNode, 1);
6 err_msg (DBG_PROG, "xml element \"%s\"", (char *) key);
7 - strncpy (netconf_buff.domainname, (char *) key, 49);
8 + strncpy (netconf_buff.domainname, (char *) key, sizeof(netconf_buff.domainname)-1);
9 netconf_buff.what_is_set &= NETADDR;
10 err_msg (DBG_INFO, "read domain name \"%s\"",
11 netconf_buff.domainname);

  ViewVC Help
Powered by ViewVC 1.1.20