Base solution for your next web application
Ends in:
01 DAYS
01 HRS
01 MIN
01 SEC
Open Closed

When I refresh the page,Impersonaton does not work #10019


User avatar
0
luo0826 created

Hi,I am planning to use the Impersonaton.I had just done some test.When I login as a user in user management page,it works.the user menu shows that I am logging in as this user. But after I refresh the page,the Impersonaton does not work.AbpSession.ImpersonatorUserId.HasValue becomes false. Why it happens?Is it a Bug?


7 Answer(s)
  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi @luo0826

    It shouldn't act like this. Could you share;

    1. Which template you are using
    2. Which version of AspNet Zero you are using
    3. Steps to reproduce this problem
  • User Avatar
    0
    luo0826 created

    Hi@ismcagdas 1.We are using ASP.NET Core MVC & jQuery template 2.The version is 9.3.0 MultiTenant is false now step1:log in as a user log in successfully step2:refresh the page or click back button now it becomes the user totally.I can not log in back to my admin user.

  • User Avatar
    0
    ismcagdas created
    Support Team

    Thanks,

    I have created an issue, please follow https://github.com/aspnetzero/aspnet-zero-core/issues/3731

  • User Avatar
    0
    luo0826 created

    The issue can not found.

  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi,

    You need to add your GitHub user on https://aspnetzero.com/LicenseManagement to access this page. It is a private GitHub repository.

  • User Avatar
    0
    luo0826 created

    Now I found out how it happened.When I set IdentityServer.IsEnabled to false in appsettings.json the bug happens. Is IdentityServer required if I want to use Impersonaton

  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi @luo0826

    I have added https://github.com/aspnetzero/aspnet-zero-core/issues/3731 to next milestone. Please follow this issue, thanks.