irda: validate peer name and attribute lengths
authorDan Rosenberg <drosenberg@vsecurity.com>
Sun, 20 Mar 2011 15:32:06 +0000 (15:32 +0000)
committerWilly Tarreau <w@1wt.eu>
Sat, 30 Apr 2011 14:53:26 +0000 (16:53 +0200)
commitfa06b46ce9ab258e3815eb39354b30781fb48aa4
tree84a8292d28e1e873f01a0e7bdeba790f081a1adc
parentc598f77065980e6ee1d374cf5e862c60563e33cf
irda: validate peer name and attribute lengths

commit d370af0ef7951188daeb15bae75db7ba57c67846 upstream.

Length fields provided by a peer for names and attributes may be longer
than the destination array sizes.  Validate lengths to prevent stack
buffer overflows.

Signed-off-by: Dan Rosenberg <drosenberg@vsecurity.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
net/irda/iriap.c