使用 HTTPS 时 OAuth 是否无关紧要?
我正在设计一个 RESTful API,它将始终通过 HTTPS 进行通信。通过 HTTPS 运行时是否有理由使用 OAuth 这样的方案?我特别感兴趣的是,当整个通信被加密时,HMAC 签名请求、随机数和时间戳等方面是否有用。
似乎任何通过 HTTPS 的身份验证方案就足够了,但我只是想获得第二意见。
I am designing a RESTful API which will always communicate over HTTPS. Is there any reason to use a scheme like OAuth when running over HTTPS? I am particularly interested whether or not aspects like HMAC-signed requests, nonces, and timestamps are useful when the entire communication is encrypted.
It seems like any authentication scheme over HTTPS is sufficient but I just wanted to get a second opinion.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
好吧,这就是 OAuth 2 背后的整个理论。您只需依赖传输层安全性并专注于授权部分,而不需要使用 OAuth 1 的复杂签名机制。 HTTPS 协议无法解决授权部分,因此您仍然需要 OAuth 2。
Well, that's the whole theory behind OAuth 2. Instead of the complicated signature mechanisms of OAuth 1, you just rely on transport-layer security and focus on the authorization piece of the puzzle. The HTTPS protocol does not solve the authorization piece, so you still need OAuth 2 for that.