Closed engharb closed 6 years ago
current api v = 0.2.3, the same error with 0.2.1
exception when calling verifyWithKeySet().
//class CognitoClient
public function decodeAccessToken($accessToken)
{
$algorithmManager = AlgorithmManager::create([
new RS256(),
]);
$serializerManager = new CompactSerializer(new StandardConverter());
$jws = $serializerManager->unserialize($accessToken);
$jwsVerifier = new JWSVerifier(
$algorithmManager
);
$keySet = $this->getJwtWebKeys();
if (!$jwsVerifier->verifyWithKeySet($jws, $keySet, 0)) {
throw new TokenVerificationException('could not verify token');
}
return json_decode($jws->getPayload(), true);
}
?
Looks like the new jwt library requires the gmp extension.
I have installed that via command: $ sudo apt-get install php7.2-gmp
Try a phpinfo()
and see if the extension is listed
I fix that, I was to set the correct php version in nginx config file.
thank you a lot
Hello, after updating the composer, and by calling
verifyAccessToken
I got the following error:do you know why is such error comes?
regards,