]> git.ipfire.org Git - thirdparty/dhcp.git/commitdiff
- Two uninitialized stack structures are now memset to zero. [ISC-Bugs #17737]
authorDavid Hankins <dhankins@isc.org>
Fri, 20 Feb 2009 00:09:24 +0000 (00:09 +0000)
committerDavid Hankins <dhankins@isc.org>
Fri, 20 Feb 2009 00:09:24 +0000 (00:09 +0000)
RELNOTES
common/lpf.c
common/packet.c

index 50064319f173011ca527d9d5734f4efb3fe3a6f5..502f365dc61f65a44dace040ad975708306f4363 100644 (file)
--- a/RELNOTES
+++ b/RELNOTES
@@ -70,6 +70,8 @@ work on other platforms. Please report any problems and suggested fixes to
 - Fix a build error in dhcrelay, using older versions of gcc with
   dhcpv6 disabled.
 
+- Two uninitialized stack structures are now memset to zero.
+
                        Changes since 4.1.0b1
 
 - A missing "else" in dhcrelay.c could have caused an interface not to
index 5dda6fa517f9503ce79b0c8c28782a831fed3834..2269f01947a75391b592d16c075d034a9eadfb33 100644 (file)
@@ -4,7 +4,7 @@
    Support Services in Vancouver, B.C. */
 
 /*
- * Copyright (c) 2004,2007 by Internet Systems Consortium, Inc. ("ISC")
+ * Copyright (c) 2004,2007,2009 by Internet Systems Consortium, Inc. ("ISC")
  * Copyright (c) 1996-2003 by Internet Software Consortium
  *
  * Permission to use, copy, modify, and distribute this software for any
@@ -248,6 +248,8 @@ static void lpf_tr_filter_setup (info)
 {
        struct sock_fprog p;
 
+       memset(&p, 0, sizeof(p));
+
        /* Set up the bpf filter program structure.    This is defined in
           bpf.c */
        p.len = dhcp_bpf_tr_filter_len;
index 3e1c91b44c0626fef05a433420564441f00f9b48..67365f797b91f36b41472327fb9b3a4d5b1c3e65 100644 (file)
@@ -3,7 +3,7 @@
    Packet assembly code, originally contributed by Archie Cobbs. */
 
 /*
- * Copyright (c) 2004,2005,2007 by Internet Systems Consortium, Inc. ("ISC")
+ * Copyright (c) 2004,2005,2007,2009 by Internet Systems Consortium, Inc. ("ISC")
  * Copyright (c) 1996-2003 by Internet Software Consortium
  *
  * Permission to use, copy, modify, and distribute this software for any
@@ -135,6 +135,8 @@ void assemble_udp_ip_header (interface, buf, bufix,
        struct ip ip;
        struct udphdr udp;
 
+       memset (&ip, 0, sizeof ip);
+
        /* Fill out the IP header */
        IP_V_SET (&ip, 4);
        IP_HL_SET (&ip, 20);