4 #include <linux/netfilter.h>
6 /* those NF_LOG_* defines and struct nf_loginfo are legacy definitios that will
7 * disappear once iptables is replaced with pkttables. Please DO NOT use them
9 #define NF_LOG_TCPSEQ 0x01 /* Log TCP sequence numbers */
10 #define NF_LOG_TCPOPT 0x02 /* Log TCP options */
11 #define NF_LOG_IPOPT 0x04 /* Log IP options */
12 #define NF_LOG_UID 0x08 /* Log UID owning local socket */
13 #define NF_LOG_MASK 0x0f
15 #define NF_LOG_TYPE_LOG 0x01
16 #define NF_LOG_TYPE_ULOG 0x02
33 typedef void nf_logfn(u_int8_t pf,
35 const struct sk_buff *skb,
36 const struct net_device *in,
37 const struct net_device *out,
38 const struct nf_loginfo *li,
45 struct list_head list[NFPROTO_NUMPROTO];
48 /* Function to register/unregister log function. */
49 int nf_log_register(u_int8_t pf, struct nf_logger *logger);
50 void nf_log_unregister(struct nf_logger *logger);
52 void nf_log_set(struct net *net, u_int8_t pf,
53 const struct nf_logger *logger);
54 void nf_log_unset(struct net *net, const struct nf_logger *logger);
56 int nf_log_bind_pf(struct net *net, u_int8_t pf,
57 const struct nf_logger *logger);
58 void nf_log_unbind_pf(struct net *net, u_int8_t pf);
60 /* Calls the registered backend logging function */
62 void nf_log_packet(struct net *net,
65 const struct sk_buff *skb,
66 const struct net_device *in,
67 const struct net_device *out,
68 const struct nf_loginfo *li,
69 const char *fmt, ...);
71 #endif /* _NF_LOG_H */