阅读背景:

获取当前主体作为我在ASP中的自定义应用程序用户。网络核心身份

来源:互联网 

In previous versions of ASP.NET, if I wanted to have a custom class as my current logged in user, what I did was: I let the FormsAuthentication module do its work, and then, in the PostAuthenticateRequest event I replaced the current Principal (HttpContext.Current.User) with my custom principal object that I fetched from the database (with some caching for performance).In previous versions of ASP.NET, if I wanted to




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: