aboutsummaryrefslogtreecommitdiffstats
path: root/apps/oauth2/tests/Controller/OauthApiControllerTest.php
Commit message (Collapse)AuthorAgeFilesLines
* chore(deps): Update nextcloud/coding-standard to v1.3.1provokateurin2024-09-191-3/+3
| | | | Signed-off-by: provokateurin <kate@provokateurin.de>
* refactor: Add void return type to PHPUnit test methodsChristoph Wurst2024-09-151-12/+12
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* fix(oauth2): fix testsJulien Veyssier2024-09-021-5/+5
| | | | Signed-off-by: Julien Veyssier <julien-nc@posteo.net>
* fix(oauth2): store hashed secret instead of encryptedJulien Veyssier2024-09-021-37/+44
| | | | Signed-off-by: Julien Veyssier <julien-nc@posteo.net>
* chore: Add SPDX headerAndy Scherzinger2024-05-311-22/+2
| | | | Signed-off-by: Andy Scherzinger <info@andy-scherzinger.de>
* rename oauth2_access_token's created_at to code_created_atJulien Veyssier2023-10-051-9/+9
| | | | Signed-off-by: Julien Veyssier <julien-nc@posteo.net>
* add test for refusing to get an oauth token from a code when we're not in ↵Julien Veyssier2023-10-051-0/+27
| | | | | | authorization state Signed-off-by: Julien Veyssier <julien-nc@posteo.net>
* add tests for oauth2 authorization code expirationJulien Veyssier2023-10-051-7/+63
| | | | Signed-off-by: Julien Veyssier <julien-nc@posteo.net>
* make oauth2 authorization code expire after 10 minutesJulien Veyssier2023-10-051-1/+5
| | | | Signed-off-by: Julien Veyssier <julien-nc@posteo.net>
* techdebt(DI): Use public IThrottler interface which exists since Nextcloud 25Joas Schilling2023-08-281-3/+3
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* add bruteforce protection in OauthApiControllerJulien Veyssier2023-06-191-0/+6
| | | | Signed-off-by: Julien Veyssier <julien-nc@posteo.net>
* fix oauth2 testsJulien Veyssier2023-06-081-24/+44
| | | | Signed-off-by: Julien Veyssier <julien-nc@posteo.net>
* encrypt oauth2 client secretsJulien Veyssier2023-06-071-0/+5
| | | | Signed-off-by: Julien Veyssier <julien-nc@posteo.net>
* Fix PHP error on PHP >= 8.2 about dynamic property use in testsCôme Chilliet2022-12-191-1/+6
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Fix last testsJoas Schilling2021-12-021-7/+7
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Update php licensesJohn Molakvoæ (skjnldsv)2021-06-041-2/+1
| | | | Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
* Update the license headers for Nextcloud 20Christoph Wurst2020-08-241-0/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Change PHPDoc type hint from PHPUnit_Framework_MockObject_MockObject to ↵Morris Jobke2020-08-121-8/+8
| | | | | | \PHPUnit\Framework\MockObject\MockObject Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Update the license headers for Nextcloud 19Christoph Wurst2020-03-311-0/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Use the shorter phpunit syntax for mocked return valuesChristoph Wurst2020-03-251-6/+6
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Update license headersChristoph Wurst2019-12-051-1/+4
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Mode to modern phpunitRoeland Jago Douma2019-11-271-1/+1
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Make phpunit8 compatibleRoeland Jago Douma2019-11-271-1/+1
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Some php-cs fixesRoeland Jago Douma2019-11-221-1/+1
| | | | | | | | | | | * Order the imports * No leading slash on imports * Empty line before namespace * One line per import * Empty after imports * Emmpty line at bottom of file Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Move ExpiredTokenException to the correct namespaceRoeland Jago Douma2018-10-301-3/+1
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Reset bruteforce on token refresh OAuthRoeland Jago Douma2018-10-301-1/+39
| | | | | | | | | | When using atoken obtained via OAuth the token expires. Resulting in brute force attempts hitting the requesting IP. This resets the brute force attempts for that UID on a valid refresh of the token. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* The OAuth endpoint needs to support Basic AuthRoeland Jago Douma2018-05-291-0/+84
| | | | | | * Add test Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Add testsRoeland Jago Douma2018-05-221-39/+305
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Add tests for OAuth2 appLukas Reschke2017-05-181-0/+106
Signed-off-by: Lukas Reschke <lukas@statuscode.ch>