Skip to content
This repository has been archived by the owner on Oct 3, 2022. It is now read-only.

Add Authorization Server to RegisterEndpointEvent #44

Closed
stevenvegt opened this issue Feb 28, 2020 · 1 comment · Fixed by #51
Closed

Add Authorization Server to RegisterEndpointEvent #44

stevenvegt opened this issue Feb 28, 2020 · 1 comment · Fixed by #51
Assignees
Projects

Comments

@stevenvegt
Copy link
Member

In order for the client side to retrieve the oauth access token, for every resource server as defined by the endpoint, we need to know the endpoint of the authorization server.

Event can look like this:

{
  "type": "RegisterEndpointEvent",
  "payload": {
    "organization": "urn:oid:2.16.840.1.113883.2.4.6.1:12345678",
    "endpointType": "urn:oid:1.3.6.1.4.1.54851.1:nuts-oauth-authentication-server",
    "identifier": "b005875b-2bd5-4a1b-b9eb-92622942dcf4",
    "status": "active",
    "version": "0.1.0",
    "URL": "http://127.0.0.1:21234",
    "authorizationServerURL": "https://nuts.examplecare.org/oauth"
  }
}
@stevenvegt stevenvegt changed the title Add Authorization Server to endpoint event Add Authorization Server to RegisterEndpointEvent Feb 28, 2020
@reinkrul
Copy link
Member

I'd rather add a property bag instead of extending an event with a dynamic set of unknown properties (since each endpoint type can have a different set of extra properties) since that makes deserialization less ambiguous (separate the known from the unknown). Something like this:

{
  "type": "RegisterEndpointEvent",
  "payload": {
    "organization": "urn:oid:2.16.840.1.113883.2.4.6.1:12345678",
    "endpointType": "urn:oid:1.3.6.1.4.1.54851.1:nuts-oauth-authentication-server",
    "identifier": "b005875b-2bd5-4a1b-b9eb-92622942dcf4",
    "status": "active",
    "version": "0.1.0",
    "URL": "http://127.0.0.1:21234",
    "properties": {
      "authorizationServerURL": "https://nuts.examplecare.org/oauth"
    }
  }
}

@reinkrul reinkrul self-assigned this Mar 2, 2020
@reinkrul reinkrul added this to To do in v0.13.0 via automation Mar 13, 2020
@woutslakhorst woutslakhorst moved this from To do to Done in v0.13.0 Mar 23, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
No open projects
v0.13.0
  
Done
Development

Successfully merging a pull request may close this issue.

2 participants