summaryrefslogtreecommitdiffstats
path: root/include/iptables.h
diff options
context:
space:
mode:
authorRusty Russell <rusty@linuxcare.com.au>2000-05-02 16:45:16 +0000
committerRusty Russell <rusty@rustcorp.com.au>2000-05-02 16:45:16 +0000
commit79dee0702b18c8ea1d1f7a2b1f6b29349466986b (patch)
treed137896a13b5d5ca59461b78b4e1abe7b231f334 /include/iptables.h
parent52a5149d58d027168b86855106f975a2364e7505 (diff)
IPv6 enhancements.
Diffstat (limited to 'include/iptables.h')
-rw-r--r--include/iptables.h28
1 files changed, 11 insertions, 17 deletions
diff --git a/include/iptables.h b/include/iptables.h
index 1ddd8712..886d576b 100644
--- a/include/iptables.h
+++ b/include/iptables.h
@@ -1,6 +1,7 @@
#ifndef _IPTABLES_USER_H
#define _IPTABLES_USER_H
+#include "iptables_common.h"
#include "libiptc/libiptc.h"
/* Include file for additions: new matches and targets. */
@@ -38,7 +39,7 @@ struct iptables_match
void (*print)(const struct ipt_ip *ip,
const struct ipt_entry_match *match, int numeric);
- /* Saves the union ipt_matchinfo in parsable form to stdout. */
+ /* Saves the match info in parsable form to stdout. */
void (*save)(const struct ipt_ip *ip,
const struct ipt_entry_match *match);
@@ -101,21 +102,8 @@ struct iptables_target
extern void register_match(struct iptables_match *me);
extern void register_target(struct iptables_target *me);
-/* Functions we share */
-enum exittype {
- OTHER_PROBLEM = 1,
- PARAMETER_PROBLEM,
- VERSION_PROBLEM
-};
-extern void exit_printhelp() __attribute__((noreturn));
-extern void exit_tryhelp(int) __attribute__((noreturn));
-int check_inverse(const char option[], int *invert);
-extern int string_to_number(const char *, int, int);
-void exit_error(enum exittype, char *, ...)__attribute__((noreturn,
- format(printf,2,3)));
+extern struct in_addr *dotted_to_addr(const char *dotted);
extern char *addr_to_dotted(const struct in_addr *addrp);
-struct in_addr *dotted_to_addr(const char *dotted);
-extern const char *program_name, *program_version;
extern int do_command(int argc, char *argv[], char **table,
iptc_handle_t *handle);
@@ -123,6 +111,12 @@ extern int do_command(int argc, char *argv[], char **table,
extern struct iptables_match *iptables_matches;
extern struct iptables_target *iptables_targets;
-extern struct iptables_target *find_target(const char *name, int tryload);
-extern struct iptables_match *find_match(const char *name, int tryload);
+enum ipt_tryload {
+ DONT_LOAD,
+ TRY_LOAD,
+ LOAD_MUST_SUCCEED
+};
+
+extern struct iptables_target *find_target(const char *name, enum ipt_tryload);
+extern struct iptables_match *find_match(const char *name, enum ipt_tryload);
#endif /*_IPTABLES_USER_H*/