Closed jakhongirovjasurbek closed 1 year ago
Hi, this is the expected behavior.
And it's frustrating, this is where both, end-users and developers, gets upset. Unfortunately only rooted devices can access sdcard/Android folder from Android 12+ (and some Android 11 cases).
Some resources may be helpful: https://www.androidcentral.com/what-scoped-storage:
MANAGE_EXTERNAL_STORAGE
https://developer.android.com/training/data-storage/manage-all-files#operations-allowed-manage-external-storage (Write access to all internal storage directories, except for /Android/data/, /sdcard/Android, and most subdirectories of /sdcard/Android).Hi, this is the expected behavior.
And it's frustrating, this is where both, end-users and developers, gets upset. Unfortunately only rooted devices can access sdcard/Android folder from Android 12+ (and some Android 11 cases).
Some resources may be helpful: https://www.androidcentral.com/what-scoped-storage:
MANAGE_EXTERNAL_STORAGE
https://developer.android.com/training/data-storage/manage-all-files#operations-allowed-manage-external-storage (Write access to all internal storage directories, except for /Android/data/, /sdcard/Android, and most subdirectories of /sdcard/Android).- Issue that is not censored by Google (yet) pointing this scoped-storage issue https://issuetracker.google.com/issues/256669329#comment8.
- StackOverflow question about this problem https://stackoverflow.com/questions/69873673/android-12-storage-access-framework-scoped-storage-not-working-anymore.
- How to fix scoped-storage issue (Reddit discussion) https://www.reddit.com/r/AndroidQuestions/comments/qk9n44/to_protect_your_privacy_choose_another_folder_fix/.
- Google reason/excuses of scoped-storage access https://www.androidcentral.com/what-scoped-storage.
Hi dear ))
I see ) But, how do file managers are working in these versions as well then? )
There is already a SO question about this: https://stackoverflow.com/questions/71654722/how-do-i-navigate-the-external-storage-file-system-in-android-12.
In summary:
I would like to make a file manager app targeting API level 31 that requires access to all files on the device. To do this, I have followed the guidance here: https://developer.android.com/training/data-storage/manage-all-files.
R: You can't, at least on unrooted devices. Even with MANAGE_EXTERNAL_STORAGE, all that you have access to is external storage, not the entire device filesystem.
But I'm bit hopeful with Settings.ACTION_MANAGE_APP_ALL_FILES_ACCESS_PERMISSION
that the guy mentioned in the answers, take a look at it, though I'll not promise it will work since I never tried it.
https://developer.android.com/training/data-storage/manage-all-files.
Since there no more questions, I'll close this as wontfix since it is not a issue with the package itself.
Could not get full access to SD card I'm working on a file manager using flutter. Because of limitations of writing access to external storage is denied and new android versions are making it too hard to get access to folders like Android/data, Android/obb and sdcard/Android/, I tried Storage Access Framework (SAF). But, I see that even this package could not get full access to SD card because of privacy related issues. It is very easy to reproduce this error
Expected behavior A clear and concise description of what you expected to happen.
Screenshots
Android Phone