]> www.infradead.org Git - users/willy/linux.git/commit
netfilter: ipset: Hold module reference while requesting a module
authorPhil Sutter <phil@nwl.cc>
Fri, 29 Nov 2024 15:30:38 +0000 (16:30 +0100)
committerPablo Neira Ayuso <pablo@netfilter.org>
Wed, 4 Dec 2024 14:39:22 +0000 (15:39 +0100)
commit456f010bfaefde84d3390c755eedb1b0a5857c3c
tree91bf2f49fc03be087674f0b33deb94c875ff6959
parent7b1d83da254be3bf054965c8f3b1ad976f460ae5
netfilter: ipset: Hold module reference while requesting a module

User space may unload ip_set.ko while it is itself requesting a set type
backend module, leading to a kernel crash. The race condition may be
provoked by inserting an mdelay() right after the nfnl_unlock() call.

Fixes: a7b4f989a629 ("netfilter: ipset: IP set core support")
Signed-off-by: Phil Sutter <phil@nwl.cc>
Acked-by: Jozsef Kadlecsik <kadlec@netfilter.org>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
net/netfilter/ipset/ip_set_core.c