OIDC Dynamic Client Registration in Wso2 Identity Server 5.3.0
OIDC dynamic client registration facilitates on the fly registrations for a client instead of manually registration.
High Level Steps to follow
- Start Identity Server
- Register applications using post request
Detailed Instructions
Register applications using post requests.
- open the on-line 'https://curlbuilder.com/' and fill the required text fields as bellow to generate the required curl command.
- Select the request as POST and URL as ‘https://localhost:9443/identity/connect/register’ to invoke the register endpoint.
- Add following as the request body.{
"redirect_uris": ["wso2.example.com"],
"client_name": "test",
"ext_param_owner": "admin",
"grant_types": ["password"]
}
"client_name": "test",
"ext_param_owner": "admin",
"grant_types": ["password"]
}
Definitions of the above parameters are as below :
redirect_uris : An array of URIs under the control of the client. The user is redirected to one of these redirect_uris after the authorization grant.
client_name : Any prefered name for the client
ext_param_owner :The name of the owner of the application
grant_types: An array of grant types supported by the client.
- For the authentication process add a custom header, Authorization: Basic and base64 encoded user name and password. In this example it is YWRtaW46YWRtaW4= which is base64 encoded value of admin:admin . ex: Authorization: Basic YWRtaW46YWRtaW4=
- Tick on the JSON data type.6. Copy the generated curl command and run it in a terminal to register the client.curl -XPOST -H 'Authorization: Basic: YWRtaW46YWRtaW4=' -H "Content-type: application/json" -d '{
"redirect_uris": ["wso2.example.com"], "client_name": “test", "ext_param_owner": "admin", "grant_types": ["password"] }' 'https://localhost:9443/identity/connect/register' -k -vExpected outcomeYou can find the client key and client secret of the registered application from the response.{"grant_types":["password"],"client_secret_expires_at":"0","redirect_uris":["wso2.example.com"],"client_secret":"bQmaGoLMCIqyQ4qh5LfxaQrQ44Qa","client_name":"admin_test","client_id":"Nrx4OGS3ah_iHbd84cNHSCtLfaQa"}
Comments
Post a Comment