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

Using Cached Access Tokens #186

Open
ahmadfsalameh opened this issue Apr 17, 2024 · 0 comments
Open

Using Cached Access Tokens #186

ahmadfsalameh opened this issue Apr 17, 2024 · 0 comments

Comments

@ahmadfsalameh
Copy link

ahmadfsalameh commented Apr 17, 2024

Description:

I'm using this library to implement LTI 1.3 into an LMS application. Reading the documentation, I'm able to get the integration working but caching access tokens doesn't make sense to me!

When setting up the server service we generate an access token for a key chain which requires passing AccessTokenRepository to store the created access tokens, However, the AccessTokenRepository is not used with service endpoint authentication so why are we storing these tokens if they're not being used?

Possible Solution?

Maybe the idea is that we create a custom validator interface and pass it to RequestAccessTokenValidator? I think that'd work by decoding the JWT and searching for the id in the cache (the database in my case).

Ideal solution

Since the AccessTokenRepository is required for generating access tokens, It should also be required for validating access tokens. so RequestAccessTokenValidator.php should be modified to use the cache adapter to search for access tokens and make sure they're not revoked or expired.

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

No branches or pull requests

1 participant