Extending the RoleProvider GetRolesForUser()

北城以北 提交于 2019-12-06 15:52:45

The solution to this problem: using a cookie to store any extra information needed by the RoleProvider.

You can store and retrieve things in the HttpContext.Current.Items array, that IS available in the RoleProvider, unlike Session.

I know this is an old question but I just wanted to suggest using specific roles per service. So instead of having something like Administrator, Manager, and User you'd have Service1_Administrator, Service2_Administrator, Service1_Manager, Service2_Manager, Service1_User, Service2_User, etc.

How did you solve it?

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!