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

Tenant Admin user is locked out - how to fix this #2561


User avatar
0
bilalhaidar created

Hi,

I got the Admin for the Default tenant locked out. I don't know why this happened. How to fix that?

Thanks Bilal


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

    Hi,

    Login as host admin, go to tenants page. In this page you can unlock the tenant admin using the "actions" menu of tenant.

  • User Avatar
    0
    bilalhaidar created

    I did. It always tells me, Login Failed! Where else I should look for errors or so?

  • User Avatar
    0
    ismcagdas created
    Support Team

    You can check Logs.txt file under your web project. It's location changes according to your template version. Take a look at either App_Data folder or the folders under bin folder.

  • User Avatar
    0
    bilalhaidar created

    This is what I am getting:

    WARN  2017-03-01 19:32:14,345 [44   ] rcTest.Web.Controllers.AccountController - Login failed!
    Abp.UI.UserFriendlyException: Login failed!
       at DrcTest.Web.Controllers.AccountController.<GetLoginResultAsync>d__22.MoveNext() in D:\Workspace\DrcTest\src\DrcTest.Web\Controllers\AccountController.cs:line 208
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
       at DrcTest.Web.Controllers.AccountController.&lt;Login&gt;d__19.MoveNext() in D:\Workspace\DrcTest\src\DrcTest.Web\Controllers\AccountController.cs:line 137
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at Abp.Threading.InternalAsyncHelper.&lt;AwaitTaskWithPostActionAndFinallyAndGetResult&gt;d__5`1.MoveNext() in D:\Halil\Github\aspnetboilerplate\src\Abp\Threading\InternalAsyncHelper.cs:line 120
    --- End of stack trace from previous location where exception was thrown ---
       at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
       at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
       at System.Web.Mvc.Async.TaskAsyncActionDescriptor.EndExecute(IAsyncResult asyncResult)
       at System.Web.Mvc.Async.AsyncControllerActionInvoker.<>c__DisplayClass37.<BeginInvokeAsynchronousActionMethod>b__36(IAsyncResult asyncResult)
       at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResult`1.CallEndDelegate(IAsyncResult asyncResult)
       at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResultBase`1.End()
       at System.Web.Mvc.Async.AsyncControllerActionInvoker.EndInvokeActionMethod(IAsyncResult asyncResult)
       at System.Web.Mvc.Async.AsyncControllerActionInvoker.AsyncInvocationWithFilters.<InvokeActionMethodFilterAsynchronouslyRecursive>b__3d()
       at System.Web.Mvc.Async.AsyncControllerActionInvoker.AsyncInvocationWithFilters.<>c__DisplayClass46.<InvokeActionMethodFilterAsynchronouslyRecursive>b__3f()
       at System.Web.Mvc.Async.AsyncControllerActionInvoker.AsyncInvocationWithFilters.<>c__DisplayClass46.<InvokeActionMethodFilterAsynchronouslyRecursive>b__3f()
       at System.Web.Mvc.Async.AsyncControllerActionInvoker.AsyncInvocationWithFilters.<>c__DisplayClass46.<InvokeActionMethodFilterAsynchronouslyRecursive>b__3f()
       at System.Web.Mvc.Async.AsyncControllerActionInvoker.AsyncInvocationWithFilters.<>c__DisplayClass46.<InvokeActionMethodFilterAsynchronouslyRecursive>b__3f()
       at System.Web.Mvc.Async.AsyncControllerActionInvoker.<>c__DisplayClass33.<BeginInvokeActionMethodWithFilters>b__32(IAsyncResult asyncResult)
       at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResult`1.CallEndDelegate(IAsyncResult asyncResult)
       at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResultBase`1.End()
       at System.Web.Mvc.Async.AsyncControllerActionInvoker.EndInvokeActionMethodWithFilters(IAsyncResult asyncResult)
       at System.Web.Mvc.Async.AsyncControllerActionInvoker.<>c__DisplayClass21.<>c__DisplayClass2b.<BeginInvokeAction>b__1c()
       at System.Web.Mvc.Async.AsyncControllerActionInvoker.<>c__DisplayClass21.<BeginInvokeAction>b__1e(IAsyncResult asyncResult)
    
  • User Avatar
    0
    bilalhaidar created

    BTW, when I login as host, I cannot see any roles or users created for tenants. Only I see Admin created for host. Correct?

  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi,

    When you logged in as host admin, you must see a menu like this. Can you see it ?

  • User Avatar
    0
    bilalhaidar created

    Yes I do. List of Tenants. In the Actions menu, there is no unlock. Neither I can see any users in that tenant, what shall I do after seeing this screen?

  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi,

    It seems like it is not implemented in your version. You can update the field "LockoutEndDateUtc" to null.

  • User Avatar
    0
    bilalhaidar created

    How can I get latest features so that I have latest features? Can I upgrade the code? or I have to replace the entire code?

  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi,

    Sorry it is my mistake, it seems like it is implemented. Which template type do you use ? MVC 5.x with jquery, Angular2, Angular1 or ASP.NET Core with jQuery ?

    Thanks.

  • User Avatar
    0
    bilalhaidar created

    ASP.NET MVC 5 + Angular js 1.x

    Thanks

  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi,

    Can you check that if this line exists in your project or not ? <a class="postlink" href="https://github.com/aspnetzero/aspnet-zero/blob/dev/src/MyCompanyName.AbpZeroTemplate.Web/App/common/views/users/index.js#L56">https://github.com/aspnetzero/aspnet-ze ... dex.js#L56</a>

    Since you are a new member, this should exist I think.

  • User Avatar
    0
    bilalhaidar created

    Yes it exists.

    I access this through Users screen not through Tenants screen. Also in my case, if I do Unlock, I will be unlocking Host Admin not specific Tenant Admin.

    So in case a Tenant Admin is locked, can a host Admin unlock him?

    Thanks

  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi,

    You are right, this is users screen, it should be in tenants list for tenant admin. Can you create an issue for this here <a class="postlink" href="https://github.com/aspnetzero/aspnet-zero">https://github.com/aspnetzero/aspnet-zero</a>, we will implement it.

    Thanks.

  • User Avatar
    0
    bilalhaidar created

    I did thanks, <a class="postlink" href="https://github.com/aspnetzero/aspnet-zero/issues/454">https://github.com/aspnetzero/aspnet-zero/issues/454</a>