0

Can someone offer a brief walk-through for firewalling Ubuntu 16 with UFW for tor. I only want to allow tor traffic out on my device. I'm not sure if it's even possible with UFW.

# ufw default deny incoming
# ufw default deny outgoing
# ufw allow out on <wireless interface> to any proto tcp port 9001
# ......?

I'm certain this is wrong. Any info on this would be valued. Cheers.

user20282
  • 1
  • 1
  • 1
    ufw does not provide sufficient functionality to configure a Tor enforcing connection. Instead you should disable ufw entirely, and use something like ferm, as described here: https://tor.stackexchange.com/questions/12343/use-iptables-to-force-traffic-through-tor/12344#12344 – cacahuatl Dec 11 '17 at 00:06
  • https://github.com/ruped24/toriptables2 - it does exactly what you're searching/asking for – Alexey Vesnin Nov 25 '21 at 21:01
  • I don't know how to do this on Ubuntu with UFW, but juuust in case you or someone reading this didn't know already, there are operating systems designed to force all of your network traffic to go through tor. They are Tails and Whonix. I don't want to bias your opinion of either so I will just recommend searching for "Tails vs Whonix". – Alexander Taylor Dec 16 '17 at 07:20
  • use QubesOS - and forget both immature ones you've mentioned ;) – Alexey Vesnin Nov 25 '21 at 20:57

0 Answers0