indieweb / indieauth

IndieAuth.net website code and IndieAuth Specification
54 stars 7 forks source link

Clarify properties in access token grant response description and example #116

Open barnabywalters opened 2 years ago

barnabywalters commented 2 years ago

https://indieauth.spec.indieweb.org/#access-token-response states that the following properties must/should/may be present in access token grant responses:

The example additionally includes token_type and scope. Some applications (e.g. Quill) require scope, and the fact that scopeless token requests are invalid implies that scope might be required.

Pending clarification, I’d suggest the following changes:

Relevant conversation: https://chat.indieweb.org/dev/2022-09-19#t1663626755838500

vikanezrimaya commented 2 years ago

The fact that Quill requires a scope property on responses is probably a remnant of an older version of the spec. It makes sense for an app to know which permissions were granted to it, even though it introduces some potential for abuse (for example, an app forcing the user to re-login if it sees that a permission it wants to use maliciously is not granted to it, or maliciously restrict functionality unrelated to the permission as revenge). I suppose adding that to the spec would be nice, though I am not sure if it is meant to be optional or required. Are there implementations in the wild that do not have scope on access token grant responses besides Kittybox, in which the issue was uncovered?

aaronpk commented 2 years ago

The token response should match OAuth 2.

dshanske commented 2 years ago

Any reason we shouldn't do a PR to address though?