Hi,
I am developing a Xamarin Application using Abp Zero for my backend. For some reason, my permission keeps getting reset for my users. For example: If i asign the admin role to a user, that user gets all the the permissions, this is reflected in the web UI and mobile app. Than lets say after a while I reopen the mobile app, than i get an error message saying the the permissions are missing and when I look at the user managerment that user still has the Admin Role, but all permissions are unchecked.
Does anyone have any idea what's happening?
6 Answer(s)
-
0
Does anyone have any idea?
-
1
Hi @suruat,
Sorry for the late reply. We haven't faced any problem which can cause this problem in AspNet Zero. Is there any place in your app might cause this problem ? You can add a log to https://github.com/aspnetzero/aspnet-zero-core/blob/dev/aspnet-core/src/MyCompanyName.AbpZeroTemplate.Application/Authorization/Users/UserAppService.cs#L230 and check the logs when this happens again.
-
0
Thanks for the Tip @ismcagdas, I added some AppInsight Logging. So hopefully this will shed some light for me.
-
0
@ismcagdas After some investigation, I am confident the issue is not with the permissions but rather with the roles. There are a few things I am noticing with the Roles.
- The Roles name in the database has strange data. The Non Static Roles have mangled strings as names:
- When I look at the data, I see that the User has the role assign, both in the UI and in the database and token, But for some reason It stops pulling the permissions to the UI, The problem might be with The GETALL() call as The GrantedPermission is empty. Gonna try debuging that code, I will update with my findings. I just wanted to leave this here first incase you had an answer for me
-
0
Issue resolved, this was due to changes I made to the GetAll() call.