claims-based-identity

Explain “claims-based authentication” to a 5-year-old

时间秒杀一切 提交于 2019-11-26 22:28:16
问题 Well, not exactly to a 5-year-old, but please avoid buzzword and enterprisespeak if possible. Claims-based authentication seems to be all the rage now, but I could not find a simple and down-to-earth explanation of what it actually is, how is it different from what we have now (I assume "what we have now" to be role-based authentication), what are the benefits of using it, etc. 回答1: @Marnix has a pretty good answer, but to step away from the technical aspect of it: Claims Based Authentication

Embedded statement cannot be a declaration or labeled statement

安稳与你 提交于 2019-11-26 20:05:15
问题 I am trying to create a user using claim identity asp.net I get this error while creating claims identity user. ApplicationUser user = new ApplicationUser { EmailConfirmed = true, UserName = model.myUser.Email, Email = model.myUser.Email , PhoneNumber = model.myUser.PhoneNumber, PhoneNumberConfirmed = true, UserImagePath = model.myUser.UserImagePath, FirstName= model.myUser.FirstName, LastName = model.myUser.LastName, DateOfBirth = model.myUser.DateOfBirth, Culture = model.myUser.Culture,

Role-based access control (RBAC) vs. Claims-based access control (CBAC) in ASP.NET MVC

穿精又带淫゛_ 提交于 2019-11-26 17:53:21
问题 What are the main benefits of using CBAC vs. RBAC? When is it better to use CBAC and when is it better to use RBAC? I'm trying to understand the general concepts of the CBAC model but the general idea is still not clear for me. 回答1: I will try to show how you can benefit from Claim Based Access Control in an ASP.NET MVC Context. When you are using Role based authentication, if you have an action for creating customer and you want that the people who are in 'Sale' role should be able to do

MVC5 (VS2012) Identity CreateIdentityAsync - Value cannot be null

江枫思渺然 提交于 2019-11-26 14:15:21
问题 I am trying to setup OAuth for a an MVC5 site (in VS2012). I am using Fluent NHibernate. I have setup my own Userstore and pass in a repository object to access NHibernate session object. I pass my store into the default aspnet usermanager provider. This eventually worked for local registration and logging in. I am not trying to setup connecting / registering with Facebook. It gets a successful account. Adds a user in the user table, adds a record in the logins table and then blows up. I have

Can I use ADFS 2.0 to authenticate certain users against SQL Server?

ぐ巨炮叔叔 提交于 2019-11-26 11:32:27
问题 I have been using ADFS to authenticate users against AD fine, using a claims aware template in VS. Some of our users will not be in Active Directory, so I would like to know if its possible to configure ADFS to look up SQL Server for these users and then carry on as normal. Does ADFS2.0 provide custom authentication stores? is a similar question, just one person says yes it can be done and other says you can\'t. 回答1: AD FS 2.0 can only authenticate against Active Directory (AD DS). This is

MVC 5 Access Claims Identity User Data

淺唱寂寞╮ 提交于 2019-11-26 06:55:48
问题 I am developing an MVC 5 web application using Entity Framework 5 Database First approach. I am using OWIN for the authentication of Users. Below shows my Login method within my Account Controller. public ActionResult Login(LoginViewModel model, string returnUrl) { if (ModelState.IsValid) { var user = _AccountService.VerifyPassword(model.UserName, model.Password, false); if (user != null) { var identity = new ClaimsIdentity(new[] { new Claim(ClaimTypes.Name, model.UserName), },

Is claims based authorization appropriate for individual resources

空扰寡人 提交于 2019-11-26 05:39:21
问题 I understand the usage of claims for things I would commonly refer to as \"roles\" or \"permissions\". I know that claims are more general, but from what I have seen in practice, it usually boils down to this: If user has this set of claims they can access certain areas, or perform certain functions. Imagine a wiki application. You might have a content_contributor claim that would allow a user to add content, a content_admin claim that would allow a user to remove content, and a modify_user