]> err.no Git - linux-2.6/blobdiff - include/net/netfilter/nf_conntrack.h
Merge master.kernel.org:/pub/scm/linux/kernel/git/torvalds/linux-2.6
[linux-2.6] / include / net / netfilter / nf_conntrack.h
index b2083d386f334de0976e84c1878f0ea54ff8ff69..90fb66d99d0c1a25ead5470b74e2c153cc4b08ec 100644 (file)
@@ -82,6 +82,8 @@ struct nf_conn_help {
 
        union nf_conntrack_help help;
 
+       struct hlist_head expectations;
+
        /* Current number of expected connections */
        unsigned int expecting;
 };
@@ -114,12 +116,6 @@ struct nf_conn
        struct ip_conntrack_counter counters[IP_CT_DIR_MAX];
 #endif
 
-       /* Unique ID that identifies this conntrack*/
-       unsigned int id;
-
-       /* features - nat, helper, ... used by allocating system */
-       u_int32_t features;
-
 #if defined(CONFIG_NF_CONNTRACK_MARK)
        u_int32_t mark;
 #endif
@@ -133,9 +129,6 @@ struct nf_conn
 
        /* Extensions */
        struct nf_ct_ext *ext;
-
-       /* features dynamically at the end: helper, nat (both optional) */
-       char data[0];
 };
 
 static inline struct nf_conn *
@@ -178,6 +171,10 @@ static inline void nf_ct_put(struct nf_conn *ct)
 extern int nf_ct_l3proto_try_module_get(unsigned short l3proto);
 extern void nf_ct_l3proto_module_put(unsigned short l3proto);
 
+extern struct hlist_head *nf_ct_alloc_hashtable(int *sizep, int *vmalloced);
+extern void nf_ct_free_hashtable(struct hlist_head *hash, int vmalloced,
+                                int size);
+
 extern struct nf_conntrack_tuple_hash *
 __nf_conntrack_find(const struct nf_conntrack_tuple *tuple,
                    const struct nf_conn *ignored_conntrack);
@@ -186,6 +183,10 @@ extern void nf_conntrack_hash_insert(struct nf_conn *ct);
 
 extern void nf_conntrack_flush(void);
 
+extern int nf_ct_get_tuplepr(const struct sk_buff *skb,
+                            unsigned int nhoff,
+                            u_int16_t l3num,
+                            struct nf_conntrack_tuple *tuple);
 extern int nf_ct_invert_tuplepr(struct nf_conntrack_tuple *inverse,
                                const struct nf_conntrack_tuple *orig);
 
@@ -219,9 +220,6 @@ extern void nf_conntrack_tcp_update(struct sk_buff *skb,
                                    struct nf_conn *conntrack,
                                    int dir);
 
-/* Call me when a conntrack is destroyed. */
-extern void (*nf_conntrack_destroyed)(struct nf_conn *conntrack);
-
 /* Fake conntrack entry for untracked connections */
 extern struct nf_conn nf_conntrack_untracked;
 
@@ -265,14 +263,6 @@ do {                                                       \
        local_bh_enable();                              \
 } while (0)
 
-/* no helper, no nat */
-#define        NF_CT_F_BASIC   0
-/* for helper */
-#define        NF_CT_F_HELP    1
-/* for nat. */
-#define        NF_CT_F_NAT     2
-#define NF_CT_F_NUM    4
-
 extern int
 nf_conntrack_register_cache(u_int32_t features, const char *name, size_t size);
 extern void