MOXA linux-2.6.x / linux-2.6.19-uc1 from UC-7110-LX-BOOTLOADER-1.9_VERSION-4.2.tgz
[linux-2.6.19-moxart.git] / include / linux / netfilter / nf_conntrack_ftp.h
blobad4a41c9ce938b2c2d4e2f56f2effb90fe46ca74
1 #ifndef _NF_CONNTRACK_FTP_H
2 #define _NF_CONNTRACK_FTP_H
3 /* FTP tracking. */
5 /* This enum is exposed to userspace */
6 enum ip_ct_ftp_type
8 /* PORT command from client */
9 IP_CT_FTP_PORT,
10 /* PASV response from server */
11 IP_CT_FTP_PASV,
12 /* EPRT command from client */
13 IP_CT_FTP_EPRT,
14 /* EPSV response from server */
15 IP_CT_FTP_EPSV,
18 #ifdef __KERNEL__
20 #define FTP_PORT 21
22 #define NUM_SEQ_TO_REMEMBER 2
23 /* This structure exists only once per master */
24 struct ip_ct_ftp_master {
25 /* Valid seq positions for cmd matching after newline */
26 u_int32_t seq_aft_nl[IP_CT_DIR_MAX][NUM_SEQ_TO_REMEMBER];
27 /* 0 means seq_match_aft_nl not set */
28 int seq_aft_nl_num[IP_CT_DIR_MAX];
31 struct ip_conntrack_expect;
33 /* For NAT to hook in when we find a packet which describes what other
34 * connection we should expect. */
35 extern unsigned int (*ip_nat_ftp_hook)(struct sk_buff **pskb,
36 enum ip_conntrack_info ctinfo,
37 enum ip_ct_ftp_type type,
38 unsigned int matchoff,
39 unsigned int matchlen,
40 struct ip_conntrack_expect *exp,
41 u32 *seq);
42 #endif /* __KERNEL__ */
44 #endif /* _NF_CONNTRACK_FTP_H */