我已经在使用 spring oauth 中实现了 oauth2.0。它在本地主机中完美运行,但是当我将它部署到服务器时,在成功获得客户端凭据授权后,我收到 403 禁止。
来自本地主机的日志:工作正常。返回刷新令牌和访问令牌。
2016-08-15 23:16:06 DEBUG AntPathRequestMatcher:151 - Checking match of request : '/oauth/token'; against '/oauth/token'
2016-08-15 23:16:06 DEBUG FilterChainProxy:324 - /oauth/token?grant_type=password&client_id=my-trusted-client&username=manju&password=123456 at position 1 of 8 in additional filter chain; firing Filter: 'SecurityContextPersistenceFilter'
2016-08-15 23:16:06 DEBUG FilterChainProxy:324 - /oauth/token?grant_type=password&client_id=my-trusted-client&username=manju&password=123456 at position 2 of 8 in additional filter chain; firing Filter: 'WebAsyncManagerIntegrationFilter'
2016-08-15 23:16:06 DEBUG FilterChainProxy:324 - /oauth/token?grant_type=password&client_id=my-trusted-client&username=manju&password=123456 at position 3 of 8 in additional filter chain; firing Filter: 'HeaderWriterFilter'
2016-08-15 23:16:06 DEBUG HstsHeaderWriter:128 - …Run Code Online (Sandbox Code Playgroud)