找出设备是否全磁盘加密,并使用了什么加密? [英] Find out whether the device is full disk encrypted and what encryption was used?

查看:170
本文介绍了找出设备是否全磁盘加密,并使用了什么加密?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

由于Android 3.0的全磁盘加密是支持的,但我不能看到这种能力的API。我需要知道的两个具体的事情是:

Since Android 3.0 full disk encryption is supported, but I can't see any API to that ability. The two specific things I need to know are:


  1. 设备是否被加密?

  2. 使用何种加密。

我发现这里中的工艺水平低的解释,它似乎建议使用的加密是AES 128 CBC与和ESSIV:SHA256,但它并没有谈论办法找到该设备是否被加密

I found a low level explanation of the process here and it seems to suggest the encryption used is 128 AES with CBC and ESSIV:SHA256, but it does not talk about a way to find whether the device is encrypted.

那么,有没有办法我的应用程序可以在设备是否使用了全磁盘加密功能查询,或者我需要求助于哈克解决方案,如要求的Runtime.exec?

So, is there a way my app can query whether the device is using the full disk encryption feature, or do I need to resort to hacky solutions like Runtime.exec calls?

推荐答案

我认为你正在寻找的API是的设备管理API 的。具体来说,你需要建立一个DeviceAdminReceiver,并在使用的策略device_admin.xml的部分中,添加一个加密存储元素。然后,你就可以自由地调用setStorageEncryption指示执行什么类型的加密。 <一href=\"http://developer.android.com/resources/samples/ApiDemos/src/com/example/android/apis/app/DeviceAdminSample.html\"相对=nofollow> DeviceAdminSample.java 应该为你提供多少code你需要的。这是一种找出该设备是否被加密的一种间接的方式,但它是唯一的公共API,我知道的。

I think the API you're looking for is part of the Device Administration APIs. Specifically, you'll need to set up a DeviceAdminReceiver and, in the "uses-policies" section of device_admin.xml, add an "encrypted-storage" element. Then you'll be free to call setStorageEncryption to indicate what type of encryption to enforce. DeviceAdminSample.java should provide you with much of the code you'll need. This is kind of an indirect way of finding out whether the device is encrypted, but it's the only public API I know of.

这也不会告诉你正在使用什么类型的加密...我一直没能找到一个API为。

This also won't tell you what kind of encryption is being used... I haven't been able to find an API for that.

这篇关于找出设备是否全磁盘加密,并使用了什么加密?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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