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

kubernetes: verify cached bearer tokens #460

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

calebdoxsey
Copy link
Contributor

@calebdoxsey calebdoxsey commented Oct 21, 2024

Summary

Currently we rely on the expiration timestamp in the cached credentials to know when they need to be refreshed. This PR updates the code to not set the expiration timestamp at all if its not set in the JWT, and to always verify the JWT by attempting to access /api with the token. If access fails we assume the credentials are invalid.

Related issues

Checklist

  • reference any related issues
  • updated docs
  • updated unit tests
  • updated UPGRADING.md
  • add appropriate tag (improvement / bug / etc)
  • ready for review

@calebdoxsey calebdoxsey requested a review from a team as a code owner October 21, 2024 21:53
authclient/authclient.go Outdated Show resolved Hide resolved
@calebdoxsey
Copy link
Contributor Author

The livez endpoint seems to work.

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