OIDC Debugger Test
OIDC Debugger Tool : https://oidcdebugger.com
We can test our OpenID Configuration with the OIDC Debugger Tool.
Parameter | Description |
---|---|
Authorize URL | Authorization Endpoint value on mID Provider Dashboard |
Redirect URI | The URL to return after a successful login process |
Client ID | The application/client name we created |
Scope | Detailed info of the OpenID request scope information |
Nonce | A random string value |
Response Type | Returning answer |
Response Mode | How the response will return |
After we fill these fields correct, OIDC Debugger creates a URL for us. This URL is the address we start the login process.
The URL created in our test:
"https://tenantname.aws1.test1.com/auth/realms/{tenantname}/protocol/openid-connect/auth?client_id={client_id}&redirect_uri=https%3A%2F%2Foidcdebugger.com%2Fdebug&scope=openid&response_type=code%20token&response_mode=form_post&nonce=2wfzjk80tki"
You can reach the login page with this URL and carry out the login process.
After we have approved the login on our mobile application, authorization code will be sent as a query parameter to the Redirect-URL address that we have already specified.
We can get the information of the user, that logged in using the authorization code we received, with the Token Endpoint address.
You can find the Token Endpoint address on your panel. In our case, it is as below: https://demokc1.aws1.kobil.com/auth/realms/demokc1/protocol/openid-connect/token
HTTP POST Method
Content-Type: application/x-www-form-urlencoded
Parameter | Description |
---|---|
Grant_type | The method by which a login request is made |
Code | The login info that returns from the authorization server |
Client_id | The application/client name we created |
Client_secret | Specified key value for the application |
Redirect_uri | Same URL as the Redirect-URL sent to the Authorization Server |
NOTE: Since the authorization code is valid for a short period, you may get an error message as below when you do this process. If you try immediately after the authorization code is generated, you will get a successful result.
{
"error": "invalid_grant",
"error_description": "Code not valid"
}
When you get a successful result, you will see the response as shown below. Here when we decode the id token value, we can reach the user’s info.
Here is the decoded id token output: