POC: Add password-reset-at to JWE token for stateless validation#7692
Draft
thabofletcher wants to merge 1 commit intomainfrom
Draft
POC: Add password-reset-at to JWE token for stateless validation#7692thabofletcher wants to merge 1 commit intomainfrom
thabofletcher wants to merge 1 commit intomainfrom
Conversation
Add offline token invalidation checking to support policy engine sidecars that can validate tokens without database lookups. Changes: - Add JWE_PAYLOAD_PASSWORD_RESET_AT constant to jwt.py - Include password_reset_at in token payload when generating JWE - Add is_token_invalidated_offline() for payload-only validation - Update extract_token_and_load_client functions to use offline check first - Add tests for offline token invalidation Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Contributor
|
The latest updates on your projects. Learn more about Vercel for GitHub. 2 Skipped Deployments
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
password-reset-atfield to JWE token payload for stateless token invalidationDocumentation: See fidesplus POC docs for full results.
POC Results Summary
This PR is part of a larger POC comparing Go, Rust, and Python for policy evaluation. See ethyca/fidesplus#3258 for the full implementation.
Benchmark Results (Averaged across 5 runs)
Python/fidesplus (5 runs)
Key Insights
Changes
JWE_PAYLOAD_PASSWORD_RESET_ATconstantpassword_reset_atin token payload when generating JWEis_token_invalidated_offline()for payload-only validationContext
This is part of the Policy Engine Sidecar POC exploring Rust vs Go for high-performance PBAC enforcement. The OAuth enhancement allows sidecars to validate tokens without requiring database access.
Related: ethyca/fidesplus#3258 (policy engine sidecars)
Test plan
🤖 Generated with Claude Code