mirror of
https://github.com/nextcloud/server.git
synced 2026-05-12 16:39:39 -04:00
Expired PK tokens should not fall back to legacy tokens
Fixes #11919 Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
This commit is contained in:
parent
f8c3b1de33
commit
49e992c1da
1 changed files with 2 additions and 0 deletions
|
|
@ -138,6 +138,8 @@ class Manager implements IProvider {
|
|||
public function getTokenById(int $tokenId): IToken {
|
||||
try {
|
||||
return $this->publicKeyTokenProvider->getTokenById($tokenId);
|
||||
} catch (ExpiredTokenException $e) {
|
||||
throw $e;
|
||||
} catch (InvalidTokenException $e) {
|
||||
return $this->defaultTokenProvider->getTokenById($tokenId);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue