From: Florian Westphal Date: Fri, 8 Mar 2024 19:57:26 +0000 (+0100) Subject: tests: shell: add regression test for double-free crash bug X-Git-Tag: v1.1.0~64 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=b237aeff41840f0c7968d02ed3d461fa9fa8fb70;p=thirdparty%2Fnftables.git tests: shell: add regression test for double-free crash bug BUG: KASAN: slab-use-after-free in nf_tables_set_elem_destroy+0x55/0x160 Call Trace: nf_tables_set_elem_destroy+0x55/0x160 nf_tables_set_elem_destroy+0x55/0x160 nft_pipapo_destroy+0x3b4/0x5a0 nft_set_destroy+0x118/0x3a0 nf_tables_trans_destroy_work+0x4f2/0xa80 This is a test case for the bug fiex with kernel commit b0e256f3dd2b ("netfilter: nft_set_pipapo: release elements in clone only from destroy path"). Reported-by: lonial con Signed-off-by: Florian Westphal --- diff --git a/tests/shell/testcases/transactions/concat_range_abort b/tests/shell/testcases/transactions/concat_range_abort new file mode 100755 index 00000000..b2bbe37b --- /dev/null +++ b/tests/shell/testcases/transactions/concat_range_abort @@ -0,0 +1,28 @@ +#!/bin/bash + +# NFT_TEST_REQUIRES(NFT_TEST_HAVE_pipapo) + +set -e + +$NFT -f /dev/stdin <