首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >OAuth 2-‘用户名和密码流’和‘客户证书流’之间的区别是什么?

OAuth 2-‘用户名和密码流’和‘客户证书流’之间的区别是什么?
EN

Stack Overflow用户
提问于 2012-08-06 17:16:23
回答 1查看 4.4K关注 0票数 7

在这两种情况下,用户凭据都被交换为访问令牌。有人能解释一下这种区别吗?

这里描述了来自http://hueniverse.com的流

代码语言:javascript
复制
• User-Agent Flow – for clients running inside a user-agent (typically a web browser).
• Web Server Flow – for clients that are part of a web server application, accessible via HTTP requests. This is a simpler version of the flow provided by OAuth 1.0.
• Device Flow – suitable for clients executing on limited devices, but where the end-user has separate access to a browser on another computer or device.
• Username and Password Flow – used in cases where the user trusts the client to handle its credentials but it is still undesirable for the client to store the user’s username and password.  This flow is only suitable when there is a high degree of trust between the user and the client.
• Client Credentials Flow – the client uses its credentials to obtain an access token. This flow supports what is known as the 2-legged scenario.
• Assertion Flow – the client presents an assertion such as a SAML assertion to the authorization server in exchange for an access token.
EN

回答 1

Stack Overflow用户

发布于 2012-08-06 20:28:52

您在这里混淆了客户端和用户凭据。

OAuth上下文中的客户端总是指获得授权的应用程序。因此,在客户端凭据流中,应用程序直接授权给提供者,而不需要来自用户的任何输入(也称为https://stackoverflow.com/a/6949008/1467115,因为只涉及两个方面)。

用户名和密码流是3条腿的流.用户向应用程序提供用户名和密码,然后应用程序使用这些凭据向提供程序请求数据。

票数 9
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/11832893

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档