From a77c35ea8fc2157439c3d5d5787de760dc0cbb14 Mon Sep 17 00:00:00 2001 From: stianst Date: Wed, 29 Apr 2020 14:02:34 +0200 Subject: [PATCH] KEYCLOAK-14009 Add fix for token revocation endpoint --- .../protocol/oidc/endpoints/TokenRevocationEndpoint.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/services/src/main/java/org/keycloak/protocol/oidc/endpoints/TokenRevocationEndpoint.java b/services/src/main/java/org/keycloak/protocol/oidc/endpoints/TokenRevocationEndpoint.java index 67c045af15..07a0045312 100644 --- a/services/src/main/java/org/keycloak/protocol/oidc/endpoints/TokenRevocationEndpoint.java +++ b/services/src/main/java/org/keycloak/protocol/oidc/endpoints/TokenRevocationEndpoint.java @@ -34,6 +34,7 @@ import org.keycloak.events.Details; import org.keycloak.events.Errors; import org.keycloak.events.EventBuilder; import org.keycloak.events.EventType; +import org.keycloak.headers.SecurityHeadersProvider; import org.keycloak.models.AuthenticatedClientSessionModel; import org.keycloak.models.ClientModel; import org.keycloak.models.KeycloakSession; @@ -100,6 +101,7 @@ public class TokenRevocationEndpoint { event.detail(Details.REVOKED_CLIENT, client.getClientId()).success(); + session.getProvider(SecurityHeadersProvider.class).options().allowEmptyContentType(); return cors.builder(Response.ok()).build(); }