diff options
| author | Jiri Benc <[email protected]> | 2014-08-21 19:33:44 +0000 |
|---|---|---|
| committer | David S. Miller <[email protected]> | 2014-08-22 18:24:04 +0000 |
| commit | 2ba5af42a7b59ef01f9081234d8855140738defd (patch) | |
| tree | f37c603b7da12aa2a07db4094ea6b524a89d2844 /lib/assoc_array.c | |
| parent | net: ipv6: fib: don't sleep inside atomic lock (diff) | |
| download | kernel-2ba5af42a7b59ef01f9081234d8855140738defd.tar.gz kernel-2ba5af42a7b59ef01f9081234d8855140738defd.zip | |
openvswitch: fix panic with multiple vlan headers
When there are multiple vlan headers present in a received frame, the first
one is put into vlan_tci and protocol is set to ETH_P_8021Q. Anything in the
skb beyond the VLAN TPID may be still non-linear, including the inner TCI
and ethertype. While ovs_flow_extract takes care of IP and IPv6 headers, it
does nothing with ETH_P_8021Q. Later, if OVS_ACTION_ATTR_POP_VLAN is
executed, __pop_vlan_tci pulls the next vlan header into vlan_tci.
This leads to two things:
1. Part of the resulting ethernet header is in the non-linear part of the
skb. When eth_type_trans is called later as the result of
OVS_ACTION_ATTR_OUTPUT, kernel BUGs in __skb_pull. Also, __pop_vlan_tci
is in fact accessing random data when it reads past the TPID.
2. network_header points into the ethernet header instead of behind it.
mac_len is set to a wrong value (10), too.
Reported-by: Yulong Pei <[email protected]>
Signed-off-by: Jiri Benc <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'lib/assoc_array.c')
0 files changed, 0 insertions, 0 deletions
