简体   繁体   English

如何在C#.NET中实现OAuth2提供程序和使用者

[英]How to implement OAuth2 provider and consumer in C# .NET

I have been doing a bit of searching around on oauth2 and think it may be a good fit for some WCF rest services I am building out that will be consumed by some WPF apps and MVC web apps. 我一直在oauth2上进行一些搜索,并认为它可能非常适合我正在构建的一些WCF休息服务,这些服务将由一些WPF应用程序和MVC Web应用程序使用。 The idea would be that the user is initially asked to login with their username / password and receives an access token which gives them access to the aforementioned resource(s). 其想法是最初要求用户使用他们的用户名/密码登录并接收访问令牌,该访问令牌使他们能够访问上述资源。

Searching around here on SO I have not found much information on oauth2 except for a few consumer related questions to facebook etc. 在这里搜索SO我没有找到关于oauth2的更多信息,除了一些与Facebook等消费者相关的问题。

I'm wondering if anybody can provide some tips on implementing oauth2 (or knows of any good resources). 我想知道是否有人可以提供一些实施oauth2的技巧(或者知道任何好的资源)。 I am interested in both the provider (authenticating and issuing access tokens) as well as the client/consumer end. 我对提供者(身份验证和发布访问令牌)以及客户端/消费者端感兴趣。

.NET OAuth2 Libraries .NET OAuth2库

The only OAuth2 library I found is from dotnetopenauth which also seems to be heavily into openid. 我找到的唯一的OAuth2库来自dotnetopenauth,它似​​乎也很重要。 At this stage I'd rather a library that is a little lighter and just emcompasses oauth2 在这个阶段,我宁愿选择一个更轻一点的图书馆,而且还要包含oauth2

Are there any other oauth2 libraries available yet? 还有其他oauth2库吗?

There's OAuth .NET OAuth .NET

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM