[keycloak-user] How I possible to reuse configuration between authenticators?
Marek Posolda
mposolda at redhat.com
Mon Mar 13 05:12:40 EDT 2017
On 12/03/17 19:13, Known Michael wrote:
> I need to use 2 authenticators in 2 different flows: browser and direct
> grant flows.
>
> It will be different authenticators from the keycloak point of view same
> Java classes.
>
> I want to reuse the authenticator configuration:
>
> - I want to update configuration of only one authenticator
>
> - I want to store it in one place in the database
>
> - I want its configuration properties will be provided only for
> one authenticator
>
> - I want to reuse the configuration in the second authenticator
>
> How is possible to do it?
Not sure I understand fully, but if your authenticator configuration is
stored in database or in properties file, then you can just add 1
property and/or 2 properties to your authenticator in Keycloak. And that
will be "databaseURL" and/or "propertiesFile" . You may not even need
any property as long as your DB and/or property file is at some known
location and can be hardcoded in your implementation.
For example, if your properties file is in
"/foo/my-authenticator.properties", then your Authenticator
implementation can just read the configuration from this property file.
And if you change something in this property file, then both KC
authenticator instances for "Browser" and "directGrant" will be
immediately able to see that change.
Marek
> _______________________________________________
> keycloak-user mailing list
> keycloak-user at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/keycloak-user
More information about the keycloak-user
mailing list