android签名保护,android – 签名保护级别 – 澄清

参见英文答案 > Regarding Android Permissions and Signature Protection level                                    2个

由于我是Android的新手,我想问一些对我来说不够清楚的事情.我在阅读关于权限的API guide作为更多Q& A考虑到这个话题,但是,我不确定我是否正确理解它.因此,签名保护级别为:

A permission that the system grants only if the requesting application

is signed with the same certificate as the application that declared

the permission. If the certificates match, the system automatically

grants the permission without notifying the user or asking for the

user’s explicit approval.

这是否意味着我无法使用具有“签名”保护级别的任何权限,因此除了正在开发它的团队之外,任何人都无法使用Android API中定义的具有此类保护级别的所有权限?

解决方法:

Does this mean that I am not able to use any permission with ‘signature’ protection level, so all permissions defined in the Android’s API and having such protection level are unavailable to anyone, apart the team which is developing it?

一般来说,是的.

更具体地说,签名级别权​​限意味着应用程序使用该权限进行自我保护(例如,通过android:权限属性),并且尝试与需要权限的第一个应用程序(< uses-permission>元素)交谈的应用程序必须由相同的签名密钥签名.

如果应用程序防御本身是设备固件的一部分,或者是操作系统本身,则只有通过与该固件相同的签名密钥签名的应用程序才能通过持有权限与防御应用程序通信.

但是,如果您使用签名级权限(例如,自定义权限)编写自我保护的应用程序A,并且您编写了想要与应用程序A的防御部分进行通信的应用程序B,则可以执行此操作,如果您要签名App A和App B具有相同的签名密钥.

标签:android,android-permissions

来源: https://codeday.me/bug/20190928/1829729.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值