Repository navigation
Add specification for using OAuth with the token server - #1418
Conversation
Current coverage is
|
|
Given that the Edit: for clarification, I was referring to |
| `WWW-Authenticate` header. | ||
|
|
||
| ## Requesting a Token | ||
| ## Requesting an Bearer Token |
There was a problem hiding this comment.
nit: an Bearer -> a Bearer
|
@BrianBland I will attempt to merge the two sections |
Signed-off-by: Derek McGowan <[email protected]> (github: dmcgowan)
Signed-off-by: Derek McGowan <[email protected]> (github: dmcgowan)
Use client_id as defined in oauth rfc instead of custom client field Signed-off-by: Derek McGowan <[email protected]> (github: dmcgowan)
|
Merged the sections, makes the changes to |
Allow providing multiple scopes in a single scope string Signed-off-by: Derek McGowan <[email protected]> (github: dmcgowan)
|
Updated the oauth section to account for single scope return field as well as requiring |
| (Optional) Token which can be used to get additional access tokens for | ||
| the same subject with different scopes. This token should be kept secure | ||
| by the client and only sent to the authorization server which issues | ||
| bearer tokens. This field will only be set when `offline_token=true` is |
There was a problem hiding this comment.
I think this means to say:
This field will only be set when `access_type=offline` is provided in the request.
There was a problem hiding this comment.
Yes, you are right, It is the GET endpoint which uses a single boolean flag.
Add post response values Update password grant type to match oauth spec Signed-off-by: Derek McGowan <[email protected]> (github: dmcgowan)
The oauth spec defines using a space to separate parts of a scope. To better comply with future implementations built on oauth use a space to separate the resource scopes. Signed-off-by: Derek McGowan <[email protected]> (github: dmcgowan)
Signed-off-by: Derek McGowan <[email protected]> (github: dmcgowan)
|
LGTM |
Currently the token server uses a single short lived token which can only be fetched using basic auth credentials. This not only forces clients to save credentials but also makes properly scoping authorization requests difficult (basic auth credentials could be used for any account resource associated with the credentials, even those not in the domain of the authorization server). OAuth is standard practice for providing the necessary security scopes as well as limited credential leaking to clients. This initial version will still require sending credentials to the client but leaves the specification open for completely bypassing having to directly send credentials from the client using the OAuth authorization code grants.
This only PR only expands the specification and is intended to inform implementations of the registry client and token servers.