I am making my own google oauth implementation in a PHP project. Everything works fine, unless I check the JWT received after requesting access to the token ( https://accounts.google.com/o/oauth2/token ).
For JWT decoding, I use the firebase / php-jwt class .
It decodes fine, but if I turn on the $verify verify option ( decode() method 3-rd arg), I get: Signature verification failed exception.
I assume that if I pass the wrong key to decode() . It is used later for the hash_hmac() function when a signature is generated.
So my question is: which key should I pass to verify the signature in the context of Google OAuth JWT?
php validation google-oauth jwt
Hast
source share