我正在使用窗体身份验证和ASP.NET MVC 2。我看到一个命名空间Microsoft.IdentityModel提供了很多同样的事情其他的System.IdentityModel基于声明的授权系统上。
I'm working on a claims-based authorization system using Forms Authentication and ASP.NET MVC 2. I see that one namespace "Microsoft.IdentityModel" provides a lot of the same things as the other "System.IdentityModel".
System.IdentityModel
Microsoft.IdentityModel
为什么这些2的命名空间单独存在,当出现功能重叠?
Why do these 2 namespaces exist seperately, when the functionality appears to overlap?
推荐答案如果您使用的是基于声明认证/授权,那么你将需要使用Microsoft.IdentityModel因为这是Windows身份验证框架的一部分。
If you are using Claims Based authentication/authorization, then you will need to use Microsoft.IdentityModel as that is part of the Windows Identity Framework.
有关各地MVC2指导和使用WIF我会建议您检查出的工作,模式和做实践。他们有我作为一个起点,一个体面的MVC样本。
For guidance around MVC2 and using WIF I would recommend checking out the work that Patterns and Practices did. They have a decent MVC sample that I used as a starting point.
更多推荐
Microsoft.IdentityModel VS System.IdentityModel
发布评论