I have a built a Tor router with Raspberry Pi 5 and a USB to Ethernet adapter. Everything works fine.
My setup is,
Raspbian Latest OS.
/etc/tor/torrc/etc/dnsmasq.conf/etc/dhcpcd.conf
/etc/sysctl.d/router-ap.confiptablesPi's eth0 is connected to main router and it got 192.168.0.130 and eth1(192.168.4.1) is connected to my workstation PC which want to use the Tor Router.
The problem I face is, from the workstation pc, I am not able to ssh to the router as 192.168.0.130 or 192.168.4.1
Both addresses are pingable from the workstation pc.
What firewall rule I should place on the pi to make the ssh work from workstation pc?
My setup is,
Raspbian Latest OS.
/etc/tor/torrc
Code:
AutomapHostsOnResolve 1AutomapHostsSuffixes .VirtualAddrNetworkIPv4 172.16.0.0/12DNSPort 0.0.0.0:9053TransPort 0.0.0.0:9040
Code:
interface=eth1dhcp-range=192.168.4.2,192.168.4.20,255.255.255.0,24hdomain=lanaddress=/rt.lan/192.168.4.1
Code:
interface eth1 static ip_address=192.168.4.1/24 nohook wpa_supplicant
/etc/sysctl.d/router-ap.conf
Code:
net.ipv4.ip_forward=1
Code:
iptables -Fiptables -t nat -Fiptables -t nat -A PREROUTING -i eth1 -p tcp --syn -j REDIRECT --to-ports 9040iptables -t nat -A PREROUTING -i eth1 -p udp --dport 53 -j REDIRECT --to-ports 53iptables -t nat -A PREROUTING -i eth1 -p tcp --dport 53 -j REDIRECT --to-ports 53iptables -t nat -A PREROUTING -i eth1 -p tcp --dport 22 -j REDIRECT --to-ports 22iptables -A FORWARD -i eth1 -j DROPiptables-save > /etc/iptables/rules.v4
The problem I face is, from the workstation pc, I am not able to ssh to the router as 192.168.0.130 or 192.168.4.1
Both addresses are pingable from the workstation pc.
What firewall rule I should place on the pi to make the ssh work from workstation pc?
Statistics: Posted by sim_tcr — Sun Nov 24, 2024 9:05 am