Kavita icon indicating copy to clipboard operation
Kavita copied to clipboard

Can't log in after hotfix

Open lukaszliniewicz opened this issue 1 year ago • 6 comments

Hi, after installing the hotfix update (the second one hasn't changed this), I can't log in to my server. The login page is displayed correctly, but when correct credentials are provided, nothing happens. Wrong credentials cause an error message to pop up. This happens on Chrome and Edge, and Firefox doesn't even display the login page correctly (just a black bar). The server is running on Linux Mint 20.2 (x64). This is the output in the terminal after I try to log in:


      Request starting HTTP/1.1 POST http://redacted/hubs/messages/negotiate?negotiateVersion=1 text/plain;charset=UTF-8 0
info: Microsoft.AspNetCore.Authorization.DefaultAuthorizationService[2]
      Authorization failed. These requirements were not met:
      DenyAnonymousAuthorizationRequirement: Requires an authenticated user.
info: Microsoft.AspNetCore.Authentication.JwtBearer.JwtBearerHandler[12]
      AuthenticationScheme: Bearer was challenged.
info: Microsoft.AspNetCore.ResponseCaching.ResponseCachingMiddleware[27]
      The response could not be cached for this request.

lukaszliniewicz avatar Aug 09 '22 19:08 lukaszliniewicz

Hi, I redacted your logs since it exposed your server url.

Can you validate you're on v0.4.5.2? You can see in logs or in console window when you start your server manually.

majora2007 avatar Aug 12 '22 01:08 majora2007

Thank you. Yes, I was certainly on the newest release. For now I downgraded to 0.4.5 and things went back to normal.

lukaszliniewicz avatar Aug 12 '22 20:08 lukaszliniewicz

I'm having the same issue and it seems to be related to loading external content (download-content) after login (css theme). If we already have a valid session with that file loaded on cache the dashboard will load. If not, we get a 401 Not Authorized on that request and are redirected to login. Changing the database record for 'themeId' back to 1 (default internal Dark theme) the login works just fine.

magujun avatar Aug 13 '22 05:08 magujun

@magujun The custom theme is now fixed, it will be available on nightly soon.

majora2007 avatar Aug 13 '22 16:08 majora2007

Thanks!

lukaszliniewicz avatar Aug 13 '22 18:08 lukaszliniewicz

Can you confirm this is working for you on the latest?

majora2007 avatar Sep 12 '22 14:09 majora2007