Hi,
I already asked this question on serverfault, but was thinking maybe here I will get more lucky. The original question was:
http://serverfault.com/questions/70...to-redirect-all-traffic-to-a-specific-ip-port
Basically I'm trying to port this rules to pf:
I'm not sure what exactly this 2 rules do, but they allow the redsocks application (https://github.com/darkk/redsocks) to send all tcp traffic going to 10.0.0.0/8 to the 127.0.0.1:12345 local server, but also keeping the original destination. So redsocks forwards it through a socks5 proxy.
I already asked this question on serverfault, but was thinking maybe here I will get more lucky. The original question was:
http://serverfault.com/questions/70...to-redirect-all-traffic-to-a-specific-ip-port
Basically I'm trying to port this rules to pf:
Code:
iptables -t nat -A REDSOCKS -p tcp -d 10.0.0.0/8 -j REDIRECT --to-ports 12345
iptables -t nat -A OUTPUT -p tcp -j REDSOCKS
I'm not sure what exactly this 2 rules do, but they allow the redsocks application (https://github.com/darkk/redsocks) to send all tcp traffic going to 10.0.0.0/8 to the 127.0.0.1:12345 local server, but also keeping the original destination. So redsocks forwards it through a socks5 proxy.