admin管理员组文章数量:1314575
I want to create a local blob storage system where I can upload files, and they will be stored in a location inaccessible to file pickers and the gallery—only my app should have access to them.
I initially tried using SQLite to store the files, but it didn’t work as expected. Ideally, I need a solution that ensures:
- The files are stored securely on the device.
- They remain hidden from other apps, file explorers, and media pickers.
- Only my app can access and retrieve these files when needed.
What would be the best approach to achieve this? Are there any specific databases, file storage mechanisms, or encryption techniques I should consider?
Any guidance or code examples would be greatly appreciated!
I want to create a local blob storage system where I can upload files, and they will be stored in a location inaccessible to file pickers and the gallery—only my app should have access to them.
I initially tried using SQLite to store the files, but it didn’t work as expected. Ideally, I need a solution that ensures:
- The files are stored securely on the device.
- They remain hidden from other apps, file explorers, and media pickers.
- Only my app can access and retrieve these files when needed.
What would be the best approach to achieve this? Are there any specific databases, file storage mechanisms, or encryption techniques I should consider?
Any guidance or code examples would be greatly appreciated!
Share Improve this question asked Jan 30 at 12:48 Anshuman SharmaAnshuman Sharma 158 bronze badges1 Answer
Reset to default 0Files stored in internal storage (context.getFilesDir()) are only accessible to your app by default. Other apps (including file explorers and media pickers) cannot access them.
File file = new File(context.getFilesDir(), "secure_blob.dat");
FileOutputStream fos = new FileOutputStream(file);
fos.write(fileData);
fos.close();
本文标签: databaseHow to Store Files Privately in Local Storage for AppOnly Access in FlutterStack Overflow
版权声明:本文标题:database - How to Store Files Privately in Local Storage for App-Only Access in Flutter? - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1741964720a2407479.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论