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

JWT Token Expiration #62

Merged
merged 1 commit into from
Jan 31, 2017
Merged

JWT Token Expiration #62

merged 1 commit into from
Jan 31, 2017

Conversation

gibarsin
Copy link
Collaborator

Summary

  • The JWT authentication token will now expire at a given date. After that date, if a resource is accessed by suppling an expired token, a 401 Unauthorized response code will be returned, and a new token will have to be created with the 'dni' and 'password' credentials. The current expiration date for the token is 1 DAY from its creation.
  • A unique JWT authentication token will be returned every time a POST is commited to /api/v1/login with the same credentials. This occurs because it is using the expiration date/time as a part of the token. It is not assured that the token will be unique every time, but it is unlikely to happen.

Trello Card

https://trello.com/c/TpajsjG3/47-authentication-token-expiration

@codecov-io
Copy link

codecov-io commented Jan 27, 2017

Codecov Report

Merging #62 into development will increase coverage by -0.01%.

@@               Coverage Diff               @@
##           development      #62      +/-   ##
===============================================
- Coverage        12.04%   12.04%   -0.01%     
===============================================
  Files               97       97              
  Lines             2631     2632       +1     
  Branches           175      175              
===============================================
  Hits               317      317              
- Misses            2314     2315       +1

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0063175...71cb0a4. Read the comment docs.

Copy link
Collaborator

@MatiasMercado MatiasMercado left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very complete documentation!

Copy link
Owner

@MatiasComercio MatiasComercio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove the merge-commit. I'll help you with this tomorrow.

- The JWT authentication token will now expire at a given date. After that date, if a resource is accessed by suppling an expired token, a 401 Unauthorized response code will be returned, and a new token will have to be created with the 'dni' and 'password' credentials. The current expiration date for the token is 1 DAY from its creation.
- A unique JWT authentication token will be returned every time a POST is commited to /api/v1/login with the same credentials. This occurs because it is using the expiration date/time as a part of the token. It is not assured that the token will be unique every time, but it is unlikely to happen.
@gibarsin gibarsin merged commit 218be46 into development Jan 31, 2017
@gibarsin gibarsin deleted the tokenExpire branch January 31, 2017 00:29
MatiasComercio pushed a commit that referenced this pull request Feb 5, 2017
- The JWT authentication token will now expire at a given date. After that date, if a resource is accessed by suppling an expired token, a 401 Unauthorized response code will be returned, and a new token will have to be created with the 'dni' and 'password' credentials. The current expiration date for the token is 1 DAY from its creation.
- A unique JWT authentication token will be returned every time a POST is commited to /api/v1/login with the same credentials. This occurs because it is using the expiration date/time as a part of the token. It is not assured that the token will be unique every time, but it is unlikely to happen.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants