File tree Expand file tree Collapse file tree 1 file changed +3
-10
lines changed
src/AuthorizationValidators Expand file tree Collapse file tree 1 file changed +3
-10
lines changed Original file line number Diff line number Diff line change @@ -74,20 +74,13 @@ private function initJwtConfiguration(): void
7474 throw new RuntimeException ('Public key is empty ' );
7575 }
7676
77- $ validationConstraints = [
77+ $ this -> jwtConfiguration -> setValidationConstraints (
7878 new LooseValidAt ($ clock , $ this ->jwtValidAtDateLeeway ),
7979 new SignedWith (
8080 new Sha256 (),
8181 InMemory::plainText ($ publicKeyContents , $ this ->publicKey ->getPassPhrase () ?? '' )
82- ),
83- ];
84-
85- // TODO: next major release: bump lcobucci/jwt to ^5.5 and remove the following check
86- if (method_exists ($ this ->jwtConfiguration , 'withValidationConstraints ' ) === true ) {
87- $ this ->jwtConfiguration = $ this ->jwtConfiguration ->withValidationConstraints (...$ validationConstraints );
88- } else {
89- $ this ->jwtConfiguration ->setValidationConstraints (...$ validationConstraints );
90- }
82+ )
83+ );
9184 }
9285
9386 /**
You can’t perform that action at this time.
0 commit comments