阅读背景:

注入的IPrincipal是匿名的,但Web API Controller User对象已通过身份验证

来源:互联网 

I'm writing a Web API 2/MVC5 project and I wanted to unit test some code that had to work with an IPrincipal using ASP.Net Identity. Instead of relying on IPrincipal I wanted to abstract that behind my own IUserService. When I look at my injected I'm writing a Web API 2/MVC5 project and I want




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

分享到: