linux-stable-rt/net/netfilter/ipvs
Arjan van de Ven 04bcef2a83 ipvs: Add boundary check on ioctl arguments
The ipvs code has a nifty system for doing the size of ioctl command
copies; it defines an array with values into which it indexes the cmd
to find the right length.

Unfortunately, the ipvs code forgot to check if the cmd was in the
range that the array provides, allowing for an index outside of the
array, which then gives a "garbage" result into the length, which
then gets used for copying into a stack buffer.

Fix this by adding sanity checks on these as well as the copy size.

[ horms@verge.net.au: adjusted limit to IP_VS_SO_GET_MAX ]
Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Patrick McHardy <kaber@trash.net>
2010-01-04 16:37:12 +01:00
..
Kconfig ipvs: ip_vs_wrr.c: use lib/gcd.c 2009-12-22 09:42:06 +01:00
Makefile
ip_vs_app.c
ip_vs_conn.c
ip_vs_core.c ipvs: fix synchronization on connection close 2009-12-14 16:38:21 +01:00
ip_vs_ctl.c ipvs: Add boundary check on ioctl arguments 2010-01-04 16:37:12 +01:00
ip_vs_dh.c
ip_vs_est.c
ip_vs_ftp.c
ip_vs_lblc.c sysctl net: Remove unused binary sysctl code 2009-11-12 02:05:06 -08:00
ip_vs_lblcr.c sysctl net: Remove unused binary sysctl code 2009-11-12 02:05:06 -08:00
ip_vs_lc.c
ip_vs_nq.c
ip_vs_proto.c
ip_vs_proto_ah_esp.c
ip_vs_proto_tcp.c
ip_vs_proto_udp.c
ip_vs_rr.c
ip_vs_sched.c
ip_vs_sed.c
ip_vs_sh.c
ip_vs_sync.c
ip_vs_wlc.c
ip_vs_wrr.c ipvs: ip_vs_wrr.c: use lib/gcd.c 2009-12-22 09:42:06 +01:00
ip_vs_xmit.c