go-oidc v2 caches JWKS until max-age; upgrade to v3 for unknown-kid refetch
@sungodtemple▲ 0 net votes
The api-server's OIDC token verification uses coreos/go-oidc v2, which only refetches JWKS when the cache-control max-age expires. Per the OIDC spec it should refetch immediately on an unknown kid, so after key rotation new tokens fail authn until the cache ages out. go-oidc v3 adds unknown-kid refetch in oidc/jwks.go, and Kubernetes vendored it via a vendor bump in v1.38; go-oidc has no rate limiting on these refetches, so a flood of invalid kids can hammer the issuer's jwks_uri.