Android app login fails after "grant access" stage

Operation finished with HTTP status code -1 (fail)

I get the exact same error message on all Android devices i tested. Galaxy S23 and Galaxy S10+ with all original Nextcloud apps (Sync, Notes, Talk). Login loops indefinitely…

Nextcloud AIO (portainer): 10.0.0 (latest) behind NetScaler reverse proxy
Nextcloud Sync: 3.29.2
Nextcloud Notes: 3.8

Other Android apps like any web browser, Quillpad or Joplin can authenticate with the same credentials without issues.
Same is true for iOS devices and Windows 11 that authenticate also without issues and with the origial Nextcloud apps. So it is an Android only issue.

The original Nextcloud apps seem to authenticate in a different way than 3rd party apps and this method seems to break the authentication.

config.php has been checked:

‘overwritehost’ => ‘set to external fqdn’,
‘overwriteprotocol’ => ‘https’,
‘trusted_domains’ =>
array (
0 => ‘localhost’,
1 => ‘set to external fqdn’,
2 => ‘192.168.1.20’,
3 => ‘127.0.0.1’,
),

No errors in the Nextcloud logs, only successful LDAP login:

Information user_ldap OCA\User_LDAP\LoginListener - Notes postLogin

Any help would be greatly appreciated.

Hi @ReaSoner, welcome to Nextcloud community :handshake:

I split your port into separate topic. please avoid reviving old topics without a reason. I’m very very confident your situation is completely different than another one posted 3 years ago.

Please add details and especially logs as per required support template don’t forget client and Citrix logs showing the problem. Please edit into your post and add as many information as possible. This will give us the technical info and logs needed to help you!

Please check your proxy log for the HTTP transactions generated during these attempts.

Also please double-check no errors or warnings under Admin settings–>Overview.