keycloak

Keycloak Docker behind loadbalancer with https fails

余生颓废 提交于 2019-12-02 00:01:42
问题 I am trying to use clustered keycloak docker behind the A10 load balancer. I am trying access all the request by https from the client application. My issue is that the same setup is working when we try to access keycloak has HTTP but at the same time when we try to access this has HTTPS it is not working. Can anyone help me to solve this issue? Please let me know whether the issue is in the keycloak level or A10 load balancer level. 回答1: I don't know A10, but you have to ensure that it sets

Keycloak Docker behind loadbalancer with https fails

混江龙づ霸主 提交于 2019-12-01 22:03:57
I am trying to use clustered keycloak docker behind the A10 load balancer. I am trying access all the request by https from the client application. My issue is that the same setup is working when we try to access keycloak has HTTP but at the same time when we try to access this has HTTPS it is not working. Can anyone help me to solve this issue? Please let me know whether the issue is in the keycloak level or A10 load balancer level. I don't know A10, but you have to ensure that it sets the request headers X-Forwarded-For and X-Forwarded-Proto . Then you have to configure Keycloak (Wildfly,

Reverse proxy configuration for keycloak (Nginx)

倾然丶 夕夏残阳落幕 提交于 2019-12-01 21:29:21
I have a spring boot application (with keycloak adapter) running on port 8000 and keycloak running on 8080 I have edited my /etc/hosts file to route requests coming on my test-domain (foo.bar.com) to route to 127.0.0.1 I am not interested in SSL as of now. My sample nginx configuration: server { listen 80; server_name foo.bar.com; location /myapp { proxy_set_header Host $host/myapp; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Host $host; proxy_set_header X-Forwarded-Server $host; proxy_set_header X-Forwarded

keycloak realmresourceprovider corse

风格不统一 提交于 2019-12-01 18:59:59
I'm evaluating some IAM Products and encountered a Problem with CORS with the RealmResourceProvider from Keycloak. The goal is to write an angular4 client able to create user and manage groups with a REST interface from Keycloak. Server-side: I tried to implement the Rest interface with the RealmResourceProvider Interface in order to access Realm and User Data as easy as possible. I followed the Beercloak example (github.com/dteleguin/beercloak) and got it working, but without a custom theme (only the REST-Resources). My own application is packaged as Jar. I managed to call this Facade via

keycloak realmresourceprovider corse

只愿长相守 提交于 2019-12-01 17:43:29
问题 I'm evaluating some IAM Products and encountered a Problem with CORS with the RealmResourceProvider from Keycloak. The goal is to write an angular4 client able to create user and manage groups with a REST interface from Keycloak. Server-side: I tried to implement the Rest interface with the RealmResourceProvider Interface in order to access Realm and User Data as easy as possible. I followed the Beercloak example (github.com/dteleguin/beercloak) and got it working, but without a custom theme

How to create a Script Mapper in Keycloak?

こ雲淡風輕ζ 提交于 2019-12-01 05:34:57
I need to create a Protocol Mapper of type Script Mapper in Keycloak. The script should get a user attribute, check its size, and put it on the token. I found no documentation or examples of how a script should be created. From the bits and pieces I could gather, I guess I the script would need to look something like: var value = user.getAttribute("myAttribute"); if (value.length > LIMIT) { value = value.substring(0,LIMIT); } token.setOtherClaims("myAttribute",value); Is this right? I made up user.getAttribute("myAttribute"). Is there a source of documentation where I can find how to get a

Keycloak add extra claims from database / external source with custom protocol mapper

你说的曾经没有我的故事 提交于 2019-11-30 23:53:33
问题 I've seen those two post that give a solution to this question but they do not provide detailed enough informations about how to do it for non Java developer like me: Keycloak add extra claims from database / external source How to register a custom ProtocolMapper in Keycloak? Here is a recap of their solutions that could help others if filled with more details. Process expected from 1st link User logs in My custom protocol mapper gets called, where I overwrite the transformAccessToken method

How to enable policy enforcing in keycloak for node.js application?

落爺英雄遲暮 提交于 2019-11-30 23:49:39
I have to integrate node.js application with keycloak.The application is in express.But the policies are not enforcing.It grants permission for all the users to access all the api. For /test api: Only users with 'chief' role has the access.I have given those policies in keycloak admin console.But those are not reflecting.Why? User without 'chief' role is also accessing /test app.js: 'use strict'; const Keycloak = require('keycloak-connect'); const express = require('express'); const session = require('express-session'); const expressHbs = require('express-handlebars'); const app = express();

wildfly integration with keycloak 403 forbidden error

。_饼干妹妹 提交于 2019-11-30 23:28:37
I have an application integrated with keycloak. THe application runs on wildfly server. I use web.xml to authenticate keycloak(as Login config). Apart from that i use keycloak.json file, where i define the keycloak realm settings in application. When i invoke the application pages, the keycloak login pages opens, after entereing the credentials, it comes back to wildfly with 403 forbidden error. Previously, the same setup was working but now after enabling ssl, i'm facing this issue. Please help me in resolving the issue, does it require any other additional setup for ssl. If its the case that

Access the keycloak API from postman

社会主义新天地 提交于 2019-11-30 23:04:02
问题 I have tried to access the keycloak API from the postman. but it is showing 400 bad request. I was calling api in the below format. http://{hostname}:8080/auth/realms/master/protocol/openid-connect/token?username=admin&password=admin&client_id=admin-cli&grant_type=password In the headers I have set the content_type as application/x-www-form-urlencoded I am getting the response as below. { "error": "invalid_request", "error_description": "Missing form parameter: grant_type" } Can any one help