kikuomax / spray-jwt

JWT related directives for spray.io
MIT License
8 stars 9 forks source link

Exp claim minimum resolution #3

Closed thyandrecardoso closed 8 years ago

thyandrecardoso commented 8 years ago

Hi there,

Is there a reason for the minimum resolution of the token expiration being set on Minutes?

I am asking this mainly because I stumbled the minimum resolution value while writing tests. Dealing with minutes on these situations is not acceptable as you may understand :) Anyway, I went to read the spec and the exp claim requires an IntDate value, which is the number of seconds since epoch...

So, is there a specific reason for this?

Thanks!!

kikuomax commented 8 years ago

Good point, @belerophon!

I just thought that no one would need the resolution of seconds in a practical application. But I understood this restriction is impractical for testing.

Changing the minimum resolution should not cause any compatibility problem. So I will change it to seconds.

Thanks

kikuomax commented 8 years ago

Hi @belerophon,

I released the version 0.0.3 that allows you to set the token expiration in seconds.

Thanks

thyandrecardoso commented 8 years ago

Thank you!!! :)