Skip to content

Conversation

lovasoa
Copy link
Collaborator

@lovasoa lovasoa commented Jul 28, 2025

Implement OIDC provider metadata caching to support key rotation and improve robustness.

Previously, OIDC provider metadata was discovered only once at startup and never refreshed, which prevented the system from picking up rotated signing keys and could lead to authentication failures or security vulnerabilities. This PR introduces a caching mechanism that refreshes the metadata and recreates the OIDC client on-demand, with a 24-hour cache duration and a 5-minute minimum refresh interval, ensuring key rotation is handled gracefully while providing robust fallback behavior.


Open in WebOpen in CursorOpen Docs

@lovasoa
Copy link
Collaborator Author

lovasoa commented Jul 28, 2025

reported by @alexisrc1

@lovasoa
Copy link
Collaborator Author

lovasoa commented Jul 28, 2025

@cursor review

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Bugbot free trial expires on August 9, 2025
Learn more in the Cursor dashboard.

cursoragent and others added 5 commits July 28, 2025 23:38
…eatures

- Preserved production-grade OIDC metadata caching implementation
- Added support for multiple JWT audiences from main branch
- Updated function signatures to match main (process_oidc_callback, get_authenticated_user_info)
- Added handle_authenticated_oidc_callback support for already-authenticated users
- Maintained async caching functionality with proper HTTP client access
- Resolved all merge conflicts while keeping both new features and security fixes
@lovasoa lovasoa closed this Jul 31, 2025
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

Successfully merging this pull request may close these issues.

2 participants