Transparent proxy
limon opened this issue · 10 comments
I run brook on my router. Is there any way to setup a transparent proxy easily, like ss-redir?
same as #102 ?
no, not a tunnel.
I need something like this: https://gist.github.com/wen-long/8644243
which use iptables to rediect packets, and clients through the router won't aware any change.
you must install redsocks in route in order to a transparent proxy. I wish add the feature in Brook.
This feature is implemented in v20180227.
Please have a try with https://github.com/txthinking/brook/tree/master/scripts
My situation:
- I have a Linux box (IP: 192.168.1.100)
- I have a MacOS (IP: 192.168.1.9)
Steps:
- Deploy a brook server
- Download brook cli on Linux box
- Run
$ brook tproxy -l :1080 -s BROOK_SERVER_IP:PORT -p PASSWORD
on Linux box - Run
$ iproute.sh
on Linux box - Run
$ iptables.sh
with BROOK_SERVER_IP and BROOK_TPROXY_PORT(1080) on Linux box - Setup gateway with 192.168.1.100, dns server with 8.8.8.8 on MacOS
the feature is not available when using iptable redirect, ex
iptables -t nat -A BROOK -p tcp -j REDIRECT --to-ports 1080 (BROOK_TPROXY_PORT)
How to deploy the firewall when brook is installed on Openwrt Route?
Unlike ss-redir, the transparent feature is not available using iptable redirect function.
Please read the wiki: https://github.com/txthinking/brook/wiki/How-to-run-transparent-proxy-on-Linux%3F
@nuclearn Brook tproxy works on mangle table