我怎样才能为我的安卓应用获得可怕的 WRITE_SECURE_SETTINGS 权限? [英] How can I get the dreaded WRITE_SECURE_SETTINGS permission for my android app?

查看:25
本文介绍了我怎样才能为我的安卓应用获得可怕的 WRITE_SECURE_SETTINGS 权限?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要能够打开和关闭 GPS 接收器,并且需要 WRITE_SECURE_SETTINGS 才能访问安全设置.我已经搜索了很多,我看到的每个答案几乎都说系统/固件之外的任何应用程序都无法获得该权限.

I need to be able to toggle the GPS receiver on and off, and WRITE_SECURE_SETTINGS is required to be able to access secure settings. I've searched around quite a bit, and every answer I saw pretty much said that no app outside of the system/firmware can get that permisssion.

然而,这完全是错误的.市场上有几个应用程序完全符合我的要求(关于 GPS),但还有更多应用程序具有 WRITE_SECURE_SETTINGS 权限.例如:

However, that is simply untrue. There are several apps on the market that do exactly what I'm trying to (in regards to GPS), but there are a bunch more that have the WRITE_SECURE_SETTINGS permissions. For example:

扩展控件

SwitchPro

个人资料流程

那么,如何做到这一点?

So, how can this be done?

推荐答案

我需要能够打开和关闭 GPS 接收器

I need to be able to toggle the GPS receiver on and off

出于隐私原因,如果不出意外,启用或禁用任何类型的位置跟踪需要完全由用户通过受信任的应用程序控制,而不是应任意第三方的要求.

For privacy reasons, if nothing else, enabling or disabling any sort of location-tracking needs to be solely in the hands of the user via trusted applications, not at the request of arbitrary third parties.

因此,如果您希望启用和禁用 GPS,请创建您自己的固件来满足您的需求,并在您希望的任何设备上加载该固件.或者,将您的更改贡献给现有的固件模块(例如 Cyanogen).

So, if you wish to enable and disable GPS, create your own firmware that does what you need and load that firmware on whatever devices you wish. Or, contribute your changes to existing firmware mods (e.g., Cyanogen).

需要 WRITE_SECURE_SETTINGS 才能访问安全设置

WRITE_SECURE_SETTINGS is required to be able to access secure settings

正确.

我已经搜索了很多,我看到的每个答案几乎都说系统/固件之外的任何应用程序都无法获得该权限.

I've searched around quite a bit, and every answer I saw pretty much said that no app outside of the system/firmware can get that permisssion.

正确.

然而,这完全是错误的.

However, that is simply untrue.

不,这是真的.

市场上有几个应用程序完全符合我的要求(关于 GPS)

There are several apps on the market that do exactly what I'm trying to (in regards to GPS)

他们发现了一个安全漏洞.我会采取措施确保这个漏洞得到修复.

They found a security loophole. I will take steps to help ensure this hole gets fixed.

但是还有很多拥有 WRITE_SECURE_SETTINGS 权限

but there are a bunch more that have the WRITE_SECURE_SETTINGS permissions

不,有很多人要求他们.您可以请求任何您想要的许可.您要求的是这些列表中显示的内容.你得到的是另一回事.

No, there are a bunch who ask for them. You can ask for whatever permission you want. What you ask for is what shows up in these listings. What you get is a different story.

这篇关于我怎样才能为我的安卓应用获得可怕的 WRITE_SECURE_SETTINGS 权限?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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