-
-
Notifications
You must be signed in to change notification settings - Fork 487
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
Endpoint /api/v1/users/sign_out revokes access token and refresh token on request #6222
Comments
@kiku1705 hi here it is forgot to @ |
coolios |
@7riumph just for clarification on how the sign out should work Right? |
@xihai01 Yes, this exactly, and would assign them to |
awesome. Thanks for clarifying |
@7riumph btw, what should the response schema be? |
@xihai01 Yes sure, sign-out |
@7riumph I'm looking at your model test for the api credentials table and I am a bit confused on the expect part. |
@xihai01 Cause when
Potentially redundant, but if the test doesn't pass there's definitely a problem 😅 |
@7riumph |
do you think it would be better to use a hard coded string? So the results are more predicatble in tests |
For our use case, it's just an 18 character string, but randomly generated for security 😎 |
right but is it the same 18 character string as the one generated by the model's (return_new_api_token![:api_token]) method? |
Can defiantly hard code if you'd like. |
No it's not. I get what you mean, though. This is to-do with the different environments, the Past then, |
@xihai01 Speaking of qa, actually still need to get Linda or Shen to run the |
lol I'm still a bit confused on that test posted above passes
How is it that both digests are the same lol I would assume if I called secure random hex each time, the strings generated would be unique and then comparing their equality, I would get false: for example, if I call secure random hex and then hash it 2 times and did a comparison between both digests:
both 1) and 2) when compared should be different digests |
wait |
Yes, exactly. |
|
@xihai01 All good now? Can hop on a call tomorrow as well. And potentially separate things out if there's clarity issues. |
@7riumph yup I basically understand it now. I'm still confused on the first line tho - |
@xihai01 This format Please check if the initialization is |
This issue has been inactive for 246 hours (10.25 days) and will be unassigned after 114 more hours (4.75 days). If you have questions, please If you are still working on this, comment here to tell the bot to give you more time |
Part of epic #3942
What type of user does this affect?
How should it operate? ⚙️🛠️
There should now be a
api/v1/users/sign_out
route that invalidates the users session upon request.Acceptance Criteria
sign_out
delete route toapi/v1/
(/api/v1/users/sign_out)
SHA-256
hashedapi_token_digest
andrefresh_token_digest
upon request/api/v1
controllers if applicableHelpful Links
API Folder Structure
The text was updated successfully, but these errors were encountered: