pow-auth / assent

Multi-provider framework in Elixir
https://powauth.com
MIT License
406 stars 47 forks source link

Capitalize token type to match OAuth 2.0 RFC #47

Closed Nayshins closed 4 years ago

Nayshins commented 4 years ago

I ran into this issue while trying to use the OIDC strategy with the Twitch API. Twitch returns a token_type: bearer, but they will validate against it being the capitalized string Bearer. According to the OAuth 2.0 RFC the Authorization header should contain a capitalized Bearer string. This change will make it so that it will always return a capitalized token type.

I was not sure where to add a test for this in the spec, but I am happy to add one if you can point me in the right direction.

danschultzer commented 4 years ago

Thanks a lot! Refactored, and added a proper test case for it 😄

Nayshins commented 4 years ago

Thanks for the merge! When do you normally do releases?

danschultzer commented 4 years ago

Usually very soon after, ideally same day. I'm working on another thing that I want to merge in very soon though, so I'll push a new release today or tomorrow depending.

danschultzer commented 4 years ago

v0.1.12 released 🚀