]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
netfilter: nft_payload: do not truncate csum_offset and csum_type
authorPablo Neira Ayuso <pablo@netfilter.org>
Sun, 21 Aug 2022 09:55:19 +0000 (11:55 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 31 Aug 2022 15:18:07 +0000 (17:18 +0200)
commit09cd8ecf3107efc4dcfb124a3079635c33965002
tree689bfa2a07d37f5e091ef6e316e75f354e7bce6f
parent0ee5c638e108de9fcf699f975a26747b09a0a5ac
netfilter: nft_payload: do not truncate csum_offset and csum_type

[ Upstream commit 7044ab281febae9e2fa9b0b247693d6026166293 ]

Instead report ERANGE if csum_offset is too long, and EOPNOTSUPP if type
is not support.

Fixes: 7ec3f7b47b8d ("netfilter: nft_payload: add packet mangling support")
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
net/netfilter/nft_payload.c