我的电脑有两个连接:ppp0(互联网)和eth0(伪装)。 我也在端口8080上运行代理。我使用这台计算机作为路由器。 有一个快速的iptables黑客将redirect端口80端口8080(我的本地代理)?
来自本地机器或来自连接的内部networking的stream量?
对于本地: iptables -t nat -A OUTPUT -p tcp --dport 80 -j DNAT --to-destination 127.0.0.1:8080
对于networking: iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j DNAT --to-destination 127.0.0.1:8080