This is a custom Keycloak Client Authenticator that validates SPIFFE SVID JWTs for client authentication. It's modeled after the existing JWT client authenticator but specifically designed for SPIFFE SVID validation.
- Validates SPIFFE SVID JWTs for client authentication
- Follows the same validation patterns as the standard JWT client authenticator
- Provider ID:
client-spiffe-jwt
To build the project:
mvn clean packageThis will create a JAR file in the target/ directory.
- Copy the generated JAR from
target/spiffe-svid-client-authenticator-1.0.0.jarto your Keycloak installation'sproviders/directory - Restart Keycloak
- Create a JBoss/WildFly module structure
- Deploy as a module in Keycloak's module system
After deployment:
- Go to Keycloak Admin Console
- Navigate to Clients → [Your Client] → Settings
- Set "Client authentication" to "On"
- Go to Credentials tab
- Set "Client authenticator" to "SPIFFE SVID JWT"
This authenticator is designed to be easily customizable. You can modify:
SpiffeSvidClientAuthenticator.java- Main authentication logicSpiffeSvidClientValidator.java- JWT validation logicSpiffeSvidClientAuthUtil.java- Error response handling
- Keycloak 26.2.5
- Java 17
- Maven 3.6+
Apache License 2.0