Open source Third party login component OAuthLogin2.0 Schema parsing and open source address

Source: Internet
Author: User

OAuthLogin2.0 Introduction Address: Entry Address:http://www.cnblogs.com/dazhuangtage/p/6306133.html  NuGet Address:https://www.nuget.org/packages/OAuthLogin2.0/

a few questions about the comments of the friends in the previous article:1: Why are there so many useless platforms built in? A: The built-in platform is the last e-commerce project used by the platform, yesterday in a project, the need to use QQ login, I took this project expanded under. Then I thought I should be able to help other people and then let it out.
2: Open source address????? answer: Look back .....

I do not think I am a good writer, so I prefer, the following I put on the architecture diagram, you see the picture should be easier to understand:platform naming mechanism:

the relationship between the platform and the application:

User Authorization process:

Authorization Callback Procedure:

Exception handling mechanism:

MVC Use Tutorial:
 public  actionresult Auth (string  Span style= "COLOR: #000000" > Etpname) { var  etp = etpname.fromstring (etpname);             var  platefrom = Platform.find (ETP);  if  (Platefrom = = null  "  return  Content ( " /span> Unsupported third-party login platform!   "             return  Redirect (platefrom.applications[ 0  ].        Generateauthorizationurl (Etpname)); }
Callback method:
  Public AsyncTask<actionresult>Authcallback () {varState = request.querystring[" State"]; varETP =etpname.fromstring (state); varPlatefrom =Platform.find (ETP); if(Platefrom = =NULL)                returnContent ("Callback parameter Error!"); varTokent =awaitplatefrom.applications[0].            Gettokenasync (System.Web.HttpContext.Current.Request); if(string. IsNullOrEmpty (tokent. OpenId)) {returnContent ("failed to get user information!"); }            returnContent ("Get user Information success!"+tokent.        ToString ()); }
Open Source Address: https://github.com/dazhuangtage/OAuthLogin2.0

There is also a oauthmanager framework, used to manage the authorization information, do not know that there is no use for everyone ... Anyway, at the moment I'm using .... The oAuthManager framework references the dbcontent architecture of EF. People feel useful, just a praise it ...

Open source Third party login component OAuthLogin2.0 Schema parsing and open source address

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.