Displaying Client ID in Keycloak Login Page
by Kunal Kumar
I have a few clients that are under my realm, and would like to display the
name of each of them at the login page to that specific client ids
respectively.
I know that the realm display name is represented by *realm.displayNameHtml
*, but how do i display the client ID?
Regards,
Kunal Kumar
6 years
Re: [keycloak-user] manipulate IdP attributes in authentication script
by Geoffrey Cleaves
Hi Cristovao, did you ever figure this out?
----
> Hi,
I'd like to know if it is possible to add a Script execution to "first
broker login" and somehow manipulate (set/see/etc...) the user's IdP
information?
I'm asking this cause my Identity Provider is a federation (like eduGAIN),
and I am having issues when users use the same credentials in 2 different
IdPs...in Keycloak all attributes will be the same except the
identity_provider_id which will cause a conflict (violates unique_id
constraint) with the already existing user account in Keycloak, which
already has a link to that Keycloak IdP (which in practice is a federation).
Best regards,
Cris
6 years
importing/exporting users alone in keycloak
by Madhu
is there a way to import/export users alone in keycloak
"bin/standalone.sh -Dkeycloak.migration.action=export -Dkeycloak.migration.provider=dir -Dkeycloak.migration.dir=<DIR TO EXPORT TO>"
seems to export the entire realm, i am interested in importing users info alone (i.e user, user attribute, user role mapping, user user group association)
any suggestions?
Madhu
6 years
keycloak 3.4.3 not setup Windows 10
by Şuayb Şimşek
I installed the 3.4.3 version of the keycloak on my computer.Errors occur
when I run the standalone.bat folder in the bin folder.I couldn't find the
solution to this error.Please,help.
16:34:57,379 ERROR [org.jboss.msc.service.fail] (ServerService Thread Pool
-- 56) MSC000001: Failed to start service
jboss.undertow.deployment.default-server.default-host./auth:
org.jboss.msc.service.StartException in service
jboss.undertow.deployment.default-server.default-host./auth:
java.lang.RuntimeException: RESTEASY003325: Failed to construct public
org.keycloak.services.resources.KeycloakApplication(javax.servlet.ServletContext,org.jboss.resteasy.core.Dispatcher)
at
org.wildfly.extension.undertow.deployment.UndertowDeploymentService$1.run(UndertowDeploymentService.java:84)
at
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
at org.jboss.threads.JBossThread.run(JBossThread.java:320)
Caused by: java.lang.RuntimeException: RESTEASY003325: Failed to construct
public
org.keycloak.services.resources.KeycloakApplication(javax.servlet.ServletContext,org.jboss.resteasy.core.Dispatcher)
at
org.jboss.resteasy.core.ConstructorInjectorImpl.construct(ConstructorInjectorImpl.java:162)
at
org.jboss.resteasy.spi.ResteasyProviderFactory.createProviderInstance(ResteasyProviderFactory.java:2298)
at
org.jboss.resteasy.spi.ResteasyDeployment.createApplication(ResteasyDeployment.java:340)
at
org.jboss.resteasy.spi.ResteasyDeployment.start(ResteasyDeployment.java:253)
at
org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.init(ServletContainerDispatcher.java:120)
at
org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.init(HttpServletDispatcher.java:36)
at
io.undertow.servlet.core.LifecyleInterceptorInvocation.proceed(LifecyleInterceptorInvocation.java:117)
at
org.wildfly.extension.undertow.security.RunAsLifecycleInterceptor.init(RunAsLifecycleInterceptor.java:78)
at
io.undertow.servlet.core.LifecyleInterceptorInvocation.proceed(LifecyleInterceptorInvocation.java:103)
at
io.undertow.servlet.core.ManagedServlet$DefaultInstanceStrategy.start(ManagedServlet.java:250)
at
io.undertow.servlet.core.ManagedServlet.createServlet(ManagedServlet.java:133)
at
io.undertow.servlet.core.DeploymentManagerImpl$2.call(DeploymentManagerImpl.java:565)
at
io.undertow.servlet.core.DeploymentManagerImpl$2.call(DeploymentManagerImpl.java:536)
at
io.undertow.servlet.core.ServletRequestContextThreadSetupAction$1.call(ServletRequestContextThreadSetupAction.java:42)
at
io.undertow.servlet.core.ContextClassLoaderSetupAction$1.call(ContextClassLoaderSetupAction.java:43)
at
org.wildfly.extension.undertow.security.SecurityContextThreadSetupAction.lambda$create$0(SecurityContextThreadSetupAction.java:105)
at
org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1508)
at
org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1508)
at
org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1508)
at
org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1508)
at
io.undertow.servlet.core.DeploymentManagerImpl.start(DeploymentManagerImpl.java:578)
at
org.wildfly.extension.undertow.deployment.UndertowDeploymentService.startContext(UndertowDeploymentService.java:100)
at
org.wildfly.extension.undertow.deployment.UndertowDeploymentService$1.run(UndertowDeploymentService.java:81)
... 6 more
Caused by: java.lang.ExceptionInInitializerError
at
org.keycloak.protocol.docker.DockerAuthV2ProtocolFactory.isSupported(DockerAuthV2ProtocolFactory.java:79)
at
org.keycloak.services.DefaultKeycloakSessionFactory.isEnabled(DefaultKeycloakSessionFactory.java:237)
at
org.keycloak.services.DefaultKeycloakSessionFactory.loadFactories(DefaultKeycloakSessionFactory.java:215)
at
org.keycloak.services.DefaultKeycloakSessionFactory.init(DefaultKeycloakSessionFactory.java:77)
at
org.keycloak.services.resources.KeycloakApplication.createSessionFactory(KeycloakApplication.java:327)
at
org.keycloak.services.resources.KeycloakApplication.<init>(KeycloakApplication.java:117)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
Method)
at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at
org.jboss.resteasy.core.ConstructorInjectorImpl.construct(ConstructorInjectorImpl.java:150)
... 28 more
Caused by: java.lang.RuntimeException: java.lang.IllegalArgumentException:
No enum constant org.keycloak.common.Profile.ProfileValue.COMMUN¦TY
at org.keycloak.common.Profile.<init>(Profile.java:114)
at org.keycloak.common.Profile.<clinit>(Profile.java:62)
... 39 more
Caused by: java.lang.IllegalArgumentException: No enum constant
org.keycloak.common.Profile.ProfileValue.COMMUN¦TY
at java.lang.Enum.valueOf(Enum.java:238)
at org.keycloak.common.Profile$ProfileValue.valueOf(Profile.java:50)
at org.keycloak.common.Profile.<init>(Profile.java:97)
... 40 more
16:34:57,395 INFO [org.jboss.as.connector.subsystems.datasources] (MSC
service thread 1-4) WFLYJCA0010: Unbound data source
[java:jboss/datasources/KeycloakDS]
16:34:57,399 INFO [org.wildfly.extension.undertow] (MSC service thread
1-5) WFLYUT0008: Undertow HTTPS listener https suspending
16:34:57,402 INFO [org.jboss.as.connector.subsystems.datasources] (MSC
service thread 1-8) WFLYJCA0010: Unbound data source
[java:jboss/datasources/ExampleDS]
16:34:57,410 INFO [org.jboss.as.connector.deployers.jdbc] (MSC service
thread 1-4) WFLYJCA0019: Stopped Driver service with driver-name = h2
16:34:57,414 INFO [org.wildfly.extension.undertow] (MSC service thread
1-5) WFLYUT0007: Undertow HTTPS listener https stopped, was bound to
127.0.0.1:8443
16:34:57,422 INFO [org.wildfly.extension.undertow] (MSC service thread
1-6) WFLYUT0019: Host default-host stopping
16:34:57,425 INFO [org.wildfly.extension.undertow] (MSC service thread
1-6) WFLYUT0008: Undertow HTTP listener default suspending
16:34:57,428 INFO [org.wildfly.extension.undertow] (MSC service thread
1-6) WFLYUT0007: Undertow HTTP listener default stopped, was bound to
127.0.0.1:8099
16:34:57,432 INFO [org.wildfly.extension.undertow] (MSC service thread
1-6) WFLYUT0004: Undertow 1.4.18.Final stopping
16:34:57,434 INFO [org.jboss.as.clustering.infinispan] (ServerService
Thread Pool -- 52) WFLYCLINF0003: Stopped clientSessions cache from
keycloak container
16:34:57,443 INFO [org.jboss.as.clustering.infinispan] (ServerService
Thread Pool -- 51) WFLYCLINF0003: Stopped client-mappings cache from ejb
container
16:34:57,443 INFO [org.jboss.as.clustering.infinispan] (ServerService
Thread Pool -- 55) WFLYCLINF0003: Stopped sessions cache from keycloak
container
16:34:57,444 INFO [org.jboss.as.server.deployment] (MSC service thread
1-1) WFLYSRV0028: Stopped deployment keycloak-server.war (runtime-name:
keycloak-server.war) in 62ms
16:34:57,454 INFO [org.jboss.as.clustering.infinispan] (ServerService
Thread Pool -- 47) WFLYCLINF0003: Stopped loginFailures cache from keycloak
container
16:34:57,455 INFO [org.jboss.as.clustering.infinispan] (ServerService
Thread Pool -- 50) WFLYCLINF0003: Stopped actionTokens cache from keycloak
container
16:34:57,456 INFO [org.jboss.as.clustering.infinispan] (ServerService
Thread Pool -- 48) WFLYCLINF0003: Stopped authorization cache from keycloak
container
16:34:57,457 INFO [org.jboss.as.clustering.infinispan] (ServerService
Thread Pool -- 56) WFLYCLINF0003: Stopped offlineSessions cache from
keycloak container
16:34:57,458 INFO [org.jboss.as.clustering.infinispan] (ServerService
Thread Pool -- 53) WFLYCLINF0003: Stopped users cache from keycloak
container
16:34:57,457 INFO [org.jboss.as.clustering.infinispan] (ServerService
Thread Pool -- 49) WFLYCLINF0003: Stopped offlineClientSessions cache from
keycloak container
16:34:57,457 INFO [org.jboss.as.clustering.infinispan] (ServerService
Thread Pool -- 54) WFLYCLINF0003: Stopped authenticationSessions cache from
keycloak container
16:34:57,456 INFO [org.jboss.as.clustering.infinispan] (ServerService
Thread Pool -- 58) WFLYCLINF0003: Stopped realms cache from keycloak
container
16:34:57,458 INFO [org.jboss.as.clustering.infinispan] (ServerService
Thread Pool -- 46) WFLYCLINF0003: Stopped work cache from keycloak container
16:34:57,457 INFO [org.jboss.as.clustering.infinispan] (ServerService
Thread Pool -- 57) WFLYCLINF0003: Stopped keys cache from keycloak container
16:34:57,478 ERROR [org.jboss.as.server] (ServerService Thread Pool -- 45)
WFLYSRV0022: Deploy of deployment "keycloak-server.war" was rolled back
with no failure message
16:34:57,485 INFO [org.jboss.as] (MSC service thread 1-2) WFLYSRV0050:
Keycloak 3.4.3.Final (WildFly Core 3.0.8.Final) stopped in 101ms
Press any key to continue . . .
6 years
Admin Client for Java
by Vagelis Savvas
Hello,
I am using the Admin Client Java library to administer Keycloak
resources (users,roles, groups, etc.)
for a multi-tenant REST API running on Wildfly.
I wonder what's the recommended usage of the library in this context,
where multiple concurrent requests are the norm.
Is it multi-threading safe? Should I use one instance for all tenants or
maybe an instance per tenant?
Cheers,
Vagelis
6 years
Run script on logout
by Vagelis Savvas
Hello,
is there a way to run custom code on a user logout?
Something like an authenticator script would be ideal,
but if that's not possible which are the available options,if any?
Cheers,
Vagelis
6 years
Keycloak Themes not loading (in admin) after upgrading to 4.4
by Chris Savory
We upgraded our Dev and Stage keycloak instances about a month ago to 4.4 with no issues. Today we took the exact same docker container that is deployed in our staging environment and moved it to production. Our custom theme is loading on the login pages, but the theme is not selectable in any of the realm admin pages. We checked the database and the themes are set correctly in the realm table. What could be the issue? We are running in a clustered mode with two keycloak instances.
--
Christopher Savory
6 years
4.6.0 Upgrade disables client scopes
by Lamina, Marco
Hi,
I upgraded to 4.6.0 using the Kubernetes Helm chart. After the upgrade, token exchange stopped working, which I was able to fix thanks to [1]. Unfortunately, none of my client scopes are working anymore. Trying to get a token using client credentials succeeds, but anything I pass into the “scope” parameter is ignored and none of my default client scopes are applied. The “scope” claim in the token endpoint response is always empty.
Is that a feature that needs to be enabled similar to the token exchange?
[1] https://stackoverflow.com/questions/53367566/unable-to-setup-idp-token-ex...
Thanks,
Marco
6 years