Answer the question
In order to leave comments, you need to log in
What are the iptables rules for blocking outgoing traffic other than proxy (proxydroid) on rooted Android 10+?
On the smartphone, proxies are used through ProxyDroid, but they do not take over all the traffic, the real ip is fired, in particular via WebRTC.
The solution I see is to prohibit all outgoing traffic, except for ip:port proxy servers (several). On the virtual android, I checked by prohibiting any traffic, except for the proxy - the necessary applications work for me.
The ban should not apply to DNS, NTP protocols.
It is required to write scripts for init.d setting rules - but my competence is not enough, please help.
The VPN option is not suitable.
If you need it personally, then in telegram @odnokasanie
Answer the question
In order to leave comments, you need to log in
deny all outgoing traffic
sudo iptables -t filter -A INPUT -p tcp -s 123.123.123.123/32 --dport 1111 -j ACCEPT
sudo iptables -t filter -A OUTPUT -p tcp -s 123.123.123.123/32 --dport 1111 -j ACCEPT
sudo iptables -P INPUT DROP
sudo iptables -P OUTPUT DROP
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question