Android 6.0 permissions - OBB mount

Hi all!

I’m not sure if this is Unreal related question, or Android related, but still, we’ve approach a serious problem when deploying a game on some devices with API23.

First of all - from API23 the application must ask for any additional permissions (in form of alert for example). It should ask for an access to telephone, contacts, external storage etc. Thankfuly, we don’t need any extra permission from the for a game, right? Well, I was thinking like that but now we have some issues with Samsung Galaxy Sx family and with Nvidia Shield

At those devices the game simply cannot mount the OBB (I have an assertion on check in MountOBB method in AndroidFile.cpp)

The OBB file is located in the /storage/emulated/0/Android/obb/com.company.name/ directory.

When I enable the Storage permission in the app settings everything works.

When I request for the permission in the runtime using the requestPermissions method in Java everything works.

But still, reading OBB file from Android/obb directory, as far as I know, shouldn’t require any additional permissions!

More, the issue occurs only on some of the devices we’ve tested:

  • Samsung Galaxy S5, S6, S7
  • Nvidia Shield Tablet

On devices from Nexus family everything works fine.

On those devices there was also a problem with pushing obb via the bat file from Binaries. The access to the (…)/0/Android/obb was denied and only (…)/0/obb directory was accessible. Still, reading from this directory requires READ_EXTERNAL_STORAGE permission. I was able to push obb files to the proper directory via windows explorer.

Even more mysterious - when I push files to the /storage/emulated/0 directory and then by using the internal file manager copy them to the (…)/0/Android/obb directory, everything works fine!


Long story short:

  1. Does the /storage/emulated/0/Android/obb/com.company.name directory requires READ_EXTERNAL_STORAGE permission to read?

  2. If no, then why on Samsung Galaxy Sx it can’t read them?

  3. If yes, then are we really doomed to stick with the popup asking for permissions at the beginning of the game?

,

It’s a Play thing. This is a new feature in Android 6.0 and higher: Apps built for Android 6.0 and higher will ask for permissions once you start using them. [Find out more here][1].

https://support…com/googleplay/answer/6270602?p=app_permissions_m&rd=1

And I’ve just found this gem (exactly mine issue): https://code…com/p/android/issues/detail?id=197287
It seems Android or Play has bugs itself :frowning:

I have the same problem. If you solved the problem, can you share it with me?