Is there any way to block specific Android apps from accessing the internet/network? (For example I have a note-taking app which has internet access, but I don’t necessarily trust it, so I’d like to just entirely block it’s access to the internet. However I still want Firefox/etc to be able to access the internet unrestricted.)
On an Android phone I just use NetGuard, which works by pretending to be a VPN (and then blocking internet access for apps of your choosing). I tried installing it on Sailfish OS, but it says it fails to activate - most likely because Android AppSupport doesn’t seem to provide any VPN settings?
For native apps I can manually copy the relevant /usr/share/applications/*.desktop file to /etc/sailjail/applications/ and edit it there, but obviously that doesn’t work for Android apps…
So, is there some way to do this?
I haven’t tried yet, but would it be possible to block an app’s network access using iptables with an appropriate --uid-owner or --gid-owner (not sure if each Android app has it’s own UID nor how I would find that out?). Or could I use SElinux to do something similar?
Thanks for your suggestion, but it’s not viable. I have many Android apps that I use, which likely have no native equivalent that I would find acceptable. Hence why I am looking to block network access for specific apps.
It is a bit OT because it does not help in the topic issue but local proxy( at localhost) definitely works for AAS. Both http and socks. Maybe I understand this statement incorrectly?
Has anyone yet tried to run RethinkDNS on AAS?
With RethinkDNS the user can grant or deny network access for each single Android app, Cellular/WLAN, on/off.
Including Firewall, IP & Port rules.
Thanks for confirming, that’s good news to me! I’ll try to do some tests again, and amend my Privoxy (and maybe i2pd) documentation.
To everybody in this thread: this should be the end of this off-topic excursion.
To contribute a little on-topic: to my knowledge there is currently no way to do per-application internet blocking (apart from the Android-native permission system, and Sailjail for SFOS Apps).