The Wayback Machine - https://web.archive.org/web/20200906102551/https://github.com/jwt/ruby-jwt/issues/233/
Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

There is no "typ" header in version 2.0.0 #233

Closed
ptarud opened this issue Sep 12, 2017 · 6 comments
Closed

There is no "typ" header in version 2.0.0 #233

ptarud opened this issue Sep 12, 2017 · 6 comments
Assignees

Comments

@ptarud
Copy link

@ptarud ptarud commented Sep 12, 2017

Why there is no type header in version 2.0.0 ?

@ptarud ptarud changed the title There is no "typ" header in new version There is no "typ" header in new version (2.0.0) Sep 12, 2017
@excpt
Copy link
Member

@excpt excpt commented Sep 13, 2017

The typ header field is optional.

See: #174 and https://tools.ietf.org/html/rfc7519#section-5.

Does this change cause any issues for you?

@excpt excpt changed the title There is no "typ" header in new version (2.0.0) There is no "typ" header in version 2.0.0 Sep 13, 2017
@excpt excpt self-assigned this Sep 13, 2017
@excpt excpt added the discussion label Sep 13, 2017
@excpt excpt modified the milestone: Version 2.1.0 Sep 13, 2017
@ptarud
Copy link
Author

@ptarud ptarud commented Sep 22, 2017

Not, but I think that for other people could be generate a issue if they use other media types in addition to JWT token. I have included it by my self, but I think would be better to include "typ" header on JWT token by default.

@lleger
Copy link

@lleger lleger commented Oct 3, 2017

After upgrading to 2.0, my tests were failing. Took me a second to realize it was because of this change. The token fixture I had included the typ param but new tokens did not — thus the failure. This is a fine change, so I’m chiming in here to help anyone else searching for test failures after upgrading to 2.0.

@excpt
Copy link
Member

@excpt excpt commented Oct 5, 2017

@lleger Thank you very much for offering help. 🥇

@excpt excpt added the documentation label Oct 5, 2017
@excpt excpt closed this Sep 16, 2019
@thegreyfellow
Copy link

@thegreyfellow thegreyfellow commented Oct 28, 2019

Hi, I just want to know if starting v2.2.1 the JWT created will always include in the header by default the entry :

"typ": "JWT"

or not?

@Seitk
Copy link

@Seitk Seitk commented Mar 16, 2020

another way around, JWT was a default header before 2.0.0
removed by this PR
https://github.com/jwt/ruby-jwt/pull/174/files

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
5 participants
You can’t perform that action at this time.