Setting up Raspberry Pi as a VPN gateway

Hi All,

I've been searching all over the internet for a guide on how to do this but thus far can't seem to find anything solid.
Basically what I want to do is set up my Raspberry Pi so that it acts as a VPN server with my PIA for all traffic on my home network. The aim of this is so I can leave the Pi switched on all the time and all traffic is passed through the VPN server, encrypted then pushed out to the web.

All the tutorials I've found have all used OpenVPN but aim at making it possible to be able to connect to a home network with a VPN server on the Pi. I don't really want that, just all traffic passing trough my router.

Any suggestions would be welcomed :-)

Comments

  • You may be using the wrong words here. See the VPN server is the host itself. If you want traffic to reach the Internet through your Pi, then you need the VPN Client. (Not the server. The Client is what you need running.)

    You connect to the PIA VPN via the client and can forward everything encrypted via OpenVPN through the servers at PIA.

    There are actually a number of threads on how to do this here, but the forum search is all but useless. Use a search engine that lets you specify a domain to restrict search results to. Here is one I use.
    Ixquick.com

    See? Much better than the forum search.
  • Thanks for the info,

    My aim is to have ALL internet traffic router through the VPN connection on the Pi, whether this is my Chromecast, Macbook, PS4, Phone & toaster ect....

    The reason I want to do this most importantly to encrypt all traffic without the need to connect the client on the individual machines but also so I can view US Netflix with the Chromecast.

    If my terminology was wrong then I do apologise, I couldn't work out whether the Pi would be a server running a VPN connection or a client that receives the traffic and then passes it on, regardless the aim is the same.

    I've searched the forums on here quite a bit and the search engine you provided (Thanks) pretty much returns the same results. If you could point me in the right direction to one of the guides you've seen on the forum then I'd appreciate that very much.

    Thanks.
  • I wish I knew which of the threads to follow, but since I do not have a Raspberry Pi to test with, I would be making a blind guess. One little thing I can tell you is that you want to change the default OpenVPN cipher to Blowfish-128 since most compiles of OpenVPN are now defaulting to AES-256 and there is no way to get that working with PIA except using their client. (You can use AES-128 if you change the port to 1194 instead of 1194.)
  • edited January 2015
    yeah, I've heard of people using a pi for a VPN client.  but, not idea how to do it.  best suggestion I have is to visit pi forums to ask them.  I'm sure there are people to help you there.
  • Unfortunately the Pi forums are a bit of a joke. Since it is a non-profit, people look rather harshly on any criticism, even if it is well justified. But if none of the threads here help, it may be the best option left.
  • why would it be criticism to ask how to make a VPN client out of it? 
    :-B
  • It would not be criticism to ask how. But this would eventually lead to questioning why the 700 Mhz single-core ARM CPU cannot handle the encryption overhead of even a relatively slow ISP. And that would be taken not as criticism, but blasphemy by the fanatics there.
  • oh, I didn't know the specs.  I'd read of people using arrays of them for bitcoin mining, so I figured they were more powerful than that.
  • oh, I didn't know the specs.  I'd read of people using arrays of them for bitcoin mining, so I figured they were more powerful than that.
    You would probably have to mine for decades to pay for them if you tried that. You can buy task specific ASIC systems that will do nothing but mining and will make a slow but steady profit. Raspberry Pis are too general in design and purpose to compete with devices like those.
  • edited October 2015
    I have published a howto on this here:

    Raspberry Pi VPN Router
    https://gist.github.com/superjamie/ac55b6d2c080582a3e64

    The Raspberry Pi 1 is powerful enough for casual browsing, though it's not hard to overwhelm the CPU with multiple concurrent downloads. I have not tried the Raspberry Pi 2 yet, but it's effectively several times faster so should be better.
  • I have published a howto on this here:

    Raspberry Pi VPN Router
    https://gist.github.com/superjamie/ac55b6d2c080582a3e64

    The Raspberry Pi 1 is powerful enough for casual browsing, though it's not hard to overwhelm the CPU with multiple concurrent downloads. I have not tried the Raspberry Pi 2 yet, but it's effectively several times faster so should be better.
    Bravo. This was badly needed. Thank you for this.
  • suprjami said:
    I have published a howto on this here:

    Raspberry Pi VPN Router
    https://gist.github.com/superjamie/ac55b6d2c080582a3e64

    The Raspberry Pi 1 is powerful enough for casual browsing, though it's not hard to overwhelm the CPU with multiple concurrent downloads. I have not tried the Raspberry Pi 2 yet, but it's effectively several times faster so should be better.
    hi, do you know of anyway i can set this up with privoxy, i want to run only a few select apps through a VPN (to bypass geolocation lock, certain torrent sites and warez sites)
  • I basically built black.box unzoner for this exact purpose. PIA is supported, among other VPN providers.

    -- ab1
Sign In or Register to comment.