My connection is: Internet - router - RPi - Android phone.
wlan0 of RPi get ip from the router.
uap0 of RPi has fixed ip 192.168.50.1, and assign ip to the phone(s).
tested the phone can get access to internet.
I can ssh to RPi's wlan0 ip thru router. However, I can't do it from the phone thru ip of uap0. I have tried JuiceSSH & Termius.
Okay, I can still use the ip of wlan0 to ssh in thru the AP connection. However, I may not always have the ip of wlan0 available when I am not with my router. I want to ssh firstname.lastname@example.org.
the iptables rule in my setup is
Code: Select all
iptables -t nat -A POSTROUTING -s 192.168.50.0/24 ! -d 192.168.50.0/24 -j MASQUERADE
Just add [Solved] to Subject