-
Notifications
You must be signed in to change notification settings - Fork 9
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
Add missing validation against allow_grant_flow_for_client
option
#15
base: master
Are you sure you want to change the base?
Add missing validation against allow_grant_flow_for_client
option
#15
Conversation
to DeviceCodeRequest and DeviceAuthorizationRequest
|
||
[Unreleased]: https://github.com/exop-group/doorkeeper-device_authorization_grant/compare/v1.0.3...HEAD | ||
[1.0.3]: https://github.com/exop-group/doorkeeper-device_authorization_grant/compare/v1.0.2...v1.0.3 | ||
[1.0.2]: https://github.com/exop-group/doorkeeper-device_authorization_grant/compare/v1.0.1...v1.0.2 | ||
[1.0.1]: https://github.com/exop-group/doorkeeper-device_authorization_grant/compare/v1.0.0...v1.0.1 | ||
[1.0.0]: https://github.com/exop-group/doorkeeper-device_authorization_grant/compare/v0.2.1...v1.0.0 | ||
[0.2.1]: https://github.com/exop-group/doorkeeper-device_authorization_grant/compare/v0.2.0...v0.2.1 | ||
[0.2.0]: https://github.com/exop-group/doorkeeper-device_authorization_grant/compare/v0.1.1...v0.2.0 | ||
[0.1.1]: https://github.com/exop-group/doorkeeper-device_authorization_grant/compare/v0.1.0...v0.1.1 | ||
[0.1.0]: https://github.com/exop-group/doorkeeper-device_authorization_grant/releases/tag/v0.1.0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Where's all that suddenly coming from?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh I realized that we used "[links]" for version's heading, but they were not pointing to anything. That's a typical destination.
About this change, I admit I've been a little insolent and didn't bother to comment in the commit message... 😇
@@ -13,6 +13,7 @@ class DeviceAuthorizationRequest < Doorkeeper::OAuth::BaseRequest | |||
attr_accessor :host_name | |||
|
|||
validate :client, error: :invalid_client | |||
validate :client_supports_grant_flow, error: :unauthorized_client |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I noticed that other Doorkeeper grants also validate the requested scopes. I suppose we should do that too, even if our own applications don't use them.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See also #9
Closes #14