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

feat(jwt): Added revoked token handler support #3960

Merged
merged 7 commits into from
Jan 21, 2025

Conversation

oek1ng
Copy link
Contributor

@oek1ng oek1ng commented Jan 20, 2025

Description

Added support for revoked_token_handler on same level with retrieve_user_handler,
thought about JWTManager like in flask-jwt-extended, but my solution, i think looks cleaner.

  • Added revoked token handler in Auths and Middlewares
  • Added tests
  • Added usage doc

Closes

#2118

@oek1ng oek1ng requested review from a team as code owners January 20, 2025 13:19
@github-actions github-actions bot added area/docs This PR involves changes to the documentation size: small type/feat pr/external Triage Required 🏥 This requires triage labels Jan 20, 2025
@oek1ng
Copy link
Contributor Author

oek1ng commented Jan 20, 2025

@all-contributors please add @oek1ng for code contributions

Copy link
Contributor

@oek1ng

I've put up a pull request to add @oek1ng! 🎉

@cofin
Copy link
Member

cofin commented Jan 20, 2025

@oek1ng Thanks for the change. I'll merge once the linting and tests are passing.

Copy link

codecov bot commented Jan 20, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 98.34%. Comparing base (46d69f4) to head (4e94bb7).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3960      +/-   ##
==========================================
- Coverage   98.34%   98.34%   -0.01%     
==========================================
  Files         347      347              
  Lines       15743    15755      +12     
  Branches     1740     1741       +1     
==========================================
+ Hits        15483    15494      +11     
- Misses        124      126       +2     
+ Partials      136      135       -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@oek1ng
Copy link
Contributor Author

oek1ng commented Jan 20, 2025

forgot to add type ignore in test, fixed in previous commit

Copy link
Member

@cofin cofin left a comment

Choose a reason for hiding this comment

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

Thanks for the change. It LGTM

@cofin cofin enabled auto-merge (squash) January 21, 2025 16:38
@cofin cofin merged commit 844c90a into litestar-org:main Jan 21, 2025
25 checks passed
Copy link

Documentation preview will be available shortly at https://litestar-org.github.io/litestar-docs-preview/3960

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/docs This PR involves changes to the documentation pr/external pr/internal size: small Triage Required 🏥 This requires triage type/feat
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants