V
V
Vasily Ivanov2021-08-17 17:25:26
linux
Vasily Ivanov, 2021-08-17 17:25:26

How to connect via socks5 to virtulbox running tor?

Tor is running on virtulbox with the following configuration:

VirtualAddrNetworkIPv4 192.168.1.0/16

AutomapHostsOnResolve 1

TransPort 9040
DNSPort 5353
SocksPort 9050
ORPort 9001

ExitPolicy reject *:*
ExitPolicy reject6 *:*

NewCircuitPeriod 3600
MaxCircuitDirtiness 86400

ControlPort 9051
HashedControlPassword XXX                                                          

ExitNodes YYY


and built a tor tunnel using iptables rules:
# Generated by iptables-save v1.6.1 on Tue Aug 17 17:06:44 2021
*mangle
:PREROUTING ACCEPT [125:31748]
:INPUT ACCEPT [125:31748]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [105:24645]
:POSTROUTING ACCEPT [105:24645]
COMMIT
# Completed on Tue Aug 17 17:06:44 2021
# Generated by iptables-save v1.6.1 on Tue Aug 17 17:06:44 2021
*nat
:PREROUTING ACCEPT [16:2388]
:INPUT ACCEPT [16:2388]
:OUTPUT ACCEPT [10:754]
:POSTROUTING ACCEPT [11:814]
-A OUTPUT -d 192.168.1.0/24 -j RETURN
-A OUTPUT -d 192.168.0.0/24 -j RETURN
-A OUTPUT -d 127.0.0.0/9 -j RETURN
-A OUTPUT -d 127.128.0.0/10 -j RETURN
-A OUTPUT -p tcp -m tcp --tcp-flags FIN,SYN,RST,ACK SYN -j REDIRECT --to-ports 9040
COMMIT
# Completed on Tue Aug 17 17:06:44 2021
# Generated by iptables-save v1.6.1 on Tue Aug 17 17:06:44 2021
*filter
:INPUT ACCEPT [72:13868]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [0:0]
-A OUTPUT -m state --state RELATED,ESTABLISHED -j ACCEPT
-A OUTPUT -d 192.168.1.0/24 -j ACCEPT
-A OUTPUT -d 192.168.0.0/24 -j ACCEPT
-A OUTPUT -d 127.0.0.0/8 -j ACCEPT
COMMIT
# Completed on Tue Aug 17 17:06:44 2021


When I try to do the following through firefox:
611bc66f66d31623554615.png

the browser stops loading pages

Answer the question

In order to leave comments, you need to log in

1 answer(s)
Z
Zzzz9, 2021-08-17
@Zzzz9

My friend, explain what it should have been
-A OUTPUT -d 127.0.0.0/9 -j RETURN
-A OUTPUT -d 127.128.0.0/10 -j RETURN

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question