File tree Expand file tree Collapse file tree 2 files changed +1
-10
lines changed Expand file tree Collapse file tree 2 files changed +1
-10
lines changed Original file line number Diff line number Diff line change 20
20
"require-dev" : {
21
21
"cakephp/cakephp" : " ^4.0" ,
22
22
"cakephp/cakephp-codesniffer" : " ^4.0" ,
23
- "firebase/php-jwt" : " ^5.5 " ,
23
+ "firebase/php-jwt" : " ^6.0 " ,
24
24
"phpunit/phpunit" : " ^8.5 || ^9.3"
25
25
},
26
26
"suggest" : {
Original file line number Diff line number Diff line change 18
18
19
19
use ArrayObject ;
20
20
use Authentication \Identifier \IdentifierInterface ;
21
- use Cake \Utility \Hash ;
22
21
use Cake \Utility \Security ;
23
22
use Exception ;
24
23
use Firebase \JWT \JWK ;
@@ -172,14 +171,6 @@ protected function decodeToken(string $token): ?object
172
171
$ jsonWebKeySet = $ this ->getConfig ('jwks ' );
173
172
if ($ jsonWebKeySet ) {
174
173
$ keySet = JWK ::parseKeySet ($ jsonWebKeySet );
175
- /*
176
- * TODO Converting Keys to Key Objects is no longer needed in firebase/php-jwt ^6.0
177
- * @link https://github.com/firebase/php-jwt/pull/376/files#diff-374f5998b3c572d86be0e79432aac3de362c79e8fb146b9ce422dc2388cdc5daR50
178
- */
179
- $ keyAlgorithms = Hash::combine ($ jsonWebKeySet ['keys ' ], '{n}.kid ' , '{n}.alg ' );
180
- array_walk ($ keySet , function (&$ keyMaterial , $ k ) use ($ keyAlgorithms ) {
181
- $ keyMaterial = new Key ($ keyMaterial , $ keyAlgorithms [$ k ]);
182
- });
183
174
184
175
return JWT ::decode (
185
176
$ token ,
You can’t perform that action at this time.
0 commit comments