我有一个使用(simple-oauth2)http://lelylan.github.io/simple-oauth2/#client-credentials-flow
编写的简单节点应用程序此处示例https://github.com/lelylan/simple-oauth2/blob/master/example/index.js
我使用下面的配置。
const credentials = {
client: {
id: 'XXXXXXXX',
secret: 'YYYYYYYYYY'
},
auth: {
tokenHost: 'https://localhost:8243',
tokenPath: '/token',
authorizeHost: 'https://localhost:8243',
authorizePath: '/authorize'
}
};
我从/ authorize得到以下回复 {error_description:'经过身份验证的客户端无权使用此授权授权类型', 错误:'unauthorized_client'}
在日志中我得到以下
TID: [-1234] [] [2018-05-09 17:03:49,697] DEBUG {org.wso2.carbon.identity.oauth2.authz.handlers.AbstractResponseTypeHandler} - Unsupported Grant Type : authorization_code for client id : 8_90GgNFMBY7zvZqEeTeKqaLgC0a {org.wso2.carbon.identity.oauth2.authz.handlers.AbstractResponseTypeHandler}
TID: [-1234] [] [2018-05-09 17:03:49,698] DEBUG {org.wso2.carbon.identity.oauth2.authz.AuthorizationHandlerManager} - Client validation failed for user : admin@carbon.super, for client : 8_90GgNFMBY7zvZqEeTeKqaLgC0a {org.wso2.carbon.identity.oauth2.authz.AuthorizationHandlerManager}
TID: [-1234] [] [2018-05-09 17:03:49,699] DEBUG {org.wso2.carbon.identity.oauth2.authz.AuthorizationHandlerManager} - Error response received for authorization request by user : admin@carbon.super, client : 8_90GgNFMBY7zvZqEeTeKqaLgC0a, scope : PRODUCTION {org.wso2.carbon.identity.oauth2.authz.AuthorizationHandlerManager}
TID: [-1234] [] [2018-05-09 17:03:49,700] DEBUG {org.wso2.carbon.webapp.mgt.loader.CarbonWebappClassLoader} - loadClass(org.apache.oltu.oauth2.as.response.OAuthASResponse, false) {org.wso2.carbon.webapp.mgt.loader.CarbonWebappClassLoader}
请让我知道出了什么问题
由于 马赫什