-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Query] Best approach to handle authorization_details and scope conflicts #101
Comments
Hi,
the behavior in such a case needs to be determined by your implementation. You might define a precedence, preferable only option should be support per RS.
Please note that the RFC states: "It is RECOMMENDED that a given API use only one form of requirement specification."
best regards,
Torsten.
Am 21. Dez. 2023, 13:25 +0100 schrieb Vimukthi Rajapaksha ***@***.***>:
… Hi,
The "Relationship to the 'scope' Parameter" section[1] says both authorization_details and scope can be used in the same authorization request. We're unsure what happens when there's a conflict between them in the same request. For example, imagine a scenario where an authorization request has both the READ_ACCOUNTS scope and the following authorization_details JSON.
[
{
"type": "account_information",
"actions": [
"WRITE_ACCOUNTS"
],
"locations": [
"https://example.com/accounts"
]
}
]
curl https://www.auth-server.com/authorize? \
response_type=code& \
client_id=<client_id>& \
redirect_uri=https://www.example.com/callback& \
scope=READ_ACCOUNTS& \
authorization_details=[{"type":"account_information","actions":["WRITE_ACCOUNTS"],"locations":["https://example.com/accounts"]}]
When the scope and authorization_details conflict, does one take precedence? Or, if it's different for each API, may we know what is the best practice suggested by the specification?
[1] https://datatracker.ietf.org/doc/html/rfc9396#name-relationship-to-the-scope-p
Thanks,
Vimukthi
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: ***@***.***>
|
It is definitely per-API to determine the precedence, just like with plain scope values on their own -- if I ask for "write" vs "read write" is that the same, or different? It depends on the API, really - you could have an API with a write-only option so they'd be different, or you could have write subsume the read operation. The same logic applies here with RAR. One approach is to define each existing scope value as expanding to a specific RAR object structure, and then define how the different RAR structures compare to each other. |
Hi,
The "Relationship to the 'scope' Parameter" section[1] says both
authorization_details
andscope
can be used in the same authorization request. We're unsure what happens when there's a conflict between them in the same request. For example, imagine a scenario where an authorization request has both theREAD_ACCOUNTS
scope and the following authorization_details JSON.When the scope and authorization_details conflict, does one take precedence? Or, if it's different for each API, may we know what is the best practice suggested by the specification?
[1] https://datatracker.ietf.org/doc/html/rfc9396#name-relationship-to-the-scope-p
Thanks,
Vimukthi
The text was updated successfully, but these errors were encountered: