Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error while updating grant types for an Application under Auth 0 #12765

Open
shilmyhasan opened this issue Mar 24, 2022 · 0 comments
Open

Error while updating grant types for an Application under Auth 0 #12765

shilmyhasan opened this issue Mar 24, 2022 · 0 comments

Comments

@shilmyhasan
Copy link
Contributor

shilmyhasan commented Mar 24, 2022

Description:

There is a bad request error while trying to update the grant types for an application registered in Auth 0. The grant types are not intitially updated for the application when trying to update the Audience for the app(which is mandatory in auth 0) and hence we need to re update the application to include the grant types and the below error is observed while trying to update the grant types.

[2022-03-24 20:39:20,831] ERROR - GlobalThrowableMapper An unknown exception has been captured by the global exception mapper.
feign.FeignException$BadRequest: [400 ] during [PATCH] to [https://dev-6sjoea18.us.auth0.com/api/v2/clients/yHks8s9CEUE4G5P3Ljj3AWROFE45Iaw6] [Auth0DCRClient#updateApplication(String,Auth0ClientInfo)]: [{"statusCode":400,"error":"Bad Request","message":"Payload validation error: 'Array items are not unique (indexes 1 and 2)' on property grant_types (A set of grant types that the client is authorized to use).","errorCode":"invalid_body"}]
at feign.FeignException.clientErrorStatus(FeignException.java:195) ~[io.github.openfeign.feign-core_11.0.0.jar:?]
at feign.FeignException.errorStatus(FeignException.java:177) ~[io.github.openfeign.feign-core_11.0.0.jar:?]
at feign.FeignException.errorStatus(FeignException.java:169) ~[io.github.openfeign.feign-core_11.0.0.jar:?]
at feign.codec.ErrorDecoder$Default.decode(ErrorDecoder.java:92) ~[io.github.openfeign.feign-core_11.0.0.jar:?]
at feign.AsyncResponseHandler.handleResponse(AsyncResponseHandler.java:96) ~[io.github.openfeign.feign-core_11.0.0.jar:?]
at feign.SynchronousMethodHandler.executeAndDecode(SynchronousMethodHandler.java:138) ~[io.github.openfeign.feign-core_11.0.0.jar:?]
at feign.SynchronousMethodHandler.invoke(SynchronousMethodHandler.java:89) ~[io.github.openfeign.feign-core_11.0.0.jar:?]
at feign.ReflectiveFeign$FeignInvocationHandler.invoke(ReflectiveFeign.java:100) ~[io.github.openfeign.feign-core_11.0.0.jar:?]
at com.sun.proxy.$Proxy505.updateApplication(Unknown Source) ~[?:?]
at org.wso2.auth0.client.Auth0OAuthClient.updateApplication(Auth0OAuthClient.java:223) ~[auth0.key.manager-1.0.3.jar:?]
at org.wso2.carbon.apimgt.impl.APIConsumerImpl.updateAuthClient_aroundBody188(APIConsumerImpl.java:4853) ~[org.wso2.carbon.apimgt.impl_6.7.206.262.jar:?]
at org.wso2.carbon.apimgt.impl.APIConsumerImpl.updateAuthClient(APIConsumerImpl.java:4760) ~[org.wso2.carbon.apimgt.impl_6.7.206.262.jar:?]
at org.wso2.carbon.apimgt.rest.api.store.v1.impl.ApplicationsApiServiceImpl.applicationsApplicationIdOauthKeysKeyMappingIdPut(ApplicationsApiServiceImpl.java:1042) ~[classes/:?]
at org.wso2.carbon.apimgt.rest.api.store.v1.ApplicationsApi.applicationsApplicationIdOauthKeysKeyMappingIdPut(ApplicationsApi.java:373) ~[classes/:?]
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?]
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:?]
at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
at java.lang.reflect.Method.invoke(Method.java:566) ~[?:?]
at org.apache.cxf.service.invoker.AbstractInvoker.performInvocation(AbstractInvoker.java:179) ~[cxf-core-3.4.4.jar:3.4.4]
at org.apache.cxf.service.invoker.AbstractInvoker.invoke(AbstractInvoker.java:96) ~[cxf-core-3.4.4.jar:3.4.4]
at org.apache.cxf.jaxrs.JAXRSInvoker.invoke(JAXRSInvoker.java:201) [cxf-rt-frontend-jaxrs-3.4.4.jar:3.4.4]
at org.apache.cxf.jaxrs.JAXRSInvoker.invoke(JAXRSInvoker.java:104) [cxf-rt-frontend-jaxrs-3.4.4.jar:3.4.4]
at org.apache.cxf.interceptor.ServiceInvokerInterceptor$1.run(ServiceInvokerInterceptor.java:59) [cxf-core-3.4.4.jar:3.4.4]
at org.apache.cxf.interceptor.ServiceInvokerInterceptor.handleMessage(ServiceInvokerInterceptor.java:96) [cxf-core-3.4.4.jar:3.4.4]
at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308) [cxf-core-3.4.4.jar:3.4.4]
at org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:121) [cxf-core-3.4.4.jar:3.4.4]
at org.apache.cxf.transport.http.AbstractHTTPDestination.invoke(AbstractHTTPDestination.java:265) [cxf-rt-transports-http-3.4.4.jar:3.4.4]
at org.apache.cxf.transport.servlet.ServletController.invokeDestination(ServletController.java:234) [cxf-rt-transports-http-3.4.4.jar:3.4.4]
at org.apache.cxf.transport.servlet.ServletController.invoke(ServletController.java:208) [cxf-rt-transports-http-3.4.4.jar:3.4.4]
at org.apache.cxf.transport.servlet.ServletController.invoke(ServletController.java:160) [cxf-rt-transports-http-3.4.4.jar:3.4.4]
at org.apache.cxf.transport.servlet.CXFNonSpringServlet.invoke(CXFNonSpringServlet.java:225) [cxf-rt-transports-http-3.4.4.jar:3.4.4]
at org.apache.cxf.transport.servlet.AbstractHTTPServlet.handleRequest(AbstractHTTPServlet.java:298) [cxf-rt-transports-http

Steps to reproduce:

Affected Product Version:

Environment details (with versions):

  • OS:
  • Client:
  • Env (Docker/K8s):

Optional Fields

Related Issues:

Suggested Labels:

Suggested Assignees:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant