diff options
author | Eric Dumazet <edumazet@google.com> | 2016-11-09 16:04:46 -0800 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2016-11-21 10:06:40 +0100 |
commit | 5c67f9477bb2122a84ad99f6e6d492bebbdf549b (patch) | |
tree | 67d8eca60ee8823e0e7733e46a5c33f729d81fb0 /net/ipv6/tcp_ipv6.c | |
parent | b67ed647d135d0c0fbb3165d3c7b8c4bd68fe7be (diff) |
net: __skb_flow_dissect() must cap its return value
[ Upstream commit 34fad54c2537f7c99d07375e50cb30aa3c23bd83 ]
After Tom patch, thoff field could point past the end of the buffer,
this could fool some callers.
If an skb was provided, skb->len should be the upper limit.
If not, hlen is supposed to be the upper limit.
Fixes: a6e544b0a88b ("flow_dissector: Jump to exit code in __skb_flow_dissect")
Signed-off-by: Eric Dumazet <edumazet@google.com>
Reported-by: Yibin Yang <yibyang@cisco.com
Acked-by: Alexander Duyck <alexander.h.duyck@intel.com>
Acked-by: Willem de Bruijn <willemb@google.com>
Acked-by: Alexei Starovoitov <ast@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'net/ipv6/tcp_ipv6.c')
0 files changed, 0 insertions, 0 deletions