Live ID with MVC with out ASP.NET Membership - model-view-controller

Does anyone know is there a way to implement Windows Live ID authentication into your ASP.NET MVC site. I am moving a project from Web Forms to a MVC solution and do not want to rebuild the database so ASP.NET Membership mentioned in windows-live-id-in-asp-net-mvc is not a valid solution.
And just to avoide this question the customer not want to use Open ID.

I don't fully understand your question, but here's an example of a MVC.NET app which uses LiveID but doesn't use an ASP.NET Membership provider:
http://blog.smarx.com/posts/actually-i-m-a-cia-agent

Related

Passing Roles from ASP.NET Web API to ASP.NET CORE MVC to allow Authorize Attribute in Controllers

I think this is the first time to ask a question here, but wanted to try. Hope I got this right. I have searched all over web but nothing seems to come up for this scenario.
On a Test Project, I was going to have a ASP.NET Web API that will be exposed to the web. It will have authentication and authorization. The roles will be managed thru the Web API. I will have a ASP.NET CORE MVC app as one of the clients accessing the Web API.
What I would like to do is pass the users roles (in a Claim?) from the Web API into the Web Site and have the roles be used in the Controllers Authorize as well as in the views (menu filter and button disable functionality). Of course the issue is the separation of the Website from the Web API.
I have seen tutorials where the role is passed to a Angular/React/Vue site but I am trying to see about this in a Asp.net Core website.
I think I want to pass the claim(with the Roles) to the Website and have it use it as if the website was accessing the DB directly.
Just trying to figure out how this would be done.
Any direction would be appreciated.
Thanks

vNext role and membership providers

How do you implement role and membership providers in vNext?
Before you needed to define them in web.cfg but that file is gone and I can't even find the base classes for the providers.
So far I have found nothing on this topic. Can anyone help?
asp.net Identity is the new thing for users and roles.
Best way to understand it is to create an asp.net 5 web app in VS 2015, it will wire up Identity using Entity Framework 7 and you can see the moving parts in action in the Account and Manage controllers that are created.
It is also possible to implement your own UserStore and RoleStore if you don't want to use EF.
the source code for asp.net identity and the EF implementation are also instructive

How to implement role based authorization in asp.net mvc3

I'm working on a school project and I need to implement Role-based authorization in an ASP.NET mvc3 application. Currently the application only stores the user's role in a field in the database and there is only one login page. I need to alter the entire application in other for it to grant different content to different users including admin, supervisor and counselors (counselors are able to input new client info and edit and view client information that they inputted. Supervisors can view and edit all client info and also view and edit counselor info. Admin has crud access to everything on the application.)
I'm not sure about what other info to provide about the application but i'll really appreciate any help i can get as i am new to ASP.net mvc as a whole. Most of the tutorials i found focus on specific piece of the role based approach. I need more of a bottom-up approach to implementing the roles and its authorization.
Take a look at ASPNET configuration tool. I believe that it's what you're looking for:
Visual Studio 2013 and ASP.NET Web Configuration Tool
http://msdn.microsoft.com/en-us/library/yy40ytx0.aspx

MVC 3 web application storing user_id

This is a a topic with a variety of opinions around the web.
Basically i am developing a SAAS application using ASP.net MVC 3.
I wanted to know what would be a good way of storing user_id to see if the correct user is authenticated?
I know the classic session asp.net method but really want to avoid this.
Any suggestions would be great
One thing is that you can Authorize the users simply in the controller method. There you can authenticate an individual user/s or group/s.
If you are using ASP.NET Membership provider,
Guid userGuid = (Guid)Membership.GetUser().ProviderUserKey;
This will work. Please comment if you need any other guidance.

MVC3 app using asp.net membership /claims aware application + STS

I have this in mind.
I just want to check if there is something like what I have in mind already done, or I should I want to work on:
MVC3 application using asp.net membership, that has single sign on (so it is a claims aware
app that will log on a STS).
I have seen http://identityserver.codeplex.com/ but not analized it in detail:
Is it a good solution to implement?
My question is:
Is there anything like that done?
Is it a common way of doing SSO? (using also membership?)
Thanks!..
IdentityServer is an STS not an application.
If you have a claims-aware application, it "emulates" the membership provider. You can configure ADFS to provide the roles and then use the standard .NET constructs
IsInRole() or
location>
...
allow role = ...>
in the web.config.

Resources