All Projects → dteleguin → beercloak

dteleguin / beercloak

Licence: other
BeerCloak: a comprehensive Keycloak extension example

Programming Languages

java
68154 projects - #9 most used programming language
HTML
75241 projects
javascript
184084 projects - #8 most used programming language
FreeMarker
481 projects
CSS
56736 projects

Labels

Projects that are alternatives of or similar to beercloak

oso-backend
Heart of the oso project.
Stars: ✭ 12 (-89.09%)
Mutual labels:  keycloak
keycloak-protocol-cas
CAS protocol provider for Keycloak
Stars: ✭ 67 (-39.09%)
Mutual labels:  keycloak
vertx-vue-keycloak
This repo holds the source codes for the Medium Article "Vert.x + VueJS + OAuth2 in 5 steps"
Stars: ✭ 20 (-81.82%)
Mutual labels:  keycloak
spid-keycloak-provider
Italian SPID authentication provider for Keycloak (https://www.keycloak.org/)
Stars: ✭ 48 (-56.36%)
Mutual labels:  keycloak
keycloak-kubernetes
Keycloak deployment into Kubernetes cluster
Stars: ✭ 25 (-77.27%)
Mutual labels:  keycloak
dinivas
AWS, GCP alternative on premise. Dinivas manage your private Cloud (OpenStack) infrastructure by providing many features based on popular Open Source projects
Stars: ✭ 15 (-86.36%)
Mutual labels:  keycloak
keycloak-phone-provider
A Keycloak provider which phone and SMS
Stars: ✭ 83 (-24.55%)
Mutual labels:  keycloak
keycloak-sso-configs
common keycloak single sign on configurations
Stars: ✭ 19 (-82.73%)
Mutual labels:  keycloak
keycloak-spring-boot-rest-angular-demo
Demo for configuring Keycloak authentication for a spring-boot rest service and AngularJs web client
Stars: ✭ 24 (-78.18%)
Mutual labels:  keycloak
keycloak-admin-client
PHP Client to connect to Keycloak admin rest apis
Stars: ✭ 57 (-48.18%)
Mutual labels:  keycloak
keycloakify-demo-app
Demo GitHub Actions setup for react projects that uses keycloakify
Stars: ✭ 34 (-69.09%)
Mutual labels:  keycloak
e-shop
Sample Spring Cloud microservices e-shop.
Stars: ✭ 48 (-56.36%)
Mutual labels:  keycloak
nest-keycloak-connect
keycloak-nodejs-connect module for Nest
Stars: ✭ 174 (+58.18%)
Mutual labels:  keycloak
keycloak-dropwizard-integration
This project shows how JBoss Keycloak and Dropwizard can be used together.
Stars: ✭ 49 (-55.45%)
Mutual labels:  keycloak
keycloak-home-idp-discovery
Keycloak: Home IdP Discovery - discover home identity provider or realm by email domain
Stars: ✭ 42 (-61.82%)
Mutual labels:  keycloak
keycloak-clustered
keycloak-clustered extends Keycloak docker image. It allows to run easily a cluster of Keycloak instances
Stars: ✭ 80 (-27.27%)
Mutual labels:  keycloak
keycloak-admin-go
Keycloak Admin REST client for go
Stars: ✭ 17 (-84.55%)
Mutual labels:  keycloak
keycloak-radius-plugin
Make the radius server as part of keycloak SSO
Stars: ✭ 102 (-7.27%)
Mutual labels:  keycloak
springboot-keycloak-openldap
The goal of this project is to create a simple Spring Boot REST API, called simple-service, and secure it with Keycloak. Furthermore, the API users will be loaded into Keycloak from OpenLDAP server.
Stars: ✭ 96 (-12.73%)
Mutual labels:  keycloak
springboot-react-keycloak
The goal of this project is to secure movies-app using Keycloak(with PKCE). movies-app consists of two applications: one is a Spring Boot Rest API called movies-api and another is a ReactJS application called movies-ui.
Stars: ✭ 192 (+74.55%)
Mutual labels:  keycloak

BeerCloak: a comprehensive Keycloak extension example

BeerCloak is a collection of different techniques for building custom admin resources in Keycloak.

  • BeerEntity JPA entity + LiquiBase changelog;
  • BeerResource realm REST resource with CRUD operations & more;
  • Authorization:
    • roles: view-beer and manage-beer;
    • automatically created for each existing realm;
    • automatically created for each newly added realm;
    • automatically included into the master admin role;
    • used for authorization on BeerResource and sub-resources;
  • Event logging:
    • AdminEventBuilder instance;
    • custom resource and action types (not yet implemented)
  • GUI extensions to the admin console.

The beercloak.resources.AbstractAdminResource is ready to be used as a base class for admin resources. It contains the code necessary to setup authorization and logging.

Structure

beercloak-core: "core" module with some "business logic", to demonstrate packaging with dependencies
beercloak-module: main module actually containing providers and everything (depends on beercloak-core)
beercloak-ear: EAR packaging module to combine all the above into a deployable EAR

Requirements

  • Keycloak 3.4.0.Final

Build

mvn install

Installation

  1. Copy beercloak-ear/target/beercloak-XXX.ear into Keycloak's standalone/deployments directory.

Warning! While Keycloak generally supports hot deployment of providers, this is not supported for EntityProviders. That means, BeerCloak shouldn't be hot (re)deployed, otherwise you'll get exceptions and non-working code.
See KEYCLOAK-5782 for more info.

  1. Configure theme in your standalone/configuration/standalone.xml:
        <subsystem xmlns="urn:jboss:domain:keycloak-server:1.1">
            ...
            <theme>
                <staticMaxAge>2592000</staticMaxAge>
                <cacheThemes>true</cacheThemes>
                <cacheTemplates>true</cacheTemplates>
                <dir>${jboss.home.dir}/themes</dir>
                <!-- Here we go -->
                <modules>
                    <module>
                        deployment.beercloak
                    </module>
                </modules>
                <default>beer</default>
            </theme>
            ...
        </subsystem>

You can omit <default>beer</default>, but then you'll have to manually choose the "beer" theme in realm configuration → Themes → Admin console theme.

(Currently, if you ship a theme inside your module, you have to configure it manually in the XML config. This may change in the future with automatic deployment of themes, you can track progress under KEYCLOAK-4547)

Running example

Run Keycloak and log into the admin console. You should be able to access the "Beer" menu item.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].