Are there any adb commands to block specific apps from accessing mobile data/wifi or in general network acesss?

Achyu@lemmy.sdf.org to Android@lemmy.world – 21 points –

The system launcher on my phone has a data usage that is non-zero. I've already disabled background data for it.

I use Lawnchair2, but haven't tried to disable/uninstall the system launcher because I've read somewhere that it affects gesture navigation(Is it actually so?)

I know that apps like Netguard can help, but is there a more direct solution, other than rooting?

Are there any other adb commands that are useful, hopefully that are not too dangerous?

I've recently found
adb shell pm trim-caches 99999M
Clears all/most app cache, without having to install some cache clear or use Gfiles. I don't really use it often.


Along with this, does anyone know way to troubleshoot gmail not being able to download attachments on mobile data? I've not disabled background data for that.
Or should I make a separate post on it. Or would it be too tech-supporty?

12

You are viewing a single comment

If you disable the system launcher, you're gonna have a Bad Time.

Yes, it's responsible for the App Switcher, and some other stuff (I forget what - I once disabled it years ago, probably on Nougat. It was an interesting experiment that I never repeated).

NoRoot Firewall can block network access by being a VPN.

No, if you have another launcher installed with quickswitch support (like Lawnchair). Then you will be fine.

Note: QuickSwitch requires root. It's for gestures and navigation support.

No rootless or adb ways?

Any ways to restrict the system launcher then?

Just remove as much permissions as possible. If you want more control rooting is still "the choice". BTW Banking apps can work with root if that's the concern.

If you don't want root. Use a custom ROM like graphene(if your device is supported) or voltageos(if your device is not supported by graphene)

Ooh, didn't realize Lawnchair had Quickswitch, nice!

I have Netguard on my phone.
Asked to see if there were any direct solutions.

  • You can't revoke android.permission.INTERNET at runtime. You can only revoke at install time. Since you don't have root you can't revoke that permission.
  • Did you check settings? There is an option to remove background data access from an app.

I did disable the background data, but it still seems to use it
Probably because it comes to the foreground when I use gestures.