AsteroidOS / AsteroidOSSync

Android application to synchronize a phone with a watch running asteroid-btsyncd.
GNU General Public License v3.0
100 stars 37 forks source link

[0.25] Can not grant permissions on Android 13 #180

Closed eLtMosen closed 1 year ago

eLtMosen commented 1 year ago

https://twitter.com/APO_161/status/1589983426522025986 grafik

LeOS-GSI commented 1 year ago

I'm the developer of LeOS-GSI. It's LineageOS-20 based and full ungoogled, but with as special LeOS-MicroG version.

Note: My LeOS doesn't allow any connection to any google server.

MagneFire commented 1 year ago

I'm the developer of LeOS-GSI. It's LineageOS-20 based and full ungoogled, but with as special LeOS-MicroG version.

Note: My LeOS doesn't allow any connection to any google server.

Thanks for providing some information, can you also give some more insight on what happens? Does the app crash when it "prompts" for the notification permission? Also, a logcat of the wpp would be massively useful.

LeOS-GSI commented 1 year ago

IMG_20221109_204943_128 IMG_20221109_204938_023

Please see attached screenshots. I'm not able to grand notification permission. That without error message is while app first run setup The other is when trying to give the permission via settings/apps/

derEremit commented 1 year ago

same thing here Graphenos Android 13

I installed through f-droid

experiencing what is explained here: https://blog.esper.io/android-13-sideloading-restriction-harder-malware-abuse-accessibility-apis/

derEremit commented 1 year ago

and after re-reading the link I posted above, this is a workaround:

"These restrictions are tied to a new permission in Android 13 called ACCESS_RESTRICTED_SETTINGS. This permission controls whether or not the user can enable an app’s accessibility service. When an app has been sideloaded using the non-session method, ACCESS_RESTRICTED_SETTINGS is first set to “deny”. After viewing the “restricted setting” dialog, ACCESS_RESTRICTED_SETTINGS is set to “ignore.” At this point, the user can go to the app info page for the app in question, tap the three-dot menu, and then tap “allow restricted settings” to unblock access to the accessibility service. The user will then be asked to authenticate themselves, and if they pass, ACCESS_RESTRICTED_SETTINGS will be set to “allow” for the app. The system does not tell the user they can do this, but this could change in future Android 13 builds."

jrtberlin commented 1 year ago

When an app has been sideloaded using the non-session method, ACCESS_RESTRICTED_SETTINGS is first set to “deny”.

So F-Droids old installation method triggers it. Maybe there is a way to check if the app is installed that way and guide the user to the settings menu.

Some additional info: https://android.googlesource.com/platform/frameworks/base/+/master/core/java/android/permission/Permissions.md#restricted-permissions

Related issue at F-Droid: https://gitlab.com/fdroid/fdroidclient/-/issues/1836

eLtMosen commented 1 year ago

Fixed at least in 0.28

duhrer commented 3 months ago

Same problem on Android 13 (as distributed by FairPhone) with 0.29. I had to use the instructions in the blog post before I could grant the required permissions and continue the process.