Hi, we would need more information to be able to help. You write that the login path is /util/Login, but the endpoints in your posted code is mapped to /login. What are you trying to achive, remap /util/login so it uses IdentityServer, or do you want to change the login URL for the whole application to use /login instead? Does the login work if you navigate to /login?
You can change the login path, to not use /util/login, in the cookie auth scheme:
services.Configure<CookieAuthenticationOptions>(o => o.LoginPath = "/login");
or directly when you configure the authentication schemes:
services
.AddAuthentication()
.AddCookie(options =>
{
options.LoginPath = "/login";
})
After upgrading to the latest version of optimizely my custom login/logout doesn't work properly anymore and the path for login that is set in startup it goes to :
.../Util/Login?returnUrl=%2F
The same code was working in .net 5 and CMS 11 :-) Anyone has any idea how to solve this?
Best Regards
Maryam