简体   繁体   English

如何安全地将数据存储在android设备中?

[英]How store the data in android device securely?

I have the problem to store the downloaded data in my android device Now I store the data on my sdcard, but this is not much prevent from the user. 我在将下载的数据存储在我的android设备中时遇到问题,现在我将数据存储在sdcard中,但这并不能阻止用户的使用。 I need to store the data securely from the user. 我需要安全地存储用户的数据。 How can I do that? 我怎样才能做到这一点?

there is no way you can prevent the user from accessing your data. 有没有办法可以阻止用户访问您的数据。 The max you can do is : 您最多可以做的是:

  1. Make the folders you create as hidden ( prefix the folder names with a . ) 将您创建的文件夹设置为隐藏(用.前缀文件夹名称)。
  2. remove the extension of the files you create, if possible. 如果可能,请删除您创建的文件的扩展名。 In most cases you can still access them & your files dont show up in other apps (like music players, Image viewers). 在大多数情况下,您仍然可以访问它们,并且文件不会显示在其他应用程序(例如音乐播放器,图像查看器)中。

For storing senstive data or some downloaded dat in the application , just use internal Storage. 要在应用程序中存储敏感数据或某些下载的数据,只需使用内部存储。 ie "data/data/{App package name}/{direcdtory name}". 即“数据/数据/ {应用程序包名称} / {目录名称}”。 if you store data inside the internal storage, only your application can access the data not the user nor other application. 如果将数据存储在内部存储器中,则只有您的应用程序可以访问数据,而用户和其他应用程序都不能访问。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM