¿Cómo cambiar los permisos de archivos de Android en la memoria interna para que sean MODE_PRIVATE?

I have an app that tries to read a file in internal memory in it's /data/data/appname folder. However, I need to inject that file within that folder before it can read it (assuming this is a rooted device).

How do I change the permissions such that only the app can read it? I tried to programmatically create a file, and then use chmod to check the permissions, and the user/group are both app_18. How do I create a file with the same parameters?


preguntado el 04 de julio de 12 a las 10:07

1 Respuestas

In android when you create a file in application's internal storage (/data/data/<package_name>) Por defecto tiene un MODO_PRIVADO permission. (Its private to your application)

Android - InternalStorage

Respondido 04 Jul 12, 10:07

No es la respuesta que estás buscando? Examinar otras preguntas etiquetadas or haz tu propia pregunta.