From ea27bb406e3d8fe9466ba274af38e6f540ff5bfc Mon Sep 17 00:00:00 2001 From: Alexander Wirt Date: Sun, 3 Jun 2012 08:49:55 +0200 Subject: Imported Upstream version 1.2.1 --- include/internal.h | 59 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 include/internal.h (limited to 'include/internal.h') diff --git a/include/internal.h b/include/internal.h new file mode 100644 index 0000000..2ba9714 --- /dev/null +++ b/include/internal.h @@ -0,0 +1,59 @@ +#ifndef _INTERNAL_H_ +#define _INTERNAL_H_ + +#include + +struct nf_conntrack; + +enum { + INTERNAL_F_POPULATE = (1 << 0), + INTERNAL_F_RESYNC = (1 << 1), + INTERNAL_F_MAX = (1 << 2) +}; + +struct internal_handler { + unsigned int flags; + + int (*init)(void); + void (*close)(void); + + struct { + void *data; + + void (*new)(struct nf_conntrack *ct, int origin_type); + void (*upd)(struct nf_conntrack *ct, int origin_type); + int (*del)(struct nf_conntrack *ct, int origin_type); + + void (*dump)(int fd, int type); + void (*populate)(struct nf_conntrack *ct); + void (*purge)(void); + int (*resync)(enum nf_conntrack_msg_type type, + struct nf_conntrack *ct, void *data); + void (*flush)(void); + + void (*stats)(int fd); + void (*stats_ext)(int fd); + } ct; + struct { + void *data; + + void (*new)(struct nf_expect *exp, int origin_type); + void (*upd)(struct nf_expect *exp, int origin_type); + int (*del)(struct nf_expect *exp, int origin_type); + + void (*dump)(int fd, int type); + void (*populate)(struct nf_expect *exp); + void (*purge)(void); + int (*resync)(enum nf_conntrack_msg_type type, + struct nf_expect *exp, void *data); + void (*flush)(void); + + void (*stats)(int fd); + void (*stats_ext)(int fd); + } exp; +}; + +extern struct internal_handler internal_cache; +extern struct internal_handler internal_bypass; + +#endif -- cgit v1.2.3