Open qlixes opened 1 year ago
Don't do this in production!
Before the line return false;
of ./vendor/firebase/php-jwt/src/JWT.php
make these modifications:
if ($success === 0) {
return false;
echo('<pre>'); // add this
print_r( \openssl_error_string() ); // add this
echo('</pre>'); // add this
It returned this:
error:0480006C:PEM routines::no start line
btw I'm using https://login.microsoftonline.com/common/discovery/v2.0/keys
as $jwksUri
@Kipjr thanks for sharing a tip to print the openssl_error_string
, I believe it should be empty if openssl_verify
succeeds.
@qlixes was the above log shared by useful for you? It wasn't clear to me whether you wanted to just show the key in laravel or asking about auth?
step reproduce :
composer.json :
access_token :
while decoded access_token on https://jwt.io, success showed headers :
while add laravel Log, it shown empty key, so verify will "false".
Please let me know if I did something wrong. Thank you a lot