Hi Team,
We are upgrading our existing application (Asp.net Core MVC + Jquery with framework .net2.1 and version 6.2.1.) to .net 8 and version 13.1.1. following documentation (Version-Updating). We have successfully resolved all conflicts of files and now try to running the project.
When doing Impersonation getting a AbpSession.ImpersonatorUserId NULL.
11 Answer(s)
-
0
Hi,
Is this happening on development time or production time ?
-
0
Development time. As we are upgrading
-
0
Hi,
In order to understand the problem, you can debug your project and first check https://github.com/aspnetzero/aspnet-zero-core/blob/dev/aspnet-core/src/MyCompanyName.AbpZeroTemplate.Core/Authorization/Impersonation/ImpersonationManager.cs#L133 and see if the token is generated correctly.
Then, when user is redirected to ImpersonateSignIn, you can check if the token is found in the cache or not here https://github.com/aspnetzero/aspnet-zero-core/blob/dev/aspnet-core/src/MyCompanyName.AbpZeroTemplate.Web.Mvc/Controllers/AccountController.cs#L1132
-
0
-
0
Hi,
Does it work if you disable OpenIddict ?
-
0
-
0
Hi Team, please respond.
-
0
Hi @razkhan78
This doesn't happen on a non-modified project. I assume a change on your project causes this problem but it is hard to understand it without seein your project. Please share how we can access your project with [email protected].
Thanks,
-
0
This problem has resolved. No response from your side since last 5 days so I tried with identityServer4 but using identityServer4 another issue came (upon login keeps redirecting back to login page and doesn't go to next page (HomeController -> Index page)). The ticket is open for this issue (https://support.aspnetzero.com/QA/Questions/11996/ASPNET-Zero-Upgrade-from-620-to-1311) please provide a solution for identityServer4 .
So switching to identityServer4 and then come back to OpenIdDict, now value is coming in ImpersonatorUserId.
-
0
Hi,
We don't support IDSRV anymore and even IDSRV itself doesn't provide support. Why don't you consider moving to OpenIddict ? If there is a problem with that, we can try to guide you.
-
0
Isuse has resolved by using OpenIddict. You can close this ticket.