开发者

How can I programmatically refresh my ASP.NET role memberships?

开发者 https://www.devze.com 2022-12-22 03:50 出处:网络
I\'m using a custom role provider (written by another developer) that uses our active directory username (obtained from HttpContext.Current.User.Identity.Name) along with a SQL table.

I'm using a custom role provider (written by another developer) that uses our active directory username (obtained from HttpContext.Current.User.Identity.Name) along with a SQL table.

Anyways, when I update my SQL table to update my roles I need to close my web browser (Internet Explorer 7) in order for my new security to become effective.

I've tried using Session.Abandon() but that doe开发者_JAVA百科sn't help.

How can I refresh my security?

Ideally I want something like: Roles.RefreshCurrent()


Delete the roles cookie and force a postback.

.ASPXROLES

http://msdn.microsoft.com/en-us/library/ms178195.aspx

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号