Florian Westphal 71ad00c50d netfilter: nf_tables: fix module unload race
We must first remove the nfnetlink protocol handler when nf_tables module
is unloaded -- we don't want userspace to submit new change requests once
we've started to tear down nft state.

Furthermore, nfnetlink must not call any subsystem function after
call_batch returned -EAGAIN.

EAGAIN means the subsys mutex was dropped, so its unlikely but possible that
nf_tables subsystem was removed due to 'rmmod nf_tables' on another cpu.

Therefore, we must abort batch completely and not move on to next part of
the batch.

Last, we can't invoke ->abort unless we've checked that the subsystem is
still registered.

Change netns exit path of nf_tables to make sure any incompleted
transaction gets removed on exit.

Signed-off-by: Florian Westphal <fw@strlen.de>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
2018-06-12 19:28:18 +02:00
..
2018-05-26 09:16:44 +02:00
2018-05-24 14:22:59 -07:00
2018-05-26 09:16:44 +02:00
2018-03-27 13:18:09 -04:00
2018-05-04 12:54:38 -04:00
2018-06-02 09:55:44 -07:00
2018-05-28 22:59:54 -04:00
2018-06-05 10:21:18 -04:00