No red error banner should pop up when opening the app.
I see this:

Point Nextcloud for iOS to server that uses LDAP based authentication.
Red error banners give an impression of a buggy product.
iOS 13.3.1
2.25.8
Operating system: FreeBSD
Web server: nginx with php-fpm
Database: PostgreSQL 11
PHP version: 7.2
Nextcloud version: (see Nextcloud admin page) 17.0.2
Same here.
This seems connected with the issues from #1147. The app sometimes is requesting a file with [uid] when it should be the [uuid]
From the apache accesslog:
[server] [client] - - [14/Feb/2020:23:59:44 +0100] "GET /index.php/avatar/[myuid]/128 HTTP/2.0" 404 0 "-" "Mozilla/5.0 (iOS) Nextcloud-iOS/2.25.8"
[server] [client] - - [14/Feb/2020:23:59:52 +0100] "GET /index.php/avatar/[myuid]/128 HTTP/2.0" 404 588 "-" "Mozilla/5.0 (iOS) Nextcloud-iOS/2.25.8"
[server] [client] - - [15/Feb/2020:00:08:44 +0100] "GET /index.php/avatar/[myuid]/128 HTTP/2.0" 404 583 "-" "Mozilla/5.0 (iOS) Nextcloud-iOS/2.25.8"
[server] [client] - - [15/Feb/2020:00:08:44 +0100] "GET /index.php/avatar/[myuuid]/128 HTTP/2.0" 200 7858 "-" "Mozilla/5.0 (iOS) Nextcloud-iOS/2.25.8"
[server] [client] - - [15/Feb/2020:00:08:42 +0100] "GET /index.php/avatar/[myuuid]/128 HTTP/2.0" 200 7821 "-" "Mozilla/5.0 (iOS) Nextcloud-iOS/2.25.8"
[server] [client] - - [15/Feb/2020:00:08:44 +0100] "GET /index.php/avatar/[myuuid]/128 HTTP/2.0" 304 421 "-" "Mozilla/5.0 (iOS) Nextcloud-iOS/2.25.8"
[server] [client] - - [15/Feb/2020:00:11:09 +0100] "GET /index.php/avatar/[myuid]/128 HTTP/2.0" 404 587 "-" "Mozilla/5.0 (iOS) Nextcloud-iOS/2.25.8"
[server] [otherclient] - - [15/Feb/2020:00:29:48 +0100] "PROPFIND /remote.php/dav/files/[myuuid]/ HTTP/2.0" 207 10267 "-" "Mozilla/5.0 (Windows) mirall/2.6.2stable-Win64 (build 20191224) (Nextcloud)"
[server] [client ] - - [15/Feb/2020:00:24:40 +0100] "REPORT /remote.php/dav/files/[myuid] HTTP/2.0" 404 286 "-" "Mozilla/5.0 (iOS) Nextcloud-iOS/2.25.8"
same here as I mentioned in
https://github.com/nextcloud/ios/issues/1147
and this also affect some other part of the app like ability to favorite files : https://github.com/nextcloud/ios/issues/223
as posted in issue 1147:
Hi,
before the update I had both 401 error and 404.
the 401 part seems solved (#1153), but not the 404 error as it is still occurring even with the update.
I have taken some time to debug this.
It has been a while the ios app is giving some difficulties for users from ldap db using a uuid as identifier.
First ability to mark as favorite or remove, then ability to edit existing text files, and recently errors when trying to to anything from navigating to opening a file. (#223)
If you check in the nextcloud apps this is logged as failure to login, while the app is well logged in and able to navigating ( while throwing 401 and 404 errors mentioned above).
if you take care at the apache access_log you then understand what is happening
let's say you have user mylogin which has been linked from ldap db with a uuid 5279b38a-b8ed-1031-9373-cf418e4c8c3b (default behaviour of nextcloud)
if you try to access a file from the web interface you will hit at a moment the search for your avatar :
GET /nextcloud/index.php/avatar/5279b38a-b8ed-1031-9373-cf418e4c8c3b/128
but the app does
GET /nextcloud/index.php/avatar/mylogin/128
and hits a 404
"GET /nextcloud/index.php/avatar/mylogin/128 HTTP/1.1" 404 - "-" "Mozilla/5.0 (iOS) Nextcloud-iOS/2.25.8"
"REPORT /nextcloud/remote.php/dav/files/mylogin HTTP/1.1" 404 225 "-" "Mozilla/5.0 (iOS) Nextcloud-iOS/2.25.8"
As I said for the 401 part seems fixed for now
"PROPFIND /nextcloud/remote.php/webdav HTTP/1.1" 401 343 "-" "Mozilla/5.0 (iOS) Nextcloud-iOS/2.25.6"
"PROPFIND /nextcloud/remote.php/webdav HTTP/1.1" 207 1183 "-" "Mozilla/5.0 (iOS) Nextcloud-iOS/2.25.8"
normal, either mylogin does not exist or is not the same user for nextcloud.
further more as default behaviour uuid is not supposed to be used as a login name, only the username and email from the ldap dp are accepted.
So the real fix would be to get the ios app translate the login used to the nextcloud uuid and start creating again all the URL with it instead of the login used.
a workaround is something proposed on some forum post, ie modify the default behaviour of ldap nextcloud implementation and risking collision between usernames from different db.
references:
https://bugs.contribs.org/show_bug.cgi?id=10876
https://help.nextcloud.com/t/ios-2-17-nc-11-0-3-error-404-with-ldap-users-and-favorites-folder-solved/11772/5
and yes I can say that both this issue and 223 are related and are fixed the same way +1 I tested migrating all my ldap users on one instance of nextcloud I control and not on the others, guess what, the one where I changed the ldap integration (which again is not suitable to do ) has stop throwing errors as reported here, and also fixed the #223 issue before updating the ios app.
everything used to work in the past, so something must have changed either in the ios app or in the server code to not translate login name to correct user uuid, and it would be good to reverse this.
I'm facing the same red 404.
My LDAP user names matching the nextcloud data folder, but on a custom location.
Is there anything new related to this issue ?
will it be solved with the next planned iOS app release (2.25.9) ?
@jonguerre it doesn't turn out to be a bug
@marinofaggiana ok but what is the solution or the workaround for this then ? this error was not on old iOS app versions...
I'm trying to understand where it comes from, but I have no data on it
@marinofaggiana ok many thanks for your reply, you can get some important infos from the post from unnilennium: https://github.com/nextcloud/ios/issues/1159#issuecomment-586554776
"let's say you have user mylogin which has been linked from ldap db with a uuid 5279b38a-b8ed-1031-9373-cf418e4c8c3b (default behaviour of nextcloud)
if you try to access a file from the web interface you will hit at a moment the search for your avatar :
GET /nextcloud/index.php/avatar/5279b38a-b8ed-1031-9373-cf418e4c8c3b/128
but the app does
GET /nextcloud/index.php/avatar/mylogin/128
and hits a 404"
the iOS app seems to use the LDAP UID (login ID, username) instead of UUID (5279b38a-b8ed-1031-9373-cf418e4c8c3b)
@jonguerre it doesn't turn out to be a bug
Are you serious? This is very clearly a bug! Your app tries to access the wrong URLs!
@bnavigator @jonguerre Today I public the new version 2.25.9, please try, probability already fixed
I don't have access to an iPhone for the rest of the day to check, but maybe one of my users can update and I see the correct entries in the log.
Either way, even if it was fixed, this was a bug.
@bnavigator sure ! but the new version will be today available only in TestFlight, next days in Apple Store, please report here if is fixed.
Thanks. Appreciate your work.
It would help a lot if you referenced the commits by which you fix the bugs. That way more people could review and help.
Version 2.25.9 Build 2 available in TestFlight
@marinofaggiana I've had the same issue, and it looks like 2.25.9 Build 2 available in TestFlight fixes the issue, I no longer get error 404 when I launch the Nextcloud client. Thanks!
This seems to be fixed for me with version 2.25.9 of Nextcloud for iOS. Thanks @marinofaggiana !!!
Seems to work for me in 2.25.9 Build 2 too.
Many thanks !
I have the same issue even with 2.25.9
Most helpful comment
@bnavigator sure ! but the new version will be today available only in TestFlight, next days in Apple Store, please report here if is fixed.