1

Android adb shell has extra permissions compared to ordinary applications. For example, it can access all or most /proc subdirectories. How to run shell with permissions as if it was an ordinary application?

jozols
  • 560
  • 7
  • 22

1 Answers1

2

You can run a specific shell command for a specific debuggable package like this:

adb shell "run-as com.example.mypackage my_command"

scottt
  • 8,301
  • 1
  • 31
  • 41