Page MenuHomeFreeBSD

D14912.id40928.diff
No OneTemporary

D14912.id40928.diff

Index: sys/net/if.c
===================================================================
--- sys/net/if.c
+++ sys/net/if.c
@@ -3122,10 +3122,10 @@
int addrs;
/*
- * Zero the ifr_name buffer to make sure we don't
- * disclose the contents of the stack.
+ * Zero the ifr to make sure we don't disclose the contents
+ * of the stack.
*/
- memset(ifr.ifr_name, 0, sizeof(ifr.ifr_name));
+ memset(&ifr, 0, sizeof(ifr));
if (strlcpy(ifr.ifr_name, ifp->if_xname, sizeof(ifr.ifr_name))
>= sizeof(ifr.ifr_name)) {
@@ -3159,7 +3159,6 @@
}
IF_ADDR_RUNLOCK(ifp);
if (addrs == 0) {
- bzero((caddr_t)&ifr.ifr_addr, sizeof(ifr.ifr_addr));
sbuf_bcat(sb, &ifr, sizeof(ifr));
max_len += sizeof(ifr);

File Metadata

Mime Type
text/plain
Expires
Sat, Nov 23, 9:48 AM (9 h, 25 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
14796837
Default Alt Text
D14912.id40928.diff (736 B)

Event Timeline