diff options
| author | Willem de Bruijn <willemb@google.com> | 2019-04-29 11:53:18 -0400 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-05-16 19:45:00 +0200 |
| commit | c6ae8a5a4396bb557fdd3bf7778e9d33cc623f20 (patch) | |
| tree | 142bee8c6bd7ea338a57f7e19bf3742362d45168 /tools | |
| parent | aed15cc2ced6d483fe577dfe981d3a9174b2c39b (diff) | |
packet: validate msg_namelen in send directly
[ Upstream commit 486efdc8f6ce802b27e15921d2353cc740c55451 ]
Packet sockets in datagram mode take a destination address. Verify its
length before passing to dev_hard_header.
Prior to 2.6.14-rc3, the send code ignored sll_halen. This is
established behavior. Directly compare msg_namelen to dev->addr_len.
Change v1->v2: initialize addr in all paths
Fixes: 6b8d95f1795c4 ("packet: validate address length if non-zero")
Suggested-by: David Laight <David.Laight@aculab.com>
Signed-off-by: Willem de Bruijn <willemb@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'tools')
0 files changed, 0 insertions, 0 deletions
