linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] fix infoleak in wilc_wfi_cfgoperations
@ 2016-05-04  1:36 Kangjie Lu
  0 siblings, 0 replies; only message in thread
From: Kangjie Lu @ 2016-05-04  1:36 UTC (permalink / raw)
  To: johnny.kim
  Cc: austin.shin, chris.park, gregkh, devel, linux-kernel,
	linux-wireless, taesoo, insu, csong84, Kangjie Lu

"mac" is an array allocated in stack without being initialized,
and will be sent out via "nla_put". The dump_station() is supposed
to initialize the mac address; otherwise, sensitive data in kernel
stack will be leaked. To fix this, copy the mac address to it.

Signed-off-by: Kangjie Lu <kjlu@gatech.edu>
---
 drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c b/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
index 448a5c8..c6e71d9 100644
--- a/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
+++ b/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
@@ -1797,6 +1797,7 @@ static int dump_station(struct wiphy *wiphy, struct net_device *dev,
 
 	wilc_get_rssi(vif, &sinfo->signal);
 
+	memcpy(mac, priv->au8AssociatedBss, ETH_ALEN);
 	return 0;
 }
 
-- 
1.9.1


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2016-05-04  1:33 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-05-04  1:36 [PATCH] fix infoleak in wilc_wfi_cfgoperations Kangjie Lu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).