Skip to content

Commit

Permalink
Merge pull request #163 from spackmat/patch-1
Browse files Browse the repository at this point in the history
Hotfix for regression with JWT v6
  • Loading branch information
hajekj authored Jun 23, 2022
2 parents 49b58be + 8e8e862 commit 06fb2d6
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/Provider/Azure.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

use Firebase\JWT\JWT;
use Firebase\JWT\JWK;
use Firebase\JWT\Key;
use League\OAuth2\Client\Grant\AbstractGrant;
use League\OAuth2\Client\Provider\AbstractProvider;
use League\OAuth2\Client\Provider\Exception\IdentityProviderException;
Expand Down Expand Up @@ -372,7 +373,7 @@ public function getJwtVerificationKeys()

$publicKey = $pkey_array ['key'];

$keys[$keyinfo['kid']] = $publicKey;
$keys[$keyinfo['kid']] = new Key($publicKey, 'RS256');
}
} else if (isset($keyinfo['n']) && isset($keyinfo['e'])) {
$pkey_object = JWK::parseKey($keyinfo);
Expand All @@ -389,7 +390,7 @@ public function getJwtVerificationKeys()

$publicKey = $pkey_array ['key'];

$keys[$keyinfo['kid']] = $publicKey;
$keys[$keyinfo['kid']] = new Key($publicKey, 'RS256');;
}
}

Expand Down

0 comments on commit 06fb2d6

Please sign in to comment.