linux/net/netfilter/ipvs
Hannes Eder 7f1c407579 IPVS: make FTP work with full NAT support
Use nf_conntrack/nf_nat code to do the packet mangling and the TCP
sequence adjusting.  The function 'ip_vs_skb_replace' is now dead
code, so it is removed.

To SNAT FTP, use something like:

% iptables -t nat -A POSTROUTING -m ipvs --vaddr 192.168.100.30/32 \
    --vport 21 -j SNAT --to-source 192.168.10.10
and for the data connections in passive mode:

% iptables -t nat -A POSTROUTING -m ipvs --vaddr 192.168.100.30/32 \
    --vportctl 21 -j SNAT --to-source 192.168.10.10
using '-m state --state RELATED' would also works.

Make sure the kernel modules ip_vs_ftp, nf_conntrack_ftp, and
nf_nat_ftp are loaded.

[ up-port and minor fixes by Simon Horman <horms@verge.net.au> ]
Signed-off-by: Hannes Eder <heder@google.com>
Signed-off-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Patrick McHardy <kaber@trash.net>
2010-07-23 12:48:52 +02:00
..
Kconfig IPVS: make FTP work with full NAT support 2010-07-23 12:48:52 +02:00
Makefile ipvs: SCTP Trasport Loadbalancing Support 2010-02-18 12:31:05 +01:00
ip_vs_app.c IPVS: make FTP work with full NAT support 2010-07-23 12:48:52 +02:00
ip_vs_conn.c Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/kaber/nf-next-2.6 2010-07-02 22:42:06 -07:00
ip_vs_core.c IPVS: make FTP work with full NAT support 2010-07-23 12:48:52 +02:00
ip_vs_ctl.c IPVS: one-packet scheduling 2010-06-22 08:07:01 +02:00
ip_vs_dh.c include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h 2010-03-30 22:02:32 +09:00
ip_vs_est.c include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h 2010-03-30 22:02:32 +09:00
ip_vs_ftp.c IPVS: make FTP work with full NAT support 2010-07-23 12:48:52 +02:00
ip_vs_lblc.c include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h 2010-03-30 22:02:32 +09:00
ip_vs_lblcr.c include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h 2010-03-30 22:02:32 +09:00
ip_vs_lc.c IPVS: use pr_err and friends instead of IP_VS_ERR and friends 2009-08-02 18:29:30 -07:00
ip_vs_nq.c IPVS: use pr_err and friends instead of IP_VS_ERR and friends 2009-08-02 18:29:30 -07:00
ip_vs_proto.c netfilter: xt_ipvs (netfilter matcher for IPVS) 2010-07-23 12:42:58 +02:00
ip_vs_proto_ah_esp.c IPVS: fix potential stack overflow with overly long protocol names 2010-04-08 13:35:47 +02:00
ip_vs_proto_sctp.c ipvs: lvs sctp protocol handler is incorrectly invoked ip_vs_app_pkt_out 2010-07-09 17:27:47 +02:00
ip_vs_proto_tcp.c net: mark read-only arrays as const 2009-08-05 10:42:58 -07:00
ip_vs_proto_udp.c net: mark read-only arrays as const 2009-08-05 10:42:58 -07:00
ip_vs_rr.c IPVS: use pr_err and friends instead of IP_VS_ERR and friends 2009-08-02 18:29:30 -07:00
ip_vs_sched.c IPVS: use pr_err and friends instead of IP_VS_ERR and friends 2009-08-02 18:29:30 -07:00
ip_vs_sed.c IPVS: use pr_err and friends instead of IP_VS_ERR and friends 2009-08-02 18:29:30 -07:00
ip_vs_sh.c include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h 2010-03-30 22:02:32 +09:00
ip_vs_sync.c net: sk_sleep() helper 2010-04-20 16:37:13 -07:00
ip_vs_wlc.c IPVS: use pr_fmt 2009-07-30 14:29:44 -07:00
ip_vs_wrr.c include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h 2010-03-30 22:02:32 +09:00
ip_vs_xmit.c IPVS: make friends with nf_conntrack 2010-07-23 12:46:32 +02:00