You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I am having an error and I wasn't able to get what is wrong, as the message showed in docker logs seems to not makes senses at all. Currently I have hydra and the consent app running in the cloud, now am trying to consume them from my local in a Golang Application, so, I registered a user only for it with this description:
Now, from my local golang app I have this to connect to hydra (and it's connecting successful):
if client, err = sdk.Connect(
sdk.Scopes("hydra.keys.get"),
sdk.SkipTLSVerify(),
sdk.ClientID(env.Getenv("HYDRA_CLIENT_ID", "local-consumer")),
sdk.ClientSecret(env.Getenv("HYDRA_CLIENT_SECRET", "somesecret")),
sdk.ClusterURL(env.Getenv("HYDRA_CLUSTER_URL", TheURLinTheCloud)),
); err != nil {
log.Fatalf("Could not connect to Hydra because: %s", err)
}
Somehow, when I attempt to login from my local using hydra I get:
Could not exhange token: oauth2: cannot fetch token: 400 Bad Request
Response: {"error":"invalid_request","error_description":"The request is missing a required parameter, includes an invalid parameter value, includes a parameter more than once, or is otherwise malformed","statusCode":400}
Then, I went to the server and check the logs, this is what I have:
time="2017-08-16T01:37:48Z" level=info msg="started handling request" method=POST remote=186.93.226.189 request="/oauth2/token"
time="2017-08-16T01:37:48Z" level=error msg="An error occurred" error="Redirect URI mismatch: The request is missing a required parameter, includes an invalid parameter value, includes a parameter more than once, or is otherwise malformed"
time="2017-08-16T01:37:48Z" level=info msg="completed handling request" measure#https://somethings.com.latency=146632466 method=POST remote=xxx.xxx.xxx.xxx request="/oauth2/token" status=400 text_status="Bad Request" took=146.632466ms
So, basically:
In the database the URI is localhost:9999/callback
In the URL I specify as callback url: localhost:9999/callback
Then, why am receiving that message? or what other things can cause this error?
Thank you in advance
The text was updated successfully, but these errors were encountered:
Hi, I am having an error and I wasn't able to get what is wrong, as the message showed in docker logs seems to not makes senses at all. Currently I have hydra and the consent app running in the cloud, now am trying to consume them from my local in a Golang Application, so, I registered a user only for it with this description:
id: local-consumer
client_name: local-consumer
client_secret: somesecret
redirect_uris: http://localhost:9999/callback
grant_types: client_credentials|authorization_code|refresh_token|client_credentials|implicit|
response_types: token|code|id_token
scope:: openid offline hydra.clients hydra.clients hydra.keys.get
Now, from my local golang app I have this to connect to hydra (and it's connecting successful):
Somehow, when I attempt to login from my local using hydra I get:
The link that I used to attempt the login was:
https://TheURLinTheCloud.com/oauth2/auth?client_id=local-app&redirect_uri=http%3A%2F%2Flocalhost%3A9999%2Fcallback&response_type=code&scope=offline+openid&state=demostatedemostatedemo&nonce=demostatedemostatedemo
Then, I went to the server and check the logs, this is what I have:
So, basically:
In the database the URI is localhost:9999/callback
In the URL I specify as callback url: localhost:9999/callback
Then, why am receiving that message? or what other things can cause this error?
Thank you in advance
The text was updated successfully, but these errors were encountered: