简体   繁体   English

在标头或POST中返回OAuth访问令牌

[英]Return OAuth Access Token in header or POST

I have an Spring OAuth2 server set up and it's working fine when the clients authenticate. 我已经安装了Spring OAuth2服务器,并且在客户端进行身份验证时可以正常工作。 The issue is that when the client is the browser the access token is show on the redirect URL on the address bar and the browser remembers it. 问题是,当客户端是浏览器时,访问令牌显示在地址栏上的重定向URL上,浏览器会记住它。

Is there a way for the Authentication server to send back the access token in a safer way while still redirecting. 身份验证服务器是否可以通过一种更安全的方式将访问令牌发送回,同时仍进行重定向。

The OAuth 2.0 Form Post Response Mode introduces a new transport mode for the access token response based on a form POST. OAuth 2.0表单发布响应模式为基于表单POST的访问令牌响应引入了新的传输模式。

To use it, it has to be implemented in your authorization server and the query parameter response_mode with the value form_post has to be understood. 要使用它,它必须在授权服务器中实现,并且必须理解值为form_post的查询参数response_mode

As far as I know, there is no specification related to a transport using a reponse header. 据我所知,还没有与使用响应头的传输相关的规范。

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

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