Update scope list to use space separator

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 <derek@mcgstyle.net> (github: dmcgowan)
This commit is contained in:
Derek McGowan 2016-03-03 17:38:12 -08:00
parent d51f76f903
commit 66d6eaa83f

View file

@ -74,18 +74,18 @@ a refresh token the passed in audience must match the audience defined for
the refresh token. The audience (resource provider) is provided using the the refresh token. The audience (resource provider) is provided using the
`service` field. Multiple resource scopes may be provided using multiple `scope` `service` field. Multiple resource scopes may be provided using multiple `scope`
fields on the `GET` request. The `POST` request only takes in a single fields on the `GET` request. The `POST` request only takes in a single
`scope` field but may use the resource scope list format to specify `scope` field but may use a space to separate a list of multiple resource
multiple resource scopes. scopes.
### Resource Scope Grammar ### Resource Scope Grammar
``` ```
resourcescopelist := resourcescope [ ',' action ]* [ ',' resourcescope]* scope := resourcescope [ ' ' resourcescope ]*
resourcescope := resourcetype ":" resourcename ":" action resourcescope := resourcetype ":" resourcename ":" action [ ',' action ]*
resourcetype := /[a-z]*/ resourcetype := /[a-z]*/
resourcename := component [ '/' component ]* resourcename := component [ '/' component ]*
action := /[a-z]*/ action := /[a-z]*/
component := alpha-numeric [separator alpha-numeric]* component := alpha-numeric [ separator alpha-numeric ]*
alpha-numeric := /[a-z0-9]+/ alpha-numeric := /[a-z0-9]+/
separator := /[_.]|__|[-]*/ separator := /[_.]|__|[-]*/
``` ```