Redirect my FTP server to VPN server

Issues related to configuring your network
nesa1212
Posts: 10
Joined: 2017/02/17 03:36:15

Make secure connection to FTP Server with VPN Openswan

Post by nesa1212 » 2017/07/22 05:45:53

I have topology:

FTP Server (192.168.122.219) -----switch---- VPN openswan L2TPD (192.168.122.172 & 103.19.208.247) ----------------switch------------------------client (103.19.208.248)

my ipsec.conf is:

Code:

Code: Select all

     conn L2TP-PSK
        authby=secret
        auto=start
        keyingtries=3
        ikelifetime=8h
        keylife=1h
        ike=3des-md5
        keyexchange=ike
        phase2=esp
        phase2alg=3des-md5
        compress=no
        type=tunnel
        left=%defaultroute
        leftid=103.19.208.247
        leftsubnet=192.168.122.0/24
        leftnexthop=%defaultroute
        right=%any
        pfs=yes
        dpddelay=10
        dpdtimeout=90
        dpdaction=clear

And when my client connect to VPN, i get IP 192.168.1.2/32 and my VPN server have local vpn ip: 192.168.1.1/32


I tried iptables -t nat -A POSTROUTING -j MASQUERADE on my VPN server and my client can ping to my FTP server but, wireshark can capture FTP password when my client access my FTP server. How to solve this problem? Thank you

Whoever
Posts: 1357
Joined: 2013/09/06 03:12:10

Re: Make secure connection to FTP Server with VPN Openswan

Post by Whoever » 2017/07/22 22:33:50

Didn't you ask this already?

viewtopic.php?f=16&t=63285

I think that you have already been told that the solution lies in the routing tables, not in the IPTABLES rules.

Post Reply