after the credentials are stored and the account exists
switch back to primary android user --> app works as expected
switch back to secondary android user --> app crashed immediately
Android version: 8.0.0
Device model: One Plus 3
Stock or customized system: Stock
Nextcloud app version: 3.1.0 (latest gplay app store version)
Nextcloud server version: 13.0.2 (latest official docker-hub version)
nothing interesting here
Insert your Nextcloud log here --> no entries created during app crash
NOTE: Be super sure to remove sensitive data like passwords, note that everybody can look here! You can use the Issue Template application to prefill some of the required information: https://apps.nextcloud.com/apps/issuetemplate
Can you provide us additional infos via logcat? https://github.com/nextcloud/android/blob/master/README.md#getting-debug-info-via-logcat
@AndyScherzinger I know you also have an OnePlus.
Somehow I cannot even start the app as a second user, can you try it please?
Sorry, i am very busy at the moment. I will look into it and try to provide the necessary logs. I hope i will get into this at the weekend.
Same issue with Android work profile.
App works correct in user profile but crashes in work profile during login attempt.
Android 8.0.0
Huawei P10
I can try to provide a logfile if you send me the command to use logcat on a windows client
Here ist the part of the logfile concerning nextcloud.
logcat_nextcloud.log
Process: com.nextcloud.client, PID: 4804
06-08 08:04:12.399 4804 7925 E AndroidRuntime: java.lang.SecurityException: get package info: Neither user 1010181 nor current process has android.permission.INTERACT_ACROSS_USERS.
06-08 08:04:12.399 4804 7925 E AndroidRuntime: at android.os.Parcel.readException(Parcel.java:1945)
06-08 08:04:12.399 4804 7925 E AndroidRuntime: at android.os.Parcel.readException(Parcel.java:1891)
06-08 08:04:12.399 4804 7925 E AndroidRuntime: at android.accounts.IAccountManager$Stub$Proxy.getAuthToken(IAccountManager.java:1488)
06-08 08:04:12.399 4804 7925 E AndroidRuntime: at android.accounts.AccountManager$11.doWork(AccountManager.java:1749)
06-08 08:04:12.399 4804 7925 E AndroidRuntime: at android.accounts.AccountManager$AmsTask.start(AccountManager.java:2240)
06-08 08:04:12.399 4804 7925 E AndroidRuntime: at android.accounts.AccountManager.getAuthToken(AccountManager.java:1746)
06-08 08:04:12.399 4804 7925 E AndroidRuntime: at android.accounts.AccountManager.getAuthToken(AccountManager.java:1658)
06-08 08:04:12.399 4804 7925 E AndroidRuntime: at android.accounts.AccountManager.blockingGetAuthToken(AccountManager.java:1495)
06-08 08:04:12.399 4804 7925 E AndroidRuntime: at com.owncloud.android.lib.common.OwnCloudClientFactory.createOwnCloudClient(OwnCloudClientFactory.java:109)
06-08 08:04:12.399 4804 7925 E AndroidRuntime: at com.owncloud.android.utils.ConnectivityUtils.isInternetWalled(ConnectivityUtils.java:67)
06-08 08:04:12.399 4804 7925 E AndroidRuntime: at com.owncloud.android.files.services.FileUploader$UploadRequester.retryFailedUploads(FileUploader.java:397)
06-08 08:04:12.399 4804 7925 E AndroidRuntime: at com.owncloud.android.utils.FilesSyncHelper.lambda$restartJobsIfNeeded$0$FilesSyncHelper(FilesSyncHelper.java:239)
06-08 08:04:12.399 4804 7925 E AndroidRuntime: at com.owncloud.android.utils.FilesSyncHelper$$Lambda$0.run(Unknown Source:4)
06-08 08:04:12.399 4804 7925 E AndroidRuntime: at java.lang.Thread.run(Thread.java:784)
As far as I read, this permission would require that the app is signed via the android system, which is not true if it is installed via gplay/other store.
Anyway, thank you @noriyuki41 for providing the root problem :+1:
@tobiasKaminsky so how would/could this be fixed? Or is this not possible?
I found nothing valid. Only other devs who are also out of clue as there are some apps where it is working, but some not.
I tried it on my onePlus3, with LineageOS and installed current App via fdroid on both user "Tobi" and "test".
It worked for me without a problem and I can access & download the files.
@tobiasKaminsky interesting, that LineageOS is able to run it on a secondary user and the stock OxygenOS is not. Is there some kind of relaxed rights management ongoing on LineageOS?
Good question, but maybe it is more related to fdroid and the priviliged right extension, with which I am installing the apps.
AFAIK @AndyScherzinger has a OnePlus3T with Lineage and Google stuff, maybe he can test.
i got the same entries in my logcat:
06-08 06:38:51.934 9631 9677 E AndroidRuntime: FATAL EXCEPTION: Thread-4
06-08 06:38:51.934 9631 9677 E AndroidRuntime: Process: com.nextcloud.client, PID: 9631
06-08 06:38:51.934 9631 9677 E AndroidRuntime: java.lang.SecurityException: get package info: Neither user 1110116 nor current process has android.permission.INTERACT_ACROSS_USERS.
06-08 06:38:51.934 9631 9677 E AndroidRuntime: at android.os.Parcel.readException(Parcel.java:1942)
06-08 06:38:51.934 9631 9677 E AndroidRuntime: at android.os.Parcel.readException(Parcel.java:1888)
06-08 06:38:51.934 9631 9677 E AndroidRuntime: at android.accounts.IAccountManager$Stub$Proxy.getAuthToken(IAccountManager.java:1488)
06-08 06:38:51.934 9631 9677 E AndroidRuntime: at android.accounts.AccountManager$11.doWork(AccountManager.java:1767)
06-08 06:38:51.934 9631 9677 E AndroidRuntime: at android.accounts.AccountManager$AmsTask.start(AccountManager.java:2265)
06-08 06:38:51.934 9631 9677 E AndroidRuntime: at android.accounts.AccountManager.getAuthToken(AccountManager.java:1763)
06-08 06:38:51.934 9631 9677 E AndroidRuntime: at android.accounts.AccountManager.getAuthToken(AccountManager.java:1675)
06-08 06:38:51.934 9631 9677 E AndroidRuntime: at android.accounts.AccountManager.blockingGetAuthToken(AccountManager.java:1511)
06-08 06:38:51.934 9631 9677 E AndroidRuntime: at com.owncloud.android.lib.common.OwnCloudClientFactory.createOwnCloudClient(OwnCloudClientFactory.java:109)
06-08 06:38:51.934 9631 9677 E AndroidRuntime: at com.owncloud.android.utils.ConnectivityUtils.isInternetWalled(ConnectivityUtils.java:67)
06-08 06:38:51.934 9631 9677 E AndroidRuntime: at com.owncloud.android.utils.FilesSyncHelper.lambda$restartJobsIfNeeded$0$FilesSyncHelper(FilesSyncHelper.java:238)
06-08 06:38:51.934 9631 9677 E AndroidRuntime: at com.owncloud.android.utils.FilesSyncHelper$$Lambda$0.run(Unknown Source:4)
06-08 06:38:51.934 9631 9677 E AndroidRuntime: at java.lang.Thread.run(Thread.java:764)
@tobiasKaminsky How did you manage to install the app with privileged rights?
Privileged rights is a fdroid extensions: https://f-droid.org/en/packages/org.fdroid.fdroid.privileged/
It basically allows fdroid to install any app, so that you do not have to manually accept every app update.
But it should make no difference, I assume.
Same here: Huawei MediaTab M5, Android 8.0.0, FDroid, tried both Nextcloud app and Nextcloud Dev app, Nextcloud server 13.0.4. (Works for primary user without issues.)
I have this issue too, using Shelter to manage the work profile. The problem disappeared when I installed nextcloud dev directly into the work profile using f-droid (separate installations, from gplay in my main one, and dev from f-droid in the work profile).
This request did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!