2014/01/08

Linux Mint - Install PPTP VPN Server

1. Install PPTP VPN Server.
apt-get install pptpd

2. Edit pptpd.conf file to add your VPN server ip settings.
gedit /etc/pptpd.conf
--------------------------------------------
localip 192.168.60.10
remoteip 192.168.60.20-30
--------------------------------------------

3. Edit pptpd-options file to add dns server and encryption.
gedit /etc/ppp/pptpd-options
--------------------------------------------
ms-dns 8.8.8.8
ms-dns 4.4.4.4

#require-mschap-v2
+chap
--------------------------------------------
4. Add username and password
gedit /etc/ppp/chap-secrets
--------------------------------------------
aaa    pptpd    bbb    *
--------------------------------------------

5. Edit sysctl.conf for network forward.
gedit /etc/sysctl.conf
--------------------------------------------
net.ipv4.ip_forward=1
--------------------------------------------

6. Configure your firewall.
--------------------------------------------
iptables -A INPUT -i eth0 -p tcp --dport 1723 -j ACCEPT
iptables -A INPUT -i eth0 -p gre -j ACCEPT
iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
iptables -A FORWARD -i ppp+ -o eth0 -j ACCEPT
iptables -A FORWARD -i eth0 -o ppp+ -j ACCEPT
--------------------------------------------

7. Start your PPTP VPN Server.
pptpd restart

沒有留言:

張貼留言