Android模拟器的root访问权限的应用程序 [英] Android emulator root access app

查看:499
本文介绍了Android模拟器的root访问权限的应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我无法将文件复制到Android模拟器的虚拟SD卡。我创建一个应用程序,将数据复制/数据/包文件夹复制到SD卡。这工作得很好,当应用程序复制了自己的包,但它不会用于其他应用做到这一点。我曾看着其他话题,但我似乎无法给我的应用程序的超级用户状态。

I am having trouble copying files to the virtual sdcard on the android emulator. I am creating an app that copies the data/data/package folder to the sdcard. This works fine when the app copies its own package but it won't do it for other apps. I have looked into other topics, but I can't seem to give my app super user status.

推荐答案

从Android开发的安全性和权限

From Android Developers, Security and Permissions:

在Android安全架构的核心设计的一点是,没有
  应用程序,默认情况下,有进行任何操作该权限
  将其它应用程序,操作系统,或不利地影响
  用户。这包括读或写用户的隐私数据
  (如联系人或电子邮件),读取或写入其他
  应用程序的文件,访问网络,保持设备
  醒等。

A central design point of the Android security architecture is that no application, by default, has permission to perform any operations that would adversely impact other applications, the operating system, or the user. This includes reading or writing the user's private data (such as contacts or e-mails), reading or writing another application's files, performing network access, keeping the device awake, etc.

此外,

由于从彼此,应用程序的Andr​​oid沙箱的应用
  必须明确共享资源和数据。他们通过宣称这样做
  他们需要的不是提供的额外功能的权限
  基本沙箱。

Because Android sandboxes applications from each other, applications must explicitly share resources and data. They do this by declaring the permissions they need for additional capabilities not provided by the basic sandbox.

所以,这回答你,为什么你不能写从其他应用程序数据的问题。为了做到你想要什么,在应用程序之间共享数据,您需要注册具有相同签名的应用程序和要求相同的 sharedUserId ,因为它是在上面的链接显示

So, this answers your question about why you cannot write data from other applications. In order to do what you want, share data between applications, you need to sign the applications with the same signature and request the same sharedUserId, as it is shown in the above link.

这篇关于Android模拟器的root访问权限的应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆