{"id":73,"date":"2015-08-24T23:46:47","date_gmt":"2015-08-24T16:46:47","guid":{"rendered":"http:\/\/prosindo.com\/blog\/?p=73"},"modified":"2015-08-24T23:46:47","modified_gmt":"2015-08-24T16:46:47","slug":"vpn-pptp-client-on-raspberry-pi","status":"publish","type":"post","link":"https:\/\/prosindo.com\/blog\/2015\/08\/24\/vpn-pptp-client-on-raspberry-pi\/","title":{"rendered":"VPN PPTP Client on Raspberry Pi"},"content":{"rendered":"<p>To start, you will need to install pptpclient, this can be achieved by:<\/p>\n<p><code>sudo apt-get install pptp-linux<\/code><\/p>\n<p>Next, Create a file in \/etc\/ppp\/peers with arbitrary name and the following contents:<\/p>\n<p><code>pty \"pptp $VPNHOSTNAME --nolaunchpppd --debug\"<\/code><br \/>\n<code>name $USERNAME<\/code><br \/>\n<code>password $PASSWORD<\/code><br \/>\n<code>remotename PPTP<\/code><br \/>\n<code>require-mppe-128<\/code><br \/>\n<code>require-mschap-v2<\/code><br \/>\n<code>refuse-eap<\/code><br \/>\n<code>refuse-pap<\/code><br \/>\n<code>refuse-chap<\/code><br \/>\n<code>refuse-mschap<\/code><br \/>\n<code>noauth<\/code><br \/>\n<code>debug<\/code><br \/>\n<code>persist<\/code><br \/>\n<code>maxfail 0<\/code><br \/>\n<code>defaultroute<\/code><br \/>\n<code>replacedefaultroute<\/code><br \/>\n<code>usepeerdns<\/code><\/p>\n<p>Where $VPNHOSTNAME is your VPN host name, $PASSWORD is your VPN password and $USERNAME is your VPN username.<\/p>\n<p>After you have done that, you should do:<\/p>\n<p><code>sudo pon $FILENAME<\/code><\/p>\n<p>where $FILENAME is the name of the file you saved earlier. Or you should do this to see debug messages (this command will display logs until connection off):<\/p>\n<p><code>pon $FILENAME debug dump logfd 2 nodetach<\/code><\/p>\n<p>To start your VPN client on boot, you can follow the instructions on <code>http:\/\/pptpclient.sourceforge.net\/howto-debian.phtml (point 8 or 9, Hand configuration section)<\/code><\/p>\n<p>An alternate method to make your VPN client run on boot is to make a script \/etc\/init.d\/pptp containing these contents:<\/p>\n<p><code>#! \/bin\/sh<\/code><\/p>\n<p><code>case \"$1\" in<\/code><br \/>\n<code>\u00a0 start)<br \/>\nsleep 10<br \/>\npon $\/etc\/ppp\/peers\/FILENAME<\/code><br \/>\n<code>\u00a0\u00a0\u00a0 echo \"PPTP Started\"<\/code><br \/>\n<code>\u00a0\u00a0\u00a0 ;;<\/code><br \/>\n<code>\u00a0 stop)<\/code><br \/>\n<code>\u00a0\u00a0\u00a0 poff $\/etc\/ppp\/peers\/FILENAME<\/code><br \/>\n<code>\u00a0\u00a0\u00a0 echo \"PPTP Stopped\"<\/code><br \/>\n<code>\u00a0\u00a0\u00a0 ;;<\/code><br \/>\n<code>\u00a0 *)<\/code><br \/>\n<code>\u00a0\u00a0\u00a0 echo \"Usage: \/etc\/init.d\/pptp {start|stop}\"<\/code><br \/>\n<code>\u00a0\u00a0\u00a0 exit 1<\/code><br \/>\n<code>\u00a0\u00a0\u00a0 ;;<\/code><br \/>\n<code>esac<\/code><\/p>\n<p><code>exit 0<\/code><\/p>\n<p>Then run:<\/p>\n<p><code>update-rc.d [filename of script] defaults<\/code><\/p>\n<p>To make it run at startup.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>To start, you will need to install pptpclient, this can be achieved by: sudo apt-get install pptp-linux Next, Create a file in \/etc\/ppp\/peers with arbitrary name and the following contents: pty &#8220;pptp $VPNHOSTNAME &#8211;nolaunchpppd &#8211;debug&#8221; name $USERNAME password $PASSWORD remotename PPTP require-mppe-128 require-mschap-v2 refuse-eap refuse-pap refuse-chap refuse-mschap noauth debug persist maxfail 0 defaultroute replacedefaultroute usepeerdns &hellip; <a href=\"https:\/\/prosindo.com\/blog\/2015\/08\/24\/vpn-pptp-client-on-raspberry-pi\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;VPN PPTP Client on Raspberry Pi&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[9,19,20],"class_list":["post-73","post","type-post","status-publish","format-standard","hentry","category-uncategorized","tag-debian","tag-pptp-client","tag-raspberry-pi"],"_links":{"self":[{"href":"https:\/\/prosindo.com\/blog\/wp-json\/wp\/v2\/posts\/73","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/prosindo.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/prosindo.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/prosindo.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/prosindo.com\/blog\/wp-json\/wp\/v2\/comments?post=73"}],"version-history":[{"count":0,"href":"https:\/\/prosindo.com\/blog\/wp-json\/wp\/v2\/posts\/73\/revisions"}],"wp:attachment":[{"href":"https:\/\/prosindo.com\/blog\/wp-json\/wp\/v2\/media?parent=73"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/prosindo.com\/blog\/wp-json\/wp\/v2\/categories?post=73"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/prosindo.com\/blog\/wp-json\/wp\/v2\/tags?post=73"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}