|
2014-07-04
, 09:13
|
Guest |
Posts: n/a |
Thanked: 0 times |
Joined on
|
#12
|
![]() |
2014-07-04
, 09:37
|
Posts: 63 |
Thanked: 37 times |
Joined on Jul 2010
|
#13
|
#!/bin/sh #the UID that Tor runs as (varies from system to system) _tor_uid="0" #Tor's TransPort _trans_port="9040" ### flush iptables iptables -F iptables -t nat -F ### set iptables *nat iptables -t nat -A OUTPUT -m owner --uid-owner $_tor_uid -j RETURN iptables -t nat -A OUTPUT -p udp --dport 53 -j REDIRECT --to-ports 53 #allow clearnet access for hosts: 127.0.0.0/9 127.128.0.0/10 iptables -t nat -A OUTPUT -d 127.0.0.0/9 -j RETURN iptables -t nat -A OUTPUT -d 127.128.0.0/10 -j RETURN #redirect all other output to Tor's TransPort iptables -t nat -A OUTPUT -p tcp --syn -j REDIRECT --to-ports $_trans_port ### set iptables *filter iptables -A OUTPUT -m state --state ESTABLISHED,RELATED -j ACCEPT #allow clearnet access for hosts: 127.0.0.0/8 iptables -A OUTPUT -d 127.0.0.0/8 -j ACCEPT #allow only Tor output iptables -A OUTPUT -m owner --uid-owner $_tor_uid -j ACCEPT iptables -A OUTPUT -j REJECT #Security fix iptables -A OUTPUT -m state --state INVALID -j DROP iptables -A OUTPUT ! -o lo ! -d 127.0.0.1 ! -s 127.0.0.1 -p tcp -m tcp --tcp-flags ACK,FIN ACK,FIN -j DROP iptables -A OUTPUT ! -o lo ! -d 127.0.0.1 ! -s 127.0.0.1 -p tcp -m tcp --tcp-flags ACK,RST ACK,RST -j DROP
![]() |
2015-10-03
, 01:29
|
Posts: 64 |
Thanked: 36 times |
Joined on Feb 2012
@ US
|
#14
|
![]() |
2015-10-04
, 01:53
|
Posts: 64 |
Thanked: 36 times |
Joined on Feb 2012
@ US
|
#15
|
![]() |
2015-10-04
, 06:40
|
Posts: 1,298 |
Thanked: 4,322 times |
Joined on Oct 2014
|
#16
|
Perhaps you need to allow the traffic to the remote proxy, which your local proxy 127.0.0.1:3339 connects to.
![]() |
2015-10-04
, 07:32
|
Posts: 64 |
Thanked: 36 times |
Joined on Feb 2012
@ US
|
#17
|
![]() |
2015-10-04
, 08:38
|
Posts: 1,298 |
Thanked: 4,322 times |
Joined on Oct 2014
|
#18
|
![]() |
2015-10-04
, 14:19
|
Posts: 1,298 |
Thanked: 4,322 times |
Joined on Oct 2014
|
#19
|
![]() |
2017-12-05
, 01:44
|
Posts: 7 |
Thanked: 9 times |
Joined on Jul 2014
@ Guangzhou,China
|
#20
|
The Following 4 Users Say Thank You to 0312birdzhang For This Useful Post: | ||
I'll look into this.