Differences

This shows you the differences between two versions of the page.

Link to this comparison view

linux:pptp_vpn [2016/09/29 15:23]
joe
linux:pptp_vpn [2018/04/01 02:11]
Line 1: Line 1:
-~~Title: iT-Joe | VPN Server ~~ 
  
-====== VPN Server ====== 
- 
-== PPTP VPN Server: Built on a Raspberry Pi == 
- 
-<note important>​Warning,​ PPTP is considered [[https://​technet.microsoft.com/​library/​security/​2743314|unsafe]]. Consider using a alternate VPN solution such as OpenVPN.</​note>​ 
- 
-A Virtual Private Network (VPN) is a method of adding a layer of security and privacy to both private and public networks. A VPN can allow you to securely access your home or business network even while connected to an untrusted public network like a wifi hotspot. In a VPN you can access all your private network resources as if you were on your home network. There are many options when it comes to VPN's. I am using a Raspberry Pi, so I need a solution that will utilize few resources. In this tutorial I will show you how to setup a Point-to-Point Tunneling Protocol (PPTP) VPN on a Raspberry Pi. PPTP is least secure VPN method but uses the least amount of resources. 
- 
-As always, update package lists to insure we get the latest packages. Then Upgrade. Check MPPE support. Then install the required vpn package(pptpd). 
-<​code>​ 
-sudo apt-get update 
-sudo apt-get upgrade 
-sudo modprobe ppp-compress-18 
-sudo apt-get install pptpd 
-</​code>​ 
- 
-Now we need to edit a few files. 
- 
-The first is the pptpd.conf file. 
-<​code>​ 
-sudo nano /​etc/​pptpd.conf 
-</​code>​    
-At the end of the file, uncomment the following lines and add your information. localip is your server IP and remoteip is the range for your clients. 
-<​code>​    
-   localip 192.168.0.1 ​ 
-   remoteip 192.168.1.245-255 
-</​code>​ 
- 
-pptd-options file 
-<​code>​ 
-sudo nano /​etc/​ppp/​pptpd-options 
-</​code>​ 
-Add the follow txt on the bottom: 
-<​code>​ 
-   ms-dns 192.168.1.1 
-   noipx 
-   mtu 1490 
-   mru 1490 
-</​code>​ 
-chap-secrets file 
-<​code>​ 
-sudo nano /​etc/​ppp/​chap-secrets 
-</​code>​     
-Add your credentials using the following syntax: 
-<​code>​ 
-username[TAB]*[TAB]password[TAB]* 
-</​code>​ 
-Restart the PPTP VPN Server 
-<​code>​sudo service pptpd restart</​code>​ 
-sysctl.conf file 
-<​code>​ 
-sudo vi /​etc/​sysctl.conf 
-</​code>​ 
-<​code>​   net.ipv4.ip_forward=1</​code>​ 
-<​code>​sudo sysctl -p</​code>​ 
- 
-rc.local file 
-<​code>​sudo nano /​etc/​rc.local</​code>​ 
-Add the following right above "exit 0" 
- 
-<​code>​sudo iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE</​code>​ 
- 
-IMPORTANT!! 
-Make sure to forward port 1723 on your router and you should be good to go!! 
- 
-<​HTML>​ 
-<div id="​disqus_thread"></​div>​ 
-<​script>​ 
- 
-/** 
- ​* ​ RECOMMENDED CONFIGURATION VARIABLES: EDIT AND UNCOMMENT THE SECTION BELOW TO INSERT DYNAMIC VALUES FROM YOUR PLATFORM OR CMS. 
- ​* ​ LEARN WHY DEFINING THESE VARIABLES IS IMPORTANT: https://​disqus.com/​admin/​universalcode/#​configuration-variables */ 
-/* 
-var disqus_config = function () { 
-    this.page.url = PAGE_URL; ​ // Replace PAGE_URL with your page's canonical URL variable 
-    this.page.identifier = PAGE_IDENTIFIER;​ // Replace PAGE_IDENTIFIER with your page's unique identifier variable 
-}; 
-*/ 
-(function() { // DON'T EDIT BELOW THIS LINE 
-    var d = document, s = d.createElement('​script'​);​ 
-    s.src = '//​itjoevpn.disqus.com/​embed.js';​ 
-    s.setAttribute('​data-timestamp',​ +new Date()); 
-    (d.head || d.body).appendChild(s);​ 
-})(); 
-</​script>​ 
-<​noscript>​Please enable JavaScript to view the <a href="​https://​disqus.com/?​ref_noscript">​comments powered by Disqus.</​a></​noscript>​ 
-</​HTML>​ 
  • Show page