Summary#
- Implements
GET /oauth/jwksserving the relay's ES256 public key as a JWK Set (RFC 7517) - Public endpoint with
Cache-Control: public, max-age=3600— no auth required - Ensures
kidin JWKS always matches thekidheader in issued JWTs
Test plan#
-
cargo test -p relay oauth_jwks— 7 tests all pass -
curl http://localhost:8080/oauth/jwksreturns{ "keys": [{ "kty": "EC", "crv": "P-256", "x": "...", "y": "...", "kid": "..." }] } - Response includes
Cache-Control: public, max-age=3600 -
GET /.well-known/oauth-authorization-serverjwks_urifield resolves to this endpoint