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

六月ゝ 毕业季﹏ 提交于 2020-01-03 12:14:29

问题


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


回答1:


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."




回答2:


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




回答3:


Additionally you might want to checks Dominick Baier blog posts here and here on the subject.



来源:https://stackoverflow.com/questions/6009251/how-to-start-using-openid-in-an-asp-net-mvc3-project

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!