diff options
author | John Hurley <john.hurley@netronome.com> | 2019-07-10 19:30:30 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2019-07-12 15:31:55 -0700 |
commit | 103b7c25f5a2509ddccec830df924a78354232c4 (patch) | |
tree | b159b6e658ffab1ec7118221c04efead541d390a /fs/ext2/file.c | |
parent | fd262a6d8a5d8d504e6a0b0183a05deda6bef7a3 (diff) | |
download | linux-103b7c25f5a2509ddccec830df924a78354232c4.tar.bz2 |
nfp: flower: ensure ip protocol is specified for L4 matches
Flower rules on the NFP firmware are able to match on an IP protocol
field. When parsing rules in the driver, unknown IP protocols are only
rejected when further matches are to be carried out on layer 4 fields, as
the firmware will not be able to extract such fields from packets.
L4 protocol dissectors such as FLOW_DISSECTOR_KEY_PORTS are only parsed if
an IP protocol is specified. This leaves a loophole whereby a rule that
attempts to match on transport layer information such as port numbers but
does not explicitly give an IP protocol type can be incorrectly offloaded
(in this case with wildcard port numbers matches).
Fix this by rejecting the offload of flows that attempt to match on L4
information, not only when matching on an unknown IP protocol type, but
also when the protocol is wildcarded.
Fixes: 2a04784594f6 ("nfp: flower: check L4 matches on unknown IP protocols")
Signed-off-by: John Hurley <john.hurley@netronome.com>
Reviewed-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'fs/ext2/file.c')
0 files changed, 0 insertions, 0 deletions