aboutsummaryrefslogtreecommitdiffstats
path: root/net/xfrm/xfrm_interface_core.c
diff options
context:
space:
mode:
authorHerbert Xu <[email protected]>2023-07-04 00:53:49 +0000
committerSteffen Klassert <[email protected]>2023-07-10 09:57:28 +0000
commit57010b8ece2821a1fdfdba2197d14a022f3769db (patch)
tree7b6414a61b50bf4c48a0e7b42ba641ffbbc78c31 /net/xfrm/xfrm_interface_core.c
parentnet: xfrm: Amend XFRMA_SEC_CTX nla_policy structure (diff)
downloadkernel-57010b8ece2821a1fdfdba2197d14a022f3769db.tar.gz
kernel-57010b8ece2821a1fdfdba2197d14a022f3769db.zip
xfrm: Silence warnings triggerable by bad packets
After the elimination of inner modes, a couple of warnings that were previously unreachable can now be triggered by malformed inbound packets. Fix this by: 1. Moving the setting of skb->protocol into the decap functions. 2. Returning -EINVAL when unexpected protocol is seen. Reported-by: Maciej Żenczykowski<[email protected]> Fixes: 5f24f41e8ea6 ("xfrm: Remove inner/outer modes from input path") Signed-off-by: Herbert Xu <[email protected]> Reviewed-by: Maciej Żenczykowski <[email protected]> Signed-off-by: Steffen Klassert <[email protected]>
Diffstat (limited to 'net/xfrm/xfrm_interface_core.c')
0 files changed, 0 insertions, 0 deletions