Files
Saeed Mirzamohammadi 10cf2d801e netfilter: nftables_offload: KASAN slab-out-of-bounds Read in nft_flow_rule_create
commit 31cc578ae2 upstream.

This patch fixes the issue due to:

BUG: KASAN: slab-out-of-bounds in nft_flow_rule_create+0x622/0x6a2
net/netfilter/nf_tables_offload.c:40
Read of size 8 at addr ffff888103910b58 by task syz-executor227/16244

The error happens when expr->ops is accessed early on before performing the boundary check and after nft_expr_next() moves the expr to go out-of-bounds.

This patch checks the boundary condition before expr->ops that fixes the slab-out-of-bounds Read issue.

Add nft_expr_more() and use it to fix this problem.

Signed-off-by: Saeed Mirzamohammadi <saeed.mirzamohammadi@oracle.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-11-01 12:47:00 +01:00
..
…
…
…
…
…
…
…
…
…
…
2020-05-05 13:23:29 -07:00
…
…
2019-12-09 10:36:44 -08:00
…
…
…
2020-06-22 21:12:44 -07:00
…
…
2020-07-19 19:20:22 -07:00
…
2020-07-24 15:41:54 -07:00
…
…
…
…
…
…
…
2019-12-09 10:36:44 -08:00
…
2020-10-02 13:00:38 -07:00
…
…
…
2020-03-04 13:25:55 -08:00
…
…
…
…
…
…
…
2020-03-23 21:57:44 -07:00
…
…
…
…
…
…
…
…
2020-06-18 20:46:23 -07:00
…
…
2019-12-09 10:28:43 -08:00
2020-07-13 15:32:56 -07:00