linux/drivers/staging/rtl8192u/ieee80211
Peter Huewe 67a88e6390 staging/rtl8192u/ieee80211: Fix buffer overflow in ieee80211_softmac_wx.c
Clang/scan-build complains about a possible buffer overflow in
ieee80211_wx_get_name:

.../staging/rtl8192u/ieee80211/ieee80211_softmac_wx.c:499:3:
warning: String copy function overflows destination buffer
	strcat(wrqu->name," link..");

.../staging/rtl8192u/ieee80211/ieee80211_softmac_wx.c:497:3:
warning: String copy function overflows destination buffer
	strcat(wrqu->name," linked");

The buffer wrqu->name is only IFNAMSIZ bytes big (currently 16),
so if we have a "802.11b/g/n linked" device we overrun the buffer by 3
bytes.

-> Use strlcopy / strlcat to populate the name.
This is done in a similar fashion in
staging/rtl8187se/ieee80211/ieee80211_softmac_wx.c

While at it cleaned some whitespace issues.

Signed-off-by: Peter Huewe <peterhuewe@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-02-14 09:26:23 -08:00
..
EndianFree.h
Makefile
aes.c
arc4.c
autoload.c
cipher.c
compress.c
crypto_compat.h
digest.c
dot11d.c
dot11d.h
ieee80211.h staging/rtl8192u: indent with tabs, not spaces 2013-01-07 12:53:40 -08:00
ieee80211_crypt.c
ieee80211_crypt.h
ieee80211_crypt_ccmp.c
ieee80211_crypt_tkip.c
ieee80211_crypt_wep.c
ieee80211_module.c staging/rtl8192u: don't init globals to 0 or NULL 2013-01-07 12:53:41 -08:00
ieee80211_rx.c staging/rtl8192u: indent with tabs, not spaces 2013-01-07 12:53:40 -08:00
ieee80211_softmac.c staging/rtl8192u: do not init statics to 0 2013-01-07 12:53:41 -08:00
ieee80211_softmac_wx.c staging/rtl8192u/ieee80211: Fix buffer overflow in ieee80211_softmac_wx.c 2013-02-14 09:26:23 -08:00
ieee80211_tx.c staging/rtl8192u: use same indent for switch and case 2013-01-07 12:53:41 -08:00
ieee80211_wx.c staging/rtl8192u: use same indent for switch and case 2013-01-07 12:53:41 -08:00
internal.h
michael_mic.c
proc.c
rtl819x_BA.h
rtl819x_BAProc.c
rtl819x_HT.h
rtl819x_HTProc.c
rtl819x_Qos.h
rtl819x_TS.h
rtl819x_TSProc.c
rtl_crypto.h staging/rtl8192u: indent with tabs, not spaces 2013-01-07 12:53:40 -08:00
scatterwalk.c
scatterwalk.h