Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to start using openID in an asp.net mvc3 project?

I want to have authentication mechanism for my site (in asp.net mvc3), first option openID another option via my site. I don't know how to start with dotnetopenid, because it does not have a good document or some guidance to start with it. Is there any visual document or any useful step by step resource for it. The other question: I want to have google and yahoo openID authentication, is there any difference for using both of them?!

tanks a lot for your suggestions

like image 481
ghedas Avatar asked May 15 '11 15:05

ghedas


2 Answers

You could do worse than download the ASP.NET MVC 2 OpenID web site (C#) template from the Visual Studio Gallery.

A C# ASP.NET MVC project template to get you on a strong start on a web site that accepts OpenID. An OAuth service provider is also included so that clients can access user data with user authorization and without a password.

There is also a templated called Html5-MVC3-BP-OpenAuth which is described as:

This template creates an MVC3 Razor project with Html5 Boilerplate from Paul Irish. Also includes the DotNetOpenAuth CTP for authentication via OpenId, Twitter (OAuth) or Facebook (OAuth2).

Alternately check out MvcOpenID - An OpenID Starter Kit for ASP.NET MVC on Codeplex:

"MvcOpenID is an OpenID starter kit for ASP.NET MVC. It is first and foremost a learning tool. I've learned a lot about OpenID while developing this and commented the code a lot. Running the application and stepping through the code is the best and probably the fastest way to learn. Apart from it's educational value you can also use it as a starter kit for your ASP.NET MVC based web applications."

like image 113
Dan Diplo Avatar answered Oct 29 '22 18:10

Dan Diplo


It was a few years ago, but I integrated DotNetOpenId in my blog:

http://blog.dantup.com/2009/04/using-openid-in-your-aspnet-mvc.html

It was pretty painless, and all the required code is on that page. It seems that StackOverflow also uses the same library:

Best OpenId API for ASP.NET MVC application

like image 1
Danny Tuppeny Avatar answered Oct 29 '22 19:10

Danny Tuppeny