summaryrefslogtreecommitdiff
path: root/src/connman.h
diff options
context:
space:
mode:
authorDaniel Wagner <daniel.wagner@bmw-carit.de>2013-03-19 13:46:29 +0100
committerPatrik Flykt <patrik.flykt@linux.intel.com>2013-03-25 13:17:57 +0200
commit6caa1417f6c8b2e1460915f2372f333c4b218ac7 (patch)
tree62ac77da9c7832b22d0fc3ac676c6f19cd0a0159 /src/connman.h
parenta0b5c505ec9e42811bfe3b398b7b074cd7aab355 (diff)
downloadconnman-6caa1417f6c8b2e1460915f2372f333c4b218ac7.tar.gz
connman-6caa1417f6c8b2e1460915f2372f333c4b218ac7.tar.bz2
connman-6caa1417f6c8b2e1460915f2372f333c4b218ac7.zip
iptables: Add chain iterator
We will implement the ConnMan iptables specific part in a different file and leave the iptables.c file as small as possible. Therefore, we move the flushing part out, but we need a way to find our chains on bootup (left over from a crash). Let's add an interater which walks over all chains which allows a higher level to find the chains it is looking for (e.g. connman-INPUT)
Diffstat (limited to 'src/connman.h')
-rw-r--r--src/connman.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/connman.h b/src/connman.h
index 8e26304b..6b81477a 100644
--- a/src/connman.h
+++ b/src/connman.h
@@ -810,6 +810,12 @@ int __connman_iptables_delete(const char *table_name,
const char *chain,
const char *rule_spec);
+typedef void (*connman_iptables_iterate_chains_cb_t) (const char *chain_name,
+ void *user_data);
+int __connman_iptables_iterate_chains(const char *table_name,
+ connman_iptables_iterate_chains_cb_t cb,
+ void *user_data);
+
int __connman_iptables_init(void);
void __connman_iptables_cleanup(void);
int __connman_iptables_commit(const char *table_name);