[英]How to grant su permission to app after unroot?
What I want:我想要的是:
I want my app to use su command to take screenshot in background even after I unroot the phone.我希望我的应用程序使用 su 命令在后台截屏,即使我取消了手机的根目录。
code example:代码示例:
val process = Runtime.getRuntime().exec("su")
val outputStream = OutputStreamWriter(process.outputStream)
outputStream.write("/system/bin/screencap -p\n")
What I tried:我尝试了什么:
I thought I will just root my phone and install the app in priv-app folder and then unroot but it's not working like that.我以为我会根我的手机并将应用程序安装在 priv-app 文件夹中,然后取消根,但它不是那样工作的。
How can I do this?我怎样才能做到这一点?
It's impossible to grant root access after unrooting.取消root后无法授予root访问权限。 You can give fake root access in termux but it just shows #.
您可以在 termux 中提供虚假的 root 访问权限,但它只显示 #。 So no use.
所以没用。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.