I just ugraded to NC 31.0.0 via the web updater.
It left the app “TwoFactorEmail” enabled, even though it is not compatible with this server version.
As a result, every user with 2FA enabled was not able to login.
The server log showed
“Could not load two-factor auth provider OCA\TwoFactorEmail\Provider\Email”
Since the admin account was also 2FA enabled, I had to login with ssh and disable the app manually:
sudo -u www-data php occ app:disable twofactor_email
I hope this helps other users with the same issue.
Twofactor_email seems not supported anymore.
I don’t know why you don’t use standard 2FA, e.g. with Google Authenticator. Because you’re afraid of smartphones or Google? That’s complete rubbish, of course. Just use TOTP with Google Authenticator, for example.
The use of e-mail is a risk. If malware is installed on the PC, the attacker can obtain the access data for Nextcloud and e-mail. Strictly speaking, this is not a real 2FA. Although if you use Nextcloud and TOTP on the same smartphone, it’s not really 2FA either.