Upgraded to NC14 and now can't login

Hi

I’ve upgraded a NC instance from 13 to 14 (no errors in the upgrade) and now I can’t login with the web interface, after I introduce the credentials the url is redirected to https://mydomain.com/index.php/login?redirect_url=/index.php/apps/files/ but login screen is reloaded, it’s just a infinite loop.

I’ve compared all the apps in that instance with another that is running fine with v14 and are the same (some people with same problems have solved same issue disabling some app), this instace had spreed installed but it’s disabled, don’t know if that can cause the problem.

I’ve take a look to nextcloud.log, apache logs…but there aren’t errors there, all seems ok.

Any hint?

1 Like

This should solve your issue:

It will be fixed in Nextcloud 14.0.1

1 Like

Meanwhile, is there any way to fix manually in v14.0.0?

Edit: fixed, I’ve modifyed PublicKeyTokenProvider.php and now all works fine.

how did you fixed/modifyed the publickeytokenprovider.php Better question where i can find this file.

Have the same Problem

Click on the link I provided and then click on „Changes“ or “Files changed”

Bernie_O has send the link with the solution, anyway if you are not familiar with git may be hard to understand.

Just edit this file (from your nextcloud root path):

lib/private/Authentication/Token/PublicKeyTokenProvider.php

Go to line 83 or find the string:

if ($token->getExpires() !== null && $token->getExpires() < $this->time->getTime()) {

and replace it with:

if ($token->getExpires() !== null && $token->getExpires() !== 0 && $token->getExpires() < $this->time->getTime()) {

Save and enjoy :slight_smile:

1 Like

The solution zx81 provided helped. But you have to live with an integrity check error afterwards

For Docker users: At the moment using nextcloud:latest will have the same problem.
We used nextcloud:14.0.1-rc for now.