netfilter-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH iptables v2]: Support the iptables lock in ip[6]tables-restore
@ 2017-03-16  7:55 Lorenzo Colitti
  2017-03-16  7:55 ` [PATCH iptables v2 1/2] iptables: remove duplicated argument parsing code Lorenzo Colitti
  2017-03-16  7:55 ` [PATCH iptables v2 2/2] iptables-restore: support acquiring the lock Lorenzo Colitti
  0 siblings, 2 replies; 7+ messages in thread
From: Lorenzo Colitti @ 2017-03-16  7:55 UTC (permalink / raw)
  To: netfilter-devel; +Cc: pablo, jscherpelz, subashab, zlpnobody

This series adds support for -w and -W to ip[6]tables-restore,
which currently do not perform any locking.

The lock is not acquired on startup. Instead, it is acquired when
a new table handle is created (on encountering '*') and released
when the table is committed (COMMIT). This makes it possible to
keep long-running iptables-restore processes in the background
(for example, reading commands from a pipe opened by a system
management daemon) and simultaneously run iptables commands.
An example usage is Android's IptablesRestoreController.cpp.

The first patch factors out to common functions the code that
parses -w and -W, in order not to have to add more copies of it.
The second patch actually adds support to iptables-restore.


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2017-03-21 13:54 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-03-16  7:55 [PATCH iptables v2]: Support the iptables lock in ip[6]tables-restore Lorenzo Colitti
2017-03-16  7:55 ` [PATCH iptables v2 1/2] iptables: remove duplicated argument parsing code Lorenzo Colitti
2017-03-17 13:14   ` Pablo Neira Ayuso
2017-03-16  7:55 ` [PATCH iptables v2 2/2] iptables-restore: support acquiring the lock Lorenzo Colitti
2017-03-17 13:20   ` Pablo Neira Ayuso
2017-03-17 16:46     ` Lorenzo Colitti
2017-03-21 13:54   ` Pablo Neira Ayuso

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).