Incorrect login redirection

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
5 years ago
I have problem with NopCommerce 4.1 configuration. unauthorized user redirects to account/login instead of /login
5 years ago
I have the same issue.  Did you find a resolution?
5 years ago
Hi,

In my case reason was Nop.Plugin.Api plugin. this plugin adds files ~\Plugins\bin folder.

"IdentityModel.AspNetCore.OAuth2Introspection.dll"
"IdentityModel.dll"
"IdentityServer4.AccessTokenValidation.dll"
"IdentityServer4.dll"
"IdentityServer4.EntityFramework.dll"
5 years ago
Thanks Datikos. Uninstalling the API plugin fixed this problem on my production site. I've raised a ticket with Nop-Templates to fix API plugin

J
5 years ago
If you are building the git source code for Nop-Templates API, you can correct the problem with the following change:

in ApiStartup.cs

private void AddTokenGenerationPipeline(IServiceCollection services){



set option for the loginUrl against AddIdentityServer

 services.AddIdentityServer(opt => opt.UserInteraction.LoginUrl = "/login")



p.s. only tested quickly on dev system. please test extensively before rolling to prod.

Jon
5 years ago
datikos wrote:
I have problem with NopCommerce 4.1 configuration. unauthorized user redirects to account/login instead of /login


Are you still experiencing the issue?
5 years ago
JonQuick wrote:
If you are building the git source code for Nop-Templates API, you can correct the problem with the following change:

in ApiStartup.cs

private void AddTokenGenerationPipeline(IServiceCollection services){



set option for the loginUrl against AddIdentityServer

 services.AddIdentityServer(opt => opt.UserInteraction.LoginUrl = "/login")



p.s. only tested quickly on dev system. please test extensively before rolling to prod.

Jon


Hi Jon,

Yes, there is already an issue in GitHub about this.

It would be great if you could create a PR and we will be happy to test and merge in the official version.

Thanks,
Boyko
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.