Routing only torrent data through VPN?

I’ve read this is possible via a few different routes, but I’d like to hear from this sub.

I have a linux (arch) nas/torrent/htpc. I want to route only my torrent traffic through a vpn and nothing else, as I’m in Canada and can’t get hulu via a vpn (they blocked all vpn’s). I use unblock us at the router level to get all my streaming content.

I do have a dd-wrt router as well, but all of my home torrenting is done through through this box so I don’t need to set something up at the router level (unless I have to).

What you’re looking for is Policy (or Source) Based Routing. I do this at a router level (via my EdgeRouter Lite), but you should also be able to do this via IPTables.

This might not be the best solution for you but I still would like to share the idea just in case.

Use a RaspberryPi, set up the VPN and the torrent client there. On your router, set the firewall to only allow VPN traffic when it comes from your Pi.

This will make your torrent activities independent from your PC so you can seed and download all day and night.

All I’ve got is using Policy-based Routing on Vyatta-based routers.

This is on Linux, technically, and should work on the open source VyOS project.

IPTables

You want to route your bittorrent traffic through your VPN.

Here’s a solution:

BTGuard.com is specifically designed to route torrent traffic only. It could prob be used for more, but it allows you to bypass the problems of having a VPN for your browsers, while keeping torrent traffic secure.

think along this lines.it even has a kill switch

Gee, I wonder what they guy is up to that lets everything but this part run in the open, but the rest is encrypted.

definitely going to want to read into iptables but I’m pretty sure openpvn only supports ipforwarding and not port so I’m not sure if that would cause an issue for OP or not.

Could be seeding linux distros.

Ya I found my pi clone. I mentioned it elsewhere in this thread.

What I’m thinking is having the opi+ powered from the 5volt rail in my computer, and put it inside my computer. Then I’ll run the VPN on the pi along with a torrent client (via web interface) and auto mount a drive off the Nas (that it’s inside of) and download directly to that.

I didn’t think I’d have to set something in my router to let VPN traffic through from only one device. Can you comment further on this? I can only find tutorials on how to set the router so all traffic goes through.

Thanks for your comment. I’m trying to not have to buy new hardware if I can. Money is sparse right now.

I’m all for a challenge, but this is going to be a steep learning curve for me.

with PIA you can get both a proxy and a VPN. I was going to route all the torrent traffic to the VPN and everything else through the proxy to get usa content. PIA is $3.40 USD p/month.

Hello. I downvoted you, but I figured I’d explain why. You didnt post anything to help this user, and instead just posted an unhelpful, sarcastic response.

OpenVPN is just the interface that he’d talk through (if he’s using openvpn!). IPTables is what would determine what traffic to modify and send through that interface. As long as the VPN is exposed as a network interface in linux, it should work.

That’s part of what I’m doing. At least that is completely legal.

Your idea sounds great. Good luck with that!

I didn’t think I’d have to set something in my router to let VPN traffic through from only one device. Can you comment further on this? I can only find tutorials on how to set the router so all traffic goes through.

I’m assuming you don’t just want to seed Linux distros. The idea here is, that if your VPN somehow disconnects the router will reject torrent traffic. That will prevent you from getting in trouble.

This is just a suggestion and not required. I should have mentioned that. :wink:

VM set up to run torrent, and only through VPN is probably the easiest.

Are you suggesting that I set up a kill switch? My family and I share pics and family videos as private torrents.

I’ll be honest though, I figured if I could get one program to use it, I could use two. What I need to do can still be done via my suggested set up. I can’t wait to try this!