Nextcloud iOS app not able to use two-factor authentication

From Nexcloud version 11 we are using Two-Factor Authentication. This works fine using Nextcloud in a web browser and using the Nextcloud Android app. Using FreeOTP or Google Authenticator. Current Nextcloud version is 11.0.2.

I switched from Android to iPhone and had to buy the Nextcloud app.
Version 2.17.3 of the Nextcloud iOS app was installed.

Entered the Nexcloud URL, username and password.
Following error occurs “Request failed: unauthorized (401)” and no way to enter the two factor authentication code.
In the Nextcloud logging the error “Warning core Login failed: ‘myname’ (Remote IP: ‘myip’)” is visible.

What do I have to do to connect my user using two-factor on my iPhone ?
Thank you.

1 Like

Use an application specific password from your personal settings page.

1 Like

Hello,
Thank you. Of course this is the solution.

Login into Nextcloud using my personal account. Then
TOTP second-factor auth => App passwords
Enter App Name and Generate New App password.
Enter this code in the password field of the iOS app.

I suppose this is the same for Android. So sorry for my confusion.
Thanks again.

Best regards

I am having a problem when I attempt to use the app password. After creating a user and then logging in with that user and going to personal and trying to assign an app password, it seems to default to admin for username and I am unable to change this. Any suggestions on how to resolve this?

Maybe login with another browser?

@STrike I thought that also, and had the same results. You get the box that has the username and then displays the password and gives the warning about this password will only be displayed once. I used the admin as username and then even if it is a regular user it signs them into my admin account (could very this as on the iphone of the user it displays the admin avitar.

Is this perhaps a bug and should be reported to the developers? THanks for your reply I appreciate it.

@albrechtar
idk, i haven´t got any ios device. But yesterday one of my android devices couldn´t login, too. The server was unreachable after login attempt. I found out that the failed logins flooded the table oc_bruteforce_attemps and blocked the ip of the device, that I couldn´t login. maybe it´s the same issue :wink:

Maybe it would help you to clear the table, if it isn´t empty :wink: