diff options
author | Benjamin Berg <benjamin.berg@intel.com> | 2023-09-25 17:18:56 +0200 |
---|---|---|
committer | Alexander Grund <flamefire89@gmail.com> | 2024-01-06 13:23:24 +0100 |
commit | 842bfdb1fe91b78e1bdf51787b735a54498d141f (patch) | |
tree | a50a14bc9416ca62057ad912483018c5274497b0 | |
parent | 9af33e9d545d7ed0b02c3a935eb41816902bc1e7 (diff) |
wifi: cfg80211: avoid leaking stack data into trace
[ Upstream commit 334bf33eec5701a1e4e967bcb7cc8611a998334b ]
If the structure is not initialized then boolean types might be copied
into the tracing data without being initialised. This causes data from
the stack to leak into the trace and also triggers a UBSAN failure which
can easily be avoided here.
Change-Id: I878101c0eacd55669bc316ebf3cad14da7c6acdf
Signed-off-by: Benjamin Berg <benjamin.berg@intel.com>
Link: https://lore.kernel.org/r/20230925171855.a9271ef53b05.I8180bae663984c91a3e036b87f36a640ba409817@changeid
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Ulrich Hecht <uli@kernel.org>
-rw-r--r-- | net/wireless/nl80211.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c index 780cf7bf841e..24331160f3be 100644 --- a/net/wireless/nl80211.c +++ b/net/wireless/nl80211.c @@ -5886,7 +5886,7 @@ static int nl80211_update_mesh_config(struct sk_buff *skb, struct cfg80211_registered_device *rdev = info->user_ptr[0]; struct net_device *dev = info->user_ptr[1]; struct wireless_dev *wdev = dev->ieee80211_ptr; - struct mesh_config cfg; + struct mesh_config cfg = {}; u32 mask; int err; |