Keycloak
You can enable login with Keycloak using OIDC.
- Create a client in your keycloak realm with:
- Client type:
OpenID Connect - Client authentication:
false - PKCE Method:
S256 - Valid redirect URLs:
<OPEN_CASE_URL>/auth/keycloak/callback - Web origins:
<OPEN_CASE_URL>/* - Valid post logout redirect URIs:
<OPEN_CASE_URL>
- (Optional) Open Case will check for the
groupsattribute from keycloak and sync the present groups. In order to add this in keycloak:
- "Add mapper" -> "By configuration" -> "Groups membership"
- (Optional) Add specific user attributes to the client scope:
- In the client configuration go to "Client scopes" and click on
<CLIENT_ID>-dedicated - "Add mapper" -> "By configuration" -> "User Attribute"
- Add any of these values to the mapping (all strings):
shift_signal_accountprivate_phone_numberprivate_signal_accountlanguagesshift_phone_number
- Add the configuration values to your dotenv:
dotenv
KEYCLOAK_DISABLE_DEFAULT_LOGIN=false
KEYCLOAK_ENABLE_USERS_BY_DEFAULT=false
KEYCLOAK_DISPLAY_NAME=My OAuth
KEYCLOAK_CLIENT_ID=<Client ID from Keycloak>
KEYCLOAK_CLIENT_SECRET=<Client ID from Keycloak>
KEYCLOAK_BASE_URL=<Keycloak URL>
KEYCLOAK_REALM=<Keycloak Realm>