- Copy jar to
/keycloak-<version>/providers
- Run the following command to complete the installation:
${kc.home.dir}/bin/kc.sh build
Configuration is done per realm in the keycloak administration console
Steps:
- Select realm to be configured
- Go to Authentication tab on the left and under Flows select registration
- On the right hand of the screen select "Duplicate" from the "Action" menu and create a copy of the registration flow
- Name the new flow "registration-with-whitelisting"
- In the Flows tab, select the newly created registration flow in order to configure it
- Under Add (+ icon), add a new step
- In the providers list, select the plugin name Registration email domain validation
- Save
- Move the newly added step to be just below Registration User Profile Creation; this is important such that all the form validation is done sequentially
- Set the new step to "Required"
- On the right there is a config button (gear settings) where the plugin is to be configured
- Under Flows tab, the newly created registration flow needs to be selected instead of the default Registration
- Click on settings (right corner with 3 verical dots) and choose bind flow
- Select registration flow
- Default Registration flow should appear as 'Not in use' now
Sample config values
- Num portal uri: http://host.docker.internal:8090/organization/domains
- Token uri: https://keycloak.dev.num-codex.de/auth/realms/crr/protocol/openid-connect/token
- Client id: num-portal
- Client secret:
- Error message:
<span class="message-text" style = "display:block">Your email-address is not allowed. Please contact our support at:<a href="mailto:[email protected]" style="color: white;font-weight: bold;padding-left: 10px;">[email protected]</a> and inform about this message.</span>
Steps to configure field length validator plugin
- Repeat step 1-6 but for previously created flow (so you have to duplicate "registration-with-whitelisting" flow)
- In the providers list, select the plugin name NUM Custom registration page field length validator
- Move the newly added execution flow to be just below Registration User Profile Creation and above "Registration email domain validation"; this is important such that all the form validation is done sequentially
- save
- On the right there is a config button (gear settings) where the plugin is to be configured (first and last name maximum length should be set to 50, department to 100 and notes to 255)
- repeat 12-13 from above
Copyright 2024 HiGHmed e.V.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.