4

How is it possible to secure all the content downloaded by application? We need these files to be available only for this single app and can't be copied/viewed by any other app or by USB cable.

Sergey Metlov
  • 24,666
  • 27
  • 90
  • 147

3 Answers3

1

Referring to the documentation http://developer.android.com/guide/topics/data/data-storage.html#filesInternal

By default, files saved to the internal storage are private to your application and other applications cannot access them (nor can the user).

grig
  • 849
  • 5
  • 15
1

You can keep your files in internal memory. Try the following code

File myFolder = context.getDir("DirectoryName", Context.MODE_PRIVATE); //Create folder in internal memory;
File myFile = new File(myFolder, "fileName"); //Create file inside the folder.
FileOutputStream ouStreamt = new FileOutputStream(myFile);

Use the ouStreamt to write your content into the file. Hope this will help you

Anu
  • 1,874
  • 13
  • 30
1

You can implement file encrytion\dercyption if it's really needed - link. But in most cases internal storage would be secure enough.

Community
  • 1
  • 1
Grecha
  • 119
  • 1
  • 11