linux-uconsole/net/llc
Mathias Krause 27fb5ec522 llc: fix info leak via getsockname()
[ Upstream commit 3592aaeb80 ]

The LLC code wrongly returns 0, i.e. "success", when the socket is
zapped. Together with the uninitialized uaddrlen pointer argument from
sys_getsockname this leads to an arbitrary memory leak of up to 128
bytes kernel stack via the getsockname() syscall.

Return an error instead when the socket is zapped to prevent the info
leak. Also remove the unnecessary memset(0). We don't directly write to
the memory pointed by uaddr but memcpy() a local structure at the end of
the function that is properly initialized.

Signed-off-by: Mathias Krause <minipli@googlemail.com>
Cc: Arnaldo Carvalho de Melo <acme@ghostprotocols.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-10-02 09:47:21 -07:00
..
af_llc.c llc: fix info leak via getsockname() 2012-10-02 09:47:21 -07:00
Kconfig
llc_c_ac.c include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h 2010-03-30 22:02:32 +09:00
llc_c_ev.c net: replace remaining __FUNCTION__ occurrences 2008-03-05 20:47:47 -08:00
llc_c_st.c
llc_conn.c include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h 2010-03-30 22:02:32 +09:00
llc_core.c llc: cleanup: remove dead code from llc_init() 2010-03-24 13:34:08 -07:00
llc_if.c include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h 2010-03-30 22:02:32 +09:00
llc_input.c llc: Fix length check in llc_fixup_skb(). 2011-04-11 18:59:05 -07:00
llc_output.c llc: use dev_hard_header 2009-12-26 20:38:23 -08:00
llc_pdu.c [LLC]: skb allocation size for responses 2008-03-31 21:02:47 -07:00
llc_proc.c llc: convert llc_sap_list to RCU 2009-12-26 20:46:28 -08:00
llc_s_ac.c [LLC]: skb allocation size for responses 2008-03-31 21:02:47 -07:00
llc_s_ev.c
llc_s_st.c
llc_sap.c net: Fix FDDI and TR config checks in ipv4 arp and LLC. 2010-05-10 04:59:07 -07:00
llc_station.c net/llc: storing negative error codes in unsigned short 2010-09-16 22:38:23 -07:00
Makefile
sysctl_net_llc.c sysctl net: Remove unused binary sysctl code 2009-11-12 02:05:06 -08:00