mirror of
https://github.com/nextcloud/server.git
synced 2026-05-28 04:32:30 -04:00
Merge pull request #59155 from nextcloud/backport/59079/stable33
[stable33] fix(oauth2): Do not store the code in throttle metadata
This commit is contained in:
commit
0ec2177370
2 changed files with 3 additions and 3 deletions
|
|
@ -93,7 +93,7 @@ class OauthApiController extends Controller {
|
|||
$response = new JSONResponse([
|
||||
'error' => 'invalid_request',
|
||||
], Http::STATUS_BAD_REQUEST);
|
||||
$response->throttle(['invalid_request' => 'token not found', 'code' => $code]);
|
||||
$response->throttle(['invalid_request' => 'token not found']);
|
||||
return $response;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -98,7 +98,7 @@ class OauthApiControllerTest extends TestCase {
|
|||
$expected = new JSONResponse([
|
||||
'error' => 'invalid_request',
|
||||
], Http::STATUS_BAD_REQUEST);
|
||||
$expected->throttle(['invalid_request' => 'token not found', 'code' => 'invalidcode']);
|
||||
$expected->throttle(['invalid_request' => 'token not found']);
|
||||
|
||||
$this->accessTokenMapper->method('getByCode')
|
||||
->with('invalidcode')
|
||||
|
|
@ -194,7 +194,7 @@ class OauthApiControllerTest extends TestCase {
|
|||
$expected = new JSONResponse([
|
||||
'error' => 'invalid_request',
|
||||
], Http::STATUS_BAD_REQUEST);
|
||||
$expected->throttle(['invalid_request' => 'token not found', 'code' => 'invalidrefresh']);
|
||||
$expected->throttle(['invalid_request' => 'token not found']);
|
||||
|
||||
$this->accessTokenMapper->method('getByCode')
|
||||
->with('invalidrefresh')
|
||||
|
|
|
|||
Loading…
Reference in a new issue