doorkeeper 5.1.0 → 5.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (163) hide show
  1. checksums.yaml +4 -4
  2. data/Appraisals +3 -3
  3. data/CHANGELOG.md +881 -0
  4. data/CONTRIBUTING.md +11 -9
  5. data/Dangerfile +2 -2
  6. data/Dockerfile +29 -0
  7. data/Gemfile +4 -3
  8. data/NEWS.md +1 -814
  9. data/README.md +11 -3
  10. data/RELEASING.md +6 -5
  11. data/app/controllers/doorkeeper/application_controller.rb +2 -2
  12. data/app/controllers/doorkeeper/application_metal_controller.rb +3 -2
  13. data/app/controllers/doorkeeper/applications_controller.rb +1 -0
  14. data/app/controllers/doorkeeper/authorizations_controller.rb +16 -9
  15. data/app/controllers/doorkeeper/authorized_applications_controller.rb +2 -2
  16. data/app/controllers/doorkeeper/tokens_controller.rb +32 -9
  17. data/app/views/doorkeeper/applications/_form.html.erb +0 -6
  18. data/app/views/doorkeeper/applications/show.html.erb +1 -1
  19. data/config/locales/en.yml +8 -2
  20. data/doorkeeper.gemspec +9 -1
  21. data/gemfiles/rails_5_0.gemfile +3 -2
  22. data/gemfiles/rails_5_1.gemfile +3 -2
  23. data/gemfiles/rails_5_2.gemfile +3 -2
  24. data/gemfiles/rails_6_0.gemfile +4 -3
  25. data/gemfiles/rails_master.gemfile +3 -2
  26. data/lib/doorkeeper/config/option.rb +13 -7
  27. data/lib/doorkeeper/config.rb +157 -42
  28. data/lib/doorkeeper/errors.rb +13 -18
  29. data/lib/doorkeeper/grape/helpers.rb +6 -2
  30. data/lib/doorkeeper/helpers/controller.rb +28 -7
  31. data/lib/doorkeeper/models/access_grant_mixin.rb +7 -6
  32. data/lib/doorkeeper/models/access_token_mixin.rb +99 -20
  33. data/lib/doorkeeper/models/application_mixin.rb +3 -3
  34. data/lib/doorkeeper/models/concerns/ownership.rb +1 -1
  35. data/lib/doorkeeper/models/concerns/reusable.rb +1 -1
  36. data/lib/doorkeeper/models/concerns/revocable.rb +0 -27
  37. data/lib/doorkeeper/oauth/authorization/code.rb +12 -14
  38. data/lib/doorkeeper/oauth/authorization/token.rb +10 -7
  39. data/lib/doorkeeper/oauth/authorization_code_request.rb +31 -15
  40. data/lib/doorkeeper/oauth/base_request.rb +10 -4
  41. data/lib/doorkeeper/oauth/client.rb +7 -8
  42. data/lib/doorkeeper/oauth/client_credentials/creator.rb +23 -2
  43. data/lib/doorkeeper/oauth/client_credentials/issuer.rb +7 -7
  44. data/lib/doorkeeper/oauth/client_credentials/{validation.rb → validator.rb} +10 -2
  45. data/lib/doorkeeper/oauth/client_credentials_request.rb +1 -1
  46. data/lib/doorkeeper/oauth/code_request.rb +5 -11
  47. data/lib/doorkeeper/oauth/code_response.rb +4 -4
  48. data/lib/doorkeeper/oauth/error.rb +1 -1
  49. data/lib/doorkeeper/oauth/error_response.rb +6 -6
  50. data/lib/doorkeeper/oauth/helpers/scope_checker.rb +7 -5
  51. data/lib/doorkeeper/oauth/helpers/unique_token.rb +8 -5
  52. data/lib/doorkeeper/oauth/helpers/uri_checker.rb +19 -5
  53. data/lib/doorkeeper/oauth/invalid_request_response.rb +43 -0
  54. data/lib/doorkeeper/oauth/invalid_token_response.rb +5 -2
  55. data/lib/doorkeeper/oauth/nonstandard.rb +39 -0
  56. data/lib/doorkeeper/oauth/password_access_token_request.rb +9 -4
  57. data/lib/doorkeeper/oauth/pre_authorization.rb +76 -38
  58. data/lib/doorkeeper/oauth/refresh_token_request.rb +17 -14
  59. data/lib/doorkeeper/oauth/token.rb +2 -2
  60. data/lib/doorkeeper/oauth/token_introspection.rb +26 -16
  61. data/lib/doorkeeper/oauth/token_request.rb +4 -18
  62. data/lib/doorkeeper/orm/active_record/access_grant.rb +4 -43
  63. data/lib/doorkeeper/orm/active_record/access_token.rb +4 -35
  64. data/lib/doorkeeper/orm/active_record/application.rb +5 -83
  65. data/lib/doorkeeper/orm/active_record/mixins/access_grant.rb +53 -0
  66. data/lib/doorkeeper/orm/active_record/mixins/access_token.rb +47 -0
  67. data/lib/doorkeeper/orm/active_record/mixins/application.rb +128 -0
  68. data/lib/doorkeeper/orm/active_record/redirect_uri_validator.rb +61 -0
  69. data/lib/doorkeeper/orm/active_record.rb +21 -6
  70. data/lib/doorkeeper/rails/helpers.rb +4 -4
  71. data/lib/doorkeeper/rails/routes.rb +5 -7
  72. data/lib/doorkeeper/rake/db.rake +3 -3
  73. data/lib/doorkeeper/request/authorization_code.rb +5 -3
  74. data/lib/doorkeeper/request/client_credentials.rb +2 -2
  75. data/lib/doorkeeper/request/password.rb +2 -2
  76. data/lib/doorkeeper/request/refresh_token.rb +3 -3
  77. data/lib/doorkeeper/request.rb +7 -12
  78. data/lib/doorkeeper/server.rb +3 -7
  79. data/lib/doorkeeper/stale_records_cleaner.rb +6 -2
  80. data/lib/doorkeeper/version.rb +1 -1
  81. data/lib/doorkeeper.rb +6 -3
  82. data/lib/generators/doorkeeper/application_owner_generator.rb +1 -1
  83. data/lib/generators/doorkeeper/confidential_applications_generator.rb +1 -1
  84. data/lib/generators/doorkeeper/migration_generator.rb +1 -1
  85. data/lib/generators/doorkeeper/pkce_generator.rb +1 -1
  86. data/lib/generators/doorkeeper/previous_refresh_token_generator.rb +7 -7
  87. data/lib/generators/doorkeeper/templates/initializer.rb +149 -33
  88. data/lib/generators/doorkeeper/templates/migration.rb.erb +4 -1
  89. data/spec/controllers/application_metal_controller_spec.rb +1 -1
  90. data/spec/controllers/applications_controller_spec.rb +95 -1
  91. data/spec/controllers/authorizations_controller_spec.rb +156 -75
  92. data/spec/controllers/protected_resources_controller_spec.rb +28 -20
  93. data/spec/controllers/token_info_controller_spec.rb +1 -1
  94. data/spec/controllers/tokens_controller_spec.rb +206 -38
  95. data/spec/dummy/config/application.rb +3 -1
  96. data/spec/dummy/config/initializers/doorkeeper.rb +54 -9
  97. data/spec/dummy/db/migrate/20151223192035_create_doorkeeper_tables.rb +3 -3
  98. data/spec/dummy/db/migrate/20160320211015_add_previous_refresh_token_to_access_tokens.rb +1 -1
  99. data/spec/dummy/db/migrate/20180210183654_add_confidential_to_applications.rb +1 -1
  100. data/spec/generators/install_generator_spec.rb +1 -1
  101. data/spec/generators/previous_refresh_token_generator_spec.rb +2 -2
  102. data/spec/helpers/doorkeeper/dashboard_helper_spec.rb +1 -1
  103. data/spec/lib/config_spec.rb +104 -7
  104. data/spec/lib/doorkeeper_spec.rb +1 -1
  105. data/spec/lib/models/revocable_spec.rb +3 -3
  106. data/spec/lib/oauth/authorization_code_request_spec.rb +129 -115
  107. data/spec/lib/oauth/base_request_spec.rb +154 -135
  108. data/spec/lib/oauth/base_response_spec.rb +27 -29
  109. data/spec/lib/oauth/client/credentials_spec.rb +1 -1
  110. data/spec/lib/oauth/client_credentials/creator_spec.rb +43 -3
  111. data/spec/lib/oauth/client_credentials/issuer_spec.rb +12 -12
  112. data/spec/lib/oauth/client_credentials/validation_spec.rb +4 -4
  113. data/spec/lib/oauth/client_credentials_integration_spec.rb +16 -18
  114. data/spec/lib/oauth/client_credentials_request_spec.rb +78 -80
  115. data/spec/lib/oauth/client_spec.rb +26 -26
  116. data/spec/lib/oauth/code_request_spec.rb +34 -35
  117. data/spec/lib/oauth/code_response_spec.rb +21 -25
  118. data/spec/lib/oauth/error_response_spec.rb +42 -44
  119. data/spec/lib/oauth/error_spec.rb +12 -14
  120. data/spec/lib/oauth/forbidden_token_response_spec.rb +11 -13
  121. data/spec/lib/oauth/helpers/scope_checker_spec.rb +30 -18
  122. data/spec/lib/oauth/helpers/uri_checker_spec.rb +17 -2
  123. data/spec/lib/oauth/invalid_request_response_spec.rb +73 -0
  124. data/spec/lib/oauth/invalid_token_response_spec.rb +32 -34
  125. data/spec/lib/oauth/password_access_token_request_spec.rb +145 -147
  126. data/spec/lib/oauth/pre_authorization_spec.rb +161 -153
  127. data/spec/lib/oauth/refresh_token_request_spec.rb +138 -138
  128. data/spec/lib/oauth/scopes_spec.rb +104 -106
  129. data/spec/lib/oauth/token_request_spec.rb +117 -110
  130. data/spec/lib/oauth/token_response_spec.rb +71 -73
  131. data/spec/lib/oauth/token_spec.rb +121 -123
  132. data/spec/lib/server_spec.rb +0 -12
  133. data/spec/models/doorkeeper/access_grant_spec.rb +21 -4
  134. data/spec/models/doorkeeper/access_token_spec.rb +42 -11
  135. data/spec/models/doorkeeper/application_spec.rb +114 -77
  136. data/spec/requests/applications/applications_request_spec.rb +1 -1
  137. data/spec/requests/endpoints/authorization_spec.rb +26 -8
  138. data/spec/requests/endpoints/token_spec.rb +1 -1
  139. data/spec/requests/flows/authorization_code_errors_spec.rb +1 -0
  140. data/spec/requests/flows/authorization_code_spec.rb +123 -45
  141. data/spec/requests/flows/client_credentials_spec.rb +38 -0
  142. data/spec/requests/flows/implicit_grant_errors_spec.rb +22 -10
  143. data/spec/requests/flows/implicit_grant_spec.rb +9 -8
  144. data/spec/requests/flows/password_spec.rb +67 -10
  145. data/spec/requests/flows/refresh_token_spec.rb +20 -20
  146. data/spec/requests/flows/revoke_token_spec.rb +37 -23
  147. data/spec/spec_helper.rb +1 -4
  148. data/spec/support/doorkeeper_rspec.rb +1 -1
  149. data/spec/support/helpers/request_spec_helper.rb +14 -2
  150. data/spec/support/shared/controllers_shared_context.rb +33 -23
  151. data/spec/validators/redirect_uri_validator_spec.rb +41 -16
  152. metadata +19 -16
  153. data/.coveralls.yml +0 -1
  154. data/.github/ISSUE_TEMPLATE.md +0 -25
  155. data/.github/PULL_REQUEST_TEMPLATE.md +0 -17
  156. data/.gitignore +0 -20
  157. data/.gitlab-ci.yml +0 -16
  158. data/.hound.yml +0 -3
  159. data/.rspec +0 -1
  160. data/.rubocop.yml +0 -50
  161. data/.travis.yml +0 -35
  162. data/app/validators/redirect_uri_validator.rb +0 -50
  163. data/spec/support/http_method_shim.rb +0 -29
data/CHANGELOG.md ADDED
@@ -0,0 +1,881 @@
1
+ # Changelog
2
+
3
+ See https://github.com/doorkeeper-gem/doorkeeper/wiki/Migration-from-old-versions for
4
+ upgrade guides.
5
+
6
+ User-visible changes worth mentioning.
7
+
8
+ ## master
9
+
10
+ - [#PR ID] Your PR short description here.
11
+
12
+ ## 5.3.0
13
+
14
+ - [#1339] Validate Resource Owner in `PasswordAccessTokenRequest` against `nil` and `false` values.
15
+ - [#1341] Fix `refresh_token_revoked_on_use` with `hash_token_secrets` enabled.
16
+ - [#1343] Fix ruby 2.7 kwargs warning in InvalidTokenResponse.
17
+ - [#1345] Allow to set custom classes for Doorkeeper models, extract reusable AR mixins.
18
+ - [#1346] Refactor `Doorkeeper::Application#to_json` into convenient `#as_json` (fix #1344).
19
+ - [#1349] Fix `Doorkeeper::Application` AR associations using an incorrect foreign key name when using a custom class.
20
+ - [#1318] Make existing token revocation for client credentials optional and disable it by default.
21
+
22
+ **[IMPORTANT]** This is a change compared to the behaviour of version 5.2.
23
+ If you were relying on access tokens being revoked once the same client
24
+ requested a new access token, reenable it with `revoke_previous_client_credentials_token` in Doorkeeper
25
+ initialization file.
26
+
27
+ ## 5.2.3
28
+
29
+ - [#1334] Remove `application_secret` flash helper and `redirect_to` keyword.
30
+ - [#1331] Move redirect_uri_validator to where it is used (`Application` model).
31
+ - [#1326] Move response_type check in pre_authorization to a method to be easily to override.
32
+ - [#1329] Fix `find_in_batches` order warning.
33
+
34
+ ## 5.2.2
35
+
36
+ - [#1320] Call configured `authenticate_resource_owner` method once per request.
37
+ - [#1315] Allow generation of new secret with `Doorkeeper::Application#renew_secret`.
38
+ - [#1309] Allow `Doorkeeper::Application#to_json` to work without arguments.
39
+
40
+ ## 5.2.1
41
+
42
+ - [#1308] Fix flash types for `api_only` mode (no flashes for `ActionController::API`).
43
+ - [#1306] Fix interpolation of `missing_param` I18n.
44
+
45
+ ## 5.2.0
46
+
47
+ - [#1305] Make `Doorkeeper::ApplicationController` to inherit from `ActionController::API` in cases
48
+ when `api_mode` enabled (fixes #1302).
49
+
50
+ ## 5.2.0.rc3
51
+
52
+ - [#1298] Slice strong params so doesn't error with Rails forms.
53
+ - [#1300] Limiting access to attributes of pre_authorization.
54
+ - [#1296] Adding client_id to strong parameters.
55
+ - [#1293] Move ar specific redirect uri validator to ar orm directory.
56
+ - [#1288] Allow to pass attributes to the `Doorkeeper::OAuth::PreAuthorization#as_json` method to customize
57
+ the PreAuthorization response.
58
+ - [#1286] Add ability to customize grant flows per application (OAuth client) (#1245 , #1207)
59
+ - [#1283] Allow to customize base class for `Doorkeeper::ApplicationMetalController` (new configuration
60
+ option called `base_metal_controller` (fix #1273).
61
+ - [#1277] Prevent requested scope be empty on authorization request, handle and add description for invalid request.
62
+
63
+ ## 5.2.0.rc2
64
+
65
+ - [#1270] Find matching tokens in batches for `reuse_access_token` option (fix #1193).
66
+ - [#1271] Reintroduce existing token revocation for client credentials.
67
+
68
+ **[IMPORTANT]** If you rely on being able to fetch multiple access tokens from the same
69
+ client using client credentials flow, you should skip to version 5.3, where this behaviour
70
+ is deactivated by default.
71
+
72
+ - [#1269] Update initializer template documentation.
73
+ - [#1266] Use strong parameters within pre-authorization.
74
+ - [#1264] Add :before_successful_authorization and :after_successful_authorization hooks in TokensController
75
+ - [#1263] Response properly when introspection fails and fix configurations's user guide.
76
+
77
+ ## 5.2.0.rc1
78
+
79
+ - [#1260], [#1262] Improve Token Introspection configuration option (access to tokens, client).
80
+ - [#1257] Add constraint configuration when using client authentication on introspection endpoint.
81
+ - [#1252] Returning `unauthorized` when the revocation of the token should not be performed due to wrong permissions.
82
+ - [#1249] Specify case sensitive uniqueness to remove Rails 6 deprecation message
83
+ - [#1248] Display the Application Secret in HTML after creating a new application even when `hash_application_secrets` is used.
84
+ - [#1248] Return the unhashed Application Secret in the JSON response after creating new application even when `hash_application_secrets` is used.
85
+ - [#1238] Better support for native app with support for custom scheme and localhost redirection.
86
+
87
+ ## 5.1.0
88
+
89
+ - [#1243] Add nil check operator in token checking at token introspection.
90
+ - [#1241] Explaining foreign key options for resource owner in a single place
91
+ - [#1237] Allow to set blank redirect URI if Doorkeeper configured to use redirect URI-less grant flows.
92
+ - [#1234] Fix `StaleRecordsCleaner` to properly work with big amount of records.
93
+ - [#1228] Allow to explicitly set non-expiring tokens in `custom_access_token_expires_in` configuration
94
+ option using `Float::INIFINITY` return value.
95
+ - [#1224] Do not try to store token if not found by fallback hashing strategy.
96
+ - [#1223] Update Hound/Rubocop rules, correct Doorkeeper codebase to follow style-guides.
97
+ - [#1220] Drop Rails 4.2 & Ruby < 2.4 support.
98
+
99
+ ## 5.1.0.rc2
100
+
101
+ - [#1208] Unify hashing implementation into secret storing strategies
102
+
103
+ **[IMPORTANT]** If you have been using the master branch of doorkeeper with bcrypt in your Gemfile.lock,
104
+ your application secrets have been hashed using BCrypt. To restore this behavior, use the initializer option
105
+ `hash_application_secrets using: 'Doorkeeper::SecretStoring::BCrypt`.
106
+
107
+ - [#1216] Add nil check to `expires_at` method.
108
+ - [#1215] Fix deprecates for Rails 6.
109
+ - [#1214] Scopes field accepts array.
110
+ - [#1209] Fix tokens validation for Token Introspection request.
111
+ - [#1202] Use correct HTTP status codes for error responses.
112
+
113
+ **[IMPORTANT]**: this change might break your application if you were relying on the previous
114
+ 401 status codes, this is now a 400 by default, or a 401 for `invalid_client` and `invalid_token` errors.
115
+
116
+ - [#1201] Fix custom TTL block `client` parameter to always be an `Doorkeeper::Application` instance.
117
+
118
+ **[IMPORTANT]**: those who defined `custom_access_token_expires_in` configuration option need to check
119
+ their block implementation: if you are using `oauth_client.application` to get `Doorkeeper::Application`
120
+ instance, then you need to replace it with just `oauth_client`.
121
+
122
+ - [#1200] Increase default Doorkeeper access token value complexity (`urlsafe_base64` instead of just `hex`)
123
+ matching RFC6749/RFC6750.
124
+
125
+ **[IMPORTANT]**: this change have possible side-effects in case you have custom database constraints for
126
+ access token value, application secrets, refresh tokens or you patched Doorkeeper models and introduced
127
+ token value validations, or you are using database with case-insensitive WHERE clause like MySQL
128
+ (you can face some collisions). Before this change access token value matched `[a-f0-9]` regex, and now
129
+ it matches `[a-zA-Z0-9\-_]`. In case you have such restrictions and your don't use custom token generator
130
+ please change configuration option `default_generator_method` to `:hex`.
131
+
132
+ - [#1195] Allow to customize Token Introspection response (fixes #1194).
133
+ - [#1189] Option to set `token_reuse_limit`.
134
+ - [#1191] Try to load bcrypt for hashing of application secrets, but add fallback.
135
+
136
+ ## 5.1.0.rc1
137
+
138
+ - [#1188] Use `params` instead of `request.POST` in tokens controller (fixes #1183).
139
+ - [#1182] Fix loopback IP redirect URIs to conform with RFC8252, p. 7.3 (fixes #1170).
140
+ - [#1179] Authorization Code Grant Flow without client id returns invalid_client error.
141
+ - [#1177] Allow to limit `scopes` for certain `grant_types`
142
+ - [#1176] Fix test factory support for `factory_bot_rails`
143
+ - [#1175] Internal refactor: use `scopes_string` inside `scopes`.
144
+ - [#1168] Allow optional hashing of tokens and secrets.
145
+ - [#1164] Fix error when `root_path` is not defined.
146
+ - [#1162] Fix `enforce_content_type` for requests without body.
147
+
148
+ ## 5.0.2
149
+
150
+ - [#1158] Fix initializer template: change `handle_auth_errors` option
151
+ - [#1157] Remove redundant index from migration template.
152
+
153
+ ## 5.0.1
154
+
155
+ - [#1154] Refactor `StaleRecordsCleaner` to be ORM agnostic.
156
+ - [#1152] Fix migration template: change resource owner data type from integer to Rails generic `references`
157
+ - [#1151] Fix Refresh Token strategy: add proper validation of client credentials both for Public & Private clients.
158
+ - [#1149] Fix for `URIChecker#valid_for_authorization?` false negative when query is blank, but `?` present.
159
+ - [#1140] Allow rendering custom errors from exceptions (issue #844). Originally opened as [#944].
160
+ - [#1138] Revert regression bug (check for token expiration in Authorizations controller so authorization
161
+ triggers every time)
162
+
163
+ ## 5.0.0
164
+
165
+ - [#1127] Change the token_type initials of the Banner Token to uppercase to comply with the RFC6750 specification.
166
+
167
+ ## 5.0.0.rc2
168
+
169
+ - [#1122] Fix AuthorizationsController#new error response to be in JSON format
170
+ - [#1119] Fix token revocation for OAuth apps using "implicit" grant flow
171
+ - [#1116] `AccessGrant`s will now be revoked along with `AccessToken`s when
172
+ hitting the `AuthorizedApplicationController#destroy` route.
173
+ - [#1114] Make token info endpoint's attributes consistent with token creation
174
+ - [#1108] Simple formating of callback URLs when listing oauth applications
175
+ - [#1106] Restrict access to AdminController with 'Forbidden 403' if admin_authenticator is not
176
+ configured by developers.
177
+
178
+ ## 5.0.0.rc1
179
+
180
+ - [#1103] Allow customizing use_refresh_token
181
+ - [#1089] Removed enable_pkce_without_secret configuration option
182
+ - [#1102] Expiration time based on scopes
183
+ - [#1099] All the configuration variables in `Doorkeeper.configuration` now
184
+ always return a non-nil value (`true` or `false`)
185
+ - [#1099] ORM / Query optimization: Do not revoke the refresh token if it is not enabled
186
+ in `doorkeeper.rb`
187
+ - [#996] Expiration Time Base On Grant Type
188
+ - [#997] Allow PKCE authorization_code flow as specified in RFC7636
189
+ - [#907] Fix lookup for matching tokens in certain edge-cases
190
+ - [#992] Add API option to use Doorkeeper without management views for API only
191
+ Rails applications (`api_only`)
192
+ - [#1045] Validate redirect_uri as the native URI when making authorization code requests
193
+ - [#1048] Remove deprecated `Doorkeeper#configured?`, `Doorkeeper#database_installed?`, and
194
+ `Doorkeeper#installed?` method
195
+ - [#1031] Allow public clients to authenticate without `client_secret`. Define an app as
196
+ either public or private/confidential
197
+
198
+ **[IMPORTANT]**: all the applications (clients) now are considered as private by default.
199
+ You need to manually change `confidential` column to `false` if you are using public clients,
200
+ in other case your mobile (or other) applications will not be able to authorize.
201
+ See [#1142](https://github.com/doorkeeper-gem/doorkeeper/issues/1142) for more details.
202
+
203
+ - [#1010] Add configuration to enforce configured scopes (`default_scopes` and
204
+ `optional_scopes`) for applications
205
+ - [#1060] Ensure that the native redirect_uri parameter matches with redirect_uri of the client
206
+ - [#1064] Add :before_successful_authorization and :after_successful_authorization hooks
207
+ - [#1069] Upgrade Bootstrap to 4 for Admin
208
+ - [#1068] Add rake task to cleanup databases that can become large over time
209
+ - [#1072] AuthorizationsController: Memoize strategy.authorize_response result to enable
210
+ subclasses to use the response object.
211
+ - [#1075] Call `before_successful_authorization` and `after_successful_authorization` hooks
212
+ on `create` action as well as `new`
213
+ - [#1082] Fix #916: remember routes mapping and use it required places (fix error with
214
+ customized Token Info route).
215
+ - [#1086, #1088] Fix bug with receiving default scopes in the token even if they are
216
+ not present in the application scopes (use scopes intersection).
217
+ - [#1076] Add config to enforce content type to application/x-www-form-urlencoded
218
+ - Fix bug with `force_ssl_in_redirect_uri` when it breaks existing applications with an
219
+ SSL redirect_uri.
220
+
221
+ ## 4.4.3
222
+
223
+ - [#1143] Adds a config option `opt_out_native_route_change` to opt out of the breaking api
224
+ changed introduced in https://github.com/doorkeeper-gem/doorkeeper/pull/1003
225
+
226
+ ## 4.4.2
227
+
228
+ - [#1130] Backport fix for native redirect_uri from 5.x.
229
+
230
+ ## 4.4.1
231
+
232
+ - [#1127] Backport token type to comply with the RFC6750 specification.
233
+ - [#1125] Backport Quote surround I18n yes/no keys
234
+
235
+ ## 4.4.0
236
+
237
+ - [#1120] Backport security fix from 5.x for token revocation when using public clients
238
+
239
+ **[IMPORTANT]**: all the applications (clients) now are considered as private by default.
240
+ You need to manually change `confidential` column to `false` if you are using public clients,
241
+ in other case your mobile (or other) applications will not be able to authorize.
242
+ See [#1142](https://github.com/doorkeeper-gem/doorkeeper/issues/1142) for more details.
243
+
244
+ ## 4.3.2
245
+
246
+ - [#1053] Support authorizing with query params in the request `redirect_uri` if explicitly present in app's `Application#redirect_uri`
247
+
248
+ ## 4.3.1
249
+
250
+ - Remove `BaseRecord` and introduce additional concern for ordering methods to fix
251
+ braking changes for Doorkeeper models.
252
+ - [#1032] Refactor BaseRequest callbacks into configurable lambdas
253
+ - [#1040] Clear mixins from ActiveRecord DSL and save only overridable API. It
254
+ allows to use this mixins in Doorkeeper ORM extensions with minimum code boilerplate.
255
+
256
+ ## 4.3.0
257
+
258
+ - [#976] Fix to invalidate the second redirect URI when the first URI is the native URI
259
+ - [#1035] Allow `Application#redirect_uri=` to handle array of URIs.
260
+ - [#1036] Allow to forbid Application redirect URI's with specific rules.
261
+ - [#1029] Deprecate `order_method` and introduce `ordered_by`. Sort applications
262
+ by `created_at` in index action.
263
+ - [#1033] Allow Doorkeeper configuration option #force_ssl_in_redirect_uri to be a callable object.
264
+ - Fix Grape integration & add specs for it
265
+ - [#913] Deferred ORM (ActiveRecord) models loading
266
+ - [#943] Fix Access Token token generation when certain errors occur in custom token generators
267
+ - [#1026] Implement RFC7662 - OAuth 2.0 Token Introspection
268
+ - [#985] Generate valid migration files for Rails >= 5
269
+ - [#972] Replace Struct subclassing with block-form initialization
270
+ - [#1003] Use URL query param to pass through native redirect auth code so automated apps can find it.
271
+
272
+ **[IMPORTANT]**: Previously authorization code response route was `/oauth/authorize/<code>`,
273
+ now it is `oauth/authorize/native?code=<code>` (in order to help applications to automatically find the code value).
274
+
275
+ - [#868] `Scopes#&` and `Scopes#+` now take an array or any other enumerable
276
+ object.
277
+ - [#1019] Remove translation not in use: `invalid_resource_owner`.
278
+ - Use Ruby 2 hash style syntax (min required Ruby version = 2.1)
279
+ - [#948] Make Scopes.<=> work with any "other" value.
280
+ - [#974] Redirect URI is checked without query params within AuthorizationCodeRequest.
281
+ - [#1004] More explicit help text for `native_redirect_uri`.
282
+ - [#1023] Update Ruby versions and test against 2.5.0 on Travis CI.
283
+ - [#1024] Migrate from FactoryGirl to FactoryBot.
284
+ - [#1025] Improve documentation for adding foreign keys
285
+ - [#1028] Make it possible to have composite strategy names.
286
+
287
+ ## 4.2.6
288
+
289
+ - [#970] Escape certain attributes in authorization forms.
290
+
291
+ ## 4.2.5
292
+
293
+ - [#936] Deprecate `Doorkeeper#configured?`, `Doorkeeper#database_installed?`, and
294
+ `Doorkeeper#installed?`
295
+ - [#909] Add `InvalidTokenResponse#reason` reader method to allow read the kind
296
+ of invalid token error.
297
+ - [#928] Test against more recent Ruby versions
298
+ - Small refactorings within the codebase
299
+ - [#921] Switch to Appraisal, and test against Rails master
300
+ - [#892] Add minimum Ruby version requirement
301
+
302
+ ## 4.2.0
303
+
304
+ - Security fix: Address CVE-2016-6582, implement token revocation according to
305
+ spec (tokens might not be revoked if client follows the spec).
306
+ - [#873] Add hooks to Doorkeeper::ApplicationMetalController
307
+ - [#871] Allow downstream users to better utilize doorkeeper spec factories by
308
+ eliminating name conflict on `:user` factory.
309
+
310
+ ## 4.1.0
311
+
312
+ - [#845] Allow customising the `Doorkeeper::ApplicationController` base
313
+ controller
314
+
315
+ ## 4.0.0
316
+
317
+ - [#834] Fix AssetNotPrecompiled error with Sprockets 4
318
+ - [#843] Revert "Fix validation error messages"
319
+ - [#847] Specify Null option to timestamps
320
+
321
+ ## 4.0.0.rc4
322
+
323
+ - [#777] Add support for public client in password grant flow
324
+ - [#823] Make configuration and specs ORM independent
325
+ - [#745] Add created_at timestamp to token generation options
326
+ - [#838] Drop `Application#scopes` generator and warning, introduced for
327
+ upgrading doorkeeper from v2 to v3.
328
+ - [#801] Fix Rails 5 warning messages
329
+ - Test against Rails 5 RC1
330
+
331
+ ## 4.0.0.rc3
332
+
333
+ - [#769] Revoke refresh token on access token use. To make use of the new config
334
+ add `previous_refresh_token` column to `oauth_access_tokens`:
335
+
336
+ ```
337
+ rails generate doorkeeper:previous_refresh_token
338
+ ```
339
+
340
+ - [#811] Toughen parameters filter with exact match
341
+ - [#813] Applications admin bugfix
342
+ - [#799] Fix Ruby Warnings
343
+ - Drop `attr_accessible` from models
344
+
345
+ ### Backward incompatible changes
346
+
347
+ - [#730] Force all timezones to use UTC to prevent comparison issues.
348
+ - [#802] Remove `config.i18n.fallbacks` from engine
349
+
350
+ ## 4.0.0.rc2
351
+
352
+ - Fix optional belongs_to for Rails 5
353
+ - Fix Ruby warnings
354
+
355
+ ## 4.0.0.rc1
356
+
357
+ ### Backward incompatible changes
358
+
359
+ - Drops support for Rails 4.1 and earlier
360
+ - Drops support for Ruby 2.0
361
+ - [#778] Bug fix: use the remaining time that a token is still valid when
362
+ building the redirect URI for the implicit grant flow
363
+
364
+ ### Other changes
365
+
366
+ - [#771] Validation error messages fixes
367
+ - Adds foreign key constraints in generated migrations between tokens and
368
+ grants, and applications
369
+ - Support Rails 5
370
+
371
+ ## 3.1.0
372
+
373
+ - [#736] Existing valid tokens are now reused in client_credentials flow
374
+ - [#749] Allow user to raise authorization error with custom messages.
375
+ Under `resource_owner_authenticator` block a user can
376
+ `raise Doorkeeper::Errors::DoorkeeperError.new('custom_message')`
377
+ - [#762] Check doesn’t abort the actual migration, so it runs
378
+ - [#722] `doorkeeper_forbidden_render_options` now supports returning a 404 by
379
+ specifying `respond_not_found_when_forbidden: true` in the
380
+ `doorkeeper_forbidden_render_options` method.
381
+ - [#734] Simplify and remove duplication in request strategy classes
382
+
383
+ ## 3.0.1
384
+
385
+ - [#712] Wrap exchange of grant token for access token and access token refresh
386
+ in transactions
387
+ - [#704] Allow applications scopes to be mass assigned
388
+ - [#707] Fixed order of Mixin inclusion and table_name configuration in models
389
+ - [#712] Wrap access token and refresh grants in transactions
390
+ - Adds JRuby support
391
+ - Specs, views and documentation adjustments
392
+
393
+ ## 3.0.0
394
+
395
+ ### Other changes
396
+
397
+ - [#693] Updates `en.yml`.
398
+
399
+ ## 3.0.0 (rc2)
400
+
401
+ ### Backward incompatible changes
402
+
403
+ - [#678] Change application-specific scopes to take precedence over server-wide
404
+ scopes. This removes the previous behavior where the intersection between
405
+ application and server scopes was used.
406
+
407
+ ### Other changes
408
+
409
+ - [#671] Fixes `NoMethodError - undefined method 'getlocal'` when calling
410
+ the /oauth/token path. Switch from using a DateTime object to update
411
+ AR to using a Time object. (Issue #668)
412
+ - [#677] Support editing application-specific scopes via the standard forms
413
+ - [#682] Pass error hash to Grape `error!`
414
+ - [#683] Generate application secret/UID if fields are blank strings
415
+
416
+ ## 3.0.0 (rc1)
417
+
418
+ ### Backward incompatible changes
419
+
420
+ - [#648] Extracts mongodb ORMs to
421
+ https://github.com/doorkeeper-gem/doorkeeper-mongodb. If you use ActiveRecord
422
+ you don’t need to do any change, otherwise you will need to install the new
423
+ plugin.
424
+ - [#665] `doorkeeper_unauthorized_render_options(error:)` and
425
+ `doorkeeper_forbidden_render_options(error:)` now accept `error` keyword
426
+ argument.
427
+
428
+ ### Removed deprecations
429
+
430
+ - Removes `doorkeeper_for` deprecation notice.
431
+ - Remove `applications.scopes` upgrade notice.
432
+
433
+ ## 2.2.2
434
+
435
+ - [#541] Fixed `undefined method attr_accessible` problem on Rails 4
436
+ (happens only when ProtectedAttributes gem is used) in #599
437
+
438
+ ## 2.2.1
439
+
440
+ - [#636] `custom_access_token_expires_in` bugfixes
441
+ - [#641] syntax error fix (Issue #612)
442
+ - [#633] Send extra details to Custom Token Generator
443
+ - [#628] Refactor: improve orm adapters to ease extension
444
+ - [#637] Upgrade to rspec to 3.2
445
+
446
+ ## 2.2.0 - 2015-04-19
447
+
448
+ - [#611] Allow custom access token generators to be used
449
+ - [#632] Properly fallback to `default_scopes` when no scope is specified
450
+ - [#622] Clarify that there is a logical OR between scopes for authorizing
451
+ - [#635] Upgrade to rspec 3
452
+ - [#627] i18n fallbacks to english
453
+ - Moved CHANGELOG to NEWS.md
454
+
455
+ ## 2.1.4 - 2015-03-27
456
+
457
+ - [#595] HTTP spec: Add `scope` for refresh token scope param
458
+ - [#596] Limit scopes in app scopes for client credentials
459
+ - [#567] Add Grape helpers for easier integration with Grape framework
460
+ - [#606] Add custom access token expiration support for Client Credentials flow
461
+
462
+ ## 2.1.3 - 2015-03-01
463
+
464
+ - [#588] Fixes scopes_match? bug that skipped authorization form in some cases
465
+
466
+ ## 2.1.2 - 2015-02-25
467
+
468
+ - [#574] Remove unused update authorization route.
469
+ - [#576] Filter out sensitive parameters from logs.
470
+ - [#582] The Authorization HTTP header fields are now case insensitive.
471
+ - [#583] Database connection bugfix in certain scenarios.
472
+ - Testing improvements
473
+
474
+ ## 2.1.1 - 2015-02-06
475
+
476
+ - Remove `wildcard_redirect_url` option
477
+ - [#481] Customize token flow OAuth expirations with a config lambda
478
+ - [#568] TokensController: Memoize strategy.authorize_response result to enable
479
+ subclasses to use the response object.
480
+ - [#571] Fix database initialization issues in some configurations.
481
+ - Documentation improvements
482
+
483
+ ## 2.1.0 - 2015-01-13
484
+
485
+ - [#540] Include `created_at` in response.
486
+ - [#538] Check application-level scopes in client_credentials and password flow.
487
+ - [5596227] Check application scopes in AccessToken when present. Fixes a bug in
488
+ doorkeeper 2.0.0 and 2.0.1 referring to application specific scopes.
489
+ - [#534] Internationalizes doorkeeper views.
490
+ - [#545] Ensure there is a connection to the database before checking for
491
+ missing columns
492
+ - [#546] Use `Doorkeeper::` prefix when referencing `Application` to avoid
493
+ possible application model name conflict.
494
+ - [#538] Test with Rails ~> 4.2.
495
+
496
+ ### Potentially backward incompatible changes
497
+
498
+ - Enable by default `authorization_code` and `client_credentials` grant flows.
499
+ Disables implicit and password grant flows by default.
500
+ - [#510, #544, 722113f] Revoked refresh token response bugfix.
501
+
502
+ ## 2.0.1 - 2014-12-17
503
+
504
+ - [#525, #526, #527] Fix `ActiveRecord::NoDatabaseError` on gem load.
505
+
506
+ ## 2.0.0 - 2014-12-16
507
+
508
+ ### Backward incompatible changes
509
+
510
+ - [#448] Removes `doorkeeper_for` helper. Now we use
511
+ `before_action :doorkeeper_authorize!`.
512
+ - [#469] Allow client applications to restrict the set of allowable scopes.
513
+ Fixes #317. `oauth_applications` relation needs a new `scopes` string column,
514
+ non nullable, which defaults to an empty string. To add the column run:
515
+
516
+ ```
517
+ rails generate doorkeeper:application_scopes
518
+ ```
519
+
520
+ If you’d rather do it by hand, your ActiveRecord migration should contain:
521
+
522
+ ```ruby
523
+ add_column :oauth_applications, :scopes, :string, null: false, default: ‘’
524
+ ```
525
+
526
+ ### Removed deprecations
527
+
528
+ - Removes `test_redirect_uri` option. It is now called `native_redirect_uri`.
529
+ - [#446] Removes `mount Doorkeeper::Engine`. Now we use `use_doorkeeper`.
530
+
531
+ ### Others
532
+
533
+ - [#484] Performance improvement - avoid performing order_by when not required.
534
+ - [#450] When password is invalid in Password Credentials Grant, Doorkeeper
535
+ returned 'invalid_resource_owner' instead of 'invalid_grant', as the spec
536
+ declares. Fixes #444.
537
+ - [#452] Allows `revoked_at` to be set in the future, for future expiry.
538
+ Rationale: https://github.com/doorkeeper-gem/doorkeeper/pull/452#issuecomment-51431459
539
+ - [#480] For Implicit grant flow, access tokens can now be reused. Fixes #421.
540
+ - [#491] Reworks of @jasl's #454 and #478. ORM refactor that allows doorkeeper
541
+ to be extended more easily with unsupported ORMs. It also marks the boundaries
542
+ between shared model code and ORM specifics inside of the gem.
543
+ - [#496] Tests with Rails 4.2.
544
+ - [#489] Adds `force_ssl_in_redirect_uri` to force the usage of the HTTPS
545
+ protocol in non-native redirect uris.
546
+ - [#516] SECURITY: Adds `protect_from_forgery` to `Doorkeeper::ApplicationController`
547
+ - [#518] Fix random failures in mongodb.
548
+
549
+ ---
550
+
551
+ ## 1.4.2 - 2015-03-02
552
+
553
+ - [#576] Filter out sensitive parameters from logs
554
+
555
+ ## 1.4.1 - 2014-12-17
556
+
557
+ - [#516] SECURITY: Adds `protect_from_forgery` to `Doorkeeper::ApplicationController`
558
+
559
+ ## 1.4.0 - 2014-07-31
560
+
561
+ - internals
562
+ - [#427] Adds specs expectations.
563
+ - [#428] Error response refactor.
564
+ - [#417] Moves token validation into Access Token class.
565
+ - [#439] Removes redundant module includes.
566
+ - [#443] TokensController and TokenInfoController inherit from ActionController::Metal
567
+ - bug
568
+ - [#418] fixes #243, requests with insufficient scope now respond 403 instead
569
+ of 401. (API change)
570
+ - [#438] fixes #398, native redirect for implicit token grant bug.
571
+ - [#440] namespace fixes
572
+ - enhancements
573
+ - [#432] Keeps query parameters
574
+
575
+ ## 1.3.1 - 2014-07-06
576
+
577
+ - enhancements
578
+ - [#405] Adds facade to more easily get the token from a request in a route
579
+ constraint.
580
+ - [#415] Extend Doorkeeper TokenResponse with an `after_successful_response`
581
+ callback that allows handling of `response` object.
582
+ - internals
583
+ - [#409] Deprecates `test_redirect_uri` in favor of `native_redirect_uri`.
584
+ See discussion in: [#351].
585
+ - [#411] Clean rspec deprecations. General test improvements.
586
+ - [#412] rspec line width can go longer than 80 (hound CI config).
587
+ - bug
588
+ - [#413] fixes #340, routing scope is now taken into account in redirect.
589
+ - [#401] and [#425] application is not required any longer for access_token.
590
+
591
+ ## 1.3.0 - 2014-05-23
592
+
593
+ - enhancements
594
+ - [#387] Adds reuse_access_token configuration option.
595
+
596
+ ## 1.2.0 - 2014-05-02
597
+
598
+ - enhancements
599
+ - [#376] Allow users to enable basic header authorization for access tokens.
600
+ - [#374] Token revocation implementation [RFC 7009]
601
+ - [#295] Only enable specific grant flows.
602
+ - internals
603
+ - [#381] Locale source fix.
604
+ - [#380] Renames `errors_for` to `doorkeeper_errors_for`.
605
+ - [#390] Style adjustments in accordance with Ruby Style Guide form
606
+ Thoughtbot.
607
+
608
+ ## 1.1.0 - 2014-03-29
609
+
610
+ - enhancements
611
+ - [#336] mongoid4 support.
612
+ - [#372] Allow users to set ActiveRecord table_name_prefix/suffix options
613
+ - internals
614
+ - [#343] separate OAuth's admin and user end-point to different layouts, upgrade theme to Bootstrap 3.1.
615
+ - [#348] Move render_options in filter after `@error` has been set
616
+
617
+ ## 1.0.0 - 2014-01-13
618
+
619
+ - bug (spec)
620
+ - [#228] token response `expires_in` value is now in seconds, relative to
621
+ request time
622
+ - [#296] client is optional for password grant type.
623
+ - [#319] If client credentials are present on password grant type they are validated
624
+ - [#326] If client credentials are present in refresh token they are validated
625
+ - [#326] If authenticated client does not match original client that
626
+ obtained a refresh token it responds `invalid_grant` instead of
627
+ `invalid_client`. Previous usage was invalid according to Section 5.2 of
628
+ the spec.
629
+ - [#329] access tokens' `scopes` string wa being compared against
630
+ `default_scopes` symbols, always unauthorizing.
631
+ - [#318] Include "WWW-Authenticate" header with Unauthorized responses
632
+ - enhancements
633
+ - [#293] Adds ActionController::Instrumentation in TokensController
634
+ - [#298] Support for multiple redirect_uris added.
635
+ - [#313] `AccessToken.revoke_all_for` actually revokes all non-revoked
636
+ tokens for an application/owner instead of deleting them.
637
+ - [#333] Rails 4.1 support
638
+ - internals
639
+ - Removes jQuery dependency [fixes #300][pr #312 is related]
640
+ - [#294] Client uid and secret will be generated only if not present.
641
+ - [#316] Test warnings addressed.
642
+ - [#338] Rspec 3 syntax.
643
+
644
+ ---
645
+
646
+ ## 0.7.4 - 2013-12-01
647
+
648
+ - bug
649
+ - Symbols instead of strings for user input.
650
+
651
+ ## 0.7.3 - 2013-10-04
652
+
653
+ - enhancements
654
+ - [#204] Allow to overwrite scope in routes
655
+ - internals
656
+ - Returns only present keys in Token Response (may imply a backwards
657
+ incompatible change). https://github.com/doorkeeper-gem/doorkeeper/issues/220
658
+ - bug
659
+ - [#290] Support for Rails 4 when 'protected_attributes' gem is present.
660
+
661
+ ## 0.7.2 - 2013-09-11
662
+
663
+ - enhancements
664
+ - [#272] Allow issuing multiple access_tokens for one user/application for multiple devices
665
+ - [#170] Increase length of allowed redirect URIs
666
+ - [#239] Do not try to load unavailable Request class for the current phase.
667
+ - [#273] Relax jquery-rails gem dependency
668
+
669
+ ## 0.7.1 - 2013-08-30
670
+
671
+ - bug
672
+ - [#269] Rails 3.2 raised `ActiveModel::MassAssignmentSecurity::Error`.
673
+
674
+ ## 0.7.0 - 2013-08-21
675
+
676
+ - enhancements
677
+ - [#229] Rails 4!
678
+ - internals
679
+ - [#203] Changing table name to be specific in column_names_with_table
680
+ - [#215] README update
681
+ - [#227] Use Rails.config.paths["config/routes"] instead of assuming "config/routes.rb" exists
682
+ - [#262] Add jquery as gem dependency
683
+ - [#263] Add a configuration for ActiveRecord.establish_connection
684
+ - Deprecation and Ruby warnings (PRs merged outside of GitHub).
685
+
686
+ ## 0.6.7 - 2013-01-13
687
+
688
+ - internals
689
+ - [#188] Add IDs to the show views for integration testing [@egtann](https://github.com/egtann)
690
+
691
+ ## 0.6.6 - 2013-01-04
692
+
693
+ - enhancements
694
+ - [#187] Raise error if configuration is not set
695
+
696
+ ## 0.6.5 - 2012-12-26
697
+
698
+ - enhancements
699
+ - [#184] Vendor the Bootstrap CSS [@tylerhunt](https://github.com/tylerhunt)
700
+
701
+ ## 0.6.4 - 2012-12-15
702
+
703
+ - bug
704
+ - [#180] Add localization to authorized_applications destroy notice [@aalvarado](https://github.com/aalvarado)
705
+
706
+ ## 0.6.3 - 2012-12-07
707
+
708
+ - bugfixes
709
+ - [#163] Error response content-type header should be application/json [@ggayan](https://github.com/ggayan)
710
+ - [#175] Make token.expires_in_seconds return nil when expires_in is nil [@miyagawa](https://github.com/miyagawa)
711
+ - enhancements
712
+ - [#166, #172, #174] Behavior to automatically authorize based on a configured proc
713
+ - internals
714
+ - [#168] Using expectation syntax for controller specs [@rdsoze](https://github.com/rdsoze)
715
+
716
+ ## 0.6.2 - 2012-11-10
717
+
718
+ - bugfixes
719
+ - [#162] Remove ownership columns from base migration template [@rdsoze](https://github.com/rdsoze)
720
+
721
+ ## 0.6.1 - 2012-11-07
722
+
723
+ - bugfixes
724
+ - [#160] Removed |routes| argument from initializer authenticator blocks
725
+ - documentation
726
+ - [#160] Fixed description of context of authenticator blocks
727
+
728
+ ## 0.6.0 - 2012-11-05
729
+
730
+ - enhancements
731
+ - Mongoid `orm` configuration accepts only :mongoid2 or :mongoid3
732
+ - Authorization endpoint does not redirect in #new action anymore. It wasn't specified by OAuth spec
733
+ - TokensController now inherits from ActionController::Metal. There might be performance upgrades
734
+ - Add link to authorization in Applications scaffold
735
+ - [#116] MongoMapper support [@carols10cents](https://github.com/carols10cents)
736
+ - [#122] Mongoid3 support [@petergoldstein](https://github.com/petergoldstein)
737
+ - [#150] Introduce test redirect uri for applications
738
+ - bugfixes
739
+ - [#157] Response token status should be `:ok`, not `:success` [@theycallmeswift](https://github.com/theycallmeswift)
740
+ - [#159] Remove ActionView::Base.field_error_proc override (fixes #145)
741
+ - internals
742
+ - Update development dependencies
743
+ - Several refactorings
744
+ - Rails/ORM are easily swichable with env vars (rails and orm)
745
+ - Travis now tests against Mongoid v2
746
+
747
+ ## 0.5.0 - 2012-10-20
748
+
749
+ Official support for rubinius was removed.
750
+
751
+ - enhancements
752
+ - Configure the way access token is retrieved from request (default to bearer header)
753
+ - Authorization Code expiration time is now configurable
754
+ - Add support for mongoid
755
+ - [#78, #128, #137, #138] Application Ownership
756
+ - [#92] Allow users to skip controllers
757
+ - [#99] Remove deprecated warnings for data-\* attributes [@towerhe](https://github.com/towerhe)
758
+ - [#101] Return existing access_token for PasswordAccessTokenRequest [@benoist](https://github.com/benoist)
759
+ - [#104] Changed access token scopes example code to default_scopes and optional_scopes [@amkirwan](https://github.com/amkirwan)
760
+ - [#107] Fix typos in initializer
761
+ - [#123] i18n for validator, flash messages [@petergoldstein](https://github.com/petergoldstein)
762
+ - [#140] ActiveRecord is the default value for the ORM [@petergoldstein](https://github.com/petergoldstein)
763
+ - internals
764
+ - [#112, #120] Replacing update_attribute with update_column to eliminate deprecation warnings [@rmoriz](https://github.com/rmoriz), [@petergoldstein](https://github.com/petergoldstein)
765
+ - [#121] Updating all development dependencies to recent versions. [@petergoldstein](https://github.com/petergoldstein)
766
+ - [#144] Adding MongoDB dependency to .travis.yml [@petergoldstein](https://github.com/petergoldstein)
767
+ - [#143] Displays errors for unconfigured error messages [@timgaleckas](https://github.com/timgaleckas)
768
+ - bugfixes
769
+ - [#102] Not returning 401 when access token generation fails [@cslew](https://github.com/cslew)
770
+ - [#125] Doorkeeper is using ActiveRecord version of as_json in ORM agnostic code [@petergoldstein](https://github.com/petergoldstein)
771
+ - [#142] Prevent double submission of password based authentication [@bdurand](https://github.com/bdurand)
772
+ - documentation
773
+ - [#141] Add rack-cors middleware to readme [@gottfrois](https://github.com/gottfrois)
774
+
775
+ ## 0.4.2 - 2012-06-05
776
+
777
+ - bugfixes:
778
+ - [#94] Uninitialized Constant in Password Flow
779
+
780
+ ## 0.4.1 - 2012-06-02
781
+
782
+ - enhancements:
783
+ - Backport: Move doorkeeper_for extension to Filter helper
784
+
785
+ ## 0.4.0 - 2012-05-26
786
+
787
+ - deprecation
788
+ - Deprecate authorization_scopes
789
+ - database changes
790
+ - AccessToken#resource_owner_id is not nullable
791
+ - enhancements
792
+ - [#83] Add Resource Owner Password Credentials flow [@jaimeiniesta](https://github.com/jaimeiniesta)
793
+ - [#76] Allow token expiration to be disabled [@mattgreen](https://github.com/mattgreen)
794
+ - [#89] Configure the way client credentials are retrieved from request
795
+ - [#b6470a] Add Client Credentials flow
796
+ - internals
797
+ - [#2ece8d, #f93778] Introduce Client and ErrorResponse classes
798
+
799
+ ## 0.3.4 - 2012-05-24
800
+
801
+ - Fix attr_accessible for rails 3.2.x
802
+
803
+ ## 0.3.3 - 2012-05-07
804
+
805
+ - [#86] shrink gem package size
806
+
807
+ ## 0.3.2 - 2012-04-29
808
+
809
+ - enhancements
810
+ - [#54] Ignore Authorization: headers that are not Bearer [@miyagawa](https://github.com/miyagawa)
811
+ - [#58, #64] Add destroy action to applications endpoint [@jaimeiniesta](https://github.com/jaimeiniesta), [@davidfrey](https://github.com/davidfrey)
812
+ - [#63] TokensController responds with `401 unauthorized` [@jaimeiniesta](https://github.com/jaimeiniesta)
813
+ - [#67, #72] Fix for mass-assignment [@cicloid](https://github.com/cicloid)
814
+ - internals
815
+ - [#49] Add Gemnasium status image to README [@laserlemon](https://github.com/laserlemon)
816
+ - [#50] Fix typos [@tomekw](https://github.com/tomekw)
817
+ - [#51] Updated the factory_girl_rails dependency, fix expires_in response which returned a float number instead of integer [@antekpiechnik](https://github.com/antekpiechnik)
818
+ - [#62] Typos, .gitignore [@jaimeiniesta](https://github.com/jaimeiniesta)
819
+ - [#65] Change \_path redirections to \_url redirections [@jaimeiniesta](https://github.com/jaimeiniesta)
820
+ - [#75] Fix unknown method #authenticate_admin! [@mattgreen](https://github.com/mattgreen)
821
+ - Remove application link in authorized app view
822
+
823
+ ## 0.3.1 - 2012-02-17
824
+
825
+ - enhancements
826
+ - [#48] Add if, else options to doorkeeper_for
827
+ - Add views generator
828
+ - internals
829
+ - Namespace models
830
+
831
+ ## 0.3.0 - 2012-02-11
832
+
833
+ - enhancements
834
+ - [#17, #31] Add support for client credentials in basic auth header [@GoldsteinTechPartners](https://github.com/GoldsteinTechPartners)
835
+ - [#28] Add indices to migration [@GoldsteinTechPartners](https://github.com/GoldsteinTechPartners)
836
+ - [#29] Allow doorkeeper to run with rails 3.2 [@john-griffin](https://github.com/john-griffin)
837
+ - [#30] Improve client's redirect uri validation [@GoldsteinTechPartners](https://github.com/GoldsteinTechPartners)
838
+ - [#32] Add token (implicit grant) flow [@GoldsteinTechPartners](https://github.com/GoldsteinTechPartners)
839
+ - [#34] Add support for custom unathorized responses [@GoldsteinTechPartners](https://github.com/GoldsteinTechPartners)
840
+ - [#36] Remove repetitions from the Authorised Applications view [@carvil](https://github.com/carvil)
841
+ - When user revoke an application, all tokens for that application are revoked
842
+ - Error messages now can be translated
843
+ - Install generator copies the error messages localization file
844
+ - internals
845
+ - Fix deprecation warnings in ActiveSupport::Base64
846
+ - Remove deprecation in doorkeeper_for that handles hash arguments
847
+ - Depends on railties instead of whole rails framework
848
+ - CI now integrates with rails 3.1 and 3.2
849
+
850
+ ## 0.2.0 - 2011-12-17
851
+
852
+ - enhancements
853
+ - [#4] Add authorized applications endpoint
854
+ - [#5, #11] Add access token scopes
855
+ - [#10] Add access token expiration by default
856
+ - [#9, #12] Add refresh token flow
857
+ - internals
858
+ - [#7] Improve configuration options with :default
859
+ - Improve configuration options with :builder
860
+ - Refactor config class
861
+ - Improve coverage of authorization request integration
862
+ - bug fixes
863
+ - [#6, #20] Fix access token response headers
864
+ - Fix issue with state parameter
865
+ - deprecation
866
+ - deprecate :only and :except options in doorkeeper_for
867
+
868
+ ## 0.1.1 - 2011-11-30
869
+
870
+ - enhancements
871
+ - [#3] Authorization code must be short lived and single use
872
+ - [#2] Improve views provided by doorkeeper
873
+ - [#1] Skips authorization form if the client has been authorized by the resource owner
874
+ - Improve readme
875
+ - bugfixes
876
+ - Fix issue when creating the access token (wrong client id)
877
+
878
+ ## 0.1.0 - 2011-11-25
879
+
880
+ - Authorization Code flow
881
+ - OAuth applications endpoint