json_web_token_ex icon indicating copy to clipboard operation
json_web_token_ex copied to clipboard

RS256 key error

Open bcardarella opened this issue 8 years ago • 1 comments

I am attempting to decode a JWT from Google via OpenID Connect. The public certs are here: https://www.googleapis.com/oauth2/v3/certs and I get the following error:

** (Protocol.UndefinedError) protocol Enumerable not implemented for "d6eb2094ac2b7f5763dd34ca277a3450efbdb6a9"
            (elixir) lib/enum.ex:1: Enumerable.impl_for!/1
            (elixir) lib/enum.ex:116: Enumerable.reduce/3
            (elixir) lib/enum.ex:726: Enum.fetch/2
            (elixir) lib/enum.ex:315: Enum.at/3
    (json_web_token) lib/json_web_token/algorithm/rsa.ex:46: JsonWebToken.Algorithm.Rsa.modulus/1
    (json_web_token) lib/json_web_token/algorithm/rsa.ex:56: JsonWebToken.Algorithm.Rsa.validate_key_size/1
    (json_web_token) lib/json_web_token/algorithm/rsa.ex:41: JsonWebToken.Algorithm.Rsa.verify?/4
    (json_web_token) lib/json_web_token/jws.ex:102: JsonWebToken.Jws.verified/3

It seems that LOC is expecting an Enumerable value?

bcardarella avatar Mar 30 '17 08:03 bcardarella

I experience the same problem. Is there any progress on this?

kanes115 avatar Jun 24 '18 22:06 kanes115