-
-
Notifications
You must be signed in to change notification settings - Fork 73
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
Nonce security when the tokenMaxAge is set to false #175
Comments
@Cvmcosta Please help with the above query |
@priyachawla11 Hello! Sorry for the late reply, i have been unable to find the time to work on this library recently. If i understand your question correctly, you are saying Ltijs should store the nonce during the login request instead of when receiving a launch request? And then throw the error if the nonce is not in the database during the launch request processing? I like this idea, it's an interesting approach. As i said i don't have a lot of time at the moment, i will try to implement this as soon as i am more available. In the meantime, if you want to create an PR with this implementation, it would be a massive help, since reviewing takes a lot less time than actually implementing. |
@Cvmcosta Can you please confirm the following too before the improvement changes: |
@priyachawla11 Yes, you are correct |
@Cvmcosta Thanks for resolving query 😊 |
@Cvmcosta I am unable to push my branch (nonce-security) to the repository for PR due to the following error -
Please help. |
@Cvmcosta A gentle reminder to please help me with the above, I am unable to push my branch to the repo. |
Hello @priyachawla11! How are you trying to push? Did you create a fork of ltijs before creating a new branch? You cant push directly to my repo. |
@priyachawla11 I am really sorry i haven't had the time to review your PR yet. I will do my best to find time and review it in the next few days |
Security Query Description
(By default, as tokenMaxAge is 10s and Nonce TTL is 10s, it remains in sync. The request is not entertained because of tokenMaxAge validation, so nonce auto-deletion is not affecting.)
LTIJS Security understanding
LTI1.3 Spec for id token expiry
LTI1.3 Spec for state
An opaque value is used to maintain the state between the request and the callback. Typically, Cross-Site Request Forgery (CSRF, XSRF) mitigation is done by cryptographically binding the value of this parameter with a browser cookie.
LTI1.3 Spec for nonce
A string value is used to associate a Client session with an ID Token, and to mitigate replay attacks. The value is passed through unmodified from the Authentication Request to the ID Token.
Observed Expiry times of idtokens for Platforms
We believe:
Nonce should be saved in Database while sending the login request and deleted on receiving the launch request, so that replay attacks won't be entertained as nonce cannot be reused in replay attacks after deletion
If the nonce request is received again or if the arbitrary nonce value is received, then it will not be present in Database and an error will be thrown.
The text was updated successfully, but these errors were encountered: