breautek commented on issue #585: URL: https://github.com/apache/cordova-plugin-file/issues/585#issuecomment-1651738942
Two things about [MANAGE_EXTERNAL_STORAGE](https://developer.android.com/training/data-storage/manage-all-files) 1. The permission is suppose to allow broad programmatic access to files, similar to older API levels. Declaring the permisison is not enough however. The user must explicitly configure your app to allow broad filesystem access. This isn't done through a permission prompt. What the `MANAGE_EXTERNAL_STORAGE` permission declaration effectively does is make the Android OS produce settings UI to allow your app to have broad filesystem access. The user must still enable your app in the android settings. The app can produce an Intent to direct users to this settings screen: > Use the [ACTION_MANAGE_ALL_FILES_ACCESS_PERMISSION](https://developer.android.com/reference/android/provider/Settings#ACTION_MANAGE_ALL_FILES_ACCESS_PERMISSION) intent action to direct users to a system settings page where they can enable the following option for your app: Allow access to manage all files. Examples of such apps that Google will deem acceptable is: - File managers - Backup and restore apps - Anti-virus apps - Document management apps - On-device file search - Disk and file encryption - [Device-to-device data migration](https://developer.android.com/guide/topics/data/testingbackup#TestingTransfer) 2. `MANAGE_EXTERNAL_STORAGE` is protected, which means if you declare this permission then Google expects justification. If you intend to deploy through the Google Play store, you'll have to provide Google an explanation on why you *need* the permission. So depending on the nature of the app, using `MANAGE_EXTERNAL_STORAGE` may not be viable, in which case you need to use the MediaStore API as noted [here](https://github.com/apache/cordova-plugin-file/issues/585#issuecomment-1651312164). The file plugin doesn't make use of the MediaStore API and for the limitations noted above, it also cannot make use of `MANAGE_EXTERNAL_STORAGE` permission. I'm closing because there is nothing actionable for the file plugin here. A better area for open-ended discussions is [Apache Cordova Discussions](https://github.com/apache/cordova/discussions). -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
