diff --git a/cmd/appview/serve.go b/cmd/appview/serve.go index e983109..890a2ab 100644 --- a/cmd/appview/serve.go +++ b/cmd/appview/serve.go @@ -385,6 +385,14 @@ func serveRegistry(cmd *cobra.Command, args []string) error { config := oauthApp.GetConfig() metadata := config.ClientMetadata() + // For confidential clients, ensure JWKS is included + // The indigo library should populate this automatically, but we explicitly set it here + // to be defensive and ensure it's always present for confidential clients + if config.IsConfidential() && metadata.JWKS == nil { + jwks := config.PublicJWKS() + metadata.JWKS = &jwks + } + // Convert indigo's metadata to map so we can add custom fields metadataBytes, err := json.Marshal(metadata) if err != nil {