The Forgerock KM depends on registration tokens in addition to the Cliend ID and secret for dynamic registration. There is an error while creating the Registration Access token for the client Id and secret provided in the admin portal.
[Error Log]
... 61 more
Caused by: feign.FeignException$BadRequest: [400 ] during [POST] to [http://localhost:8080/openam/oauth2/register] [ForgerockDCRClient#createApplication(ClientInfo)]: [{"error_description":"Access Token not valid","error":"access_denied"}]
at feign.FeignException.clientErrorStatus(FeignException.java:213) ~[io.github.openfeign.feign-core_11.9.1.jar:?]
at feign.FeignException.errorStatus(FeignException.java:194) ~[io.github.openfeign.feign-core_11.9.1.jar:?]
at feign.FeignException.errorStatus(FeignException.java:185) ~[io.github.openfeign.feign-core_11.9.1.jar:?]
at feign.codec.ErrorDecoder$Default.decode(ErrorDecoder.java:92) ~[io.github.openfeign.feign-core_11.9.1.jar:?]
at feign.AsyncResponseHandler.handleResponse(AsyncResponseHandler.java:98) ~[io.github.openfeign.feign-core_11.9.1.jar:?]
at feign.SynchronousMethodHandler.executeAndDecode(SynchronousMethodHandler.java:141) ~[io.github.openfeign.feign-core_11.9.1.jar:?]
at feign.SynchronousMethodHandler.invoke(SynchronousMethodHandler.java:91) ~[io.github.openfeign.feign-core_11.9.1.jar:?]
at feign.ReflectiveFeign$FeignInvocationHandler.invoke(ReflectiveFeign.java:100) ~[io.github.openfeign.feign-core_11.9.1.jar:?]
at com.sun.proxy.$Proxy507.createApplication(Unknown Source) ~[?:?]
at org.wso2.forgerock.client.ForgerockOAuthClient.createApplication(ForgerockOAuthClient.java:105) ~[forgerock.key.manager_1.1.0.jar:?]
at org.wso2.carbon.apimgt.impl.workflow.AbstractApplicationRegistrationWorkflowExecutor.dogenerateKeysForApplication_aroundBody8(AbstractApplicationRegistrationWorkflowExecutor.java:153) ~[org.wso2.carbon.apimgt.impl_9.28.71.jar:?]
The issue happens due to config changes in the Forgerock web applications. Once the Oauth2 provider and the Client configured as per new standards. The issue get resolves.
Description
The Forgerock KM depends on registration tokens in addition to the Cliend ID and secret for dynamic registration. There is an error while creating the Registration Access token for the client Id and secret provided in the admin portal.
[Error Log]
Caused by: feign.FeignException$BadRequest: [400 ] during [POST] to [http://localhost:8080/openam/oauth2/register] [ForgerockDCRClient#createApplication(ClientInfo)]: [{"error_description":"Access Token not valid","error":"access_denied"}] at feign.FeignException.clientErrorStatus(FeignException.java:213) ~[io.github.openfeign.feign-core_11.9.1.jar:?] at feign.FeignException.errorStatus(FeignException.java:194) ~[io.github.openfeign.feign-core_11.9.1.jar:?] at feign.FeignException.errorStatus(FeignException.java:185) ~[io.github.openfeign.feign-core_11.9.1.jar:?] at feign.codec.ErrorDecoder$Default.decode(ErrorDecoder.java:92) ~[io.github.openfeign.feign-core_11.9.1.jar:?] at feign.AsyncResponseHandler.handleResponse(AsyncResponseHandler.java:98) ~[io.github.openfeign.feign-core_11.9.1.jar:?] at feign.SynchronousMethodHandler.executeAndDecode(SynchronousMethodHandler.java:141) ~[io.github.openfeign.feign-core_11.9.1.jar:?] at feign.SynchronousMethodHandler.invoke(SynchronousMethodHandler.java:91) ~[io.github.openfeign.feign-core_11.9.1.jar:?] at feign.ReflectiveFeign$FeignInvocationHandler.invoke(ReflectiveFeign.java:100) ~[io.github.openfeign.feign-core_11.9.1.jar:?] at com.sun.proxy.$Proxy507.createApplication(Unknown Source) ~[?:?] at org.wso2.forgerock.client.ForgerockOAuthClient.createApplication(ForgerockOAuthClient.java:105) ~[forgerock.key.manager_1.1.0.jar:?] at org.wso2.carbon.apimgt.impl.workflow.AbstractApplicationRegistrationWorkflowExecutor.dogenerateKeysForApplication_aroundBody8(AbstractApplicationRegistrationWorkflowExecutor.java:153) ~[org.wso2.carbon.apimgt.impl_9.28.71.jar:?]
Steps to Reproduce
Affected Component
APIM
Version
4.2.0
Environment Details (with versions)
No response
Relevant Log Output
No response
Related Issues
No response
Suggested Labels
No response