From 62756e7bc44de81b884fc91ae90c9fbddb67bef0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20N=C3=BCtzi?= Date: Wed, 15 Jul 2026 08:18:14 +0200 Subject: [PATCH 01/16] feat: add keycloak service - Adapted from devenv.sh keycloak service which I maintain. --- nix/services/keycloak-certs_test.nix | 51 + nix/services/keycloak.nix | 10 + nix/services/keycloak/options.nix | 312 ++ nix/services/keycloak/service.nix | 247 ++ nix/services/keycloak/test-certs/ssl-cert.crt | 19 + nix/services/keycloak/test-certs/ssl-cert.key | 28 + nix/services/keycloak/test-realms/master.json | 2499 +++++++++++++++++ nix/services/keycloak/test-realms/test.json | 1980 +++++++++++++ nix/services/keycloak_test.nix | 47 + test/flake.nix | 2 + 10 files changed, 5195 insertions(+) create mode 100644 nix/services/keycloak-certs_test.nix create mode 100644 nix/services/keycloak.nix create mode 100644 nix/services/keycloak/options.nix create mode 100644 nix/services/keycloak/service.nix create mode 100644 nix/services/keycloak/test-certs/ssl-cert.crt create mode 100644 nix/services/keycloak/test-certs/ssl-cert.key create mode 100644 nix/services/keycloak/test-realms/master.json create mode 100644 nix/services/keycloak/test-realms/test.json create mode 100644 nix/services/keycloak_test.nix diff --git a/nix/services/keycloak-certs_test.nix b/nix/services/keycloak-certs_test.nix new file mode 100644 index 00000000..8b8cb894 --- /dev/null +++ b/nix/services/keycloak-certs_test.nix @@ -0,0 +1,51 @@ +{ pkgs, config, ... }: +{ + services.keycloak.k1 = { + enable = true; + settings.http-port = 8089; + + database.type = "dev-file"; + + sslCertificate = "./certs/ssl-cert.crt"; + sslCertificateKey = "./certs/ssl-cert.key"; + + realms = { + master = { + path = "./realms/master.json"; + export = true; + import = false; + }; + + test = { + path = "./keycloak/test-realms/realms/test.json"; + import = true; + export = true; + }; + }; + }; + + settings.processes.test = + let + cfg = config.services.keycloak."k1"; + in + { + command = pkgs.writeShellApplication { + runtimeInputs = [ + cfg.package + pkgs.gnugrep + pkgs.curl + pkgs.uutils-coreutils-noprefix + pkgs.jq + ]; + text = " + # TODO: Realm export tests were removed because the H2 embedded database + # (dev-file) holds a file lock that isn't reliably released by the time the + # export JVM starts. Consider re-adding export tests with a PostgreSQL backend. + "; + name = "keycloak-test"; + }; + + depends_on."k1".condition = "process_healthy"; + }; +} +} diff --git a/nix/services/keycloak.nix b/nix/services/keycloak.nix new file mode 100644 index 00000000..bea8814e --- /dev/null +++ b/nix/services/keycloak.nix @@ -0,0 +1,10 @@ +# Based on Devenv's keycloak module: +# Ref: https://github.com/cachix/devenv/commit/32f6747aabbd5aeb7413bae53d7e01e224ec77bc +{ ... +}: +{ + imports = [ + ./keycloak/service.nix + ./keycloak/options.nix + ]; +} diff --git a/nix/services/keycloak/options.nix b/nix/services/keycloak/options.nix new file mode 100644 index 00000000..4b2d4afd --- /dev/null +++ b/nix/services/keycloak/options.nix @@ -0,0 +1,312 @@ +# Based on Devenv's keycloak module: +# Ref: https://github.com/cachix/devenv/commit/32f6747aabbd5aeb7413bae53d7e01e224ec77bc +{ config +, lib +, pkgs +, ... +}: + +let + cfg = config.services.keycloak; + + hasRealmExports = lib.any (lib.mapAttrsToList (realmName: opts: opts.export.enable) cfg.realms); + + inherit (lib) + mkOption + mkPackageOption + types + ; +in +{ + options = { + enable = mkOption { + type = types.bool; + default = false; + example = true; + description = '' + Whether to enable the Keycloak identity and access management + server. + ''; + }; + dataDir = mkOption { + type = types.str; + default = "./data"; + description = '' + Base directory where keycloak stores its data `/keycloak`. + ''; + }; + + sslCertificate = mkOption { + type = types.nullOr ( + lib.types.pathWith { + inStore = false; + absolute = false; + } + ); + default = null; + example = "/run/keys/ssl_cert"; + description = '' + The path to a PEM formatted certificate to use for TLS/SSL + connections. + ''; + }; + + sslCertificateKey = mkOption { + type = types.nullOr ( + types.pathWith { + inStore = false; + absolute = false; + } + ); + default = null; + example = "/run/keys/ssl_key"; + description = '' + The path to a PEM formatted private key to use for TLS/SSL + connections. + ''; + }; + + plugins = mkOption { + type = types.listOf types.path; + default = [ ]; + description = '' + Keycloak plugin jar, ear files or derivations containing + them. Packaged plugins are available through + `pkgs.keycloak.plugins`. + ''; + }; + + database = { + type = mkOption { + type = types.enum [ + "dev-mem" + "dev-file" + ]; + default = "dev-file"; + example = "dev-mem"; + apply = + val: + assert lib.assertMsg (val == "dev-mem" -> !hasRealmExports) '' + You cannot export realms with `realms.«name».export == true` when + using `database.type == 'dev-mem'`, import however works. + You can disable realms export with `exportRealms = true` globally. + ''; + val; + description = '' + The type of database Keycloak should connect to. + If you use `dev-mem`, the realm export over script + `keycloak-realm-export-*` does not work. + ''; + }; + }; + + package = mkPackageOption pkgs "keycloak" { }; + + initialAdminPassword = mkOption { + type = types.str; + default = "admin"; + description = '' + Initial password set for the temporary `admin` user. + The password is not stored safely and should be changed + immediately in the admin panel. + + See [Admin bootstrap and recovery](https://www.keycloak.org/server/bootstrap-admin-recovery) for details. + ''; + }; + + scripts = { + exportRealm = mkOption { + type = types.bool; + default = true; + description = '' + Global toggle to enable/disable the **single** realm export + script `keycloak-realm-export`. + ''; + }; + }; + + processes = { + exportRealms = mkOption { + type = types.bool; + default = true; + description = '' + Global toggle to enable/disable the realms export process `keycloak-realm-export-all` + if any realms have `realms.«name».export == true`. + ''; + }; + }; + + realms = mkOption { + default = { }; + type = types.attrsOf ( + types.submodule { + options = { + path = mkOption { + type = types.nullOr ( + lib.types.pathWith { + inStore = false; + absolute = false; + } + ); + default = null; + example = "./realms/a.json"; + description = '' + The path (string, relative to `DEVENV_ROOT`) where you want to import (or export) this realm «name» to. + If not set and `import` is `true` this realm is not imported. + If not set and `export` is `true` its exported to `$DEVENV_STATE/keycloak/realm-export/«name».json`. + ''; + }; + + import = mkOption { + type = types.bool; + default = true; + example = true; + description = '' + If you want to import that realm on start up, if the realm does not yet exist. + ''; + }; + + export = mkOption { + type = types.bool; + default = false; + example = true; + description = '' + If you want to export that realm on process/script launch `keycloak-export-realms`. + ''; + }; + }; + } + ); + + example = lib.literalExpression '' + { + myrealm = { + path = "./myfolder/export.json"; + import = true; # default + export = true; + }; + } + ''; + + description = '' + Specify the realms you want to import on start up and + export on a manual start of process/script 'keycloak-realm-export-all'. + ''; + }; + + settings = mkOption { + type = lib.types.submodule { + freeformType = types.attrsOf ( + types.nullOr ( + types.oneOf [ + types.str + types.int + types.bool + (types.attrsOf types.path) + ] + ) + ); + + options = { + http-host = mkOption { + type = types.str; + default = "::"; + example = "::1"; + description = '' + On which address Keycloak should accept new connections. + ''; + }; + + http-port = mkOption { + type = types.port; + default = 8080; + example = 8080; + description = '' + On which port Keycloak should listen for new HTTP connections. + ''; + }; + + http-management-port = mkOption { + type = types.port; + default = 9000; + example = 9000; + description = '' + The port where Keycloak exposes management API endpoints (e.g. `/health`). + ''; + }; + + https-port = mkOption { + type = types.port; + default = 34429; + example = 34429; + description = '' + On which port Keycloak should listen for new HTTPS connections. + If its not set, its disabled. + ''; + }; + + http-relative-path = mkOption { + type = types.str; + default = "/"; + example = "/auth"; + apply = x: if !(lib.hasPrefix "/") x then "/" + x else x; + description = '' + The path relative to `/` for serving + resources. + + ::: {.note} + In versions of Keycloak using Wildfly (<17), + this defaulted to `/auth`. If + upgrading from the Wildfly version of Keycloak, + i.e. a NixOS version before 22.05, you'll likely + want to set this to `/auth` to + keep compatibility with your clients. + + See + for more information on migrating from Wildfly to Quarkus. + ::: + ''; + }; + + hostname = mkOption { + type = types.str; + default = "localhost"; + example = "localhost"; + description = '' + The hostname part of the public URL used as base for + all frontend requests. + + See + for more information about hostname configuration. + ''; + }; + }; + }; + + example = lib.literalExpression '' + { + hostname = "localhost"; + https-key-store-file = "/path/to/file"; + https-key-store-password = { _secret = "/run/keys/store_password"; }; + } + ''; + + description = '' + Configuration options corresponding to parameters set in + {file}`conf/keycloak.conf`. + + Most available options are documented at . + + Options containing secret data should be set to an attribute + set containing the attribute `_secret` - a + string pointing to a file containing the value the option + should be set to. See the example to get a better picture of + this: in the resulting + {file}`conf/keycloak.conf` file, the + `https-key-store-password` key will be set + to the contents of the + {file}`/run/keys/store_password` file. + ''; + }; + }; +} diff --git a/nix/services/keycloak/service.nix b/nix/services/keycloak/service.nix new file mode 100644 index 00000000..9d6f37eb --- /dev/null +++ b/nix/services/keycloak/service.nix @@ -0,0 +1,247 @@ +{ config +, lib +, pkgs +, name +, ... +}: +let + cfg = config.services.keycloak; + + isSecret = v: lib.isAttrs v && v ? _secret && lib.isString v._secret; + + # Generate the keycloak config file to build it. + keycloakConfig = lib.generators.toKeyValue { + mkKeyValue = lib.flip lib.generators.mkKeyValueDefault "=" { + mkValueString = + v: + if builtins.isInt v then + toString v + else if builtins.isString v then + v + else if true == v then + "true" + else if false == v then + "false" + else if isSecret v then + builtins.hashString "sha256" v._secret + else + throw "unsupported type ${builtins.typeOf v}: ${(lib.generators.toPretty { }) v}"; + }; + }; + + # Filters empty values out. + filteredConfig = lib.converge + (lib.filterAttrsRecursive ( + _: v: + !builtins.elem v [ + { } + null + ] + )) + cfg.settings; + + # Write the keycloak config file. + confFile = pkgs.writeText "keycloak.conf" (keycloakConfig filteredConfig); + + # Build keycloak derivation. + keycloakBuild = ( + cfg.package.override { + inherit confFile; + + plugins = cfg.package.enabledPlugins ++ cfg.plugins; + } + ); + + # Create dummy certificate derivation. + dummyCertificates = pkgs.stdenv.mkDerivation { + pname = "dev-ssl-cert"; + version = "1.0"; + buildInputs = [ pkgs.openssl ]; + src = null; + dontUnpack = true; + buildPhase = '' + mkdir -p $out + openssl req -x509 -newkey rsa:2048 -nodes \ + -keyout $out/ssl-cert.key -out $out/ssl-cert.crt \ + -days 365 \ + -subj "/CN=localhost" + ''; + + installPhase = "true"; + }; + + providedSSLCerts = cfg.sslCertificate != null && cfg.sslCertificateKey != null; + + # Generate the command to import realms. + realmImport = lib.mapAttrsToList + ( + realm: e: + let + f = config.env.DEVENV_ROOT + "/" + e.path; + in + '' + echo "Symlinking realm file '${f}' to import path '$KC_HOME_DIR/data/import'." + if [ ! -f "${f}" ]; then + echo "Realm file '${f}' does not exist!" >&2 + exit 1 + fi + ln -fs "${f}" "$KC_HOME_DIR/data/import/" + '' + ) + (lib.filterAttrs (_: v: v.import && v.path != null) cfg.realms); + + # Generate the commands to export realms. + assertKeycloakStopped = [ + '' + if ${keycloak-health}/bin/keycloak-health; then + echo "You must first stop keycloak and then run this command again." >&2 + exit 1 + fi + + # Ensure the KC_HOME_DIR is set up for the export command. + mkdir -p "$KC_HOME_DIR/conf" + ln -fs ${keycloakBuild}/providers "$KC_HOME_DIR/" + ln -fs ${keycloakBuild}/lib "$KC_HOME_DIR/" + install -D -m 0600 ${confFile} "$KC_HOME_DIR/conf/keycloak.conf" + '' + ]; + + keycloak-realm-export = pkgs.writeShellScriptBin "keycloak-realm-export" ( + lib.concatStringsSep "\n" ( + assertKeycloakStopped + ++ [ + '' + ${keycloakBuild}/bin/kc.sh export --optimized --realm "$1" --file "$2" + '' + ] + ) + ); + + realmsToExport = lib.filterAttrs (_: v: v.export) cfg.realms; + realmsExport = + if (!cfg.processes.exportRealms || lib.length (lib.attrNames realmsToExport) == 0) then + [ ] + else + assertKeycloakStopped + ++ lib.mapAttrsToList + ( + realm: e: + let + file = + if e.path == null then + (config.env.DEVENV_STATE + "/keycloak/realm-export/${realm}.json") + else + e.path; + in + '' + echo "Exporting realm '${realm}' to '${file}'." + mkdir -p "$(dirname "${file}")" + ${keycloakBuild}/bin/kc.sh export --optimized --realm "${realm}" --file "${file}" + + echo "Beautifying realm export '${file}' for diffing." + temp_file=$(${pkgs.coreutils}/bin/mktemp) + ${pkgs.jq}/bin/jq --sort-keys . "${file}" > "$temp_file" + ${pkgs.coreutils}/bin/mv "$temp_file" "${file}" + '' + ) + realmsToExport; + + keycloak-realm-export-all = pkgs.writeShellScriptBin "keycloak-realm-export-all" ( + lib.concatStringsSep "\n" realmsExport + ); + + keycloak-health = pkgs.writeShellScriptBin "keycloak-health" '' + ${pkgs.curl}/bin/curl -k --head -fsS "https://localhost:${toString cfg.settings.http-management-port}${lib.removeSuffix "/" cfg.settings.http-management-relative-path}/health/ready" + ''; + + dataDir = "./" + cfg.dataDir; + keycloakEnv = { + KC_HOME_DIR = dataDir + "/keycloak"; + KC_CONF_DIR = dataDir + "/keycloak/conf"; + KC_TMP_DIR = dataDir + "/keycloak/tmp"; + + KC_BOOTSTRAP_ADMIN_USERNAME = "admin"; + KC_BOOTSTRAP_ADMIN_PASSWORD = "${lib.escapeShellArg cfg.initialAdminPassword}"; + }; + + keycloak-start = + pkgs.writeShellScriptBin "keycloak-start" + # Bash + '' + set -euo pipefail + mkdir -p "$KC_HOME_DIR" + mkdir -p "$KC_HOME_DIR/conf" + mkdir -p "$KC_HOME_DIR/tmp" + + # Always remove the symlinks for the realm imports. + rm -rf "$KC_HOME_DIR/data/import" || true + mkdir -p "$KC_HOME_DIR/data/import" + + ln -fs ${keycloakBuild}/providers "$KC_HOME_DIR/" + ln -fs ${keycloakBuild}/lib "$KC_HOME_DIR/" + install -D -m 0600 ${confFile} "$KC_HOME_DIR/conf/keycloak.conf" + + echo "Keycloak config:" + ${keycloakBuild}/bin/kc.sh show-config || true + + echo "Import realms (if any)..." + ${builtins.concatStringsSep "\n" realmImport} + echo "========================" + + echo "Start keycloak:" + exec ${keycloakBuild}/bin/kc.sh start --optimized --import-realm + ''; +in +{ + outputs = { + # Merge some default values into the freeform options. + services.keycloak.settings = lib.mapAttrs (n: v: lib.mkOptionDefault v) { + # We always enable http since we also use it to check the health. + http-enabled = true; + db = cfg.database.type; + + health-enabled = true; + http-management-relative-path = "/"; + + log-console-level = "info"; + log-level = "info"; + + https-certificate-file = + if providedSSLCerts then cfg.sslCertificate else "${dummyCertificates}/ssl-cert.crt"; + https-certificate-key-file = + if providedSSLCerts then cfg.sslCertificateKey else "${dummyCertificates}/ssl-cert.key"; + }; + + settings.processes = lib.mkIf cfg.enable { + ${name} = { + environment = keycloakEnv; + command = "${lib.getExe keycloak-start}"; + readiness_probe = { + exec = { + command = "${lib.getExe keycloak-health}"; + }; + initial_delay_seconds = 10; + timeout_seconds = 4; + failure_threshold = 20; + }; + }; + + "${name}-realm-export" = lib.mkIf cfg.scripts.exportRealm { + command = "${keycloak-realm-export}/bin/keycloak-realm-export"; + disabled = true; + description = '' + Export a realm '$1' (first argument) from keycloak to location '$2' (second argument). + ''; + }; + + # Export all configured realms. + "${name}-realm-export-all" = lib.mkIf (realmsExport != [ ]) { + command = "${keycloak-realm-export-all}/bin/keycloak-realm-export-all"; + disabled = true; + description = '' + Save the configured realms from keycloak, to back them up. You can run it manually. + ''; + }; + }; + }; +} diff --git a/nix/services/keycloak/test-certs/ssl-cert.crt b/nix/services/keycloak/test-certs/ssl-cert.crt new file mode 100644 index 00000000..e633df0f --- /dev/null +++ b/nix/services/keycloak/test-certs/ssl-cert.crt @@ -0,0 +1,19 @@ +-----BEGIN CERTIFICATE----- +MIIDCTCCAfGgAwIBAgIUePpk+xLT7G7317grthXd+ATTcWgwDQYJKoZIhvcNAQEL +BQAwFDESMBAGA1UEAwwJbG9jYWxob3N0MB4XDTI1MDUxMjA2MDM1NVoXDTI2MDUx +MjA2MDM1NVowFDESMBAGA1UEAwwJbG9jYWxob3N0MIIBIjANBgkqhkiG9w0BAQEF +AAOCAQ8AMIIBCgKCAQEAmb/B9IIGerR7aIj1QUK8nukBetvwCqwYHs7tz1rfaROR +598d8cbXOwa+9BXJeqDUee29+3d3bctMCjgWpiDo1d7V3DlPrnbSzkkwezthNX1m +N2JvIlerOHqnIdG1TSJlQwX4q87I7+7zrscX7TOUjP+nM2pAxzaTLztjmFeccRbt +QaLCLKtsFBqCSj3DHaS+OUoWmwNjj1VodxHXeelouFp3uZA6fuPRLtWHo3LIQttJ +3wUDrxGKl7WXhpz1zr2DHUbLtzx/eRbkcwrxAO+p3avWgET6X0POLI34+bhfPme1 +WoY8E8ZuAdiBx6lOBc0LDN5k2M2KxfXicCOzFYE2sQIDAQABo1MwUTAdBgNVHQ4E +FgQUsQ1P7x5459sgVqHsCogOAzbYj5QwHwYDVR0jBBgwFoAUsQ1P7x5459sgVqHs +CogOAzbYj5QwDwYDVR0TAQH/BAUwAwEB/zANBgkqhkiG9w0BAQsFAAOCAQEAh8Xy +1kQtRRo23qLJh+yAFZy2sB1vlcRUYr9TFn5ys/UHtqKvl+arn2VerPmAludeTbgz +Bpsqp4IXwxEW4YcQ848R7/G4iORLWqpszCCSlRSr2O6Mh0Zs0qasQJ3EH27zhF0B +xQgQ9bgdXEH/JvvpWTHiz3DN2Lr/5ZdWVeLhoDRIpKy5u7XXb2JToIH/sk4rKY2B +j5MQyQiSuId9najCH8ZLiIJ4rZld/yUESE/bn1Dp7jSwB8vOtxqLEpTuKb47+deM +hW4IsB0q0hi3FrGEsgAtBoUtsbJALTKMKulx/CAUmgF4BQ3IIIRPgSnGo4Vs6R3a +t3inOVJ+xg83lwkvSg== +-----END CERTIFICATE----- diff --git a/nix/services/keycloak/test-certs/ssl-cert.key b/nix/services/keycloak/test-certs/ssl-cert.key new file mode 100644 index 00000000..0d7b1c37 --- /dev/null +++ b/nix/services/keycloak/test-certs/ssl-cert.key @@ -0,0 +1,28 @@ +-----BEGIN PRIVATE KEY----- +MIIEvgIBADANBgkqhkiG9w0BAQEFAASCBKgwggSkAgEAAoIBAQCZv8H0ggZ6tHto +iPVBQrye6QF62/AKrBgezu3PWt9pE5Hn3x3xxtc7Br70Fcl6oNR57b37d3dty0wK +OBamIOjV3tXcOU+udtLOSTB7O2E1fWY3Ym8iV6s4eqch0bVNImVDBfirzsjv7vOu +xxftM5SM/6czakDHNpMvO2OYV5xxFu1BosIsq2wUGoJKPcMdpL45ShabA2OPVWh3 +Edd56Wi4Wne5kDp+49Eu1YejcshC20nfBQOvEYqXtZeGnPXOvYMdRsu3PH95FuRz +CvEA76ndq9aARPpfQ84sjfj5uF8+Z7VahjwTxm4B2IHHqU4FzQsM3mTYzYrF9eJw +I7MVgTaxAgMBAAECggEABksjKq8Siiijzz5L9m/qPgGrsyvC7QI+ZS8d7O77Vixx +kdxAODVmJLRnUfZ9A4Kx2ovbdapePnr5PIcvO32oCkPPh+7l+W5DvXihfhSK1iBb +9B3DZCnSiG1SNMAw0Qd8vabw7EIlV4JLLKGvCQv4zgy+ULcjZQQxjNgRgPA/0cve +NSz94u+aAxsCWUf4Urk2KaPFf8O8+OTcY0PntCW/BOa5F7J93vWYTgaycHmwGBjp +85FdofNRbs91kF0Nq2tPXGbVpoleR9xtelk8Sj4aTg1Bgt5GgXep24RZbSFOTHJ7 +4VyyfV3xyNDM43/qHuZkN6PePx7CnQjPv4mVBZadQQKBgQDMdd/zGQcnKUc7Db23 +xY1jWaGy3Ml+N3bJkWaQHOoW+RcFxfr6aKa4mYWXnXaWA74Ff6QbJKc/GxM7dqJZ +Fiv+VrX2CnVsJFDqayl26rlFcqBYkFmAlcfSNUOy+zh9tYxpHUu3scHxmpy4I0ao +w9F5JXk0q4UHpJf3rE2FC3TIrwKBgQDAgWdqT+/ibqwT7qoiPn9ZlWvoPZlhVq1C +AJ2CJD0bzPdLbB2gI6ZDf4XXayBG8Wdgs0rou7E5eHo+j3mHC7ALa2HQ1hiOYPvs +qRXGGMiI65iDA8oCNY4+VZ3HIBVwQQVBLy1tB2I2ipz2BOGZqkSPjAf/irTAmu7D +zBt4bLEOnwKBgQCcG2vP+k4B0nx2VDmENKuNLYROQlD9s29Y21FJuynoPGsdl1nX +E0woKd9cMXe3dkgBfsFXkBa6EfwPLLcr+cfBO4dWwgmBdgDp2sQf7Xtj0O8ob55G +lRWqI8z6vOEW6iS4pQuIx4ni5D/AP/7VIB2xt7DhTAwYF82H5uCRMnwKNQKBgQCr +T/2KHI0sArVcH56ETv3h6RlYWckvWIVjIU0KTdmb7fF8y0AqDM+fbdLb+9eDir0m +zyewqadzr4WKOwA5b+tAnlU0FfNQcXqAB5D6838yagcVQL/661IkouiAFks91H8q +nSNdzZ5XT0+TmJBzwZS18jYD8ZoddUNaNz+TEZcXnQKBgDpVhyX/1ILLCMffT1Wa +HUGMghPb03SuH6y3RYLkfD8DX5wycQ7jBELWnJFs1lWn8N9M0cSqupSfIcy65ZQS +URm5rM5LK2TeoxELVO0FWqzTbPmOfQwcDfTQ+FX0JsdtuTKhDKC57qavJcY/GoGN +mnJm/F1e1mncg3sH8mdlQmC2 +-----END PRIVATE KEY----- diff --git a/nix/services/keycloak/test-realms/master.json b/nix/services/keycloak/test-realms/master.json new file mode 100644 index 00000000..69de95bc --- /dev/null +++ b/nix/services/keycloak/test-realms/master.json @@ -0,0 +1,2499 @@ +{ + "id": "10202c48-820f-43e1-9c59-4da0e93028f6", + "realm": "master", + "displayName": "Keycloak", + "displayNameHtml": "
Keycloak
", + "notBefore": 0, + "defaultSignatureAlgorithm": "RS256", + "revokeRefreshToken": false, + "refreshTokenMaxReuse": 0, + "accessTokenLifespan": 60, + "accessTokenLifespanForImplicitFlow": 900, + "ssoSessionIdleTimeout": 1800, + "ssoSessionMaxLifespan": 36000, + "ssoSessionIdleTimeoutRememberMe": 0, + "ssoSessionMaxLifespanRememberMe": 0, + "offlineSessionIdleTimeout": 2592000, + "offlineSessionMaxLifespanEnabled": false, + "offlineSessionMaxLifespan": 5184000, + "clientSessionIdleTimeout": 0, + "clientSessionMaxLifespan": 0, + "clientOfflineSessionIdleTimeout": 0, + "clientOfflineSessionMaxLifespan": 0, + "accessCodeLifespan": 60, + "accessCodeLifespanUserAction": 300, + "accessCodeLifespanLogin": 1800, + "actionTokenGeneratedByAdminLifespan": 43200, + "actionTokenGeneratedByUserLifespan": 300, + "oauth2DeviceCodeLifespan": 600, + "oauth2DevicePollingInterval": 5, + "enabled": true, + "sslRequired": "external", + "registrationAllowed": false, + "registrationEmailAsUsername": false, + "rememberMe": false, + "verifyEmail": false, + "loginWithEmailAllowed": true, + "duplicateEmailsAllowed": false, + "resetPasswordAllowed": false, + "editUsernameAllowed": false, + "bruteForceProtected": false, + "permanentLockout": false, + "maxTemporaryLockouts": 0, + "bruteForceStrategy": "MULTIPLE", + "maxFailureWaitSeconds": 900, + "minimumQuickLoginWaitSeconds": 60, + "waitIncrementSeconds": 60, + "quickLoginCheckMilliSeconds": 1000, + "maxDeltaTimeSeconds": 43200, + "failureFactor": 30, + "roles": { + "realm": [ + { + "id": "2d5f6195-d923-4231-9e7c-d7376ed5eeac", + "name": "uma_authorization", + "description": "${role_uma_authorization}", + "composite": false, + "clientRole": false, + "containerId": "10202c48-820f-43e1-9c59-4da0e93028f6", + "attributes": {} + }, + { + "id": "3e86fd03-a375-4b11-a2f8-56339696ad22", + "name": "offline_access", + "description": "${role_offline-access}", + "composite": false, + "clientRole": false, + "containerId": "10202c48-820f-43e1-9c59-4da0e93028f6", + "attributes": {} + }, + { + "id": "ef9855c1-4317-4f26-b5e9-c27f13411338", + "name": "admin", + "description": "${role_admin}", + "composite": true, + "composites": { + "realm": ["create-realm"], + "client": { + "test-realm": [ + "manage-realm", + "manage-identity-providers", + "manage-clients", + "view-authorization", + "query-users", + "query-groups", + "query-realms", + "view-clients", + "view-users", + "manage-authorization", + "view-identity-providers", + "query-clients", + "create-client", + "view-events", + "manage-events", + "impersonation", + "manage-users", + "view-realm" + ], + "master-realm": [ + "create-client", + "view-clients", + "manage-users", + "manage-realm", + "query-realms", + "manage-clients", + "view-authorization", + "query-groups", + "query-users", + "manage-authorization", + "view-users", + "view-realm", + "view-identity-providers", + "query-clients", + "view-events", + "manage-identity-providers", + "manage-events", + "impersonation" + ] + } + }, + "clientRole": false, + "containerId": "10202c48-820f-43e1-9c59-4da0e93028f6", + "attributes": {} + }, + { + "id": "6ba1b611-b56b-43f1-8ab0-65086b8a1a36", + "name": "default-roles-master", + "description": "${role_default-roles}", + "composite": true, + "composites": { + "realm": ["offline_access", "uma_authorization"], + "client": { + "account": ["manage-account", "view-profile"] + } + }, + "clientRole": false, + "containerId": "10202c48-820f-43e1-9c59-4da0e93028f6", + "attributes": {} + }, + { + "id": "47b6b17c-fafb-4976-8fd8-c19bf88cdd83", + "name": "create-realm", + "description": "${role_create-realm}", + "composite": false, + "clientRole": false, + "containerId": "10202c48-820f-43e1-9c59-4da0e93028f6", + "attributes": {} + } + ], + "client": { + "test-realm": [ + { + "id": "17c921b2-1a64-4388-851a-5c6d26a4d132", + "name": "manage-authorization", + "description": "${role_manage-authorization}", + "composite": false, + "clientRole": true, + "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", + "attributes": {} + }, + { + "id": "f0e63981-0dd2-437a-b4a9-ae87237149eb", + "name": "manage-realm", + "description": "${role_manage-realm}", + "composite": false, + "clientRole": true, + "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", + "attributes": {} + }, + { + "id": "b9594598-798e-4d3e-b2c5-db805a51f21d", + "name": "view-identity-providers", + "description": "${role_view-identity-providers}", + "composite": false, + "clientRole": true, + "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", + "attributes": {} + }, + { + "id": "d9dd7bc9-9339-4b3c-9edc-d4deaec9af7d", + "name": "manage-clients", + "description": "${role_manage-clients}", + "composite": false, + "clientRole": true, + "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", + "attributes": {} + }, + { + "id": "ac3cb040-fa5f-40b7-bffa-1c8758734ea1", + "name": "manage-identity-providers", + "description": "${role_manage-identity-providers}", + "composite": false, + "clientRole": true, + "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", + "attributes": {} + }, + { + "id": "63c8a6b7-0369-44c9-a010-6ba08912614c", + "name": "view-authorization", + "description": "${role_view-authorization}", + "composite": false, + "clientRole": true, + "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", + "attributes": {} + }, + { + "id": "6dddf717-4b6b-40d8-a1c4-3a18944f1b46", + "name": "query-users", + "description": "${role_query-users}", + "composite": false, + "clientRole": true, + "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", + "attributes": {} + }, + { + "id": "46647441-7995-4326-9bdb-adf375803df6", + "name": "query-clients", + "description": "${role_query-clients}", + "composite": false, + "clientRole": true, + "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", + "attributes": {} + }, + { + "id": "a16caccb-7f18-4bff-ae14-85a9b55feabf", + "name": "query-groups", + "description": "${role_query-groups}", + "composite": false, + "clientRole": true, + "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", + "attributes": {} + }, + { + "id": "00ed40a2-e1f9-463f-b391-a89d6c0eb4ff", + "name": "query-realms", + "description": "${role_query-realms}", + "composite": false, + "clientRole": true, + "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", + "attributes": {} + }, + { + "id": "6eb0f5ff-2f33-47d0-9cca-5ca9095f86e8", + "name": "view-clients", + "description": "${role_view-clients}", + "composite": true, + "composites": { + "client": { + "test-realm": ["query-clients"] + } + }, + "clientRole": true, + "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", + "attributes": {} + }, + { + "id": "96fa5c5e-b2f1-4011-9856-cd92d336c1bb", + "name": "create-client", + "description": "${role_create-client}", + "composite": false, + "clientRole": true, + "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", + "attributes": {} + }, + { + "id": "64c868b3-fb1a-4701-bd30-b422dcc002fa", + "name": "manage-events", + "description": "${role_manage-events}", + "composite": false, + "clientRole": true, + "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", + "attributes": {} + }, + { + "id": "36ae32c3-1073-4a1d-993e-d8bda8b91449", + "name": "view-events", + "description": "${role_view-events}", + "composite": false, + "clientRole": true, + "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", + "attributes": {} + }, + { + "id": "1c2091a0-02aa-4494-92f2-963033e9e5a6", + "name": "impersonation", + "description": "${role_impersonation}", + "composite": false, + "clientRole": true, + "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", + "attributes": {} + }, + { + "id": "f6242eef-e49a-482c-91da-fd4e671bb0b8", + "name": "manage-users", + "description": "${role_manage-users}", + "composite": false, + "clientRole": true, + "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", + "attributes": {} + }, + { + "id": "08e073ff-5870-4b3e-b52d-bdf8950667a9", + "name": "view-users", + "description": "${role_view-users}", + "composite": true, + "composites": { + "client": { + "test-realm": ["query-users", "query-groups"] + } + }, + "clientRole": true, + "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", + "attributes": {} + }, + { + "id": "cef07a65-fe7f-49ac-a191-830915649dc0", + "name": "view-realm", + "description": "${role_view-realm}", + "composite": false, + "clientRole": true, + "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", + "attributes": {} + } + ], + "security-admin-console": [], + "admin-cli": [], + "account-console": [], + "broker": [ + { + "id": "c3d05038-2267-4442-9da7-9c57bc3ed08c", + "name": "read-token", + "description": "${role_read-token}", + "composite": false, + "clientRole": true, + "containerId": "2a45fa0e-d1c8-4b7a-ba6c-bc268ebcd051", + "attributes": {} + } + ], + "master-realm": [ + { + "id": "bd0f9732-62e6-468a-90f6-7df2007bf2c9", + "name": "manage-authorization", + "description": "${role_manage-authorization}", + "composite": false, + "clientRole": true, + "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", + "attributes": {} + }, + { + "id": "9cd5470d-8502-4aec-b2fc-c2c8d0979ccf", + "name": "query-users", + "description": "${role_query-users}", + "composite": false, + "clientRole": true, + "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", + "attributes": {} + }, + { + "id": "238cb438-6819-4c0b-bb22-b620aef6ff73", + "name": "view-users", + "description": "${role_view-users}", + "composite": true, + "composites": { + "client": { + "master-realm": ["query-users", "query-groups"] + } + }, + "clientRole": true, + "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", + "attributes": {} + }, + { + "id": "65a9a3a9-5bed-4a96-b2c6-bfa34782d9f7", + "name": "create-client", + "description": "${role_create-client}", + "composite": false, + "clientRole": true, + "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", + "attributes": {} + }, + { + "id": "1be37f2a-3734-46f3-a232-fa7d470e9c0e", + "name": "view-clients", + "description": "${role_view-clients}", + "composite": true, + "composites": { + "client": { + "master-realm": ["query-clients"] + } + }, + "clientRole": true, + "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", + "attributes": {} + }, + { + "id": "52dceddd-8dbb-42e0-b5dd-be2ddba299cd", + "name": "manage-users", + "description": "${role_manage-users}", + "composite": false, + "clientRole": true, + "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", + "attributes": {} + }, + { + "id": "111206ae-8ca1-4c73-b877-46e378da2b77", + "name": "manage-realm", + "description": "${role_manage-realm}", + "composite": false, + "clientRole": true, + "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", + "attributes": {} + }, + { + "id": "5e9c9f9a-b5c6-4282-b415-6b6edfa88ac3", + "name": "view-identity-providers", + "description": "${role_view-identity-providers}", + "composite": false, + "clientRole": true, + "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", + "attributes": {} + }, + { + "id": "4c49df4f-9196-447e-a580-fc1afde5b8f9", + "name": "view-realm", + "description": "${role_view-realm}", + "composite": false, + "clientRole": true, + "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", + "attributes": {} + }, + { + "id": "1d3faa5a-20d3-41b1-85db-37b28dcf64a4", + "name": "query-realms", + "description": "${role_query-realms}", + "composite": false, + "clientRole": true, + "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", + "attributes": {} + }, + { + "id": "2ad70757-0a71-4039-94e7-8e34ff9e1631", + "name": "query-clients", + "description": "${role_query-clients}", + "composite": false, + "clientRole": true, + "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", + "attributes": {} + }, + { + "id": "5be6fbcc-5cf7-450e-95ac-02b5b3b5e1b8", + "name": "view-events", + "description": "${role_view-events}", + "composite": false, + "clientRole": true, + "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", + "attributes": {} + }, + { + "id": "e496f3c0-b752-4f9b-8cd5-2d52f0ffd7a1", + "name": "manage-clients", + "description": "${role_manage-clients}", + "composite": false, + "clientRole": true, + "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", + "attributes": {} + }, + { + "id": "64986494-b7ce-471c-83ca-4e80339ca746", + "name": "manage-identity-providers", + "description": "${role_manage-identity-providers}", + "composite": false, + "clientRole": true, + "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", + "attributes": {} + }, + { + "id": "5f04d04a-9b93-4045-9241-f0bebedf3951", + "name": "manage-events", + "description": "${role_manage-events}", + "composite": false, + "clientRole": true, + "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", + "attributes": {} + }, + { + "id": "578a03cd-e1b8-4288-a0c7-aa6cfc093e04", + "name": "view-authorization", + "description": "${role_view-authorization}", + "composite": false, + "clientRole": true, + "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", + "attributes": {} + }, + { + "id": "1d2b50ef-b8a5-44f2-a7bc-abfd44261238", + "name": "impersonation", + "description": "${role_impersonation}", + "composite": false, + "clientRole": true, + "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", + "attributes": {} + }, + { + "id": "ee1c214d-7108-4dfb-8fed-9b75ae574eea", + "name": "query-groups", + "description": "${role_query-groups}", + "composite": false, + "clientRole": true, + "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", + "attributes": {} + } + ], + "account": [ + { + "id": "6754bc7c-cea3-4020-a80e-638b3934a7a2", + "name": "manage-account", + "description": "${role_manage-account}", + "composite": true, + "composites": { + "client": { + "account": ["manage-account-links"] + } + }, + "clientRole": true, + "containerId": "17980fdb-0e2a-4eed-ba5d-32e621651d7e", + "attributes": {} + }, + { + "id": "bf76017b-8207-4973-ade9-0c43b38ba8bb", + "name": "manage-account-links", + "description": "${role_manage-account-links}", + "composite": false, + "clientRole": true, + "containerId": "17980fdb-0e2a-4eed-ba5d-32e621651d7e", + "attributes": {} + }, + { + "id": "c3affb17-990b-4501-947a-dd3faf766e1d", + "name": "view-profile", + "description": "${role_view-profile}", + "composite": false, + "clientRole": true, + "containerId": "17980fdb-0e2a-4eed-ba5d-32e621651d7e", + "attributes": {} + }, + { + "id": "35752cce-d484-4fef-9077-faa31a26f2ce", + "name": "manage-consent", + "description": "${role_manage-consent}", + "composite": true, + "composites": { + "client": { + "account": ["view-consent"] + } + }, + "clientRole": true, + "containerId": "17980fdb-0e2a-4eed-ba5d-32e621651d7e", + "attributes": {} + }, + { + "id": "7a7d8632-6073-4915-bb04-b023aece320e", + "name": "view-consent", + "description": "${role_view-consent}", + "composite": false, + "clientRole": true, + "containerId": "17980fdb-0e2a-4eed-ba5d-32e621651d7e", + "attributes": {} + }, + { + "id": "18c9f83c-9d65-4b41-888a-1115fbbb4d96", + "name": "view-applications", + "description": "${role_view-applications}", + "composite": false, + "clientRole": true, + "containerId": "17980fdb-0e2a-4eed-ba5d-32e621651d7e", + "attributes": {} + }, + { + "id": "1061a7f3-39e5-4efa-80f3-9ff98f3be39c", + "name": "delete-account", + "description": "${role_delete-account}", + "composite": false, + "clientRole": true, + "containerId": "17980fdb-0e2a-4eed-ba5d-32e621651d7e", + "attributes": {} + }, + { + "id": "babd71b0-2c6f-4286-9e57-6ae9741515f7", + "name": "view-groups", + "description": "${role_view-groups}", + "composite": false, + "clientRole": true, + "containerId": "17980fdb-0e2a-4eed-ba5d-32e621651d7e", + "attributes": {} + } + ] + } + }, + "groups": [], + "defaultRole": { + "id": "6ba1b611-b56b-43f1-8ab0-65086b8a1a36", + "name": "default-roles-master", + "description": "${role_default-roles}", + "composite": true, + "clientRole": false, + "containerId": "10202c48-820f-43e1-9c59-4da0e93028f6" + }, + "requiredCredentials": ["password"], + "otpPolicyType": "totp", + "otpPolicyAlgorithm": "HmacSHA1", + "otpPolicyInitialCounter": 0, + "otpPolicyDigits": 6, + "otpPolicyLookAheadWindow": 1, + "otpPolicyPeriod": 30, + "otpPolicyCodeReusable": false, + "otpSupportedApplications": [ + "totpAppFreeOTPName", + "totpAppGoogleName", + "totpAppMicrosoftAuthenticatorName" + ], + "localizationTexts": {}, + "webAuthnPolicyRpEntityName": "keycloak", + "webAuthnPolicySignatureAlgorithms": ["ES256", "RS256"], + "webAuthnPolicyRpId": "", + "webAuthnPolicyAttestationConveyancePreference": "not specified", + "webAuthnPolicyAuthenticatorAttachment": "not specified", + "webAuthnPolicyRequireResidentKey": "not specified", + "webAuthnPolicyUserVerificationRequirement": "not specified", + "webAuthnPolicyCreateTimeout": 0, + "webAuthnPolicyAvoidSameAuthenticatorRegister": false, + "webAuthnPolicyAcceptableAaguids": [], + "webAuthnPolicyExtraOrigins": [], + "webAuthnPolicyPasswordlessRpEntityName": "keycloak", + "webAuthnPolicyPasswordlessSignatureAlgorithms": ["ES256", "RS256"], + "webAuthnPolicyPasswordlessRpId": "", + "webAuthnPolicyPasswordlessAttestationConveyancePreference": "not specified", + "webAuthnPolicyPasswordlessAuthenticatorAttachment": "not specified", + "webAuthnPolicyPasswordlessRequireResidentKey": "not specified", + "webAuthnPolicyPasswordlessUserVerificationRequirement": "not specified", + "webAuthnPolicyPasswordlessCreateTimeout": 0, + "webAuthnPolicyPasswordlessAvoidSameAuthenticatorRegister": false, + "webAuthnPolicyPasswordlessAcceptableAaguids": [], + "webAuthnPolicyPasswordlessExtraOrigins": [], + "users": [ + { + "id": "75f5ae44-997a-4606-b3c6-edc27a2f7787", + "username": "admin", + "emailVerified": false, + "attributes": { + "is_temporary_admin": ["true"] + }, + "createdTimestamp": 1744804739968, + "enabled": true, + "totp": false, + "credentials": [ + { + "id": "1d248d21-9add-4ad8-8a7f-ff375c45ae2f", + "type": "password", + "createdDate": 1744804740051, + "secretData": "{\"value\":\"JtpjzkDeGtTuQ/cVHmYr8QtQfrwo5mP0GmZQyDhdlMs=\",\"salt\":\"lJtTvGs3GKcXgIcKnyJdlw==\",\"additionalParameters\":{}}", + "credentialData": "{\"hashIterations\":5,\"algorithm\":\"argon2\",\"additionalParameters\":{\"hashLength\":[\"32\"],\"memory\":[\"7168\"],\"type\":[\"id\"],\"version\":[\"1.3\"],\"parallelism\":[\"1\"]}}" + } + ], + "disableableCredentialTypes": [], + "requiredActions": [], + "realmRoles": ["admin", "default-roles-master"], + "notBefore": 0, + "groups": [] + } + ], + "scopeMappings": [ + { + "clientScope": "offline_access", + "roles": ["offline_access"] + } + ], + "clientScopeMappings": { + "account": [ + { + "client": "account-console", + "roles": ["manage-account", "view-groups"] + } + ] + }, + "clients": [ + { + "id": "17980fdb-0e2a-4eed-ba5d-32e621651d7e", + "clientId": "account", + "name": "${client_account}", + "rootUrl": "${authBaseUrl}", + "baseUrl": "/realms/master/account/", + "surrogateAuthRequired": false, + "enabled": true, + "alwaysDisplayInConsole": false, + "clientAuthenticatorType": "client-secret", + "redirectUris": ["/realms/master/account/*"], + "webOrigins": [], + "notBefore": 0, + "bearerOnly": false, + "consentRequired": false, + "standardFlowEnabled": true, + "implicitFlowEnabled": false, + "directAccessGrantsEnabled": false, + "serviceAccountsEnabled": false, + "publicClient": true, + "frontchannelLogout": false, + "protocol": "openid-connect", + "attributes": { + "realm_client": "false", + "post.logout.redirect.uris": "+" + }, + "authenticationFlowBindingOverrides": {}, + "fullScopeAllowed": false, + "nodeReRegistrationTimeout": 0, + "defaultClientScopes": [ + "web-origins", + "acr", + "profile", + "roles", + "basic", + "email" + ], + "optionalClientScopes": [ + "address", + "phone", + "organization", + "offline_access", + "microprofile-jwt" + ] + }, + { + "id": "30dd42d3-55a3-47c8-b3c3-5fa22567d360", + "clientId": "account-console", + "name": "${client_account-console}", + "rootUrl": "${authBaseUrl}", + "baseUrl": "/realms/master/account/", + "surrogateAuthRequired": false, + "enabled": true, + "alwaysDisplayInConsole": false, + "clientAuthenticatorType": "client-secret", + "redirectUris": ["/realms/master/account/*"], + "webOrigins": [], + "notBefore": 0, + "bearerOnly": false, + "consentRequired": false, + "standardFlowEnabled": true, + "implicitFlowEnabled": false, + "directAccessGrantsEnabled": false, + "serviceAccountsEnabled": false, + "publicClient": true, + "frontchannelLogout": false, + "protocol": "openid-connect", + "attributes": { + "realm_client": "false", + "post.logout.redirect.uris": "+", + "pkce.code.challenge.method": "S256" + }, + "authenticationFlowBindingOverrides": {}, + "fullScopeAllowed": false, + "nodeReRegistrationTimeout": 0, + "protocolMappers": [ + { + "id": "cce21460-bc9a-4ed7-9b67-49861a5fd50d", + "name": "audience resolve", + "protocol": "openid-connect", + "protocolMapper": "oidc-audience-resolve-mapper", + "consentRequired": false, + "config": {} + } + ], + "defaultClientScopes": [ + "web-origins", + "acr", + "profile", + "roles", + "basic", + "email" + ], + "optionalClientScopes": [ + "address", + "phone", + "organization", + "offline_access", + "microprofile-jwt" + ] + }, + { + "id": "7b717c60-fd62-46ae-b69a-028b2feca00d", + "clientId": "admin-cli", + "name": "${client_admin-cli}", + "surrogateAuthRequired": false, + "enabled": true, + "alwaysDisplayInConsole": false, + "clientAuthenticatorType": "client-secret", + "redirectUris": [], + "webOrigins": [], + "notBefore": 0, + "bearerOnly": false, + "consentRequired": false, + "standardFlowEnabled": false, + "implicitFlowEnabled": false, + "directAccessGrantsEnabled": true, + "serviceAccountsEnabled": false, + "publicClient": true, + "frontchannelLogout": false, + "protocol": "openid-connect", + "attributes": { + "realm_client": "false", + "client.use.lightweight.access.token.enabled": "true" + }, + "authenticationFlowBindingOverrides": {}, + "fullScopeAllowed": true, + "nodeReRegistrationTimeout": 0, + "defaultClientScopes": [ + "web-origins", + "acr", + "profile", + "roles", + "basic", + "email" + ], + "optionalClientScopes": [ + "address", + "phone", + "organization", + "offline_access", + "microprofile-jwt" + ] + }, + { + "id": "2a45fa0e-d1c8-4b7a-ba6c-bc268ebcd051", + "clientId": "broker", + "name": "${client_broker}", + "surrogateAuthRequired": false, + "enabled": true, + "alwaysDisplayInConsole": false, + "clientAuthenticatorType": "client-secret", + "redirectUris": [], + "webOrigins": [], + "notBefore": 0, + "bearerOnly": true, + "consentRequired": false, + "standardFlowEnabled": true, + "implicitFlowEnabled": false, + "directAccessGrantsEnabled": false, + "serviceAccountsEnabled": false, + "publicClient": false, + "frontchannelLogout": false, + "protocol": "openid-connect", + "attributes": { + "realm_client": "true" + }, + "authenticationFlowBindingOverrides": {}, + "fullScopeAllowed": false, + "nodeReRegistrationTimeout": 0, + "defaultClientScopes": [ + "web-origins", + "acr", + "profile", + "roles", + "basic", + "email" + ], + "optionalClientScopes": [ + "address", + "phone", + "organization", + "offline_access", + "microprofile-jwt" + ] + }, + { + "id": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", + "clientId": "master-realm", + "name": "master Realm", + "surrogateAuthRequired": false, + "enabled": true, + "alwaysDisplayInConsole": false, + "clientAuthenticatorType": "client-secret", + "redirectUris": [], + "webOrigins": [], + "notBefore": 0, + "bearerOnly": true, + "consentRequired": false, + "standardFlowEnabled": true, + "implicitFlowEnabled": false, + "directAccessGrantsEnabled": false, + "serviceAccountsEnabled": false, + "publicClient": false, + "frontchannelLogout": false, + "attributes": { + "realm_client": "true" + }, + "authenticationFlowBindingOverrides": {}, + "fullScopeAllowed": false, + "nodeReRegistrationTimeout": 0, + "defaultClientScopes": [ + "web-origins", + "acr", + "profile", + "roles", + "basic", + "email" + ], + "optionalClientScopes": [ + "address", + "phone", + "organization", + "offline_access", + "microprofile-jwt" + ] + }, + { + "id": "59c2a59f-bbfe-414b-8d01-c507882da73c", + "clientId": "security-admin-console", + "name": "${client_security-admin-console}", + "rootUrl": "${authAdminUrl}", + "baseUrl": "/admin/master/console/", + "surrogateAuthRequired": false, + "enabled": true, + "alwaysDisplayInConsole": false, + "clientAuthenticatorType": "client-secret", + "redirectUris": ["/admin/master/console/*"], + "webOrigins": ["+"], + "notBefore": 0, + "bearerOnly": false, + "consentRequired": false, + "standardFlowEnabled": true, + "implicitFlowEnabled": false, + "directAccessGrantsEnabled": false, + "serviceAccountsEnabled": false, + "publicClient": true, + "frontchannelLogout": false, + "protocol": "openid-connect", + "attributes": { + "realm_client": "false", + "client.use.lightweight.access.token.enabled": "true", + "post.logout.redirect.uris": "+", + "pkce.code.challenge.method": "S256" + }, + "authenticationFlowBindingOverrides": {}, + "fullScopeAllowed": true, + "nodeReRegistrationTimeout": 0, + "protocolMappers": [ + { + "id": "0a6040d0-3720-4f04-a44d-7109206cb1b6", + "name": "locale", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "userinfo.token.claim": "true", + "user.attribute": "locale", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "locale", + "jsonType.label": "String" + } + } + ], + "defaultClientScopes": [ + "web-origins", + "acr", + "profile", + "roles", + "basic", + "email" + ], + "optionalClientScopes": [ + "address", + "phone", + "organization", + "offline_access", + "microprofile-jwt" + ] + }, + { + "id": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", + "clientId": "test-realm", + "name": "test Realm", + "surrogateAuthRequired": false, + "enabled": true, + "alwaysDisplayInConsole": false, + "clientAuthenticatorType": "client-secret", + "redirectUris": [], + "webOrigins": [], + "notBefore": 0, + "bearerOnly": true, + "consentRequired": false, + "standardFlowEnabled": true, + "implicitFlowEnabled": false, + "directAccessGrantsEnabled": false, + "serviceAccountsEnabled": false, + "publicClient": false, + "frontchannelLogout": false, + "attributes": { + "realm_client": "true" + }, + "authenticationFlowBindingOverrides": {}, + "fullScopeAllowed": false, + "nodeReRegistrationTimeout": 0, + "defaultClientScopes": [], + "optionalClientScopes": [] + } + ], + "clientScopes": [ + { + "id": "204cb677-238a-4da3-a823-f91759e7f9df", + "name": "web-origins", + "description": "OpenID Connect scope for add allowed web origins to the access token", + "protocol": "openid-connect", + "attributes": { + "include.in.token.scope": "false", + "consent.screen.text": "", + "display.on.consent.screen": "false" + }, + "protocolMappers": [ + { + "id": "c5d738cf-af5b-483e-9c6a-4deb4b28af3f", + "name": "allowed web origins", + "protocol": "openid-connect", + "protocolMapper": "oidc-allowed-origins-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "access.token.claim": "true" + } + } + ] + }, + { + "id": "6958bf2c-f31a-429b-b16c-3ed592d96e39", + "name": "organization", + "description": "Additional claims about the organization a subject belongs to", + "protocol": "openid-connect", + "attributes": { + "include.in.token.scope": "true", + "consent.screen.text": "${organizationScopeConsentText}", + "display.on.consent.screen": "true" + }, + "protocolMappers": [ + { + "id": "588144fa-ca22-4f87-9d48-d74c9ab7cce4", + "name": "organization", + "protocol": "openid-connect", + "protocolMapper": "oidc-organization-membership-mapper", + "consentRequired": false, + "config": { + "id.token.claim": "true", + "introspection.token.claim": "true", + "access.token.claim": "true", + "claim.name": "organization", + "jsonType.label": "String", + "multivalued": "true" + } + } + ] + }, + { + "id": "229df93f-214d-4845-a960-d96d836f27ed", + "name": "roles", + "description": "OpenID Connect scope for add user roles to the access token", + "protocol": "openid-connect", + "attributes": { + "include.in.token.scope": "false", + "consent.screen.text": "${rolesScopeConsentText}", + "display.on.consent.screen": "true" + }, + "protocolMappers": [ + { + "id": "ac7f28bd-43e0-47b7-ae4f-55af9a225ab4", + "name": "realm roles", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-realm-role-mapper", + "consentRequired": false, + "config": { + "user.attribute": "foo", + "introspection.token.claim": "true", + "access.token.claim": "true", + "claim.name": "realm_access.roles", + "jsonType.label": "String", + "multivalued": "true" + } + }, + { + "id": "7c60ef9d-4bcb-48fd-8418-84c65196c51e", + "name": "client roles", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-client-role-mapper", + "consentRequired": false, + "config": { + "user.attribute": "foo", + "introspection.token.claim": "true", + "access.token.claim": "true", + "claim.name": "resource_access.${client_id}.roles", + "jsonType.label": "String", + "multivalued": "true" + } + }, + { + "id": "099b0944-177f-44af-a6d2-c927d5eb9c9c", + "name": "audience resolve", + "protocol": "openid-connect", + "protocolMapper": "oidc-audience-resolve-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "access.token.claim": "true" + } + } + ] + }, + { + "id": "39f1ebfb-3912-4b66-a75c-3648bec0e37f", + "name": "basic", + "description": "OpenID Connect scope for add all basic claims to the token", + "protocol": "openid-connect", + "attributes": { + "include.in.token.scope": "false", + "display.on.consent.screen": "false" + }, + "protocolMappers": [ + { + "id": "11f60cd5-f906-4dad-83d2-be4eb22b3708", + "name": "sub", + "protocol": "openid-connect", + "protocolMapper": "oidc-sub-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "access.token.claim": "true" + } + }, + { + "id": "cd97a289-7cb9-4263-bc80-b28675a09d2c", + "name": "auth_time", + "protocol": "openid-connect", + "protocolMapper": "oidc-usersessionmodel-note-mapper", + "consentRequired": false, + "config": { + "user.session.note": "AUTH_TIME", + "id.token.claim": "true", + "introspection.token.claim": "true", + "access.token.claim": "true", + "claim.name": "auth_time", + "jsonType.label": "long" + } + } + ] + }, + { + "id": "44193e7b-b4f0-4545-bc1f-d113b1f689a2", + "name": "microprofile-jwt", + "description": "Microprofile - JWT built-in scope", + "protocol": "openid-connect", + "attributes": { + "include.in.token.scope": "true", + "display.on.consent.screen": "false" + }, + "protocolMappers": [ + { + "id": "33f84fa8-16a2-43af-ab1c-22287d86f4e1", + "name": "groups", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-realm-role-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "multivalued": "true", + "user.attribute": "foo", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "groups", + "jsonType.label": "String" + } + }, + { + "id": "0645a1f6-c545-43c5-91a8-67b451512486", + "name": "upn", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "userinfo.token.claim": "true", + "user.attribute": "username", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "upn", + "jsonType.label": "String" + } + } + ] + }, + { + "id": "500e314e-40c0-40f7-ad0c-004bb37ab8c0", + "name": "email", + "description": "OpenID Connect built-in scope: email", + "protocol": "openid-connect", + "attributes": { + "include.in.token.scope": "true", + "consent.screen.text": "${emailScopeConsentText}", + "display.on.consent.screen": "true" + }, + "protocolMappers": [ + { + "id": "b5b20994-930e-48ce-8382-5c5bfda58054", + "name": "email verified", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-property-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "userinfo.token.claim": "true", + "user.attribute": "emailVerified", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "email_verified", + "jsonType.label": "boolean" + } + }, + { + "id": "f1cbee3a-8b36-4d92-bb5a-d2f0741e2acd", + "name": "email", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "userinfo.token.claim": "true", + "user.attribute": "email", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "email", + "jsonType.label": "String" + } + } + ] + }, + { + "id": "8e9ee770-d4c7-49f9-b3e1-8b8839494249", + "name": "phone", + "description": "OpenID Connect built-in scope: phone", + "protocol": "openid-connect", + "attributes": { + "include.in.token.scope": "true", + "consent.screen.text": "${phoneScopeConsentText}", + "display.on.consent.screen": "true" + }, + "protocolMappers": [ + { + "id": "d2fbecc4-05cd-46d1-8c2d-76719b76675d", + "name": "phone number", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "userinfo.token.claim": "true", + "user.attribute": "phoneNumber", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "phone_number", + "jsonType.label": "String" + } + }, + { + "id": "3fe410b9-0d63-42c5-a044-02cd7ce27b8f", + "name": "phone number verified", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "userinfo.token.claim": "true", + "user.attribute": "phoneNumberVerified", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "phone_number_verified", + "jsonType.label": "boolean" + } + } + ] + }, + { + "id": "7f5c5b83-f705-4ec1-a8ea-03d991d893b9", + "name": "role_list", + "description": "SAML role list", + "protocol": "saml", + "attributes": { + "consent.screen.text": "${samlRoleListScopeConsentText}", + "display.on.consent.screen": "true" + }, + "protocolMappers": [ + { + "id": "98f97dec-2935-43f3-a87c-190154baf50e", + "name": "role list", + "protocol": "saml", + "protocolMapper": "saml-role-list-mapper", + "consentRequired": false, + "config": { + "single": "false", + "attribute.nameformat": "Basic", + "attribute.name": "Role" + } + } + ] + }, + { + "id": "87cadeba-210e-44d1-b788-8d044b389727", + "name": "address", + "description": "OpenID Connect built-in scope: address", + "protocol": "openid-connect", + "attributes": { + "include.in.token.scope": "true", + "consent.screen.text": "${addressScopeConsentText}", + "display.on.consent.screen": "true" + }, + "protocolMappers": [ + { + "id": "e561fbce-d658-4953-915a-8786f86b4da7", + "name": "address", + "protocol": "openid-connect", + "protocolMapper": "oidc-address-mapper", + "consentRequired": false, + "config": { + "user.attribute.formatted": "formatted", + "user.attribute.country": "country", + "introspection.token.claim": "true", + "user.attribute.postal_code": "postal_code", + "userinfo.token.claim": "true", + "user.attribute.street": "street", + "id.token.claim": "true", + "user.attribute.region": "region", + "access.token.claim": "true", + "user.attribute.locality": "locality" + } + } + ] + }, + { + "id": "0e17f3d3-c95d-4bfa-8905-fc2c46744796", + "name": "acr", + "description": "OpenID Connect scope for add acr (authentication context class reference) to the token", + "protocol": "openid-connect", + "attributes": { + "include.in.token.scope": "false", + "display.on.consent.screen": "false" + }, + "protocolMappers": [ + { + "id": "c9eb53cd-a36b-4090-aae5-35c56e92f140", + "name": "acr loa level", + "protocol": "openid-connect", + "protocolMapper": "oidc-acr-mapper", + "consentRequired": false, + "config": { + "id.token.claim": "true", + "introspection.token.claim": "true", + "access.token.claim": "true" + } + } + ] + }, + { + "id": "d1734bba-a423-4768-9037-973635f4d64e", + "name": "offline_access", + "description": "OpenID Connect built-in scope: offline_access", + "protocol": "openid-connect", + "attributes": { + "consent.screen.text": "${offlineAccessScopeConsentText}", + "display.on.consent.screen": "true" + } + }, + { + "id": "891ab605-54d0-4b71-b55e-d13e9138a8cc", + "name": "profile", + "description": "OpenID Connect built-in scope: profile", + "protocol": "openid-connect", + "attributes": { + "include.in.token.scope": "true", + "consent.screen.text": "${profileScopeConsentText}", + "display.on.consent.screen": "true" + }, + "protocolMappers": [ + { + "id": "78f4a125-2730-47a5-a429-62f37965f391", + "name": "nickname", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "userinfo.token.claim": "true", + "user.attribute": "nickname", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "nickname", + "jsonType.label": "String" + } + }, + { + "id": "8dd88372-60ac-45b5-aa3f-a7359bfe4721", + "name": "zoneinfo", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "userinfo.token.claim": "true", + "user.attribute": "zoneinfo", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "zoneinfo", + "jsonType.label": "String" + } + }, + { + "id": "f980949c-3187-43d5-914a-41ed3df28603", + "name": "username", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "userinfo.token.claim": "true", + "user.attribute": "username", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "preferred_username", + "jsonType.label": "String" + } + }, + { + "id": "86f666f4-b84f-4f90-b4da-466fc71131a7", + "name": "profile", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "userinfo.token.claim": "true", + "user.attribute": "profile", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "profile", + "jsonType.label": "String" + } + }, + { + "id": "551eb2e7-de26-424c-83fe-a0df535dc3a3", + "name": "website", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "userinfo.token.claim": "true", + "user.attribute": "website", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "website", + "jsonType.label": "String" + } + }, + { + "id": "708067ad-2112-43be-bb97-874cc2d3f6e5", + "name": "family name", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "userinfo.token.claim": "true", + "user.attribute": "lastName", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "family_name", + "jsonType.label": "String" + } + }, + { + "id": "bf9a553a-5688-4205-be3c-f39ab7c0ef44", + "name": "gender", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "userinfo.token.claim": "true", + "user.attribute": "gender", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "gender", + "jsonType.label": "String" + } + }, + { + "id": "6e65b3f2-4fb5-4a5e-bcb5-29d03422c14c", + "name": "given name", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "userinfo.token.claim": "true", + "user.attribute": "firstName", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "given_name", + "jsonType.label": "String" + } + }, + { + "id": "709afabd-6e20-46a2-91f1-eb37bf43a81e", + "name": "locale", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "userinfo.token.claim": "true", + "user.attribute": "locale", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "locale", + "jsonType.label": "String" + } + }, + { + "id": "2cef61ef-cb7e-43e7-b501-b57f060fb99e", + "name": "birthdate", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "userinfo.token.claim": "true", + "user.attribute": "birthdate", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "birthdate", + "jsonType.label": "String" + } + }, + { + "id": "24e00bfb-c1a3-4efb-ab16-62db6b00ab0f", + "name": "picture", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "userinfo.token.claim": "true", + "user.attribute": "picture", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "picture", + "jsonType.label": "String" + } + }, + { + "id": "599645cb-dc46-4c52-b366-5b0d21498aff", + "name": "full name", + "protocol": "openid-connect", + "protocolMapper": "oidc-full-name-mapper", + "consentRequired": false, + "config": { + "id.token.claim": "true", + "introspection.token.claim": "true", + "access.token.claim": "true", + "userinfo.token.claim": "true" + } + }, + { + "id": "c37dfd9e-9d03-4eb0-a531-8469e05002c5", + "name": "middle name", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "userinfo.token.claim": "true", + "user.attribute": "middleName", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "middle_name", + "jsonType.label": "String" + } + }, + { + "id": "3c9fd938-d90c-482b-8a3e-a2493c534981", + "name": "updated at", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "introspection.token.claim": "true", + "userinfo.token.claim": "true", + "user.attribute": "updatedAt", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "updated_at", + "jsonType.label": "long" + } + } + ] + }, + { + "id": "95f8cba8-d15d-4b95-acbc-7a89b40c329d", + "name": "saml_organization", + "description": "Organization Membership", + "protocol": "saml", + "attributes": { + "display.on.consent.screen": "false" + }, + "protocolMappers": [ + { + "id": "c6058070-af3e-4afd-9588-b79ea3085383", + "name": "organization", + "protocol": "saml", + "protocolMapper": "saml-organization-membership-mapper", + "consentRequired": false, + "config": {} + } + ] + } + ], + "defaultDefaultClientScopes": [ + "role_list", + "saml_organization", + "profile", + "email", + "roles", + "web-origins", + "acr", + "basic" + ], + "defaultOptionalClientScopes": [ + "offline_access", + "address", + "phone", + "microprofile-jwt", + "organization" + ], + "browserSecurityHeaders": { + "contentSecurityPolicyReportOnly": "", + "xContentTypeOptions": "nosniff", + "referrerPolicy": "no-referrer", + "xRobotsTag": "none", + "xFrameOptions": "SAMEORIGIN", + "contentSecurityPolicy": "frame-src 'self'; frame-ancestors 'self'; object-src 'none';", + "xXSSProtection": "1; mode=block", + "strictTransportSecurity": "max-age=31536000; includeSubDomains" + }, + "smtpServer": {}, + "eventsEnabled": false, + "eventsListeners": ["jboss-logging"], + "enabledEventTypes": [], + "adminEventsEnabled": false, + "adminEventsDetailsEnabled": false, + "identityProviders": [], + "identityProviderMappers": [], + "components": { + "org.keycloak.services.clientregistration.policy.ClientRegistrationPolicy": [ + { + "id": "eaaedd6a-cd62-4c3c-8e84-46349a6184d0", + "name": "Allowed Protocol Mapper Types", + "providerId": "allowed-protocol-mappers", + "subType": "anonymous", + "subComponents": {}, + "config": { + "allowed-protocol-mapper-types": [ + "saml-role-list-mapper", + "oidc-usermodel-attribute-mapper", + "saml-user-attribute-mapper", + "oidc-usermodel-property-mapper", + "oidc-full-name-mapper", + "oidc-sha256-pairwise-sub-mapper", + "saml-user-property-mapper", + "oidc-address-mapper" + ] + } + }, + { + "id": "9c00e8fc-20c6-4a1b-a800-55b6e859f365", + "name": "Allowed Client Scopes", + "providerId": "allowed-client-templates", + "subType": "anonymous", + "subComponents": {}, + "config": { + "allow-default-scopes": ["true"] + } + }, + { + "id": "2e694fd5-601c-4c0c-9d87-be9b0489c2c2", + "name": "Trusted Hosts", + "providerId": "trusted-hosts", + "subType": "anonymous", + "subComponents": {}, + "config": { + "host-sending-registration-request-must-match": ["true"], + "client-uris-must-match": ["true"] + } + }, + { + "id": "6ea1b304-94ae-4655-bc91-a46754ff3d26", + "name": "Allowed Client Scopes", + "providerId": "allowed-client-templates", + "subType": "authenticated", + "subComponents": {}, + "config": { + "allow-default-scopes": ["true"] + } + }, + { + "id": "e79c8888-128e-4876-9ebe-2856a1d042c2", + "name": "Consent Required", + "providerId": "consent-required", + "subType": "anonymous", + "subComponents": {}, + "config": {} + }, + { + "id": "584f41cb-39e6-42b2-af41-15a515268360", + "name": "Max Clients Limit", + "providerId": "max-clients", + "subType": "anonymous", + "subComponents": {}, + "config": { + "max-clients": ["200"] + } + }, + { + "id": "c6b0070e-d511-4005-9b42-dd175173fd89", + "name": "Full Scope Disabled", + "providerId": "scope", + "subType": "anonymous", + "subComponents": {}, + "config": {} + }, + { + "id": "56d7d42f-e443-4080-a644-fd523b3f34a5", + "name": "Allowed Protocol Mapper Types", + "providerId": "allowed-protocol-mappers", + "subType": "authenticated", + "subComponents": {}, + "config": { + "allowed-protocol-mapper-types": [ + "saml-role-list-mapper", + "oidc-address-mapper", + "oidc-full-name-mapper", + "oidc-sha256-pairwise-sub-mapper", + "oidc-usermodel-attribute-mapper", + "oidc-usermodel-property-mapper", + "saml-user-attribute-mapper", + "saml-user-property-mapper" + ] + } + } + ], + "org.keycloak.userprofile.UserProfileProvider": [ + { + "id": "174c56e9-46c0-4b2d-9507-5a5fc7b74929", + "providerId": "declarative-user-profile", + "subComponents": {}, + "config": { + "kc.user.profile.config": [ + "{\"attributes\":[{\"name\":\"username\",\"displayName\":\"${username}\",\"validations\":{\"length\":{\"min\":3,\"max\":255},\"username-prohibited-characters\":{},\"up-username-not-idn-homograph\":{}},\"permissions\":{\"view\":[\"admin\",\"user\"],\"edit\":[\"admin\",\"user\"]},\"multivalued\":false},{\"name\":\"email\",\"displayName\":\"${email}\",\"validations\":{\"email\":{},\"length\":{\"max\":255}},\"permissions\":{\"view\":[\"admin\",\"user\"],\"edit\":[\"admin\",\"user\"]},\"multivalued\":false},{\"name\":\"firstName\",\"displayName\":\"${firstName}\",\"validations\":{\"length\":{\"max\":255},\"person-name-prohibited-characters\":{}},\"permissions\":{\"view\":[\"admin\",\"user\"],\"edit\":[\"admin\",\"user\"]},\"multivalued\":false},{\"name\":\"lastName\",\"displayName\":\"${lastName}\",\"validations\":{\"length\":{\"max\":255},\"person-name-prohibited-characters\":{}},\"permissions\":{\"view\":[\"admin\",\"user\"],\"edit\":[\"admin\",\"user\"]},\"multivalued\":false}],\"groups\":[{\"name\":\"user-metadata\",\"displayHeader\":\"User metadata\",\"displayDescription\":\"Attributes, which refer to user metadata\"}]}" + ] + } + } + ], + "org.keycloak.keys.KeyProvider": [ + { + "id": "47bb7102-e487-4cc9-8154-515f20181108", + "name": "rsa-generated", + "providerId": "rsa-generated", + "subComponents": {}, + "config": { + "privateKey": [ + "MIIEpAIBAAKCAQEAtIenRRUFCtCyVHne6Ser5NiuRBLzZNvm64BWErtHfutq6+t5MjY2mnE8GdUfbX1/9k7tx+st3y1AeVgqCFsOKqGOk2Ikl+p5T2qLjYHAo86mTbGVoc5uC6GFwDmJV3Mq2vrVwdA1cvCWOR0he3Z3lOek3ZpRg66mIdAthNOmwn1vxjBXRkKEFzRIZK2GYnrwAMApaSCFqF8YYaW9mW2/Nt9ytNslC98yWFIe0dVLmgeD0K12pnnAoT19Quu0Oj9exofLUGTdRm8GKIPta9WGsRuRgE1/oiXoqb0nVpaDMBqz5cgs6TSdgr39v76cfakHSl8ozv5eeyjM6TYg3aE2kQIDAQABAoIBAA3IY41jJvDl8Q+BBHNBi56bqmZZGgsDvPQS5r9kW/eFKrMbVbPvLqkI5yFDw7P8xmW8Lew6+NQWpNr+z6q2pPS9Q+Ddt9R/Wsak6EWj99ypvMmmurlRRNaPfOIpomIyUT3Js8MpzcLaOmXe4v0FlOih7NTcYMfQcC+ZsLf43rzvbILAT/JLXb0r8rnBV2y81ao4U/zE912vv/jaNh8QgTiPkxhyN3F6qLYD1eylxUa3pTcb4sa4YDCjsrIik8b2iE62stuQ48rBKiYuWoZi4foPCxWDyeNfNPWRrifH2eFMGho+BYzyhSRX042UJJ6iZeIWIHEJGy/oWE7JE83OPT8CgYEA+h1zk/6HoDAv32CRI52r4w/N0i8V2GeC5/nUr4dW8oI8VSkqMWktFn/ZxC2tU93avxj8WgMA7xC/LbZ/lEIiphq0vcsSKTJd/UWugirbtXN76LSvYzoCeTWvwO2wS/YShDmzdapvsqYUa+oaVqZmbavLJlBl0Cz8ytcvDiFeQtcCgYEAuMcPqg0AzezqyD9urJg7RI3Kcpg2NeezWhlfXpbG5GQqlxXK//tOjyKaymkGo12tuzAgjaeiUT5uiPaZgxJ4s2OA57JpYF3L3ZvrguesabaGC1w20MCYr83C+GIYF7Ozikq8FZ5+aJrd6ns5e6bBb2joC6UEjVUg64ai/dCzDNcCgYEA45RIxjCjV66A4NANQEsHS+Plc4pEZlRJWKqKS+zpwF+gZhy+t5br370VeNvXCqijkZ46f+ybvOuQCRg1ncFPpbRHISrVq4aY3wu4bdhxcflSlbtSmwb9mSywbuvXrkaJMqcOE9KxL+zOSCMLNCzUppXak1I0UeedXTPPLRxPmKECgYEAnqLADwWU4DZ7pynWUbVshMGawmFtgUAIGd1YpHOcE+7vJcEfBD/0RSy3aflbKpw9kEyUVilKUKfh7BKS3xXXrGNMAx+IGqTMZtj7C+rseeGrGUu0/+mp7J0hu280Mf0ksiDRc1ocOqBiz3G1ezRCM+0D8yNcUh544dw4SOKJJgcCgYAQlnSOqosWVuVV7NPuqs9Twcm7Tm+/CjKeIr3FJE9zXzyBJ1UI+UV9i8356WWcTVCMOQEQ4mR+idmxalE5czctIie73ty2gxnSA5Iafpy0nn6qaEArtVbArBg350yueqng2RO60YyjNU0coyfh9dAfXkj5Az+V+wflX/2UZ4JJdw==" + ], + "keyUse": ["SIG"], + "certificate": [ + "MIICmzCCAYMCBgGWPnd60TANBgkqhkiG9w0BAQsFADARMQ8wDQYDVQQDDAZtYXN0ZXIwHhcNMjUwNDE2MTE1NzE5WhcNMzUwNDE2MTE1ODU5WjARMQ8wDQYDVQQDDAZtYXN0ZXIwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQC0h6dFFQUK0LJUed7pJ6vk2K5EEvNk2+brgFYSu0d+62rr63kyNjaacTwZ1R9tfX/2Tu3H6y3fLUB5WCoIWw4qoY6TYiSX6nlPaouNgcCjzqZNsZWhzm4LoYXAOYlXcyra+tXB0DVy8JY5HSF7dneU56TdmlGDrqYh0C2E06bCfW/GMFdGQoQXNEhkrYZievAAwClpIIWoXxhhpb2Zbb8233K02yUL3zJYUh7R1UuaB4PQrXamecChPX1C67Q6P17Gh8tQZN1GbwYog+1r1YaxG5GATX+iJeipvSdWloMwGrPlyCzpNJ2Cvf2/vpx9qQdKXyjO/l57KMzpNiDdoTaRAgMBAAEwDQYJKoZIhvcNAQELBQADggEBAI5nKcSg1AfgXRkubow1O4yPX1tJ5GaOyPTz4uIuadbtfMk0p6Q8LSdMHjtprJ3pAQjMaIxQBWpuedrBYf3XRyYvapmt6xnLO2RkGB2yxYYCpIf9/ovB+stmkKsWKxP+GA38HDsvw8pqHMVMPJvqaKnNk5r1u7ic/awNWqCAA2zFxtT2aRZCx15jE7fBc7uRbe1iLumJNQPZ3EPYaXYgeu+dFWpNSvwuPYRGc1Bm7VFHrSqk1jFr63llMAiyJujMJBdB3JJGws2zgBnQBVTp1eRrv6NkOiZT/WVRCkY263poC7aEbJFI3WcUkvKcPnHSNOfPbZkkI0ND3IeLUKK+dMg=" + ], + "priority": ["100"] + } + }, + { + "id": "bc5eb611-7d39-48d0-b08c-4f24fdfbc397", + "name": "hmac-generated-hs512", + "providerId": "hmac-generated", + "subComponents": {}, + "config": { + "kid": ["96709a88-f5c7-4869-9b75-ee92423e0a42"], + "secret": [ + "gh2Ge2AEf4e6u-ezQBqn1K-wgfSR4daGjRrMw0TQUSWccZ5piq6-AB4SqMXU9a4vdcEju7JSP-heOTlLsqdVNOgPbu0qiLdS-_tntcn8nZ7w8Pk-iOxgfbpq94RrU8StJMNR7WQfOlOeU5DwfjsbpgrErn5Oi3R3m37RZK48IAU" + ], + "priority": ["100"], + "algorithm": ["HS512"] + } + }, + { + "id": "dc3e105b-1ef5-4e46-bd2d-0614fa51ecc4", + "name": "aes-generated", + "providerId": "aes-generated", + "subComponents": {}, + "config": { + "kid": ["72aff008-5d1d-4271-9399-ca83b88c0b82"], + "secret": ["ekNo8k_fi2O0MjYMBW1Fxw"], + "priority": ["100"] + } + }, + { + "id": "5da54863-69d2-473d-9a8d-4a1f20fc87ef", + "name": "rsa-enc-generated", + "providerId": "rsa-enc-generated", + "subComponents": {}, + "config": { + "privateKey": [ + "MIIEpAIBAAKCAQEAsuAaMlm0k0Sx5948Kyxxvskqw3bLCUoqJ47zFzmRaXiDwR4t2bQe8eU6a7Xp3woQ4kg6gwXAwVHh0un3dab5QBomwf/gWyWJFTOAot/JE2QIX6FTtgBdr6y/XWgt32jw01EaDLMq2UT28u3ARGZ1OlXUM6k/wSgPRF26d4E+ZH+SiHBJWXe6DaUU6TLCNrk3L8GumwcVgh/93ffm/7xpb2XLt9v4Sh/GZ1enwDnnYiHZxJnTr4mbK1ZJSScNGRxlEKjo+zq1IS74hCLML3nBD1VeAf2L+i1ANIL69gK8+/tYnSnAF2hfeQN8xEu7/SiJmrip7s/nLc0+ATWNrPNtjwIDAQABAoIBAAii9DxHQ2GXyPBcNSU4gGso7jiBPUPRRlKiESanWTNxnL+B/4VOi6WpukgYgLseJQRDXs2UIKxrtkECvu6MKi+MuEQPYLKhWQp934hrYtJLbd+AKbkd52gal20O2BOX84Z74fk/AMd8NKp9exYtzWTn8bIeAQbj6R+noSjn+pwUqTNLwk+AHvS3IWUJRJbrjNW6nLhyp1C+3u5YT5CmoVNoKxb0teRmUtWr4HK3QUvwWooLV+q3s3TNCLMDfZOrVZpHQ93yC6HLqMcZq4JEcxre+QNXnYR7MYIPpXRpa0nGiwRnCEc8BiKmPLZobHkUkPwz65UcKIyoUCKlAigiy+ECgYEA5isjQxu7bNiUTcIaRRZUzP6TetKkJnDX4uVKJLK99BNV53evFAGeeGL9kiQ5PA1Iu+LBKBsWG8dL1sejz1i1kICXllVl3AvbB2MN3yTL5zSa+SozzqYZB/6yWLbK+y+EdRMGj0LugGDGYD8ap7h93lm9JkooMwvEWqBxQqlbXpcCgYEAxvNJYYNqddJ+47WjpiQCkLDd7u3z9EVSZQa/cwfRVu/mrvLfFkLBTZnxEA9fAEZ/sR3RBbNo/UIdR8MfAzMYNJFuO9+4AulT6yxlIeNRQaB+rH9YUD2Hy8qPU5TbpPhN6TIWg8qshX4B8SxoNPJoiAKpArdUeHP6Nx2vxXRpP8kCgYAcjm+SjOdFCt3jg9iEh8+/mzoq++VXy5pNUUtQoEiG9rsqu6OiJM1HfGifcBUVyUQj4285jZrBmYlkPWKqgAQOyJWGFlRL58Cl+vkmnUcbCWDM1xqUYfErF8OC1DL81Rlm+RRQQ+qZTOhv2oRxGKetJY8dKAgyxRv4bn1+2so2QwKBgQCKuBfyZi9U9/CB1aTFs1YWjTwx3Li9GZjZ2FqlWk4c0CmI0s+6NdGSykPLbuxOxNlEJgYYc4BBFlhUMTjugjHedYjnNpaXcRmSYOIjPtzpZX7tx91MFZsZ/aLyJFkCLiAk+Ue5nRet/K5d+xit0lgQfcpamnnLgxJ0W76zbvf0AQKBgQCn55Yh5KpSmPkDeChnRMX674Qmr8SS1+qG65U19OfXEF0ruzRltSGYSf1ifBd4o51Y7q/6TKdqh+kYH05AV1pJKbtFO8k5LOUzmbl6FoTsDMAzvbTpe3vOHZg0jAEdSw/zTlb0CSX6PCndY3NBxno9goOzB/PjSqritTgJOStq/w==" + ], + "keyUse": ["ENC"], + "certificate": [ + "MIICmzCCAYMCBgGWPnd7QDANBgkqhkiG9w0BAQsFADARMQ8wDQYDVQQDDAZtYXN0ZXIwHhcNMjUwNDE2MTE1NzE5WhcNMzUwNDE2MTE1ODU5WjARMQ8wDQYDVQQDDAZtYXN0ZXIwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCy4BoyWbSTRLHn3jwrLHG+ySrDdssJSionjvMXOZFpeIPBHi3ZtB7x5TprtenfChDiSDqDBcDBUeHS6fd1pvlAGibB/+BbJYkVM4Ci38kTZAhfoVO2AF2vrL9daC3faPDTURoMsyrZRPby7cBEZnU6VdQzqT/BKA9EXbp3gT5kf5KIcElZd7oNpRTpMsI2uTcvwa6bBxWCH/3d9+b/vGlvZcu32/hKH8ZnV6fAOediIdnEmdOviZsrVklJJw0ZHGUQqOj7OrUhLviEIswvecEPVV4B/Yv6LUA0gvr2Arz7+1idKcAXaF95A3zES7v9KImauKnuz+ctzT4BNY2s822PAgMBAAEwDQYJKoZIhvcNAQELBQADggEBADWyrt7oJoXz+vBurCWY9WZrJzh+4Rg4XYlUwpLdrjzOxOgII2bk8arn1pk9ZiAKE4WFJ3S4ixwM/q8xf4Hkgxp4dNMkbE+TUYJsu+zX5SGJXe+1neQlgVEG27ILnquUX5JkrJBmXuTcPz8q6c1HqG6HF9IibVRzLsyUYdyTEO0uhJrcn0ZZ9XS8YmkBfbbC589FQqcLRebte2+9zbVrUPOJaOmt9V9oM4jUHAi6Rrf+Boatb1hBD0uaOTzJJ0DgZZi8zEblLWyRo9Wts9CaQ1tLJ1Vg79wuwvErzee3kVlYb/p2TCOtP6WK9NDpwvJ/YW4CMy+a1/710xDGtaeg2oU=" + ], + "priority": ["100"], + "algorithm": ["RSA-OAEP"] + } + } + ] + }, + "internationalizationEnabled": false, + "supportedLocales": [], + "authenticationFlows": [ + { + "id": "abe67ec8-48d2-4edb-8517-2ab5885ea549", + "alias": "Account verification options", + "description": "Method with which to verity the existing account", + "providerId": "basic-flow", + "topLevel": false, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "idp-email-verification", + "authenticatorFlow": false, + "requirement": "ALTERNATIVE", + "priority": 10, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticatorFlow": true, + "requirement": "ALTERNATIVE", + "priority": 20, + "autheticatorFlow": true, + "flowAlias": "Verify Existing Account by Re-authentication", + "userSetupAllowed": false + } + ] + }, + { + "id": "0c5ba11d-163f-45e0-8146-22abc12f4fb5", + "alias": "Browser - Conditional OTP", + "description": "Flow to determine if the OTP is required for the authentication", + "providerId": "basic-flow", + "topLevel": false, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "conditional-user-configured", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 10, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticator": "auth-otp-form", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 20, + "autheticatorFlow": false, + "userSetupAllowed": false + } + ] + }, + { + "id": "3b6cd857-3807-4a62-97e0-a1384da77523", + "alias": "Direct Grant - Conditional OTP", + "description": "Flow to determine if the OTP is required for the authentication", + "providerId": "basic-flow", + "topLevel": false, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "conditional-user-configured", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 10, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticator": "direct-grant-validate-otp", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 20, + "autheticatorFlow": false, + "userSetupAllowed": false + } + ] + }, + { + "id": "306d3eeb-792d-4937-9860-b360ca34e764", + "alias": "First broker login - Conditional OTP", + "description": "Flow to determine if the OTP is required for the authentication", + "providerId": "basic-flow", + "topLevel": false, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "conditional-user-configured", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 10, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticator": "auth-otp-form", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 20, + "autheticatorFlow": false, + "userSetupAllowed": false + } + ] + }, + { + "id": "c03c34c3-da1e-4d08-8857-1e59c3dc279a", + "alias": "Handle Existing Account", + "description": "Handle what to do if there is existing account with same email/username like authenticated identity provider", + "providerId": "basic-flow", + "topLevel": false, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "idp-confirm-link", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 10, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticatorFlow": true, + "requirement": "REQUIRED", + "priority": 20, + "autheticatorFlow": true, + "flowAlias": "Account verification options", + "userSetupAllowed": false + } + ] + }, + { + "id": "52f7662e-3180-4ced-86ea-3dcc52fcf925", + "alias": "Reset - Conditional OTP", + "description": "Flow to determine if the OTP should be reset or not. Set to REQUIRED to force.", + "providerId": "basic-flow", + "topLevel": false, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "conditional-user-configured", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 10, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticator": "reset-otp", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 20, + "autheticatorFlow": false, + "userSetupAllowed": false + } + ] + }, + { + "id": "434f457f-5e1b-4a4d-af57-ab9a2013d68d", + "alias": "User creation or linking", + "description": "Flow for the existing/non-existing user alternatives", + "providerId": "basic-flow", + "topLevel": false, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticatorConfig": "create unique user config", + "authenticator": "idp-create-user-if-unique", + "authenticatorFlow": false, + "requirement": "ALTERNATIVE", + "priority": 10, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticatorFlow": true, + "requirement": "ALTERNATIVE", + "priority": 20, + "autheticatorFlow": true, + "flowAlias": "Handle Existing Account", + "userSetupAllowed": false + } + ] + }, + { + "id": "8410476c-6ba9-4e42-90ce-d492ce447a11", + "alias": "Verify Existing Account by Re-authentication", + "description": "Reauthentication of existing account", + "providerId": "basic-flow", + "topLevel": false, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "idp-username-password-form", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 10, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticatorFlow": true, + "requirement": "CONDITIONAL", + "priority": 20, + "autheticatorFlow": true, + "flowAlias": "First broker login - Conditional OTP", + "userSetupAllowed": false + } + ] + }, + { + "id": "b2be31f8-19de-4fbc-86d3-f4126d081514", + "alias": "browser", + "description": "Browser based authentication", + "providerId": "basic-flow", + "topLevel": true, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "auth-cookie", + "authenticatorFlow": false, + "requirement": "ALTERNATIVE", + "priority": 10, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticator": "auth-spnego", + "authenticatorFlow": false, + "requirement": "DISABLED", + "priority": 20, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticator": "identity-provider-redirector", + "authenticatorFlow": false, + "requirement": "ALTERNATIVE", + "priority": 25, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticatorFlow": true, + "requirement": "ALTERNATIVE", + "priority": 30, + "autheticatorFlow": true, + "flowAlias": "forms", + "userSetupAllowed": false + } + ] + }, + { + "id": "29fe5fc8-7a57-401a-b686-bc0a8ed3b975", + "alias": "clients", + "description": "Base authentication for clients", + "providerId": "client-flow", + "topLevel": true, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "client-secret", + "authenticatorFlow": false, + "requirement": "ALTERNATIVE", + "priority": 10, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticator": "client-jwt", + "authenticatorFlow": false, + "requirement": "ALTERNATIVE", + "priority": 20, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticator": "client-secret-jwt", + "authenticatorFlow": false, + "requirement": "ALTERNATIVE", + "priority": 30, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticator": "client-x509", + "authenticatorFlow": false, + "requirement": "ALTERNATIVE", + "priority": 40, + "autheticatorFlow": false, + "userSetupAllowed": false + } + ] + }, + { + "id": "0ac78504-b5a2-4c3d-9c37-902700a23363", + "alias": "direct grant", + "description": "OpenID Connect Resource Owner Grant", + "providerId": "basic-flow", + "topLevel": true, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "direct-grant-validate-username", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 10, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticator": "direct-grant-validate-password", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 20, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticatorFlow": true, + "requirement": "CONDITIONAL", + "priority": 30, + "autheticatorFlow": true, + "flowAlias": "Direct Grant - Conditional OTP", + "userSetupAllowed": false + } + ] + }, + { + "id": "a30731f4-0ef3-4fc5-9e4c-937e60388642", + "alias": "docker auth", + "description": "Used by Docker clients to authenticate against the IDP", + "providerId": "basic-flow", + "topLevel": true, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "docker-http-basic-authenticator", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 10, + "autheticatorFlow": false, + "userSetupAllowed": false + } + ] + }, + { + "id": "7f6e6a7c-09d0-4100-b6fe-3f2dfcd44274", + "alias": "first broker login", + "description": "Actions taken after first broker login with identity provider account, which is not yet linked to any Keycloak account", + "providerId": "basic-flow", + "topLevel": true, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticatorConfig": "review profile config", + "authenticator": "idp-review-profile", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 10, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticatorFlow": true, + "requirement": "REQUIRED", + "priority": 20, + "autheticatorFlow": true, + "flowAlias": "User creation or linking", + "userSetupAllowed": false + } + ] + }, + { + "id": "905f088c-5904-41d4-97fd-cdc11dcc8e6a", + "alias": "forms", + "description": "Username, password, otp and other auth forms.", + "providerId": "basic-flow", + "topLevel": false, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "auth-username-password-form", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 10, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticatorFlow": true, + "requirement": "CONDITIONAL", + "priority": 20, + "autheticatorFlow": true, + "flowAlias": "Browser - Conditional OTP", + "userSetupAllowed": false + } + ] + }, + { + "id": "93271f48-3852-4898-acb3-712c0ac29099", + "alias": "registration", + "description": "Registration flow", + "providerId": "basic-flow", + "topLevel": true, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "registration-page-form", + "authenticatorFlow": true, + "requirement": "REQUIRED", + "priority": 10, + "autheticatorFlow": true, + "flowAlias": "registration form", + "userSetupAllowed": false + } + ] + }, + { + "id": "c0b4f598-6721-4d06-9052-3b97267ce2c2", + "alias": "registration form", + "description": "Registration form", + "providerId": "form-flow", + "topLevel": false, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "registration-user-creation", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 20, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticator": "registration-password-action", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 50, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticator": "registration-recaptcha-action", + "authenticatorFlow": false, + "requirement": "DISABLED", + "priority": 60, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticator": "registration-terms-and-conditions", + "authenticatorFlow": false, + "requirement": "DISABLED", + "priority": 70, + "autheticatorFlow": false, + "userSetupAllowed": false + } + ] + }, + { + "id": "b867afc5-330e-45a3-b935-b82654640eb0", + "alias": "reset credentials", + "description": "Reset credentials for a user if they forgot their password or something", + "providerId": "basic-flow", + "topLevel": true, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "reset-credentials-choose-user", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 10, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticator": "reset-credential-email", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 20, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticator": "reset-password", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 30, + "autheticatorFlow": false, + "userSetupAllowed": false + }, + { + "authenticatorFlow": true, + "requirement": "CONDITIONAL", + "priority": 40, + "autheticatorFlow": true, + "flowAlias": "Reset - Conditional OTP", + "userSetupAllowed": false + } + ] + }, + { + "id": "88b9b0ca-da06-486c-857e-05c6532d4f42", + "alias": "saml ecp", + "description": "SAML ECP Profile Authentication Flow", + "providerId": "basic-flow", + "topLevel": true, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "http-basic-authenticator", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 10, + "autheticatorFlow": false, + "userSetupAllowed": false + } + ] + } + ], + "authenticatorConfig": [ + { + "id": "39e74390-4e8d-4c38-be83-58a3a73d5aa4", + "alias": "create unique user config", + "config": { + "require.password.update.after.registration": "false" + } + }, + { + "id": "c3950873-95c9-4094-8ec9-00897ab5d208", + "alias": "review profile config", + "config": { + "update.profile.on.first.login": "missing" + } + } + ], + "requiredActions": [ + { + "alias": "CONFIGURE_TOTP", + "name": "Configure OTP", + "providerId": "CONFIGURE_TOTP", + "enabled": true, + "defaultAction": false, + "priority": 10, + "config": {} + }, + { + "alias": "TERMS_AND_CONDITIONS", + "name": "Terms and Conditions", + "providerId": "TERMS_AND_CONDITIONS", + "enabled": false, + "defaultAction": false, + "priority": 20, + "config": {} + }, + { + "alias": "UPDATE_PASSWORD", + "name": "Update Password", + "providerId": "UPDATE_PASSWORD", + "enabled": true, + "defaultAction": false, + "priority": 30, + "config": {} + }, + { + "alias": "UPDATE_PROFILE", + "name": "Update Profile", + "providerId": "UPDATE_PROFILE", + "enabled": true, + "defaultAction": false, + "priority": 40, + "config": {} + }, + { + "alias": "VERIFY_EMAIL", + "name": "Verify Email", + "providerId": "VERIFY_EMAIL", + "enabled": true, + "defaultAction": false, + "priority": 50, + "config": {} + }, + { + "alias": "delete_account", + "name": "Delete Account", + "providerId": "delete_account", + "enabled": false, + "defaultAction": false, + "priority": 60, + "config": {} + }, + { + "alias": "webauthn-register", + "name": "Webauthn Register", + "providerId": "webauthn-register", + "enabled": true, + "defaultAction": false, + "priority": 70, + "config": {} + }, + { + "alias": "webauthn-register-passwordless", + "name": "Webauthn Register Passwordless", + "providerId": "webauthn-register-passwordless", + "enabled": true, + "defaultAction": false, + "priority": 80, + "config": {} + }, + { + "alias": "VERIFY_PROFILE", + "name": "Verify Profile", + "providerId": "VERIFY_PROFILE", + "enabled": true, + "defaultAction": false, + "priority": 90, + "config": {} + }, + { + "alias": "delete_credential", + "name": "Delete Credential", + "providerId": "delete_credential", + "enabled": true, + "defaultAction": false, + "priority": 100, + "config": {} + }, + { + "alias": "update_user_locale", + "name": "Update User Locale", + "providerId": "update_user_locale", + "enabled": true, + "defaultAction": false, + "priority": 1000, + "config": {} + } + ], + "browserFlow": "browser", + "registrationFlow": "registration", + "directGrantFlow": "direct grant", + "resetCredentialsFlow": "reset credentials", + "clientAuthenticationFlow": "clients", + "dockerAuthenticationFlow": "docker auth", + "firstBrokerLoginFlow": "first broker login", + "attributes": { + "cibaBackchannelTokenDeliveryMode": "poll", + "cibaExpiresIn": "120", + "cibaAuthRequestedUserHint": "login_hint", + "parRequestUriLifespan": "60", + "cibaInterval": "5", + "realmReusableOtpCode": "false" + }, + "keycloakVersion": "26.0.6", + "userManagedAccessAllowed": false, + "organizationsEnabled": false, + "clientProfiles": { + "profiles": [] + }, + "clientPolicies": { + "policies": [] + } +} diff --git a/nix/services/keycloak/test-realms/test.json b/nix/services/keycloak/test-realms/test.json new file mode 100644 index 00000000..4a959540 --- /dev/null +++ b/nix/services/keycloak/test-realms/test.json @@ -0,0 +1,1980 @@ +{ + "id" : "552b672d-d487-4213-b464-1d3a6290ec67", + "realm" : "test", + "notBefore" : 0, + "defaultSignatureAlgorithm" : "RS256", + "revokeRefreshToken" : false, + "refreshTokenMaxReuse" : 0, + "accessTokenLifespan" : 300, + "accessTokenLifespanForImplicitFlow" : 900, + "ssoSessionIdleTimeout" : 1800, + "ssoSessionMaxLifespan" : 36000, + "ssoSessionIdleTimeoutRememberMe" : 0, + "ssoSessionMaxLifespanRememberMe" : 0, + "offlineSessionIdleTimeout" : 2592000, + "offlineSessionMaxLifespanEnabled" : false, + "offlineSessionMaxLifespan" : 5184000, + "clientSessionIdleTimeout" : 0, + "clientSessionMaxLifespan" : 0, + "clientOfflineSessionIdleTimeout" : 0, + "clientOfflineSessionMaxLifespan" : 0, + "accessCodeLifespan" : 60, + "accessCodeLifespanUserAction" : 300, + "accessCodeLifespanLogin" : 1800, + "actionTokenGeneratedByAdminLifespan" : 43200, + "actionTokenGeneratedByUserLifespan" : 300, + "oauth2DeviceCodeLifespan" : 600, + "oauth2DevicePollingInterval" : 5, + "enabled" : true, + "sslRequired" : "external", + "registrationAllowed" : false, + "registrationEmailAsUsername" : false, + "rememberMe" : false, + "verifyEmail" : false, + "loginWithEmailAllowed" : true, + "duplicateEmailsAllowed" : false, + "resetPasswordAllowed" : false, + "editUsernameAllowed" : false, + "bruteForceProtected" : false, + "permanentLockout" : false, + "maxTemporaryLockouts" : 0, + "bruteForceStrategy" : "MULTIPLE", + "maxFailureWaitSeconds" : 900, + "minimumQuickLoginWaitSeconds" : 60, + "waitIncrementSeconds" : 60, + "quickLoginCheckMilliSeconds" : 1000, + "maxDeltaTimeSeconds" : 43200, + "failureFactor" : 30, + "roles" : { + "realm" : [ { + "id" : "16367bbc-fdf0-4fd4-aa94-437eb16f052d", + "name" : "offline_access", + "description" : "${role_offline-access}", + "composite" : false, + "clientRole" : false, + "containerId" : "552b672d-d487-4213-b464-1d3a6290ec67", + "attributes" : { } + }, { + "id" : "346248d8-22cf-44bc-8f54-d8a5a169f4c9", + "name" : "uma_authorization", + "description" : "${role_uma_authorization}", + "composite" : false, + "clientRole" : false, + "containerId" : "552b672d-d487-4213-b464-1d3a6290ec67", + "attributes" : { } + }, { + "id" : "1cdfa035-675e-4984-a797-44ec4c45ffd8", + "name" : "default-roles-test", + "description" : "${role_default-roles}", + "composite" : true, + "composites" : { + "realm" : [ "offline_access", "uma_authorization" ], + "client" : { + "account" : [ "view-profile", "manage-account" ] + } + }, + "clientRole" : false, + "containerId" : "552b672d-d487-4213-b464-1d3a6290ec67", + "attributes" : { } + } ], + "client" : { + "realm-management" : [ { + "id" : "675fb0d6-88a9-4956-81c3-511db5ef171f", + "name" : "impersonation", + "description" : "${role_impersonation}", + "composite" : false, + "clientRole" : true, + "containerId" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "attributes" : { } + }, { + "id" : "9ed43326-2f5b-4bec-8f2b-4460fa4eb11b", + "name" : "manage-authorization", + "description" : "${role_manage-authorization}", + "composite" : false, + "clientRole" : true, + "containerId" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "attributes" : { } + }, { + "id" : "00db75ee-ba5e-4f2a-a87a-383f88dca26e", + "name" : "realm-admin", + "description" : "${role_realm-admin}", + "composite" : true, + "composites" : { + "client" : { + "realm-management" : [ "impersonation", "manage-authorization", "manage-clients", "manage-identity-providers", "view-realm", "query-groups", "query-users", "view-events", "view-clients", "manage-events", "query-clients", "view-authorization", "manage-realm", "view-users", "create-client", "query-realms", "view-identity-providers", "manage-users" ] + } + }, + "clientRole" : true, + "containerId" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "attributes" : { } + }, { + "id" : "0f93e63a-23a4-4c57-bfeb-8b7b779901c2", + "name" : "manage-clients", + "description" : "${role_manage-clients}", + "composite" : false, + "clientRole" : true, + "containerId" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "attributes" : { } + }, { + "id" : "9facf169-58f4-45bf-b7c4-0f41cf6cd2b4", + "name" : "manage-identity-providers", + "description" : "${role_manage-identity-providers}", + "composite" : false, + "clientRole" : true, + "containerId" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "attributes" : { } + }, { + "id" : "19a0e285-664c-436c-babe-8c572698e63d", + "name" : "view-realm", + "description" : "${role_view-realm}", + "composite" : false, + "clientRole" : true, + "containerId" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "attributes" : { } + }, { + "id" : "4c063494-03ec-4beb-9932-454faaf4d7fc", + "name" : "query-groups", + "description" : "${role_query-groups}", + "composite" : false, + "clientRole" : true, + "containerId" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "attributes" : { } + }, { + "id" : "83e9111d-3204-431a-bf4a-6b87fad954b3", + "name" : "query-users", + "description" : "${role_query-users}", + "composite" : false, + "clientRole" : true, + "containerId" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "attributes" : { } + }, { + "id" : "75098b40-cc49-41a2-bec4-335a7caf67e3", + "name" : "view-clients", + "description" : "${role_view-clients}", + "composite" : true, + "composites" : { + "client" : { + "realm-management" : [ "query-clients" ] + } + }, + "clientRole" : true, + "containerId" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "attributes" : { } + }, { + "id" : "3801bb21-9312-4939-bbf9-cf831332f17e", + "name" : "view-events", + "description" : "${role_view-events}", + "composite" : false, + "clientRole" : true, + "containerId" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "attributes" : { } + }, { + "id" : "968ac58b-5b6d-4578-9a37-7e581579f785", + "name" : "manage-events", + "description" : "${role_manage-events}", + "composite" : false, + "clientRole" : true, + "containerId" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "attributes" : { } + }, { + "id" : "7a6768e9-8955-4234-b8ea-1529762a3a08", + "name" : "query-clients", + "description" : "${role_query-clients}", + "composite" : false, + "clientRole" : true, + "containerId" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "attributes" : { } + }, { + "id" : "82471aa3-8dfd-4bdf-bf58-82109e124219", + "name" : "view-authorization", + "description" : "${role_view-authorization}", + "composite" : false, + "clientRole" : true, + "containerId" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "attributes" : { } + }, { + "id" : "cb97adc1-6677-42df-9420-853c47f692b7", + "name" : "manage-realm", + "description" : "${role_manage-realm}", + "composite" : false, + "clientRole" : true, + "containerId" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "attributes" : { } + }, { + "id" : "af732a84-c47d-4617-b7b1-57b12ebbc7c4", + "name" : "create-client", + "description" : "${role_create-client}", + "composite" : false, + "clientRole" : true, + "containerId" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "attributes" : { } + }, { + "id" : "483bd584-5ea7-4891-9362-a0c34f106cf0", + "name" : "view-users", + "description" : "${role_view-users}", + "composite" : true, + "composites" : { + "client" : { + "realm-management" : [ "query-groups", "query-users" ] + } + }, + "clientRole" : true, + "containerId" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "attributes" : { } + }, { + "id" : "28c8ee8d-38ad-41f9-910c-3bd13a7ec78b", + "name" : "query-realms", + "description" : "${role_query-realms}", + "composite" : false, + "clientRole" : true, + "containerId" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "attributes" : { } + }, { + "id" : "155d8f95-bc0c-435e-9a98-f9df471ff144", + "name" : "view-identity-providers", + "description" : "${role_view-identity-providers}", + "composite" : false, + "clientRole" : true, + "containerId" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "attributes" : { } + }, { + "id" : "b18cf4b2-a153-45e3-ba79-5311699ef0a3", + "name" : "manage-users", + "description" : "${role_manage-users}", + "composite" : false, + "clientRole" : true, + "containerId" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "attributes" : { } + } ], + "test" : [ ], + "security-admin-console" : [ ], + "admin-cli" : [ ], + "account-console" : [ ], + "broker" : [ { + "id" : "451c1d48-734f-4800-9774-48bd4bf4812f", + "name" : "read-token", + "description" : "${role_read-token}", + "composite" : false, + "clientRole" : true, + "containerId" : "67be77be-c624-4bbe-943f-6c3ebcd339cf", + "attributes" : { } + } ], + "account" : [ { + "id" : "04bb39fe-8f52-4ea2-b4e5-4bf64aab31dd", + "name" : "delete-account", + "description" : "${role_delete-account}", + "composite" : false, + "clientRole" : true, + "containerId" : "8ab5429a-e7e1-462d-9cad-4bebafeb3e38", + "attributes" : { } + }, { + "id" : "0e13a4ff-5279-445f-b094-6df79b2f5cf0", + "name" : "view-groups", + "description" : "${role_view-groups}", + "composite" : false, + "clientRole" : true, + "containerId" : "8ab5429a-e7e1-462d-9cad-4bebafeb3e38", + "attributes" : { } + }, { + "id" : "417f919c-74c7-4234-acfb-383834c373cd", + "name" : "manage-account-links", + "description" : "${role_manage-account-links}", + "composite" : false, + "clientRole" : true, + "containerId" : "8ab5429a-e7e1-462d-9cad-4bebafeb3e38", + "attributes" : { } + }, { + "id" : "4e7253a2-d890-4bb1-b4de-49ee8d8876e8", + "name" : "manage-consent", + "description" : "${role_manage-consent}", + "composite" : true, + "composites" : { + "client" : { + "account" : [ "view-consent" ] + } + }, + "clientRole" : true, + "containerId" : "8ab5429a-e7e1-462d-9cad-4bebafeb3e38", + "attributes" : { } + }, { + "id" : "99237935-d669-48bf-8e63-c87e4e7aaee0", + "name" : "view-profile", + "description" : "${role_view-profile}", + "composite" : false, + "clientRole" : true, + "containerId" : "8ab5429a-e7e1-462d-9cad-4bebafeb3e38", + "attributes" : { } + }, { + "id" : "be075bde-6dba-4fec-b09f-a2daf7dd40b4", + "name" : "view-applications", + "description" : "${role_view-applications}", + "composite" : false, + "clientRole" : true, + "containerId" : "8ab5429a-e7e1-462d-9cad-4bebafeb3e38", + "attributes" : { } + }, { + "id" : "9afbaab3-9df6-406a-a602-57081a52b594", + "name" : "view-consent", + "description" : "${role_view-consent}", + "composite" : false, + "clientRole" : true, + "containerId" : "8ab5429a-e7e1-462d-9cad-4bebafeb3e38", + "attributes" : { } + }, { + "id" : "5b248f9e-9824-4642-9686-579705c4a5ed", + "name" : "manage-account", + "description" : "${role_manage-account}", + "composite" : true, + "composites" : { + "client" : { + "account" : [ "manage-account-links" ] + } + }, + "clientRole" : true, + "containerId" : "8ab5429a-e7e1-462d-9cad-4bebafeb3e38", + "attributes" : { } + } ] + } + }, + "groups" : [ ], + "defaultRole" : { + "id" : "1cdfa035-675e-4984-a797-44ec4c45ffd8", + "name" : "default-roles-test", + "description" : "${role_default-roles}", + "composite" : true, + "clientRole" : false, + "containerId" : "552b672d-d487-4213-b464-1d3a6290ec67" + }, + "requiredCredentials" : [ "password" ], + "otpPolicyType" : "totp", + "otpPolicyAlgorithm" : "HmacSHA1", + "otpPolicyInitialCounter" : 0, + "otpPolicyDigits" : 6, + "otpPolicyLookAheadWindow" : 1, + "otpPolicyPeriod" : 30, + "otpPolicyCodeReusable" : false, + "otpSupportedApplications" : [ "totpAppFreeOTPName", "totpAppGoogleName", "totpAppMicrosoftAuthenticatorName" ], + "localizationTexts" : { }, + "webAuthnPolicyRpEntityName" : "keycloak", + "webAuthnPolicySignatureAlgorithms" : [ "ES256", "RS256" ], + "webAuthnPolicyRpId" : "", + "webAuthnPolicyAttestationConveyancePreference" : "not specified", + "webAuthnPolicyAuthenticatorAttachment" : "not specified", + "webAuthnPolicyRequireResidentKey" : "not specified", + "webAuthnPolicyUserVerificationRequirement" : "not specified", + "webAuthnPolicyCreateTimeout" : 0, + "webAuthnPolicyAvoidSameAuthenticatorRegister" : false, + "webAuthnPolicyAcceptableAaguids" : [ ], + "webAuthnPolicyExtraOrigins" : [ ], + "webAuthnPolicyPasswordlessRpEntityName" : "keycloak", + "webAuthnPolicyPasswordlessSignatureAlgorithms" : [ "ES256", "RS256" ], + "webAuthnPolicyPasswordlessRpId" : "", + "webAuthnPolicyPasswordlessAttestationConveyancePreference" : "not specified", + "webAuthnPolicyPasswordlessAuthenticatorAttachment" : "not specified", + "webAuthnPolicyPasswordlessRequireResidentKey" : "not specified", + "webAuthnPolicyPasswordlessUserVerificationRequirement" : "not specified", + "webAuthnPolicyPasswordlessCreateTimeout" : 0, + "webAuthnPolicyPasswordlessAvoidSameAuthenticatorRegister" : false, + "webAuthnPolicyPasswordlessAcceptableAaguids" : [ ], + "webAuthnPolicyPasswordlessExtraOrigins" : [ ], + "scopeMappings" : [ { + "clientScope" : "offline_access", + "roles" : [ "offline_access" ] + } ], + "clientScopeMappings" : { + "account" : [ { + "client" : "account-console", + "roles" : [ "manage-account", "view-groups" ] + } ] + }, + "clients" : [ { + "id" : "8ab5429a-e7e1-462d-9cad-4bebafeb3e38", + "clientId" : "account", + "name" : "${client_account}", + "rootUrl" : "${authBaseUrl}", + "baseUrl" : "/realms/test/account/", + "surrogateAuthRequired" : false, + "enabled" : true, + "alwaysDisplayInConsole" : false, + "clientAuthenticatorType" : "client-secret", + "redirectUris" : [ "/realms/test/account/*" ], + "webOrigins" : [ ], + "notBefore" : 0, + "bearerOnly" : false, + "consentRequired" : false, + "standardFlowEnabled" : true, + "implicitFlowEnabled" : false, + "directAccessGrantsEnabled" : false, + "serviceAccountsEnabled" : false, + "publicClient" : true, + "frontchannelLogout" : false, + "protocol" : "openid-connect", + "attributes" : { + "realm_client" : "false", + "post.logout.redirect.uris" : "+" + }, + "authenticationFlowBindingOverrides" : { }, + "fullScopeAllowed" : false, + "nodeReRegistrationTimeout" : 0, + "defaultClientScopes" : [ "web-origins", "acr", "roles", "profile", "basic", "email" ], + "optionalClientScopes" : [ "address", "phone", "organization", "offline_access", "microprofile-jwt" ] + }, { + "id" : "4b57b2c5-f15c-4a00-a48d-3fcbaa9a7bae", + "clientId" : "account-console", + "name" : "${client_account-console}", + "rootUrl" : "${authBaseUrl}", + "baseUrl" : "/realms/test/account/", + "surrogateAuthRequired" : false, + "enabled" : true, + "alwaysDisplayInConsole" : false, + "clientAuthenticatorType" : "client-secret", + "redirectUris" : [ "/realms/test/account/*" ], + "webOrigins" : [ ], + "notBefore" : 0, + "bearerOnly" : false, + "consentRequired" : false, + "standardFlowEnabled" : true, + "implicitFlowEnabled" : false, + "directAccessGrantsEnabled" : false, + "serviceAccountsEnabled" : false, + "publicClient" : true, + "frontchannelLogout" : false, + "protocol" : "openid-connect", + "attributes" : { + "realm_client" : "false", + "post.logout.redirect.uris" : "+", + "pkce.code.challenge.method" : "S256" + }, + "authenticationFlowBindingOverrides" : { }, + "fullScopeAllowed" : false, + "nodeReRegistrationTimeout" : 0, + "protocolMappers" : [ { + "id" : "d4d3ec7e-4016-49b6-9846-6351d3cf3253", + "name" : "audience resolve", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-audience-resolve-mapper", + "consentRequired" : false, + "config" : { } + } ], + "defaultClientScopes" : [ "web-origins", "acr", "roles", "profile", "basic", "email" ], + "optionalClientScopes" : [ "address", "phone", "organization", "offline_access", "microprofile-jwt" ] + }, { + "id" : "2bd0bd42-b0c6-48d9-8e9d-056641672f3f", + "clientId" : "admin-cli", + "name" : "${client_admin-cli}", + "surrogateAuthRequired" : false, + "enabled" : true, + "alwaysDisplayInConsole" : false, + "clientAuthenticatorType" : "client-secret", + "redirectUris" : [ ], + "webOrigins" : [ ], + "notBefore" : 0, + "bearerOnly" : false, + "consentRequired" : false, + "standardFlowEnabled" : false, + "implicitFlowEnabled" : false, + "directAccessGrantsEnabled" : true, + "serviceAccountsEnabled" : false, + "publicClient" : true, + "frontchannelLogout" : false, + "protocol" : "openid-connect", + "attributes" : { + "realm_client" : "false", + "client.use.lightweight.access.token.enabled" : "true" + }, + "authenticationFlowBindingOverrides" : { }, + "fullScopeAllowed" : true, + "nodeReRegistrationTimeout" : 0, + "defaultClientScopes" : [ "web-origins", "acr", "roles", "profile", "basic", "email" ], + "optionalClientScopes" : [ "address", "phone", "organization", "offline_access", "microprofile-jwt" ] + }, { + "id" : "67be77be-c624-4bbe-943f-6c3ebcd339cf", + "clientId" : "broker", + "name" : "${client_broker}", + "surrogateAuthRequired" : false, + "enabled" : true, + "alwaysDisplayInConsole" : false, + "clientAuthenticatorType" : "client-secret", + "redirectUris" : [ ], + "webOrigins" : [ ], + "notBefore" : 0, + "bearerOnly" : true, + "consentRequired" : false, + "standardFlowEnabled" : true, + "implicitFlowEnabled" : false, + "directAccessGrantsEnabled" : false, + "serviceAccountsEnabled" : false, + "publicClient" : false, + "frontchannelLogout" : false, + "protocol" : "openid-connect", + "attributes" : { + "realm_client" : "true" + }, + "authenticationFlowBindingOverrides" : { }, + "fullScopeAllowed" : false, + "nodeReRegistrationTimeout" : 0, + "defaultClientScopes" : [ "web-origins", "acr", "roles", "profile", "basic", "email" ], + "optionalClientScopes" : [ "address", "phone", "organization", "offline_access", "microprofile-jwt" ] + }, { + "id" : "6bf0c67f-4593-4720-ab82-68cf955febc7", + "clientId" : "realm-management", + "name" : "${client_realm-management}", + "surrogateAuthRequired" : false, + "enabled" : true, + "alwaysDisplayInConsole" : false, + "clientAuthenticatorType" : "client-secret", + "redirectUris" : [ ], + "webOrigins" : [ ], + "notBefore" : 0, + "bearerOnly" : true, + "consentRequired" : false, + "standardFlowEnabled" : true, + "implicitFlowEnabled" : false, + "directAccessGrantsEnabled" : false, + "serviceAccountsEnabled" : false, + "publicClient" : false, + "frontchannelLogout" : false, + "protocol" : "openid-connect", + "attributes" : { + "realm_client" : "true" + }, + "authenticationFlowBindingOverrides" : { }, + "fullScopeAllowed" : false, + "nodeReRegistrationTimeout" : 0, + "defaultClientScopes" : [ "web-origins", "acr", "roles", "profile", "basic", "email" ], + "optionalClientScopes" : [ "address", "phone", "organization", "offline_access", "microprofile-jwt" ] + }, { + "id" : "4a93c590-3487-44a9-a759-c7faf78dbdb4", + "clientId" : "security-admin-console", + "name" : "${client_security-admin-console}", + "rootUrl" : "${authAdminUrl}", + "baseUrl" : "/admin/test/console/", + "surrogateAuthRequired" : false, + "enabled" : true, + "alwaysDisplayInConsole" : false, + "clientAuthenticatorType" : "client-secret", + "redirectUris" : [ "/admin/test/console/*" ], + "webOrigins" : [ "+" ], + "notBefore" : 0, + "bearerOnly" : false, + "consentRequired" : false, + "standardFlowEnabled" : true, + "implicitFlowEnabled" : false, + "directAccessGrantsEnabled" : false, + "serviceAccountsEnabled" : false, + "publicClient" : true, + "frontchannelLogout" : false, + "protocol" : "openid-connect", + "attributes" : { + "realm_client" : "false", + "client.use.lightweight.access.token.enabled" : "true", + "post.logout.redirect.uris" : "+", + "pkce.code.challenge.method" : "S256" + }, + "authenticationFlowBindingOverrides" : { }, + "fullScopeAllowed" : true, + "nodeReRegistrationTimeout" : 0, + "protocolMappers" : [ { + "id" : "b58e7931-b037-4606-b29b-6d160bb68b71", + "name" : "locale", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-attribute-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "userinfo.token.claim" : "true", + "user.attribute" : "locale", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "locale", + "jsonType.label" : "String" + } + } ], + "defaultClientScopes" : [ "web-origins", "acr", "roles", "profile", "basic", "email" ], + "optionalClientScopes" : [ "address", "phone", "organization", "offline_access", "microprofile-jwt" ] + }, { + "id" : "874dd5ca-1830-47ff-9f2a-f567eacb3cf6", + "clientId" : "test", + "name" : "test", + "description" : "test", + "rootUrl" : "", + "adminUrl" : "", + "baseUrl" : "", + "surrogateAuthRequired" : false, + "enabled" : true, + "alwaysDisplayInConsole" : true, + "clientAuthenticatorType" : "client-secret", + "redirectUris" : [ "/*" ], + "webOrigins" : [ "/*" ], + "notBefore" : 0, + "bearerOnly" : false, + "consentRequired" : false, + "standardFlowEnabled" : true, + "implicitFlowEnabled" : false, + "directAccessGrantsEnabled" : true, + "serviceAccountsEnabled" : false, + "publicClient" : true, + "frontchannelLogout" : true, + "protocol" : "openid-connect", + "attributes" : { + "realm_client" : "false", + "oidc.ciba.grant.enabled" : "false", + "backchannel.logout.session.required" : "true", + "oauth2.device.authorization.grant.enabled" : "false", + "display.on.consent.screen" : "false", + "backchannel.logout.revoke.offline.tokens" : "false" + }, + "authenticationFlowBindingOverrides" : { }, + "fullScopeAllowed" : true, + "nodeReRegistrationTimeout" : -1, + "defaultClientScopes" : [ "web-origins", "acr", "roles", "profile", "basic", "email" ], + "optionalClientScopes" : [ "address", "phone", "organization", "offline_access", "microprofile-jwt" ] + } ], + "clientScopes" : [ { + "id" : "a78ea679-7a18-452d-9f9d-e431370e39ea", + "name" : "address", + "description" : "OpenID Connect built-in scope: address", + "protocol" : "openid-connect", + "attributes" : { + "include.in.token.scope" : "true", + "consent.screen.text" : "${addressScopeConsentText}", + "display.on.consent.screen" : "true" + }, + "protocolMappers" : [ { + "id" : "fadeb169-a6b8-4963-bc26-9deb9801f5eb", + "name" : "address", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-address-mapper", + "consentRequired" : false, + "config" : { + "user.attribute.formatted" : "formatted", + "user.attribute.country" : "country", + "introspection.token.claim" : "true", + "user.attribute.postal_code" : "postal_code", + "userinfo.token.claim" : "true", + "user.attribute.street" : "street", + "id.token.claim" : "true", + "user.attribute.region" : "region", + "access.token.claim" : "true", + "user.attribute.locality" : "locality" + } + } ] + }, { + "id" : "60679a33-1b5b-490b-90a5-2ec1e9598c65", + "name" : "saml_organization", + "description" : "Organization Membership", + "protocol" : "saml", + "attributes" : { + "display.on.consent.screen" : "false" + }, + "protocolMappers" : [ { + "id" : "55c44c17-646e-483c-aed9-fbae2531192d", + "name" : "organization", + "protocol" : "saml", + "protocolMapper" : "saml-organization-membership-mapper", + "consentRequired" : false, + "config" : { } + } ] + }, { + "id" : "ef6d2a5b-32ef-4545-98dd-f0f17befbf4b", + "name" : "microprofile-jwt", + "description" : "Microprofile - JWT built-in scope", + "protocol" : "openid-connect", + "attributes" : { + "include.in.token.scope" : "true", + "display.on.consent.screen" : "false" + }, + "protocolMappers" : [ { + "id" : "29a74667-da1a-4e27-ac9b-d8db3d8e3ce3", + "name" : "groups", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-realm-role-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "multivalued" : "true", + "user.attribute" : "foo", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "groups", + "jsonType.label" : "String" + } + }, { + "id" : "73979be6-8fda-4b04-a821-c49c5319cf65", + "name" : "upn", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-attribute-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "userinfo.token.claim" : "true", + "user.attribute" : "username", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "upn", + "jsonType.label" : "String" + } + } ] + }, { + "id" : "a4a354ff-a162-4e20-b3de-0c861ebb9339", + "name" : "profile", + "description" : "OpenID Connect built-in scope: profile", + "protocol" : "openid-connect", + "attributes" : { + "include.in.token.scope" : "true", + "consent.screen.text" : "${profileScopeConsentText}", + "display.on.consent.screen" : "true" + }, + "protocolMappers" : [ { + "id" : "59388447-df18-4468-a851-ee54f3691382", + "name" : "nickname", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-attribute-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "userinfo.token.claim" : "true", + "user.attribute" : "nickname", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "nickname", + "jsonType.label" : "String" + } + }, { + "id" : "5ab38ba2-d09b-4c82-bb60-82ed961c4629", + "name" : "birthdate", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-attribute-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "userinfo.token.claim" : "true", + "user.attribute" : "birthdate", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "birthdate", + "jsonType.label" : "String" + } + }, { + "id" : "f69b07c7-e27f-4c62-9a85-cf6a5ac24f5a", + "name" : "picture", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-attribute-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "userinfo.token.claim" : "true", + "user.attribute" : "picture", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "picture", + "jsonType.label" : "String" + } + }, { + "id" : "c337f8fb-4a27-4161-aeae-6f5393425fdd", + "name" : "full name", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-full-name-mapper", + "consentRequired" : false, + "config" : { + "id.token.claim" : "true", + "introspection.token.claim" : "true", + "access.token.claim" : "true", + "userinfo.token.claim" : "true" + } + }, { + "id" : "85cf7a83-72b2-40f3-8d5a-94d89e784003", + "name" : "zoneinfo", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-attribute-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "userinfo.token.claim" : "true", + "user.attribute" : "zoneinfo", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "zoneinfo", + "jsonType.label" : "String" + } + }, { + "id" : "fe78c20c-c1cc-415a-aeb4-01255711e192", + "name" : "middle name", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-attribute-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "userinfo.token.claim" : "true", + "user.attribute" : "middleName", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "middle_name", + "jsonType.label" : "String" + } + }, { + "id" : "9659f64e-74ae-4c9e-a3dc-da50d31a5d55", + "name" : "family name", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-attribute-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "userinfo.token.claim" : "true", + "user.attribute" : "lastName", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "family_name", + "jsonType.label" : "String" + } + }, { + "id" : "77de0854-9be9-4968-9999-545715bc8335", + "name" : "given name", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-attribute-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "userinfo.token.claim" : "true", + "user.attribute" : "firstName", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "given_name", + "jsonType.label" : "String" + } + }, { + "id" : "b831aebf-44aa-4c88-a5a2-93ce71f8b226", + "name" : "username", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-attribute-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "userinfo.token.claim" : "true", + "user.attribute" : "username", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "preferred_username", + "jsonType.label" : "String" + } + }, { + "id" : "e1b3f4b0-f5de-4023-ba51-479cb531eabb", + "name" : "updated at", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-attribute-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "userinfo.token.claim" : "true", + "user.attribute" : "updatedAt", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "updated_at", + "jsonType.label" : "long" + } + }, { + "id" : "ca77142e-ba2a-471d-8d4a-b8cfb92bcad9", + "name" : "profile", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-attribute-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "userinfo.token.claim" : "true", + "user.attribute" : "profile", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "profile", + "jsonType.label" : "String" + } + }, { + "id" : "a540fdf9-d2f5-40f8-be99-3545ea5066f7", + "name" : "website", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-attribute-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "userinfo.token.claim" : "true", + "user.attribute" : "website", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "website", + "jsonType.label" : "String" + } + }, { + "id" : "f0f1a6d8-bbb7-4322-882e-c373dd7b3c03", + "name" : "locale", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-attribute-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "userinfo.token.claim" : "true", + "user.attribute" : "locale", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "locale", + "jsonType.label" : "String" + } + }, { + "id" : "62c83a8f-83cc-4d28-b1b3-edb24685fc88", + "name" : "gender", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-attribute-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "userinfo.token.claim" : "true", + "user.attribute" : "gender", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "gender", + "jsonType.label" : "String" + } + } ] + }, { + "id" : "c8bba8f0-0dc4-45f3-81d9-910ecd7af19a", + "name" : "role_list", + "description" : "SAML role list", + "protocol" : "saml", + "attributes" : { + "consent.screen.text" : "${samlRoleListScopeConsentText}", + "display.on.consent.screen" : "true" + }, + "protocolMappers" : [ { + "id" : "c8bf85c6-af49-4214-87b1-a1ab8a37fdb0", + "name" : "role list", + "protocol" : "saml", + "protocolMapper" : "saml-role-list-mapper", + "consentRequired" : false, + "config" : { + "single" : "false", + "attribute.nameformat" : "Basic", + "attribute.name" : "Role" + } + } ] + }, { + "id" : "5a669800-ce2d-44de-a644-7c579173ae2a", + "name" : "web-origins", + "description" : "OpenID Connect scope for add allowed web origins to the access token", + "protocol" : "openid-connect", + "attributes" : { + "include.in.token.scope" : "false", + "consent.screen.text" : "", + "display.on.consent.screen" : "false" + }, + "protocolMappers" : [ { + "id" : "6940024d-bf71-42ed-952a-d1f73667d8de", + "name" : "allowed web origins", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-allowed-origins-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "access.token.claim" : "true" + } + } ] + }, { + "id" : "2ee8d8a9-d6ca-4b7f-938e-55bbb20188e8", + "name" : "roles", + "description" : "OpenID Connect scope for add user roles to the access token", + "protocol" : "openid-connect", + "attributes" : { + "include.in.token.scope" : "false", + "consent.screen.text" : "${rolesScopeConsentText}", + "display.on.consent.screen" : "true" + }, + "protocolMappers" : [ { + "id" : "bf02d5df-0af8-446f-ab85-ac81169ddf33", + "name" : "client roles", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-client-role-mapper", + "consentRequired" : false, + "config" : { + "user.attribute" : "foo", + "introspection.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "resource_access.${client_id}.roles", + "jsonType.label" : "String", + "multivalued" : "true" + } + }, { + "id" : "89a8e566-6c89-493c-a64c-69569a0ac487", + "name" : "audience resolve", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-audience-resolve-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "access.token.claim" : "true" + } + }, { + "id" : "7bb946ff-a185-47f0-a581-1a3d8a9d002e", + "name" : "realm roles", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-realm-role-mapper", + "consentRequired" : false, + "config" : { + "user.attribute" : "foo", + "introspection.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "realm_access.roles", + "jsonType.label" : "String", + "multivalued" : "true" + } + } ] + }, { + "id" : "3e208995-4ad7-4dd2-b24a-2125522cd8d6", + "name" : "organization", + "description" : "Additional claims about the organization a subject belongs to", + "protocol" : "openid-connect", + "attributes" : { + "include.in.token.scope" : "true", + "consent.screen.text" : "${organizationScopeConsentText}", + "display.on.consent.screen" : "true" + }, + "protocolMappers" : [ { + "id" : "71595dca-ff58-4d32-a896-e89e54abfc97", + "name" : "organization", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-organization-membership-mapper", + "consentRequired" : false, + "config" : { + "id.token.claim" : "true", + "introspection.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "organization", + "jsonType.label" : "String", + "multivalued" : "true" + } + } ] + }, { + "id" : "c8247fa9-a443-4d3a-98c1-f77102d22a0b", + "name" : "acr", + "description" : "OpenID Connect scope for add acr (authentication context class reference) to the token", + "protocol" : "openid-connect", + "attributes" : { + "include.in.token.scope" : "false", + "display.on.consent.screen" : "false" + }, + "protocolMappers" : [ { + "id" : "d5979017-4f94-4232-ace3-53e8f9c01b89", + "name" : "acr loa level", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-acr-mapper", + "consentRequired" : false, + "config" : { + "id.token.claim" : "true", + "introspection.token.claim" : "true", + "access.token.claim" : "true" + } + } ] + }, { + "id" : "46162a47-e6b3-4511-8ece-d47808b7a951", + "name" : "offline_access", + "description" : "OpenID Connect built-in scope: offline_access", + "protocol" : "openid-connect", + "attributes" : { + "consent.screen.text" : "${offlineAccessScopeConsentText}", + "display.on.consent.screen" : "true" + } + }, { + "id" : "d59fa3e3-3e96-442a-90d7-ce19e61aa62a", + "name" : "phone", + "description" : "OpenID Connect built-in scope: phone", + "protocol" : "openid-connect", + "attributes" : { + "include.in.token.scope" : "true", + "consent.screen.text" : "${phoneScopeConsentText}", + "display.on.consent.screen" : "true" + }, + "protocolMappers" : [ { + "id" : "0acb7991-6bc2-43d3-9bab-737c25066ee0", + "name" : "phone number verified", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-attribute-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "userinfo.token.claim" : "true", + "user.attribute" : "phoneNumberVerified", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "phone_number_verified", + "jsonType.label" : "boolean" + } + }, { + "id" : "cd8671b8-c6df-447f-935d-c741eed07041", + "name" : "phone number", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-attribute-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "userinfo.token.claim" : "true", + "user.attribute" : "phoneNumber", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "phone_number", + "jsonType.label" : "String" + } + } ] + }, { + "id" : "79b33ecb-fbc2-42cc-a091-fdd84a8a9cf2", + "name" : "basic", + "description" : "OpenID Connect scope for add all basic claims to the token", + "protocol" : "openid-connect", + "attributes" : { + "include.in.token.scope" : "false", + "display.on.consent.screen" : "false" + }, + "protocolMappers" : [ { + "id" : "4679d850-5b86-4c75-915c-a002a4afa90c", + "name" : "auth_time", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usersessionmodel-note-mapper", + "consentRequired" : false, + "config" : { + "user.session.note" : "AUTH_TIME", + "id.token.claim" : "true", + "introspection.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "auth_time", + "jsonType.label" : "long" + } + }, { + "id" : "abc3e3ab-5e2e-4a5d-88ef-07d25efb53a0", + "name" : "sub", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-sub-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "access.token.claim" : "true" + } + } ] + }, { + "id" : "d18cb6e9-9480-4927-921e-d872b6c01606", + "name" : "email", + "description" : "OpenID Connect built-in scope: email", + "protocol" : "openid-connect", + "attributes" : { + "include.in.token.scope" : "true", + "consent.screen.text" : "${emailScopeConsentText}", + "display.on.consent.screen" : "true" + }, + "protocolMappers" : [ { + "id" : "92aec799-88a0-4006-8c21-f12a201fadc3", + "name" : "email", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-attribute-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "userinfo.token.claim" : "true", + "user.attribute" : "email", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "email", + "jsonType.label" : "String" + } + }, { + "id" : "876aafa0-39ec-4797-8647-89b01c2c3c41", + "name" : "email verified", + "protocol" : "openid-connect", + "protocolMapper" : "oidc-usermodel-property-mapper", + "consentRequired" : false, + "config" : { + "introspection.token.claim" : "true", + "userinfo.token.claim" : "true", + "user.attribute" : "emailVerified", + "id.token.claim" : "true", + "access.token.claim" : "true", + "claim.name" : "email_verified", + "jsonType.label" : "boolean" + } + } ] + } ], + "defaultDefaultClientScopes" : [ "role_list", "saml_organization", "profile", "email", "roles", "web-origins", "acr", "basic" ], + "defaultOptionalClientScopes" : [ "offline_access", "address", "phone", "microprofile-jwt", "organization" ], + "browserSecurityHeaders" : { + "contentSecurityPolicyReportOnly" : "", + "xContentTypeOptions" : "nosniff", + "referrerPolicy" : "no-referrer", + "xRobotsTag" : "none", + "xFrameOptions" : "SAMEORIGIN", + "contentSecurityPolicy" : "frame-src 'self'; frame-ancestors 'self'; object-src 'none';", + "xXSSProtection" : "1; mode=block", + "strictTransportSecurity" : "max-age=31536000; includeSubDomains" + }, + "smtpServer" : { }, + "eventsEnabled" : false, + "eventsListeners" : [ "jboss-logging" ], + "enabledEventTypes" : [ ], + "adminEventsEnabled" : false, + "adminEventsDetailsEnabled" : false, + "identityProviders" : [ ], + "identityProviderMappers" : [ ], + "components" : { + "org.keycloak.services.clientregistration.policy.ClientRegistrationPolicy" : [ { + "id" : "b4b7ad08-eda3-4014-863f-410e302928a0", + "name" : "Trusted Hosts", + "providerId" : "trusted-hosts", + "subType" : "anonymous", + "subComponents" : { }, + "config" : { + "host-sending-registration-request-must-match" : [ "true" ], + "client-uris-must-match" : [ "true" ] + } + }, { + "id" : "6f9b09ba-a4df-4450-baef-21ca5b38fb79", + "name" : "Max Clients Limit", + "providerId" : "max-clients", + "subType" : "anonymous", + "subComponents" : { }, + "config" : { + "max-clients" : [ "200" ] + } + }, { + "id" : "f186f1a0-89d0-43eb-9b13-712bc794eb0b", + "name" : "Allowed Client Scopes", + "providerId" : "allowed-client-templates", + "subType" : "authenticated", + "subComponents" : { }, + "config" : { + "allow-default-scopes" : [ "true" ] + } + }, { + "id" : "c00ecb53-8184-455c-bc50-338f7acdffab", + "name" : "Consent Required", + "providerId" : "consent-required", + "subType" : "anonymous", + "subComponents" : { }, + "config" : { } + }, { + "id" : "1688c409-e2a3-4fb0-a333-fae9aebe723d", + "name" : "Full Scope Disabled", + "providerId" : "scope", + "subType" : "anonymous", + "subComponents" : { }, + "config" : { } + }, { + "id" : "1900175a-ff1c-46b6-9a1a-daa8cbc7b275", + "name" : "Allowed Protocol Mapper Types", + "providerId" : "allowed-protocol-mappers", + "subType" : "authenticated", + "subComponents" : { }, + "config" : { + "allowed-protocol-mapper-types" : [ "oidc-usermodel-attribute-mapper", "oidc-full-name-mapper", "oidc-address-mapper", "oidc-sha256-pairwise-sub-mapper", "saml-role-list-mapper", "saml-user-property-mapper", "oidc-usermodel-property-mapper", "saml-user-attribute-mapper" ] + } + }, { + "id" : "a773476d-4312-4aa1-86d5-bbf34a8b6427", + "name" : "Allowed Client Scopes", + "providerId" : "allowed-client-templates", + "subType" : "anonymous", + "subComponents" : { }, + "config" : { + "allow-default-scopes" : [ "true" ] + } + }, { + "id" : "5c5f2f31-f7d9-4276-96a8-ab18d75d6d40", + "name" : "Allowed Protocol Mapper Types", + "providerId" : "allowed-protocol-mappers", + "subType" : "anonymous", + "subComponents" : { }, + "config" : { + "allowed-protocol-mapper-types" : [ "saml-user-attribute-mapper", "oidc-usermodel-property-mapper", "saml-user-property-mapper", "oidc-full-name-mapper", "oidc-address-mapper", "oidc-usermodel-attribute-mapper", "oidc-sha256-pairwise-sub-mapper", "saml-role-list-mapper" ] + } + } ], + "org.keycloak.keys.KeyProvider" : [ { + "id" : "c7481f9f-0d25-4399-87fb-cd6ca77c98a0", + "name" : "rsa-generated", + "providerId" : "rsa-generated", + "subComponents" : { }, + "config" : { + "privateKey" : [ "MIIEowIBAAKCAQEAnSnYxW3Npy1y7XQccmo9bEUm1G0zWM6ldVkpeQ4egiRNfPXHjyOI7WIprkubkfsBj0F9SYRLiyvVJC8El61sXWWKWARmv4AD3zGSjIZh4FTFu6KFp6RHf/TLUwcxCJe/2wKhwAhj9G6dy5eNSaLr0Fbn0eWwXV0AnkvmBZod0o3A421ODZlby4Fp8Rscvnb0KNraS8v8pVewIFZ+kimaZ5fxv11h894kdqV1OSPc6bTfkyO4pQkEnPnIvEywjZbIl+2WhUvzZkTOmF1JlhcRn9FywsO1kUsqox6V6O5XvbPbgG53arVx96Mf+9goI7W1c3zNiLXdO5pGQIDN8+HC4QIDAQABAoIBACtYbkPNS+nuvALHgk0ABh7FV7dAwuecXr/lrm2HulxUXNa5BqfwugQWjb5XdfmmC8ER49cR2K/yj99h5Fdc6kU8CxLJa/km+mplRrDhIz92we5FHa2lvl6JCkbE9f4TtENYD3piFgdFNtn+22XSvE0Cmv8l5SVq0A/YiQFEhzMZnNJ8AiJEhU7/s8Fj7SsPOfBSPHE1P20TfVeCI96kv3g3H+xOq80zCBeeR6bUS8SqOtj8ZVoDQMLdSNKenMCgtTaAWvMhsXdlHvxh2g3vF20n57fF7ak39/ClXTMiMJXsMOjWGMIh6f3frbZ8E+j4YtcLHAee3ns4/tbHZOW1yZ0CgYEAyntkA3zMVhu/DFDYanGo6qW8AFeonayhzsv/TBgqlfRW3rAb0XlAWIyzOgq1c0c6r8FUx8HfxoksZlFfB3NpPYd/4uo5gm7x3+nZFfSsBWgtPUihf4ab3hh6FDs1SPmpglW+Bno/Auq1hs//QBuwZS7G8uXp1AXzSiRcniIj78sCgYEAxrQNeY4koK5tgNWeKzKGyDZIWlnc24hIu4rDU/KAjW/yHNN6nLtjGZ5AtKhc9IFn/nUtcoDU4B3xR0hHa/TPEA3B/p8SNMkPAA2GiE0d3gcSM8D0ZrC2DXbPT1mEX+B7uifxBFjD4F+TOo8JA2E7CYugUy7NQKhBFGOMiCAcaoMCgYEAxzqJufS9iaxbWt7hUjrrnZXdWejme940h6mpVVIh9NIp94sIlB/d9ELcxqtqxja7w9tSdAqLCGpISZSfEFG6p1P/vWIBnBlV3J/Xfgb0i41plfc1EKl+DBXBaM6pK1icNSXwh6cZAOG4IyHdYVLdSXGxR6Z5YKlKLRWCHAYznekCgYBT1fX1em6jyNR0zixs52WMpbKDRHT1vxuI3TQqgB+TDU9msCeEZ1+ZmHaOgpatpse8ya3CKO8oHBoHzEwuFV0j1doq1uy0jrwgdpRzf64BVpRsd5XmmdpF9gHj5c3/MdSiJ2X+QoFqcojI5T6VSXnCPkIHtrBs/lBvDM1nRb0XhwKBgDiyrcGGv3eevvx/xQKZkw8BK+YtEc81C52YjVKHSZ7wLMWA+hKDv6ls2fR51Thll1GnIC12iDH0ES+ulr1NJ/90XCA5HGwuVz6TjxmldFe066wCap6k7v6sJlY0UlBMWyLUvSNZBHcVYH9OLa+zEFiX0hoR3IWBwdj4tIveKrei" ], + "keyUse" : [ "SIG" ], + "certificate" : [ "MIIClzCCAX8CBgGWPnnAvjANBgkqhkiG9w0BAQsFADAPMQ0wCwYDVQQDDAR0ZXN0MB4XDTI1MDQxNjExNTk0OFoXDTM1MDQxNjEyMDEyOFowDzENMAsGA1UEAwwEdGVzdDCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAJ0p2MVtzactcu10HHJqPWxFJtRtM1jOpXVZKXkOHoIkTXz1x48jiO1iKa5Lm5H7AY9BfUmES4sr1SQvBJetbF1lilgEZr+AA98xkoyGYeBUxbuihaekR3/0y1MHMQiXv9sCocAIY/RuncuXjUmi69BW59HlsF1dAJ5L5gWaHdKNwONtTg2ZW8uBafEbHL529Cja2kvL/KVXsCBWfpIpmmeX8b9dYfPeJHaldTkj3Om035MjuKUJBJz5yLxMsI2WyJftloVL82ZEzphdSZYXEZ/RcsLDtZFLKqMelejuV72z24Bud2q1cfejH/vYKCO1tXN8zYi13TuaRkCAzfPhwuECAwEAATANBgkqhkiG9w0BAQsFAAOCAQEAWpvrgepMfJeQBSh+6Ifpe6olWIORLkzJ13Xhv/fjbFk4vH0mb9UoG5qF53T3M2TzTF9B0Rp47nie26lPCRcuYoVRux5MH5lzU6Toge/rE620J93/6jWX+dTsYW/0lFF9/lBWNmwr2xe9lxGSvDygtxoWr8ruAzdH24Se0Deo+HJk6YEHryOrvNg/e/MMEilSTv2rOG/CzQKK8Webu5zNj6x8vqJM82P0tlMgv40aDVoLPSu7pQf6Hj3Skz8knc1U6gV4JcBO602Pif5w/axk8oCzWjw1ut9tDNE4m0VB/uNMkU3oDCC0Zwfm0GPJBKGyl6ZQ4sMkT/M2DjaBQfvP1Q==" ], + "priority" : [ "100" ] + } + }, { + "id" : "2f871868-4ce3-48de-9929-fc59cf008fe7", + "name" : "aes-generated", + "providerId" : "aes-generated", + "subComponents" : { }, + "config" : { + "kid" : [ "d586998a-a144-493a-9eda-f791d88fe613" ], + "secret" : [ "M0aIVcP2VTSW7vFhG_fDog" ], + "priority" : [ "100" ] + } + }, { + "id" : "75438b30-2cfa-44d2-ac7b-d7195c875bfc", + "name" : "hmac-generated-hs512", + "providerId" : "hmac-generated", + "subComponents" : { }, + "config" : { + "kid" : [ "a18428cf-f714-4fb1-9263-247dfa4c17b6" ], + "secret" : [ "0Lce2dkRLmzsj5t6K-bE7SmBtOGAGBzP6UM7B3w0g7VXiYRPYGvNQFXWq-36v_En5IRTULMZWNnPGfFuZkQkq4JrK1jqK25jeL77SWCnoQvdJl9mT7fLSj_-5kx3YRkSsTxJNo3zivDNTeIssoySg9u3Gk0ycjnp5FopkCS_ldE" ], + "priority" : [ "100" ], + "algorithm" : [ "HS512" ] + } + }, { + "id" : "62755f35-490a-43ce-ad5f-dc0f8850351b", + "name" : "rsa-enc-generated", + "providerId" : "rsa-enc-generated", + "subComponents" : { }, + "config" : { + "privateKey" : [ "MIIEpQIBAAKCAQEAsEqc3bbbmK/qAzTZVwq+gV57oaAaDph2S+FPRt5qRbV8ZOCALk4w6NOn18kUcMP6kuDymOq6x8Nm4uZTu5SXzDzoEehclPjlPvlFA2Elw+Ik9ZtfYZaBrqDxWAq4q6m10SP88IaGA9Lh5d5+EcA/FUJMwwdtPiH1F7b6os8oNwMewOCs85B8r8hBK4xXG1lWJViJ112YK1Qt6uOn/2p6e5tNaRDLMTQ1ETt39i1cMnuw9pm3Uu23DdnycgQb/MSTQgYPf9rOH3Hn7fD8NhkRP/u3fJFl2a5giZAAqhZl7mHgK/Jsb+vGDbfCpDaVfvHcLudUHhwYbf431RvKTa/OuQIDAQABAoIBAAGWooQy5hahmyOtQboRjDbhMY76wNFZ2VMEtDCox19aa8UC6tS/+pvWcGA23RrJAUR6h2UOVGGBZrdrqNx7UcTS1ap3pAHpnjMrjs4hfXQe4QNfg4P/FasLozEOY6yUSmGYh+po4+M77rIiB5PEXi0kXEmzku3o42rzyJ1X7X5VYoRP0303tqZHQyqt5fsD8TVWRjMPtUczSGAcllflNHexIb7knBzYedvhiMdsu3ItDD01xcKt6Owx52yqdPrRzuwveV+qb2cxqjGhPT3xQiHB6lezGabL/6CZBS/Du7ADIUdCKH6ulNzDEA4dltf6KyszX3XB8/BMzXTPQ+9PQQECgYEA6kfDzROaCVtBw30IT1pEfKKMcvqsLo4wFqQpz41TY7i4xPwTAADCbc8uEAVjcpasjzOnVHRpLy84E0Kei/CfIIKW02130apIT+Ct4CpQlrksISfWYK3yejYEgnjoQA5cz30MfCZ1Iv3yd4kyv6az1YedUsh0INKExEpMxzYmcfkCgYEAwKKVRABjwgUCuKrNcco4Fd4QI0n7na1fPCwUeROPPIXuQ+rHKpXaK66yuovFap+2rJisKr9yRzpmNaTvXMVbGeBteZKT8f82boWYkhq9ZDFigsWwrhNkJH8M/tPKBed4CqmBruSiZ4TbRBd78OlchtGKUJ05+2ZDJhu6h7hLcsECgYEA3ZnAJSzTWOJO1EBiKdzyRwnh26gsUWUBK4lgWwgMxpilfP4KYshVIFUF9vWB2ZOX6WQsdIAgNhdt7RnoqemSOsgLLjWvTkzJVXTqQs0DqW3BxiLObmhaoSqTHW6MEHsFYuWfd5dQ2SZnwJWvwQRHukQqlXEyFxHJr3mwIgagWtECgYEAnWp+1cIHwz36+lNBbZJVgLEluOC1SCWsJGzVEhgEve2oRkHuHYO1dGrfTQf4/GeljKd6Ubh+t2wmqAGvRL1V8/BtJaK9WU03+tsbUZGeYOjmWn0YIzhfZl+YjAkgFvEPLI9WFUhq2nM8Bwm106mvXdCP2c6R2jm398VDCbN1nEECgYEAhSvLDtOthHGeE2RBOir15XJi+UjNncncyGrr54MF2K2JIT4cv3Y92AMRJhz0k43k4XQbXv5rLwxnzgEk7sLk3f53CPik95Q78ll8ZvwZyMz5CsV8HjeeGcQxoFqzxwOKFTUcgGnfUnSNlL6T25/cOHuVydqwX7a0NCd3+5YV/8I=" ], + "keyUse" : [ "ENC" ], + "certificate" : [ "MIIClzCCAX8CBgGWPnnBCjANBgkqhkiG9w0BAQsFADAPMQ0wCwYDVQQDDAR0ZXN0MB4XDTI1MDQxNjExNTk0OFoXDTM1MDQxNjEyMDEyOFowDzENMAsGA1UEAwwEdGVzdDCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBALBKnN2225iv6gM02VcKvoFee6GgGg6YdkvhT0beakW1fGTggC5OMOjTp9fJFHDD+pLg8pjqusfDZuLmU7uUl8w86BHoXJT45T75RQNhJcPiJPWbX2GWga6g8VgKuKuptdEj/PCGhgPS4eXefhHAPxVCTMMHbT4h9Re2+qLPKDcDHsDgrPOQfK/IQSuMVxtZViVYidddmCtULerjp/9qenubTWkQyzE0NRE7d/YtXDJ7sPaZt1Lttw3Z8nIEG/zEk0IGD3/azh9x5+3w/DYZET/7t3yRZdmuYImQAKoWZe5h4CvybG/rxg23wqQ2lX7x3C7nVB4cGG3+N9Ubyk2vzrkCAwEAATANBgkqhkiG9w0BAQsFAAOCAQEAWKQx3QX3eR6KhkUE6NhhjNNbPcaIYE1/pcpeCxFvW6s4Awtmm8hmYHO3wlC7q+4JdJiq2vo2exphIUWyzGl0NS2j1RaLA2BRyP2jKFLPIsF3HIGg8lBcswXKNcqzqunHg//PGoKmzPjuGQylzeZbObMCkbdoMfbv4t0o6QUbpAbWZ1l8/7W+rimURTPP0mgUMPkIR4pnU9uItwb9pDqtFUvIxxd1rqleUQ9dfXUTCq/Ec0txnApv7MQVD601tRWIbVXyUKQWirIK9QsbW8Izjs3MBZ6dZo/S1ec7cgDMEiw8OgXNlm7TSRADJ5C1I+WVehQd3+DSEA4WLbamT6yhiA==" ], + "priority" : [ "100" ], + "algorithm" : [ "RSA-OAEP" ] + } + } ] + }, + "internationalizationEnabled" : false, + "supportedLocales" : [ ], + "authenticationFlows" : [ { + "id" : "0620c000-55d6-4297-83a4-29fb811bf31a", + "alias" : "Account verification options", + "description" : "Method with which to verity the existing account", + "providerId" : "basic-flow", + "topLevel" : false, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticator" : "idp-email-verification", + "authenticatorFlow" : false, + "requirement" : "ALTERNATIVE", + "priority" : 10, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticatorFlow" : true, + "requirement" : "ALTERNATIVE", + "priority" : 20, + "autheticatorFlow" : true, + "flowAlias" : "Verify Existing Account by Re-authentication", + "userSetupAllowed" : false + } ] + }, { + "id" : "9eb72380-8b37-46ef-b97a-266ad6144a28", + "alias" : "Browser - Conditional OTP", + "description" : "Flow to determine if the OTP is required for the authentication", + "providerId" : "basic-flow", + "topLevel" : false, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticator" : "conditional-user-configured", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 10, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticator" : "auth-otp-form", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 20, + "autheticatorFlow" : false, + "userSetupAllowed" : false + } ] + }, { + "id" : "3512ba71-d34f-429f-97c6-b633c93ec667", + "alias" : "Browser - Conditional Organization", + "description" : "Flow to determine if the organization identity-first login is to be used", + "providerId" : "basic-flow", + "topLevel" : false, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticator" : "conditional-user-configured", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 10, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticator" : "organization", + "authenticatorFlow" : false, + "requirement" : "ALTERNATIVE", + "priority" : 20, + "autheticatorFlow" : false, + "userSetupAllowed" : false + } ] + }, { + "id" : "407f6fde-7273-4248-9781-15d1be7810b4", + "alias" : "Direct Grant - Conditional OTP", + "description" : "Flow to determine if the OTP is required for the authentication", + "providerId" : "basic-flow", + "topLevel" : false, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticator" : "conditional-user-configured", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 10, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticator" : "direct-grant-validate-otp", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 20, + "autheticatorFlow" : false, + "userSetupAllowed" : false + } ] + }, { + "id" : "f5250e54-461b-4225-92fd-2337de0f6005", + "alias" : "First Broker Login - Conditional Organization", + "description" : "Flow to determine if the authenticator that adds organization members is to be used", + "providerId" : "basic-flow", + "topLevel" : false, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticator" : "conditional-user-configured", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 10, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticator" : "idp-add-organization-member", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 20, + "autheticatorFlow" : false, + "userSetupAllowed" : false + } ] + }, { + "id" : "fcb5ee37-cded-47bd-a078-5633d9fcaa57", + "alias" : "First broker login - Conditional OTP", + "description" : "Flow to determine if the OTP is required for the authentication", + "providerId" : "basic-flow", + "topLevel" : false, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticator" : "conditional-user-configured", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 10, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticator" : "auth-otp-form", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 20, + "autheticatorFlow" : false, + "userSetupAllowed" : false + } ] + }, { + "id" : "76091fc6-1521-4b44-b29b-3435999229d7", + "alias" : "Handle Existing Account", + "description" : "Handle what to do if there is existing account with same email/username like authenticated identity provider", + "providerId" : "basic-flow", + "topLevel" : false, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticator" : "idp-confirm-link", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 10, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticatorFlow" : true, + "requirement" : "REQUIRED", + "priority" : 20, + "autheticatorFlow" : true, + "flowAlias" : "Account verification options", + "userSetupAllowed" : false + } ] + }, { + "id" : "344643c9-1447-4f00-ac02-c3d66aee834d", + "alias" : "Organization", + "providerId" : "basic-flow", + "topLevel" : false, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticatorFlow" : true, + "requirement" : "CONDITIONAL", + "priority" : 10, + "autheticatorFlow" : true, + "flowAlias" : "Browser - Conditional Organization", + "userSetupAllowed" : false + } ] + }, { + "id" : "7c7ab0b1-5f2d-493d-947e-4cbf24d715d6", + "alias" : "Reset - Conditional OTP", + "description" : "Flow to determine if the OTP should be reset or not. Set to REQUIRED to force.", + "providerId" : "basic-flow", + "topLevel" : false, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticator" : "conditional-user-configured", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 10, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticator" : "reset-otp", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 20, + "autheticatorFlow" : false, + "userSetupAllowed" : false + } ] + }, { + "id" : "274c10eb-36a7-474a-abc8-9274c50a6016", + "alias" : "User creation or linking", + "description" : "Flow for the existing/non-existing user alternatives", + "providerId" : "basic-flow", + "topLevel" : false, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticatorConfig" : "create unique user config", + "authenticator" : "idp-create-user-if-unique", + "authenticatorFlow" : false, + "requirement" : "ALTERNATIVE", + "priority" : 10, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticatorFlow" : true, + "requirement" : "ALTERNATIVE", + "priority" : 20, + "autheticatorFlow" : true, + "flowAlias" : "Handle Existing Account", + "userSetupAllowed" : false + } ] + }, { + "id" : "da5a2ea9-4df2-49d6-964d-2e08d7efa869", + "alias" : "Verify Existing Account by Re-authentication", + "description" : "Reauthentication of existing account", + "providerId" : "basic-flow", + "topLevel" : false, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticator" : "idp-username-password-form", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 10, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticatorFlow" : true, + "requirement" : "CONDITIONAL", + "priority" : 20, + "autheticatorFlow" : true, + "flowAlias" : "First broker login - Conditional OTP", + "userSetupAllowed" : false + } ] + }, { + "id" : "8a48643d-e66e-4f15-843a-0f336ffe24c0", + "alias" : "browser", + "description" : "Browser based authentication", + "providerId" : "basic-flow", + "topLevel" : true, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticator" : "auth-cookie", + "authenticatorFlow" : false, + "requirement" : "ALTERNATIVE", + "priority" : 10, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticator" : "auth-spnego", + "authenticatorFlow" : false, + "requirement" : "DISABLED", + "priority" : 20, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticator" : "identity-provider-redirector", + "authenticatorFlow" : false, + "requirement" : "ALTERNATIVE", + "priority" : 25, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticatorFlow" : true, + "requirement" : "ALTERNATIVE", + "priority" : 26, + "autheticatorFlow" : true, + "flowAlias" : "Organization", + "userSetupAllowed" : false + }, { + "authenticatorFlow" : true, + "requirement" : "ALTERNATIVE", + "priority" : 30, + "autheticatorFlow" : true, + "flowAlias" : "forms", + "userSetupAllowed" : false + } ] + }, { + "id" : "067a99b0-93c9-4df0-a60f-894767571e15", + "alias" : "clients", + "description" : "Base authentication for clients", + "providerId" : "client-flow", + "topLevel" : true, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticator" : "client-secret", + "authenticatorFlow" : false, + "requirement" : "ALTERNATIVE", + "priority" : 10, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticator" : "client-jwt", + "authenticatorFlow" : false, + "requirement" : "ALTERNATIVE", + "priority" : 20, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticator" : "client-secret-jwt", + "authenticatorFlow" : false, + "requirement" : "ALTERNATIVE", + "priority" : 30, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticator" : "client-x509", + "authenticatorFlow" : false, + "requirement" : "ALTERNATIVE", + "priority" : 40, + "autheticatorFlow" : false, + "userSetupAllowed" : false + } ] + }, { + "id" : "b65867de-ba79-40d8-8b42-64f1b170a3f0", + "alias" : "direct grant", + "description" : "OpenID Connect Resource Owner Grant", + "providerId" : "basic-flow", + "topLevel" : true, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticator" : "direct-grant-validate-username", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 10, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticator" : "direct-grant-validate-password", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 20, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticatorFlow" : true, + "requirement" : "CONDITIONAL", + "priority" : 30, + "autheticatorFlow" : true, + "flowAlias" : "Direct Grant - Conditional OTP", + "userSetupAllowed" : false + } ] + }, { + "id" : "66b14857-1092-45fe-949d-40af91ab80e2", + "alias" : "docker auth", + "description" : "Used by Docker clients to authenticate against the IDP", + "providerId" : "basic-flow", + "topLevel" : true, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticator" : "docker-http-basic-authenticator", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 10, + "autheticatorFlow" : false, + "userSetupAllowed" : false + } ] + }, { + "id" : "067f7472-9ac2-4a9e-a330-a4c3c2bd9b60", + "alias" : "first broker login", + "description" : "Actions taken after first broker login with identity provider account, which is not yet linked to any Keycloak account", + "providerId" : "basic-flow", + "topLevel" : true, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticatorConfig" : "review profile config", + "authenticator" : "idp-review-profile", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 10, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticatorFlow" : true, + "requirement" : "REQUIRED", + "priority" : 20, + "autheticatorFlow" : true, + "flowAlias" : "User creation or linking", + "userSetupAllowed" : false + }, { + "authenticatorFlow" : true, + "requirement" : "CONDITIONAL", + "priority" : 50, + "autheticatorFlow" : true, + "flowAlias" : "First Broker Login - Conditional Organization", + "userSetupAllowed" : false + } ] + }, { + "id" : "1481c1d1-08c1-4dcf-947f-33e7e9336ef7", + "alias" : "forms", + "description" : "Username, password, otp and other auth forms.", + "providerId" : "basic-flow", + "topLevel" : false, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticator" : "auth-username-password-form", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 10, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticatorFlow" : true, + "requirement" : "CONDITIONAL", + "priority" : 20, + "autheticatorFlow" : true, + "flowAlias" : "Browser - Conditional OTP", + "userSetupAllowed" : false + } ] + }, { + "id" : "64d969f4-baf9-446b-9ba1-b36721711594", + "alias" : "registration", + "description" : "Registration flow", + "providerId" : "basic-flow", + "topLevel" : true, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticator" : "registration-page-form", + "authenticatorFlow" : true, + "requirement" : "REQUIRED", + "priority" : 10, + "autheticatorFlow" : true, + "flowAlias" : "registration form", + "userSetupAllowed" : false + } ] + }, { + "id" : "e4c76812-79ae-4237-b7d6-4809a43fda16", + "alias" : "registration form", + "description" : "Registration form", + "providerId" : "form-flow", + "topLevel" : false, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticator" : "registration-user-creation", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 20, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticator" : "registration-password-action", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 50, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticator" : "registration-recaptcha-action", + "authenticatorFlow" : false, + "requirement" : "DISABLED", + "priority" : 60, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticator" : "registration-terms-and-conditions", + "authenticatorFlow" : false, + "requirement" : "DISABLED", + "priority" : 70, + "autheticatorFlow" : false, + "userSetupAllowed" : false + } ] + }, { + "id" : "d3f0087b-4e9b-45f9-9138-f965a80e2474", + "alias" : "reset credentials", + "description" : "Reset credentials for a user if they forgot their password or something", + "providerId" : "basic-flow", + "topLevel" : true, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticator" : "reset-credentials-choose-user", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 10, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticator" : "reset-credential-email", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 20, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticator" : "reset-password", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 30, + "autheticatorFlow" : false, + "userSetupAllowed" : false + }, { + "authenticatorFlow" : true, + "requirement" : "CONDITIONAL", + "priority" : 40, + "autheticatorFlow" : true, + "flowAlias" : "Reset - Conditional OTP", + "userSetupAllowed" : false + } ] + }, { + "id" : "c7f62cee-a5ed-42b4-bcc5-11beeaf1ac02", + "alias" : "saml ecp", + "description" : "SAML ECP Profile Authentication Flow", + "providerId" : "basic-flow", + "topLevel" : true, + "builtIn" : true, + "authenticationExecutions" : [ { + "authenticator" : "http-basic-authenticator", + "authenticatorFlow" : false, + "requirement" : "REQUIRED", + "priority" : 10, + "autheticatorFlow" : false, + "userSetupAllowed" : false + } ] + } ], + "authenticatorConfig" : [ { + "id" : "b99be709-8dec-412c-89d3-226bfbaeb65a", + "alias" : "create unique user config", + "config" : { + "require.password.update.after.registration" : "false" + } + }, { + "id" : "7c5ca9a1-4681-46c6-af34-cad7175f621c", + "alias" : "review profile config", + "config" : { + "update.profile.on.first.login" : "missing" + } + } ], + "requiredActions" : [ { + "alias" : "CONFIGURE_TOTP", + "name" : "Configure OTP", + "providerId" : "CONFIGURE_TOTP", + "enabled" : true, + "defaultAction" : false, + "priority" : 10, + "config" : { } + }, { + "alias" : "TERMS_AND_CONDITIONS", + "name" : "Terms and Conditions", + "providerId" : "TERMS_AND_CONDITIONS", + "enabled" : false, + "defaultAction" : false, + "priority" : 20, + "config" : { } + }, { + "alias" : "UPDATE_PASSWORD", + "name" : "Update Password", + "providerId" : "UPDATE_PASSWORD", + "enabled" : true, + "defaultAction" : false, + "priority" : 30, + "config" : { } + }, { + "alias" : "UPDATE_PROFILE", + "name" : "Update Profile", + "providerId" : "UPDATE_PROFILE", + "enabled" : true, + "defaultAction" : false, + "priority" : 40, + "config" : { } + }, { + "alias" : "VERIFY_EMAIL", + "name" : "Verify Email", + "providerId" : "VERIFY_EMAIL", + "enabled" : true, + "defaultAction" : false, + "priority" : 50, + "config" : { } + }, { + "alias" : "delete_account", + "name" : "Delete Account", + "providerId" : "delete_account", + "enabled" : false, + "defaultAction" : false, + "priority" : 60, + "config" : { } + }, { + "alias" : "webauthn-register", + "name" : "Webauthn Register", + "providerId" : "webauthn-register", + "enabled" : true, + "defaultAction" : false, + "priority" : 70, + "config" : { } + }, { + "alias" : "webauthn-register-passwordless", + "name" : "Webauthn Register Passwordless", + "providerId" : "webauthn-register-passwordless", + "enabled" : true, + "defaultAction" : false, + "priority" : 80, + "config" : { } + }, { + "alias" : "VERIFY_PROFILE", + "name" : "Verify Profile", + "providerId" : "VERIFY_PROFILE", + "enabled" : true, + "defaultAction" : false, + "priority" : 90, + "config" : { } + }, { + "alias" : "delete_credential", + "name" : "Delete Credential", + "providerId" : "delete_credential", + "enabled" : true, + "defaultAction" : false, + "priority" : 100, + "config" : { } + }, { + "alias" : "update_user_locale", + "name" : "Update User Locale", + "providerId" : "update_user_locale", + "enabled" : true, + "defaultAction" : false, + "priority" : 1000, + "config" : { } + } ], + "browserFlow" : "browser", + "registrationFlow" : "registration", + "directGrantFlow" : "direct grant", + "resetCredentialsFlow" : "reset credentials", + "clientAuthenticationFlow" : "clients", + "dockerAuthenticationFlow" : "docker auth", + "firstBrokerLoginFlow" : "first broker login", + "attributes" : { + "cibaBackchannelTokenDeliveryMode" : "poll", + "cibaExpiresIn" : "120", + "cibaAuthRequestedUserHint" : "login_hint", + "oauth2DeviceCodeLifespan" : "600", + "oauth2DevicePollingInterval" : "5", + "parRequestUriLifespan" : "60", + "cibaInterval" : "5", + "realmReusableOtpCode" : "false" + }, + "keycloakVersion" : "26.0.6", + "userManagedAccessAllowed" : false, + "organizationsEnabled" : false, + "clientProfiles" : { + "profiles" : [ ] + }, + "clientPolicies" : { + "policies" : [ ] + } +} \ No newline at end of file diff --git a/nix/services/keycloak_test.nix b/nix/services/keycloak_test.nix new file mode 100644 index 00000000..16585586 --- /dev/null +++ b/nix/services/keycloak_test.nix @@ -0,0 +1,47 @@ +{ pkgs, config, ... }: +{ + services.keycloak.k1 = { + enable = true; + settings.http-port = 8089; + + database.type = "dev-file"; + + realms = { + master = { + path = "./realms/master.json"; + export = true; + import = false; + }; + + test = { + path = "./keycloak/test-realms/realms/test.json"; + import = true; + export = true; + }; + }; + }; + + settings.processes.test = + let + cfg = config.services.keycloak."k1"; + in + { + command = pkgs.writeShellApplication { + runtimeInputs = [ + cfg.package + pkgs.gnugrep + pkgs.curl + pkgs.uutils-coreutils-noprefix + pkgs.jq + ]; + text = " + # TODO: Realm export tests were removed because the H2 embedded database + # (dev-file) holds a file lock that isn't reliably released by the time the + # export JVM starts. Consider re-adding export tests with a PostgreSQL backend. + "; + name = "keycloak-test"; + }; + + depends_on."k1".condition = "process_healthy"; + }; +} diff --git a/test/flake.nix b/test/flake.nix index bd104f51..ed07b195 100644 --- a/test/flake.nix +++ b/test/flake.nix @@ -91,6 +91,8 @@ # ] "${inputs.services-flake}/nix/services/open-webui_test.nix" "${inputs.services-flake}/nix/services/seaweedfs_test.nix" # Darwin build fixed in https://github.com/NixOS/nixpkgs/pull/534897 + "${inputs.services-flake}/nix/services/keycloak_test.nix" + "${inputs.services-flake}/nix/services/keycloak-certs_test.nix" ] # Tests on non-linux host only ++ lib.optionals (!pkgs.stdenv.hostPlatform.isLinux) [ From 5d17919b51f12e6e153cf20098475830eb51dc2d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20N=C3=BCtzi?= Date: Wed, 15 Jul 2026 08:57:24 +0200 Subject: [PATCH 02/16] fix: basic tests work --- nix/services/default.nix | 81 ++++++++++++++-------------- nix/services/keycloak-certs_test.nix | 15 +++--- nix/services/keycloak/options.nix | 35 ++++-------- nix/services/keycloak/service.nix | 53 +++++++++--------- nix/services/keycloak_test.nix | 6 +-- 5 files changed, 89 insertions(+), 101 deletions(-) diff --git a/nix/services/default.nix b/nix/services/default.nix index 58c82bc9..5cec4953 100644 --- a/nix/services/default.nix +++ b/nix/services/default.nix @@ -2,44 +2,47 @@ let inherit (import ../lib.nix) multiService; in { - imports = (builtins.map multiService [ - ./apache-kafka.nix - ./azurite.nix - ./clickhouse - ./dynamodb-local.nix - ./elasticmq.nix - ./elasticsearch.nix - ./mongodb.nix - ./mysql - ./nginx - ./ollama.nix - ./postgres - ./open-webui.nix - ./plantuml.nix - ./redis-cluster.nix - ./redis.nix - ./seaweedfs.nix - ./zookeeper.nix - ./grafana.nix - ./memcached.nix - ./minio.nix - ./nats-server.nix - ./prometheus.nix - ./pgadmin.nix - ./cassandra.nix - ./pyroscope.nix - ./tempo.nix - ./weaviate.nix - ./searxng.nix - ./tika.nix - ./loki.nix - ./phpfpm.nix - ./pubsub-emulator.nix - ./qdrant.nix - ./chromadb.nix - ./neo4j.nix - ]) ++ [ - ./devshell.nix - ]; + imports = + (map multiService [ + ./apache-kafka.nix + ./azurite.nix + ./clickhouse + ./dynamodb-local.nix + ./elasticmq.nix + ./elasticsearch.nix + ./mongodb.nix + ./mysql + ./nginx + ./ollama.nix + ./postgres + ./open-webui.nix + ./plantuml.nix + ./redis-cluster.nix + ./redis.nix + ./seaweedfs.nix + ./zookeeper.nix + ./grafana.nix + ./memcached.nix + ./minio.nix + ./nats-server.nix + ./prometheus.nix + ./pgadmin.nix + ./cassandra.nix + ./pyroscope.nix + ./tempo.nix + ./weaviate.nix + ./searxng.nix + ./tika.nix + ./loki.nix + ./phpfpm.nix + ./pubsub-emulator.nix + ./qdrant.nix + ./chromadb.nix + ./neo4j.nix + ./keycloak.nix + ]) + ++ [ + ./devshell.nix + ]; } diff --git a/nix/services/keycloak-certs_test.nix b/nix/services/keycloak-certs_test.nix index 8b8cb894..91679e9c 100644 --- a/nix/services/keycloak-certs_test.nix +++ b/nix/services/keycloak-certs_test.nix @@ -1,8 +1,8 @@ { pkgs, config, ... }: { - services.keycloak.k1 = { + services.keycloak.k1-certs = { enable = true; - settings.http-port = 8089; + settings.http-port = 8090; database.type = "dev-file"; @@ -11,13 +11,13 @@ realms = { master = { - path = "./realms/master.json"; + path = ./keycloak/test-realms/master.json; export = true; import = false; }; test = { - path = "./keycloak/test-realms/realms/test.json"; + path = ./keycloak/test-realms/test.json; import = true; export = true; }; @@ -26,7 +26,7 @@ settings.processes.test = let - cfg = config.services.keycloak."k1"; + cfg = config.services.keycloak.k1-certs; in { command = pkgs.writeShellApplication { @@ -42,10 +42,9 @@ # (dev-file) holds a file lock that isn't reliably released by the time the # export JVM starts. Consider re-adding export tests with a PostgreSQL backend. "; - name = "keycloak-test"; + name = "k1-certs-tests"; }; - depends_on."k1".condition = "process_healthy"; + depends_on."k1-certs".condition = "process_healthy"; }; } -} diff --git a/nix/services/keycloak/options.nix b/nix/services/keycloak/options.nix index 4b2d4afd..64242501 100644 --- a/nix/services/keycloak/options.nix +++ b/nix/services/keycloak/options.nix @@ -7,7 +7,7 @@ }: let - cfg = config.services.keycloak; + cfg = config; hasRealmExports = lib.any (lib.mapAttrsToList (realmName: opts: opts.export.enable) cfg.realms); @@ -19,23 +19,6 @@ let in { options = { - enable = mkOption { - type = types.bool; - default = false; - example = true; - description = '' - Whether to enable the Keycloak identity and access management - server. - ''; - }; - dataDir = mkOption { - type = types.str; - default = "./data"; - description = '' - Base directory where keycloak stores its data `/keycloak`. - ''; - }; - sslCertificate = mkOption { type = types.nullOr ( lib.types.pathWith { @@ -143,17 +126,21 @@ in options = { path = mkOption { type = types.nullOr ( - lib.types.pathWith { - inStore = false; - absolute = false; - } + # A relative, user-provided path. + lib.types.either + (lib.types.pathWith { + inStore = false; + absolute = false; + }) + # A nix store path. + (lib.types.pathWith { inStore = true; }) ); default = null; example = "./realms/a.json"; description = '' - The path (string, relative to `DEVENV_ROOT`) where you want to import (or export) this realm «name» to. + The path (string, relative to `config.dataDir`) where you want to import (or export) this realm «name» to. If not set and `import` is `true` this realm is not imported. - If not set and `export` is `true` its exported to `$DEVENV_STATE/keycloak/realm-export/«name».json`. + If not set and `export` is `true` its exported to `''${config.dataDir}/keycloak/realm-export/«name».json`. ''; }; diff --git a/nix/services/keycloak/service.nix b/nix/services/keycloak/service.nix index 9d6f37eb..c7c55e82 100644 --- a/nix/services/keycloak/service.nix +++ b/nix/services/keycloak/service.nix @@ -5,7 +5,7 @@ , ... }: let - cfg = config.services.keycloak; + cfg = config; isSecret = v: lib.isAttrs v && v ? _secret && lib.isString v._secret; @@ -77,7 +77,7 @@ let ( realm: e: let - f = config.env.DEVENV_ROOT + "/" + e.path; + f = e.path; in '' echo "Symlinking realm file '${f}' to import path '$KC_HOME_DIR/data/import'." @@ -128,8 +128,8 @@ let realm: e: let file = - if e.path == null then - (config.env.DEVENV_STATE + "/keycloak/realm-export/${realm}.json") + if (e.path == null || lib.isStorePath e.path) then + (config.dataDir + "/keycloak/realm-export/${realm}.json") else e.path; in @@ -154,11 +154,10 @@ let ${pkgs.curl}/bin/curl -k --head -fsS "https://localhost:${toString cfg.settings.http-management-port}${lib.removeSuffix "/" cfg.settings.http-management-relative-path}/health/ready" ''; - dataDir = "./" + cfg.dataDir; keycloakEnv = { - KC_HOME_DIR = dataDir + "/keycloak"; - KC_CONF_DIR = dataDir + "/keycloak/conf"; - KC_TMP_DIR = dataDir + "/keycloak/tmp"; + KC_HOME_DIR = cfg.dataDir + "/keycloak"; + KC_CONF_DIR = cfg.dataDir + "/keycloak/conf"; + KC_TMP_DIR = cfg.dataDir + "/keycloak/tmp"; KC_BOOTSTRAP_ADMIN_USERNAME = "admin"; KC_BOOTSTRAP_ADMIN_PASSWORD = "${lib.escapeShellArg cfg.initialAdminPassword}"; @@ -193,26 +192,26 @@ let ''; in { - outputs = { - # Merge some default values into the freeform options. - services.keycloak.settings = lib.mapAttrs (n: v: lib.mkOptionDefault v) { - # We always enable http since we also use it to check the health. - http-enabled = true; - db = cfg.database.type; - - health-enabled = true; - http-management-relative-path = "/"; - - log-console-level = "info"; - log-level = "info"; - - https-certificate-file = - if providedSSLCerts then cfg.sslCertificate else "${dummyCertificates}/ssl-cert.crt"; - https-certificate-key-file = - if providedSSLCerts then cfg.sslCertificateKey else "${dummyCertificates}/ssl-cert.key"; - }; + # Merge some default values into the freeform options. + settings = lib.mapAttrs (n: v: lib.mkOptionDefault v) { + # We always enable http since we also use it to check the health. + http-enabled = true; + db = cfg.database.type; + + health-enabled = true; + http-management-relative-path = "/"; + + log-console-level = "info"; + log-level = "info"; + + https-certificate-file = + if providedSSLCerts then cfg.sslCertificate else "${dummyCertificates}/ssl-cert.crt"; + https-certificate-key-file = + if providedSSLCerts then cfg.sslCertificateKey else "${dummyCertificates}/ssl-cert.key"; + }; - settings.processes = lib.mkIf cfg.enable { + outputs = { + settings.processes = { ${name} = { environment = keycloakEnv; command = "${lib.getExe keycloak-start}"; diff --git a/nix/services/keycloak_test.nix b/nix/services/keycloak_test.nix index 16585586..ec5da691 100644 --- a/nix/services/keycloak_test.nix +++ b/nix/services/keycloak_test.nix @@ -8,13 +8,13 @@ realms = { master = { - path = "./realms/master.json"; + path = ./keycloak/test-realms/master.json; export = true; import = false; }; test = { - path = "./keycloak/test-realms/realms/test.json"; + path = ./keycloak/test-realms/test.json; import = true; export = true; }; @@ -39,7 +39,7 @@ # (dev-file) holds a file lock that isn't reliably released by the time the # export JVM starts. Consider re-adding export tests with a PostgreSQL backend. "; - name = "keycloak-test"; + name = "k1-tests"; }; depends_on."k1".condition = "process_healthy"; From 11d902ec928e256e704a6a1638ed155039536811 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20N=C3=BCtzi?= Date: Wed, 15 Jul 2026 10:48:27 +0200 Subject: [PATCH 03/16] fix: tests with certificates also works --- nix/services/keycloak-certs_test.nix | 65 ++++++++++----- nix/services/keycloak/options.nix | 11 ++- nix/services/keycloak/service.nix | 24 ++++-- nix/services/keycloak/test-realms/export.nix | 83 ++++++++++++++++++++ nix/services/keycloak_test.nix | 36 ++++----- test/flake.nix | 4 +- 6 files changed, 175 insertions(+), 48 deletions(-) create mode 100644 nix/services/keycloak/test-realms/export.nix diff --git a/nix/services/keycloak-certs_test.nix b/nix/services/keycloak-certs_test.nix index 91679e9c..13fd8b2e 100644 --- a/nix/services/keycloak-certs_test.nix +++ b/nix/services/keycloak-certs_test.nix @@ -1,13 +1,21 @@ { pkgs, config, ... }: +let + name = "k1-certs"; + inherit (config.services.keycloak.${name}) dataDir; + realmSrc = ./keycloak/test-realms/test.json; + + sslCertificate = "./keycloak/test-certs/ssl-cert.crt"; + sslCertificateKey = "./keycloak/test-certs/ssl-cert.key"; +in { - services.keycloak.k1-certs = { + services.keycloak.${name} = { enable = true; settings.http-port = 8090; database.type = "dev-file"; - sslCertificate = "./certs/ssl-cert.crt"; - sslCertificateKey = "./certs/ssl-cert.key"; + # They must not end up in the Nix store. + inherit sslCertificate sslCertificateKey; realms = { master = { @@ -17,34 +25,53 @@ }; test = { - path = ./keycloak/test-realms/test.json; + path = realmSrc; import = true; export = true; }; }; }; + # Copy certificates from the Nix store to correct location (only for tests). + settings.processes.copy-certs = + let + cert = ./keycloak/test-certs/ssl-cert.crt; + certKey = ./keycloak/test-certs/ssl-cert.key; + in + { + command = pkgs.writeShellApplication { + name = "copy-certs"; + text = + # Bash + '' + echo "Copying certificates (pwd: $(pwd))..." + mkdir -p "keycloak/test-certs" + cp "${cert}" "keycloak/test-certs/ssl-cert.crt" + cp "${certKey}" "keycloak/test-certs/ssl-cert.key" + ''; + }; + }; + + settings.processes.${name} = { + depends_on.copy-certs.condition = "process_completed_successfully"; + }; + settings.processes.test = let - cfg = config.services.keycloak.k1-certs; + test-export = pkgs.callPackage ./keycloak/test-realms/export.nix { + process-compose = config.package; + realmDstDir = "${dataDir}/realm-export"; + pcSocketPath = config.cli.options.unix-socket; + keycloak-name = name; + }; in { command = pkgs.writeShellApplication { - runtimeInputs = [ - cfg.package - pkgs.gnugrep - pkgs.curl - pkgs.uutils-coreutils-noprefix - pkgs.jq - ]; - text = " - # TODO: Realm export tests were removed because the H2 embedded database - # (dev-file) holds a file lock that isn't reliably released by the time the - # export JVM starts. Consider re-adding export tests with a PostgreSQL backend. - "; - name = "k1-certs-tests"; + runtimeInputs = [ test-export ]; + text = "test-export"; + name = "${name}-test"; }; - depends_on."k1-certs".condition = "process_healthy"; + depends_on.${name}.condition = "process_healthy"; }; } diff --git a/nix/services/keycloak/options.nix b/nix/services/keycloak/options.nix index 64242501..aa590466 100644 --- a/nix/services/keycloak/options.nix +++ b/nix/services/keycloak/options.nix @@ -138,9 +138,14 @@ in default = null; example = "./realms/a.json"; description = '' - The path (string, relative to `config.dataDir`) where you want to import (or export) this realm «name» to. - If not set and `import` is `true` this realm is not imported. - If not set and `export` is `true` its exported to `''${config.dataDir}/keycloak/realm-export/«name».json`. + The path (relative to the `process-compose` working dir or an Nix store path) + where you want to import (or export) this realm «name» to. + - If not set and `import` is `true` this realm is not imported. + - If + - set to an Nix store path + - or not it is not set + and `export` is `true` then + it is exported to `''${config.dataDir}/realm-export/«name».json`. ''; }; diff --git a/nix/services/keycloak/service.nix b/nix/services/keycloak/service.nix index c7c55e82..5d6efb49 100644 --- a/nix/services/keycloak/service.nix +++ b/nix/services/keycloak/service.nix @@ -93,7 +93,7 @@ let # Generate the commands to export realms. assertKeycloakStopped = [ '' - if ${keycloak-health}/bin/keycloak-health; then + if ${keycloak-health}/bin/keycloak-health &>/dev/null; then echo "You must first stop keycloak and then run this command again." >&2 exit 1 fi @@ -117,6 +117,20 @@ let ) ); + realmExportPath = + let + isInStore = + x: + lib.path.hasStorePathPrefix ( + if builtins.isPath x then x else /. + builtins.unsafeDiscardStringContext x + ); + in + realm: e: + if (e.path == null || isInStore e.path) then + (config.dataDir + "/realm-export/${realm}.json") + else + e.path; + realmsToExport = lib.filterAttrs (_: v: v.export) cfg.realms; realmsExport = if (!cfg.processes.exportRealms || lib.length (lib.attrNames realmsToExport) == 0) then @@ -127,11 +141,7 @@ let ( realm: e: let - file = - if (e.path == null || lib.isStorePath e.path) then - (config.dataDir + "/keycloak/realm-export/${realm}.json") - else - e.path; + file = realmExportPath realm e; in '' echo "Exporting realm '${realm}' to '${file}'." @@ -226,6 +236,7 @@ in }; "${name}-realm-export" = lib.mkIf cfg.scripts.exportRealm { + environment = keycloakEnv; command = "${keycloak-realm-export}/bin/keycloak-realm-export"; disabled = true; description = '' @@ -235,6 +246,7 @@ in # Export all configured realms. "${name}-realm-export-all" = lib.mkIf (realmsExport != [ ]) { + environment = keycloakEnv; command = "${keycloak-realm-export-all}/bin/keycloak-realm-export-all"; disabled = true; description = '' diff --git a/nix/services/keycloak/test-realms/export.nix b/nix/services/keycloak/test-realms/export.nix new file mode 100644 index 00000000..18b749a1 --- /dev/null +++ b/nix/services/keycloak/test-realms/export.nix @@ -0,0 +1,83 @@ +{ writeShellApplication +, process-compose +, jq +, # Own stuff. + keycloak-name +, realmDstDir +, pcSocketPath +, ... +}: + +writeShellApplication { + name = "test-export"; + + runtimeInputs = [ + process-compose + jq + ]; + + text = + # Bash + '' + export PC_SOCKET_PATH="${pcSocketPath}" + + # Silence process-compose not finding a config home. + mkdir -p "$(pwd)/.config/process-compose" + # shellcheck disable=SC2155 + export XDG_CONFIG_HOME="$(pwd)/.config" + + test_export() { + echo "Stop keycloak..." + process-compose process stop "${keycloak-name}" -u "$PC_SOCKET_PATH" + + for _ in $(seq 1 10); do + if + [ "$( + process-compose process get "${keycloak-name}" -o json -u "$PC_SOCKET_PATH" | + jq -r ".[0].status" + )" = "Completed" ] + then + completed="true" + break + fi + + sleep 2 + done + + echo "Export realms..." + process-compose process start "${keycloak-name}-realm-export-all" -u "$PC_SOCKET_PATH" + + completed="false" + for _ in $(seq 1 30); do + if + [ "$( + process-compose process get "${keycloak-name}-realm-export-all" \ + -o json -u "$PC_SOCKET_PATH" | + jq -r ".[0].status" + )" = "Completed" ] + then + completed="true" + break + fi + + sleep 2 + done + + if [ "$completed" != "true" ]; then + echo "!! Realm export did not complete in time." + return 1 + fi + + if [ ! -f "${realmDstDir}/master.json" ]; then + echo "!! Realm '${realmDstDir}/master.json' did not get exported." + return 1 + fi + + if [ ! -f "${realmDstDir}/test.json" ]; then + echo "!! Realm '${realmDstDir}/test.json' did not get exported". + fi + } + + test_export + ''; +} diff --git a/nix/services/keycloak_test.nix b/nix/services/keycloak_test.nix index ec5da691..7213762f 100644 --- a/nix/services/keycloak_test.nix +++ b/nix/services/keycloak_test.nix @@ -1,8 +1,13 @@ { pkgs, config, ... }: +let + name = "k1"; + inherit (config.services.keycloak.${name}) dataDir; + realmSrc = ./keycloak/test-realms/test.json; +in { - services.keycloak.k1 = { + services.keycloak.${name} = { enable = true; - settings.http-port = 8089; + settings.http-port = 8091; database.type = "dev-file"; @@ -14,7 +19,7 @@ }; test = { - path = ./keycloak/test-realms/test.json; + path = realmSrc; import = true; export = true; }; @@ -23,25 +28,20 @@ settings.processes.test = let - cfg = config.services.keycloak."k1"; + test-export = pkgs.callPackage ./keycloak/test-realms/export.nix { + process-compose = config.package; + realmDstDir = "${dataDir}/realm-export"; + pcSocketPath = config.cli.options.unix-socket; + keycloak-name = name; + }; in { command = pkgs.writeShellApplication { - runtimeInputs = [ - cfg.package - pkgs.gnugrep - pkgs.curl - pkgs.uutils-coreutils-noprefix - pkgs.jq - ]; - text = " - # TODO: Realm export tests were removed because the H2 embedded database - # (dev-file) holds a file lock that isn't reliably released by the time the - # export JVM starts. Consider re-adding export tests with a PostgreSQL backend. - "; - name = "k1-tests"; + runtimeInputs = [ test-export ]; + text = "test-export"; + name = "${name}-test"; }; - depends_on."k1".condition = "process_healthy"; + depends_on.${name}.condition = "process_healthy"; }; } diff --git a/test/flake.nix b/test/flake.nix index ed07b195..3a3aec08 100644 --- a/test/flake.nix +++ b/test/flake.nix @@ -69,6 +69,8 @@ "${inputs.services-flake}/nix/services/tika_test.nix" "${inputs.services-flake}/nix/services/weaviate_test.nix" "${inputs.services-flake}/nix/services/zookeeper_test.nix" + "${inputs.services-flake}/nix/services/keycloak_test.nix" + "${inputs.services-flake}/nix/services/keycloak-certs_test.nix" ] ++ lib.optionals pkgs.stdenv.hostPlatform.isLinux [ # `phpfpm` test fails on aarch64-darwin: # [phpfpm1 ] [28-Jul-2025 13:05:47.512506] DEBUG: pid 90757, fpm_stdio_save_original_stderr(), line 81: saving original STDERR fd: dup() @@ -91,8 +93,6 @@ # ] "${inputs.services-flake}/nix/services/open-webui_test.nix" "${inputs.services-flake}/nix/services/seaweedfs_test.nix" # Darwin build fixed in https://github.com/NixOS/nixpkgs/pull/534897 - "${inputs.services-flake}/nix/services/keycloak_test.nix" - "${inputs.services-flake}/nix/services/keycloak-certs_test.nix" ] # Tests on non-linux host only ++ lib.optionals (!pkgs.stdenv.hostPlatform.isLinux) [ From e7a153f84eb39199a57f9837f1900c1eddcdd54f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20N=C3=BCtzi?= Date: Wed, 15 Jul 2026 13:18:25 +0200 Subject: [PATCH 04/16] fix: create symlink to absolute path in keycloak import folder --- nix/services/keycloak/service.nix | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/nix/services/keycloak/service.nix b/nix/services/keycloak/service.nix index 5d6efb49..189bfb7d 100644 --- a/nix/services/keycloak/service.nix +++ b/nix/services/keycloak/service.nix @@ -79,13 +79,16 @@ let let f = e.path; in + # Bash '' - echo "Symlinking realm file '${f}' to import path '$KC_HOME_DIR/data/import'." - if [ ! -f "${f}" ]; then - echo "Realm file '${f}' does not exist!" >&2 + f=$(realpath "${f}") + echo "Symlinking realm file '$f' to import path '$KC_HOME_DIR/data/import'." + if [ ! -f "$f" ]; then + echo "Realm file '$f' does not exist!" >&2 exit 1 fi - ln -fs "${f}" "$KC_HOME_DIR/data/import/" + ln -fs "$f" "$KC_HOME_DIR/data/import/" + unset f '' ) (lib.filterAttrs (_: v: v.import && v.path != null) cfg.realms); From ac0e2a852c407ea412f3fcd1d81b686b77d8694d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20N=C3=BCtzi?= Date: Wed, 15 Jul 2026 15:29:08 +0200 Subject: [PATCH 05/16] chore: documentation and obsolete configuration --- doc/keycloak.md | 97 +++++++++++++++++++++++++++++++ nix/services/keycloak/service.nix | 9 --- 2 files changed, 97 insertions(+), 9 deletions(-) create mode 100644 doc/keycloak.md diff --git a/doc/keycloak.md b/doc/keycloak.md new file mode 100644 index 00000000..56b0b77e --- /dev/null +++ b/doc/keycloak.md @@ -0,0 +1,97 @@ +# Keycloak + +[Keycloak](https://www.keycloak.org/) is an open-source identity and access management solution providing single sign-on (SSO), user federation, and support for OpenID Connect, OAuth 2.0 and SAML. + +> [!NOTE] +> +> This module runs Keycloak in development mode (`start --optimized` with an embedded database). It is intended for local development and testing, not production. + +{#start} + +## Getting Started + +```nix +# In `perSystem.process-compose.` +{ + services.keycloak."kc" = { + enable = true; + settings.http-port = 8091; + + database.type = "dev-file"; + + realms = { + master = { + path = ./master.json; + export = true; + import = false; + }; + test = { + path = ./test.json; + import = false; # Set that to true once exported. + export = true; + }; + }; + }; +} +``` + +Keycloak becomes available at [http://localhost:8091](http://localhost:8091). +The temporary admin user is `admin` with the password set by [`initialAdminPassword`](#admin-password) (`admin` by default). + +{#tips} + +## Tips & Tricks + +{#import-realms} + +### Import Realms + +A realm listed under `realms` with `import = true` (the default) and a `path` set is imported on start up, provided the realm does not already exist. +The `path` may be relative to the `process-compose` working directory or a Nix store path. + +```nix +{ + services.keycloak."kc" = { + enable = true; + + realms.test = { + path = ./test.json; + import = true; + }; + }; +} +``` + +{#export-realms} + +### Export Settings + +To export realms when you made changes in the UI, make sure to have set `export = true` on the realms you care about: + +```nix +{ + services.keycloak."kc" = { + enable = true; + realms.test = { + path = ./test.json; + export = true; + }; + }; +} +``` + +This creates two process-compose processes, both **disabled by default** (they are not run automatically, since exporting requires Keycloak to be stopped): + +- `«name»-realm-export-all` — exports every realm with `export = true`. + +Run it manually once Keycloak has stopped, e.g. from the process-compose TUI, or: + +```bash +# Stop keycloak first then run the export: +process-compose process stop «name» +process-compose process start «name»-realm-export-all +``` + +Each realm is exported to its `path` when that path is a relative (non-store) location, otherwise to `${config.services.keycloak.«name».dataDir}/realm-export/.json`. Exports are pretty-printed with `jq` for easy diffing. + +You can disable the export processes/scripts globally with `processes.exportRealms = false;`. diff --git a/nix/services/keycloak/service.nix b/nix/services/keycloak/service.nix index 189bfb7d..af00c4f1 100644 --- a/nix/services/keycloak/service.nix +++ b/nix/services/keycloak/service.nix @@ -238,15 +238,6 @@ in }; }; - "${name}-realm-export" = lib.mkIf cfg.scripts.exportRealm { - environment = keycloakEnv; - command = "${keycloak-realm-export}/bin/keycloak-realm-export"; - disabled = true; - description = '' - Export a realm '$1' (first argument) from keycloak to location '$2' (second argument). - ''; - }; - # Export all configured realms. "${name}-realm-export-all" = lib.mkIf (realmsExport != [ ]) { environment = keycloakEnv; From 2c225c7939379123c943defdd7c4fa88e78c439d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20N=C3=BCtzi?= Date: Wed, 15 Jul 2026 15:32:07 +0200 Subject: [PATCH 06/16] chore: documentation and obsolete configuration --- doc/keycloak.md | 2 +- nix/services/keycloak/options.nix | 27 +++++++-------------------- nix/services/keycloak/service.nix | 2 +- 3 files changed, 9 insertions(+), 22 deletions(-) diff --git a/doc/keycloak.md b/doc/keycloak.md index 56b0b77e..664ec234 100644 --- a/doc/keycloak.md +++ b/doc/keycloak.md @@ -94,4 +94,4 @@ process-compose process start «name»-realm-export-all Each realm is exported to its `path` when that path is a relative (non-store) location, otherwise to `${config.services.keycloak.«name».dataDir}/realm-export/.json`. Exports are pretty-printed with `jq` for easy diffing. -You can disable the export processes/scripts globally with `processes.exportRealms = false;`. +You can disable the export processes/scripts globally with `exportRealms = false;`. diff --git a/nix/services/keycloak/options.nix b/nix/services/keycloak/options.nix index aa590466..e4c3c702 100644 --- a/nix/services/keycloak/options.nix +++ b/nix/services/keycloak/options.nix @@ -97,26 +97,13 @@ in ''; }; - scripts = { - exportRealm = mkOption { - type = types.bool; - default = true; - description = '' - Global toggle to enable/disable the **single** realm export - script `keycloak-realm-export`. - ''; - }; - }; - - processes = { - exportRealms = mkOption { - type = types.bool; - default = true; - description = '' - Global toggle to enable/disable the realms export process `keycloak-realm-export-all` - if any realms have `realms.«name».export == true`. - ''; - }; + exportRealms = mkOption { + type = types.bool; + default = true; + description = '' + Global toggle to enable/disable the realms export process `keycloak-realm-export-all` + if any realms have `realms.«name».export == true`. + ''; }; realms = mkOption { diff --git a/nix/services/keycloak/service.nix b/nix/services/keycloak/service.nix index af00c4f1..fa0771c8 100644 --- a/nix/services/keycloak/service.nix +++ b/nix/services/keycloak/service.nix @@ -136,7 +136,7 @@ let realmsToExport = lib.filterAttrs (_: v: v.export) cfg.realms; realmsExport = - if (!cfg.processes.exportRealms || lib.length (lib.attrNames realmsToExport) == 0) then + if (!cfg.exportRealms || lib.length (lib.attrNames realmsToExport) == 0) then [ ] else assertKeycloakStopped From 0f64cc3056f209e4bf31d1e713df0fdd99ae9aae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20N=C3=BCtzi?= Date: Fri, 17 Jul 2026 16:20:30 +0200 Subject: [PATCH 07/16] fix: correct `keycloak` dataDir --- nix/services/keycloak/service.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/nix/services/keycloak/service.nix b/nix/services/keycloak/service.nix index fa0771c8..76972021 100644 --- a/nix/services/keycloak/service.nix +++ b/nix/services/keycloak/service.nix @@ -168,9 +168,9 @@ let ''; keycloakEnv = { - KC_HOME_DIR = cfg.dataDir + "/keycloak"; - KC_CONF_DIR = cfg.dataDir + "/keycloak/conf"; - KC_TMP_DIR = cfg.dataDir + "/keycloak/tmp"; + KC_HOME_DIR = lib.traceVal cfg.dataDir; + KC_CONF_DIR = cfg.dataDir + "/conf"; + KC_TMP_DIR = cfg.dataDir + "/tmp"; KC_BOOTSTRAP_ADMIN_USERNAME = "admin"; KC_BOOTSTRAP_ADMIN_PASSWORD = "${lib.escapeShellArg cfg.initialAdminPassword}"; From d6ac7cec8b9c59ab53a7f51a5d2bb95a29d6a703 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20N=C3=BCtzi?= Date: Fri, 17 Jul 2026 16:36:25 +0200 Subject: [PATCH 08/16] fix: correct keycloak home directory for startup --- nix/services/keycloak/service.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/nix/services/keycloak/service.nix b/nix/services/keycloak/service.nix index 76972021..5f700221 100644 --- a/nix/services/keycloak/service.nix +++ b/nix/services/keycloak/service.nix @@ -168,7 +168,9 @@ let ''; keycloakEnv = { - KC_HOME_DIR = lib.traceVal cfg.dataDir; + # Note: we add "./" cause keycloak's database url + # does not allow implicitly relative paths. + KC_HOME_DIR = "./" + cfg.dataDir; KC_CONF_DIR = cfg.dataDir + "/conf"; KC_TMP_DIR = cfg.dataDir + "/tmp"; From b4621ffe980d483bbca7e3f8315a928c15e1d93b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20N=C3=BCtzi?= Date: Fri, 17 Jul 2026 18:29:01 +0200 Subject: [PATCH 09/16] fix: remove unused keycloak file export --- nix/services/keycloak/service.nix | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/nix/services/keycloak/service.nix b/nix/services/keycloak/service.nix index 5f700221..8e03795d 100644 --- a/nix/services/keycloak/service.nix +++ b/nix/services/keycloak/service.nix @@ -109,17 +109,6 @@ let '' ]; - keycloak-realm-export = pkgs.writeShellScriptBin "keycloak-realm-export" ( - lib.concatStringsSep "\n" ( - assertKeycloakStopped - ++ [ - '' - ${keycloakBuild}/bin/kc.sh export --optimized --realm "$1" --file "$2" - '' - ] - ) - ); - realmExportPath = let isInStore = From 5bde4fc639a3cf8451247c7942340367319b291e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20N=C3=BCtzi?= Date: Sun, 19 Jul 2026 18:30:32 +0200 Subject: [PATCH 10/16] fix: replace `lib.mkIf` with `if` sequence --- nix/services/keycloak/service.nix | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/nix/services/keycloak/service.nix b/nix/services/keycloak/service.nix index 8e03795d..6ed39d07 100644 --- a/nix/services/keycloak/service.nix +++ b/nix/services/keycloak/service.nix @@ -135,6 +135,7 @@ let let file = realmExportPath realm e; in + # Bash '' echo "Exporting realm '${realm}' to '${file}'." mkdir -p "$(dirname "${file}")" @@ -229,8 +230,10 @@ in }; }; + } + // (lib.optionalAttrs (realmsExport != [ ]) { # Export all configured realms. - "${name}-realm-export-all" = lib.mkIf (realmsExport != [ ]) { + "${name}-realm-export-all" = { environment = keycloakEnv; command = "${keycloak-realm-export-all}/bin/keycloak-realm-export-all"; disabled = true; @@ -238,6 +241,6 @@ in Save the configured realms from keycloak, to back them up. You can run it manually. ''; }; - }; + }); }; } From a3f9637e94c600e4b915226966c63c58e40920af Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20N=C3=BCtzi?= Date: Tue, 21 Jul 2026 10:35:19 +0200 Subject: [PATCH 11/16] docs: entry link --- doc/services.md | 1 + 1 file changed, 1 insertion(+) diff --git a/doc/services.md b/doc/services.md index 00a499bf..05a847a3 100644 --- a/doc/services.md +++ b/doc/services.md @@ -16,6 +16,7 @@ short-title: Services - [[tempo]] - [[loki]] - [[pyroscope]] +- [[keycloak]]# - [[memcached]]# - [[minio]]# - [[mongodb]]# From 8631804aefb652355ad46b7166ecb3150be8428d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20N=C3=BCtzi?= Date: Tue, 21 Jul 2026 10:55:06 +0200 Subject: [PATCH 12/16] fix: revert format --- nix/services/default.nix | 83 ++++++++++++++++++++-------------------- 1 file changed, 41 insertions(+), 42 deletions(-) diff --git a/nix/services/default.nix b/nix/services/default.nix index 5cec4953..68e79fc3 100644 --- a/nix/services/default.nix +++ b/nix/services/default.nix @@ -2,47 +2,46 @@ let inherit (import ../lib.nix) multiService; in { - imports = - (map multiService [ - ./apache-kafka.nix - ./azurite.nix - ./clickhouse - ./dynamodb-local.nix - ./elasticmq.nix - ./elasticsearch.nix - ./mongodb.nix - ./mysql - ./nginx - ./ollama.nix - ./postgres - ./open-webui.nix - ./plantuml.nix - ./redis-cluster.nix - ./redis.nix - ./seaweedfs.nix - ./zookeeper.nix - ./grafana.nix - ./memcached.nix - ./minio.nix - ./nats-server.nix - ./prometheus.nix - ./pgadmin.nix - ./cassandra.nix - ./pyroscope.nix - ./tempo.nix - ./weaviate.nix - ./searxng.nix - ./tika.nix - ./loki.nix - ./phpfpm.nix - ./pubsub-emulator.nix - ./qdrant.nix - ./chromadb.nix - ./neo4j.nix - ./keycloak.nix - ]) - ++ [ - ./devshell.nix - ]; + imports = (map multiService [ + ./apache-kafka.nix + ./azurite.nix + ./clickhouse + ./dynamodb-local.nix + ./elasticmq.nix + ./elasticsearch.nix + ./mongodb.nix + ./mysql + ./nginx + ./ollama.nix + ./postgres + ./open-webui.nix + ./plantuml.nix + ./redis-cluster.nix + ./redis.nix + ./seaweedfs.nix + ./zookeeper.nix + ./grafana.nix + ./memcached.nix + ./minio.nix + ./nats-server.nix + ./prometheus.nix + ./pgadmin.nix + ./cassandra.nix + ./pyroscope.nix + ./tempo.nix + ./weaviate.nix + ./searxng.nix + ./tika.nix + ./loki.nix + ./phpfpm.nix + ./pubsub-emulator.nix + ./qdrant.nix + ./chromadb.nix + ./neo4j.nix + ./keycloak.nix + ]) + ++ [ + ./devshell.nix + ]; } From 76dd1e06d295d5cfd405f6aa2ad70fd6517004c1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20N=C3=BCtzi?= Date: Tue, 21 Jul 2026 10:55:31 +0200 Subject: [PATCH 13/16] fix: revert format --- nix/services/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nix/services/default.nix b/nix/services/default.nix index 68e79fc3..6d4b38c0 100644 --- a/nix/services/default.nix +++ b/nix/services/default.nix @@ -2,7 +2,7 @@ let inherit (import ../lib.nix) multiService; in { - imports = (map multiService [ + imports = (builtins.map multiService [ ./apache-kafka.nix ./azurite.nix ./clickhouse From de77a90d02c36fdb26352fae59440566f7ea1cc6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20N=C3=BCtzi?= Date: Wed, 22 Jul 2026 15:37:31 +0200 Subject: [PATCH 14/16] chore: command takes derivation instead of string --- nix/services/keycloak/service.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nix/services/keycloak/service.nix b/nix/services/keycloak/service.nix index 6ed39d07..d6e40864 100644 --- a/nix/services/keycloak/service.nix +++ b/nix/services/keycloak/service.nix @@ -219,7 +219,7 @@ in settings.processes = { ${name} = { environment = keycloakEnv; - command = "${lib.getExe keycloak-start}"; + command = keycloak-start; readiness_probe = { exec = { command = "${lib.getExe keycloak-health}"; @@ -235,7 +235,7 @@ in # Export all configured realms. "${name}-realm-export-all" = { environment = keycloakEnv; - command = "${keycloak-realm-export-all}/bin/keycloak-realm-export-all"; + command = keycloak-realm-export-all; disabled = true; description = '' Save the configured realms from keycloak, to back them up. You can run it manually. From 251ec39068f217483c6c7450b4f881c58231118f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20N=C3=BCtzi?= Date: Thu, 23 Jul 2026 09:15:55 +0200 Subject: [PATCH 15/16] fix: formatting in flake.nix --- test/flake.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/flake.nix b/test/flake.nix index 3a3aec08..8687883f 100644 --- a/test/flake.nix +++ b/test/flake.nix @@ -48,6 +48,8 @@ "${inputs.services-flake}/nix/services/dynamodb-local_test.nix" "${inputs.services-flake}/nix/services/elasticmq_test.nix" "${inputs.services-flake}/nix/services/grafana_test.nix" + "${inputs.services-flake}/nix/services/keycloak_test.nix" + "${inputs.services-flake}/nix/services/keycloak-certs_test.nix" "${inputs.services-flake}/nix/services/memcached_test.nix" "${inputs.services-flake}/nix/services/mysql/mysql_test.nix" "${inputs.services-flake}/nix/services/nats-server_test.nix" @@ -69,8 +71,6 @@ "${inputs.services-flake}/nix/services/tika_test.nix" "${inputs.services-flake}/nix/services/weaviate_test.nix" "${inputs.services-flake}/nix/services/zookeeper_test.nix" - "${inputs.services-flake}/nix/services/keycloak_test.nix" - "${inputs.services-flake}/nix/services/keycloak-certs_test.nix" ] ++ lib.optionals pkgs.stdenv.hostPlatform.isLinux [ # `phpfpm` test fails on aarch64-darwin: # [phpfpm1 ] [28-Jul-2025 13:05:47.512506] DEBUG: pid 90757, fpm_stdio_save_original_stderr(), line 81: saving original STDERR fd: dup() From 8b4f1b4f8f77090d6ab23356119e89fbe7cc8604 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20N=C3=BCtzi?= Date: Tue, 4 Aug 2026 16:44:40 +0200 Subject: [PATCH 16/16] fix: improve options setup on import/export --- doc/keycloak.md | 34 +- nix/services/keycloak-certs_test.nix | 13 +- nix/services/keycloak/options.nix | 36 +- nix/services/keycloak/service.nix | 17 +- nix/services/keycloak/test-realms/master.json | 2499 ----------------- nix/services/keycloak_test.nix | 13 +- 6 files changed, 66 insertions(+), 2546 deletions(-) delete mode 100644 nix/services/keycloak/test-realms/master.json diff --git a/doc/keycloak.md b/doc/keycloak.md index 664ec234..a6a1c7a1 100644 --- a/doc/keycloak.md +++ b/doc/keycloak.md @@ -21,14 +21,18 @@ realms = { master = { - path = ./master.json; - export = true; - import = false; + export = { + enable = true; # Export to data folder. + }; }; test = { - path = ./test.json; - import = false; # Set that to true once exported. - export = true; + # Set that once exported. + # import = "./test.json" + + export = { + enable = true; + path = "./test.json"; + }; }; }; }; @@ -46,8 +50,8 @@ The temporary admin user is `admin` with the password set by [`initialAdminPassw ### Import Realms -A realm listed under `realms` with `import = true` (the default) and a `path` set is imported on start up, provided the realm does not already exist. -The `path` may be relative to the `process-compose` working directory or a Nix store path. +A realm listed under `realms` with `import` set is imported on start up, provided the realm does not already exist. +The `import` path may be relative to the `process-compose` working directory or a Nix store path. ```nix { @@ -55,8 +59,7 @@ The `path` may be relative to the `process-compose` working directory or a Nix s enable = true; realms.test = { - path = ./test.json; - import = true; + import = ./test.json; # Nix store path. Quote to make it a relative path. }; }; } @@ -66,15 +69,18 @@ The `path` may be relative to the `process-compose` working directory or a Nix s ### Export Settings -To export realms when you made changes in the UI, make sure to have set `export = true` on the realms you care about: +To export realms when you made changes in the UI, make sure to have set `export` on the realms you care about: ```nix { services.keycloak."kc" = { enable = true; + realms.test = { - path = ./test.json; - export = true; + export = { + enable = true; + path = "./test.json"; # Optional. + }; }; }; } @@ -82,7 +88,7 @@ To export realms when you made changes in the UI, make sure to have set `export This creates two process-compose processes, both **disabled by default** (they are not run automatically, since exporting requires Keycloak to be stopped): -- `«name»-realm-export-all` — exports every realm with `export = true`. +- `«name»-realm-export-all` — exports every realm with `export.enable = true`. Run it manually once Keycloak has stopped, e.g. from the process-compose TUI, or: diff --git a/nix/services/keycloak-certs_test.nix b/nix/services/keycloak-certs_test.nix index 13fd8b2e..601c5e17 100644 --- a/nix/services/keycloak-certs_test.nix +++ b/nix/services/keycloak-certs_test.nix @@ -19,15 +19,16 @@ in realms = { master = { - path = ./keycloak/test-realms/master.json; - export = true; - import = false; + export = { + enable = true; + }; }; test = { - path = realmSrc; - import = true; - export = true; + import = realmSrc; + export = { + enable = true; + }; }; }; }; diff --git a/nix/services/keycloak/options.nix b/nix/services/keycloak/options.nix index e4c3c702..03676f34 100644 --- a/nix/services/keycloak/options.nix +++ b/nix/services/keycloak/options.nix @@ -14,6 +14,7 @@ let inherit (lib) mkOption mkPackageOption + mkEnableOption types ; in @@ -111,7 +112,7 @@ in type = types.attrsOf ( types.submodule { options = { - path = mkOption { + import = mkOption { type = types.nullOr ( # A relative, user-provided path. lib.types.either @@ -136,22 +137,27 @@ in ''; }; - import = mkOption { - type = types.bool; - default = true; - example = true; - description = '' - If you want to import that realm on start up, if the realm does not yet exist. + export = { + enable = mkEnableOption '' + export the realm on process launch `-export-realms`. ''; - }; - export = mkOption { - type = types.bool; - default = false; - example = true; - description = '' - If you want to export that realm on process/script launch `keycloak-export-realms`. - ''; + path = mkOption { + type = types.nullOr ( + lib.types.pathWith { + inStore = false; + absolute = false; + } + ); + default = null; + example = "./realms/a.json"; + description = '' + The path (relative to the `process-compose` working dir or an Nix store path) + where you want to export this realm «name» to. + - If not set and `import.path` is relative it is used as default. + - If not set otherwise its defaulted to a value in the data folder. + ''; + }; }; }; } diff --git a/nix/services/keycloak/service.nix b/nix/services/keycloak/service.nix index d6e40864..9b47079e 100644 --- a/nix/services/keycloak/service.nix +++ b/nix/services/keycloak/service.nix @@ -77,7 +77,7 @@ let ( realm: e: let - f = e.path; + f = e.import; in # Bash '' @@ -91,7 +91,7 @@ let unset f '' ) - (lib.filterAttrs (_: v: v.import && v.path != null) cfg.realms); + (lib.filterAttrs (_: v: v.import != null) cfg.realms); # Generate the commands to export realms. assertKeycloakStopped = [ @@ -118,12 +118,17 @@ let ); in realm: e: - if (e.path == null || isInStore e.path) then - (config.dataDir + "/realm-export/${realm}.json") + if e.export.path != null then + e.export.path else - e.path; + ( + if e.import == null || isInStore e.import then + (config.dataDir + "/realm-export/${realm}.json") + else + e.import + ); - realmsToExport = lib.filterAttrs (_: v: v.export) cfg.realms; + realmsToExport = lib.filterAttrs (_: v: v.export.enable) cfg.realms; realmsExport = if (!cfg.exportRealms || lib.length (lib.attrNames realmsToExport) == 0) then [ ] diff --git a/nix/services/keycloak/test-realms/master.json b/nix/services/keycloak/test-realms/master.json deleted file mode 100644 index 69de95bc..00000000 --- a/nix/services/keycloak/test-realms/master.json +++ /dev/null @@ -1,2499 +0,0 @@ -{ - "id": "10202c48-820f-43e1-9c59-4da0e93028f6", - "realm": "master", - "displayName": "Keycloak", - "displayNameHtml": "
Keycloak
", - "notBefore": 0, - "defaultSignatureAlgorithm": "RS256", - "revokeRefreshToken": false, - "refreshTokenMaxReuse": 0, - "accessTokenLifespan": 60, - "accessTokenLifespanForImplicitFlow": 900, - "ssoSessionIdleTimeout": 1800, - "ssoSessionMaxLifespan": 36000, - "ssoSessionIdleTimeoutRememberMe": 0, - "ssoSessionMaxLifespanRememberMe": 0, - "offlineSessionIdleTimeout": 2592000, - "offlineSessionMaxLifespanEnabled": false, - "offlineSessionMaxLifespan": 5184000, - "clientSessionIdleTimeout": 0, - "clientSessionMaxLifespan": 0, - "clientOfflineSessionIdleTimeout": 0, - "clientOfflineSessionMaxLifespan": 0, - "accessCodeLifespan": 60, - "accessCodeLifespanUserAction": 300, - "accessCodeLifespanLogin": 1800, - "actionTokenGeneratedByAdminLifespan": 43200, - "actionTokenGeneratedByUserLifespan": 300, - "oauth2DeviceCodeLifespan": 600, - "oauth2DevicePollingInterval": 5, - "enabled": true, - "sslRequired": "external", - "registrationAllowed": false, - "registrationEmailAsUsername": false, - "rememberMe": false, - "verifyEmail": false, - "loginWithEmailAllowed": true, - "duplicateEmailsAllowed": false, - "resetPasswordAllowed": false, - "editUsernameAllowed": false, - "bruteForceProtected": false, - "permanentLockout": false, - "maxTemporaryLockouts": 0, - "bruteForceStrategy": "MULTIPLE", - "maxFailureWaitSeconds": 900, - "minimumQuickLoginWaitSeconds": 60, - "waitIncrementSeconds": 60, - "quickLoginCheckMilliSeconds": 1000, - "maxDeltaTimeSeconds": 43200, - "failureFactor": 30, - "roles": { - "realm": [ - { - "id": "2d5f6195-d923-4231-9e7c-d7376ed5eeac", - "name": "uma_authorization", - "description": "${role_uma_authorization}", - "composite": false, - "clientRole": false, - "containerId": "10202c48-820f-43e1-9c59-4da0e93028f6", - "attributes": {} - }, - { - "id": "3e86fd03-a375-4b11-a2f8-56339696ad22", - "name": "offline_access", - "description": "${role_offline-access}", - "composite": false, - "clientRole": false, - "containerId": "10202c48-820f-43e1-9c59-4da0e93028f6", - "attributes": {} - }, - { - "id": "ef9855c1-4317-4f26-b5e9-c27f13411338", - "name": "admin", - "description": "${role_admin}", - "composite": true, - "composites": { - "realm": ["create-realm"], - "client": { - "test-realm": [ - "manage-realm", - "manage-identity-providers", - "manage-clients", - "view-authorization", - "query-users", - "query-groups", - "query-realms", - "view-clients", - "view-users", - "manage-authorization", - "view-identity-providers", - "query-clients", - "create-client", - "view-events", - "manage-events", - "impersonation", - "manage-users", - "view-realm" - ], - "master-realm": [ - "create-client", - "view-clients", - "manage-users", - "manage-realm", - "query-realms", - "manage-clients", - "view-authorization", - "query-groups", - "query-users", - "manage-authorization", - "view-users", - "view-realm", - "view-identity-providers", - "query-clients", - "view-events", - "manage-identity-providers", - "manage-events", - "impersonation" - ] - } - }, - "clientRole": false, - "containerId": "10202c48-820f-43e1-9c59-4da0e93028f6", - "attributes": {} - }, - { - "id": "6ba1b611-b56b-43f1-8ab0-65086b8a1a36", - "name": "default-roles-master", - "description": "${role_default-roles}", - "composite": true, - "composites": { - "realm": ["offline_access", "uma_authorization"], - "client": { - "account": ["manage-account", "view-profile"] - } - }, - "clientRole": false, - "containerId": "10202c48-820f-43e1-9c59-4da0e93028f6", - "attributes": {} - }, - { - "id": "47b6b17c-fafb-4976-8fd8-c19bf88cdd83", - "name": "create-realm", - "description": "${role_create-realm}", - "composite": false, - "clientRole": false, - "containerId": "10202c48-820f-43e1-9c59-4da0e93028f6", - "attributes": {} - } - ], - "client": { - "test-realm": [ - { - "id": "17c921b2-1a64-4388-851a-5c6d26a4d132", - "name": "manage-authorization", - "description": "${role_manage-authorization}", - "composite": false, - "clientRole": true, - "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", - "attributes": {} - }, - { - "id": "f0e63981-0dd2-437a-b4a9-ae87237149eb", - "name": "manage-realm", - "description": "${role_manage-realm}", - "composite": false, - "clientRole": true, - "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", - "attributes": {} - }, - { - "id": "b9594598-798e-4d3e-b2c5-db805a51f21d", - "name": "view-identity-providers", - "description": "${role_view-identity-providers}", - "composite": false, - "clientRole": true, - "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", - "attributes": {} - }, - { - "id": "d9dd7bc9-9339-4b3c-9edc-d4deaec9af7d", - "name": "manage-clients", - "description": "${role_manage-clients}", - "composite": false, - "clientRole": true, - "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", - "attributes": {} - }, - { - "id": "ac3cb040-fa5f-40b7-bffa-1c8758734ea1", - "name": "manage-identity-providers", - "description": "${role_manage-identity-providers}", - "composite": false, - "clientRole": true, - "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", - "attributes": {} - }, - { - "id": "63c8a6b7-0369-44c9-a010-6ba08912614c", - "name": "view-authorization", - "description": "${role_view-authorization}", - "composite": false, - "clientRole": true, - "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", - "attributes": {} - }, - { - "id": "6dddf717-4b6b-40d8-a1c4-3a18944f1b46", - "name": "query-users", - "description": "${role_query-users}", - "composite": false, - "clientRole": true, - "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", - "attributes": {} - }, - { - "id": "46647441-7995-4326-9bdb-adf375803df6", - "name": "query-clients", - "description": "${role_query-clients}", - "composite": false, - "clientRole": true, - "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", - "attributes": {} - }, - { - "id": "a16caccb-7f18-4bff-ae14-85a9b55feabf", - "name": "query-groups", - "description": "${role_query-groups}", - "composite": false, - "clientRole": true, - "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", - "attributes": {} - }, - { - "id": "00ed40a2-e1f9-463f-b391-a89d6c0eb4ff", - "name": "query-realms", - "description": "${role_query-realms}", - "composite": false, - "clientRole": true, - "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", - "attributes": {} - }, - { - "id": "6eb0f5ff-2f33-47d0-9cca-5ca9095f86e8", - "name": "view-clients", - "description": "${role_view-clients}", - "composite": true, - "composites": { - "client": { - "test-realm": ["query-clients"] - } - }, - "clientRole": true, - "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", - "attributes": {} - }, - { - "id": "96fa5c5e-b2f1-4011-9856-cd92d336c1bb", - "name": "create-client", - "description": "${role_create-client}", - "composite": false, - "clientRole": true, - "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", - "attributes": {} - }, - { - "id": "64c868b3-fb1a-4701-bd30-b422dcc002fa", - "name": "manage-events", - "description": "${role_manage-events}", - "composite": false, - "clientRole": true, - "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", - "attributes": {} - }, - { - "id": "36ae32c3-1073-4a1d-993e-d8bda8b91449", - "name": "view-events", - "description": "${role_view-events}", - "composite": false, - "clientRole": true, - "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", - "attributes": {} - }, - { - "id": "1c2091a0-02aa-4494-92f2-963033e9e5a6", - "name": "impersonation", - "description": "${role_impersonation}", - "composite": false, - "clientRole": true, - "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", - "attributes": {} - }, - { - "id": "f6242eef-e49a-482c-91da-fd4e671bb0b8", - "name": "manage-users", - "description": "${role_manage-users}", - "composite": false, - "clientRole": true, - "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", - "attributes": {} - }, - { - "id": "08e073ff-5870-4b3e-b52d-bdf8950667a9", - "name": "view-users", - "description": "${role_view-users}", - "composite": true, - "composites": { - "client": { - "test-realm": ["query-users", "query-groups"] - } - }, - "clientRole": true, - "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", - "attributes": {} - }, - { - "id": "cef07a65-fe7f-49ac-a191-830915649dc0", - "name": "view-realm", - "description": "${role_view-realm}", - "composite": false, - "clientRole": true, - "containerId": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", - "attributes": {} - } - ], - "security-admin-console": [], - "admin-cli": [], - "account-console": [], - "broker": [ - { - "id": "c3d05038-2267-4442-9da7-9c57bc3ed08c", - "name": "read-token", - "description": "${role_read-token}", - "composite": false, - "clientRole": true, - "containerId": "2a45fa0e-d1c8-4b7a-ba6c-bc268ebcd051", - "attributes": {} - } - ], - "master-realm": [ - { - "id": "bd0f9732-62e6-468a-90f6-7df2007bf2c9", - "name": "manage-authorization", - "description": "${role_manage-authorization}", - "composite": false, - "clientRole": true, - "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", - "attributes": {} - }, - { - "id": "9cd5470d-8502-4aec-b2fc-c2c8d0979ccf", - "name": "query-users", - "description": "${role_query-users}", - "composite": false, - "clientRole": true, - "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", - "attributes": {} - }, - { - "id": "238cb438-6819-4c0b-bb22-b620aef6ff73", - "name": "view-users", - "description": "${role_view-users}", - "composite": true, - "composites": { - "client": { - "master-realm": ["query-users", "query-groups"] - } - }, - "clientRole": true, - "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", - "attributes": {} - }, - { - "id": "65a9a3a9-5bed-4a96-b2c6-bfa34782d9f7", - "name": "create-client", - "description": "${role_create-client}", - "composite": false, - "clientRole": true, - "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", - "attributes": {} - }, - { - "id": "1be37f2a-3734-46f3-a232-fa7d470e9c0e", - "name": "view-clients", - "description": "${role_view-clients}", - "composite": true, - "composites": { - "client": { - "master-realm": ["query-clients"] - } - }, - "clientRole": true, - "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", - "attributes": {} - }, - { - "id": "52dceddd-8dbb-42e0-b5dd-be2ddba299cd", - "name": "manage-users", - "description": "${role_manage-users}", - "composite": false, - "clientRole": true, - "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", - "attributes": {} - }, - { - "id": "111206ae-8ca1-4c73-b877-46e378da2b77", - "name": "manage-realm", - "description": "${role_manage-realm}", - "composite": false, - "clientRole": true, - "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", - "attributes": {} - }, - { - "id": "5e9c9f9a-b5c6-4282-b415-6b6edfa88ac3", - "name": "view-identity-providers", - "description": "${role_view-identity-providers}", - "composite": false, - "clientRole": true, - "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", - "attributes": {} - }, - { - "id": "4c49df4f-9196-447e-a580-fc1afde5b8f9", - "name": "view-realm", - "description": "${role_view-realm}", - "composite": false, - "clientRole": true, - "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", - "attributes": {} - }, - { - "id": "1d3faa5a-20d3-41b1-85db-37b28dcf64a4", - "name": "query-realms", - "description": "${role_query-realms}", - "composite": false, - "clientRole": true, - "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", - "attributes": {} - }, - { - "id": "2ad70757-0a71-4039-94e7-8e34ff9e1631", - "name": "query-clients", - "description": "${role_query-clients}", - "composite": false, - "clientRole": true, - "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", - "attributes": {} - }, - { - "id": "5be6fbcc-5cf7-450e-95ac-02b5b3b5e1b8", - "name": "view-events", - "description": "${role_view-events}", - "composite": false, - "clientRole": true, - "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", - "attributes": {} - }, - { - "id": "e496f3c0-b752-4f9b-8cd5-2d52f0ffd7a1", - "name": "manage-clients", - "description": "${role_manage-clients}", - "composite": false, - "clientRole": true, - "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", - "attributes": {} - }, - { - "id": "64986494-b7ce-471c-83ca-4e80339ca746", - "name": "manage-identity-providers", - "description": "${role_manage-identity-providers}", - "composite": false, - "clientRole": true, - "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", - "attributes": {} - }, - { - "id": "5f04d04a-9b93-4045-9241-f0bebedf3951", - "name": "manage-events", - "description": "${role_manage-events}", - "composite": false, - "clientRole": true, - "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", - "attributes": {} - }, - { - "id": "578a03cd-e1b8-4288-a0c7-aa6cfc093e04", - "name": "view-authorization", - "description": "${role_view-authorization}", - "composite": false, - "clientRole": true, - "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", - "attributes": {} - }, - { - "id": "1d2b50ef-b8a5-44f2-a7bc-abfd44261238", - "name": "impersonation", - "description": "${role_impersonation}", - "composite": false, - "clientRole": true, - "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", - "attributes": {} - }, - { - "id": "ee1c214d-7108-4dfb-8fed-9b75ae574eea", - "name": "query-groups", - "description": "${role_query-groups}", - "composite": false, - "clientRole": true, - "containerId": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", - "attributes": {} - } - ], - "account": [ - { - "id": "6754bc7c-cea3-4020-a80e-638b3934a7a2", - "name": "manage-account", - "description": "${role_manage-account}", - "composite": true, - "composites": { - "client": { - "account": ["manage-account-links"] - } - }, - "clientRole": true, - "containerId": "17980fdb-0e2a-4eed-ba5d-32e621651d7e", - "attributes": {} - }, - { - "id": "bf76017b-8207-4973-ade9-0c43b38ba8bb", - "name": "manage-account-links", - "description": "${role_manage-account-links}", - "composite": false, - "clientRole": true, - "containerId": "17980fdb-0e2a-4eed-ba5d-32e621651d7e", - "attributes": {} - }, - { - "id": "c3affb17-990b-4501-947a-dd3faf766e1d", - "name": "view-profile", - "description": "${role_view-profile}", - "composite": false, - "clientRole": true, - "containerId": "17980fdb-0e2a-4eed-ba5d-32e621651d7e", - "attributes": {} - }, - { - "id": "35752cce-d484-4fef-9077-faa31a26f2ce", - "name": "manage-consent", - "description": "${role_manage-consent}", - "composite": true, - "composites": { - "client": { - "account": ["view-consent"] - } - }, - "clientRole": true, - "containerId": "17980fdb-0e2a-4eed-ba5d-32e621651d7e", - "attributes": {} - }, - { - "id": "7a7d8632-6073-4915-bb04-b023aece320e", - "name": "view-consent", - "description": "${role_view-consent}", - "composite": false, - "clientRole": true, - "containerId": "17980fdb-0e2a-4eed-ba5d-32e621651d7e", - "attributes": {} - }, - { - "id": "18c9f83c-9d65-4b41-888a-1115fbbb4d96", - "name": "view-applications", - "description": "${role_view-applications}", - "composite": false, - "clientRole": true, - "containerId": "17980fdb-0e2a-4eed-ba5d-32e621651d7e", - "attributes": {} - }, - { - "id": "1061a7f3-39e5-4efa-80f3-9ff98f3be39c", - "name": "delete-account", - "description": "${role_delete-account}", - "composite": false, - "clientRole": true, - "containerId": "17980fdb-0e2a-4eed-ba5d-32e621651d7e", - "attributes": {} - }, - { - "id": "babd71b0-2c6f-4286-9e57-6ae9741515f7", - "name": "view-groups", - "description": "${role_view-groups}", - "composite": false, - "clientRole": true, - "containerId": "17980fdb-0e2a-4eed-ba5d-32e621651d7e", - "attributes": {} - } - ] - } - }, - "groups": [], - "defaultRole": { - "id": "6ba1b611-b56b-43f1-8ab0-65086b8a1a36", - "name": "default-roles-master", - "description": "${role_default-roles}", - "composite": true, - "clientRole": false, - "containerId": "10202c48-820f-43e1-9c59-4da0e93028f6" - }, - "requiredCredentials": ["password"], - "otpPolicyType": "totp", - "otpPolicyAlgorithm": "HmacSHA1", - "otpPolicyInitialCounter": 0, - "otpPolicyDigits": 6, - "otpPolicyLookAheadWindow": 1, - "otpPolicyPeriod": 30, - "otpPolicyCodeReusable": false, - "otpSupportedApplications": [ - "totpAppFreeOTPName", - "totpAppGoogleName", - "totpAppMicrosoftAuthenticatorName" - ], - "localizationTexts": {}, - "webAuthnPolicyRpEntityName": "keycloak", - "webAuthnPolicySignatureAlgorithms": ["ES256", "RS256"], - "webAuthnPolicyRpId": "", - "webAuthnPolicyAttestationConveyancePreference": "not specified", - "webAuthnPolicyAuthenticatorAttachment": "not specified", - "webAuthnPolicyRequireResidentKey": "not specified", - "webAuthnPolicyUserVerificationRequirement": "not specified", - "webAuthnPolicyCreateTimeout": 0, - "webAuthnPolicyAvoidSameAuthenticatorRegister": false, - "webAuthnPolicyAcceptableAaguids": [], - "webAuthnPolicyExtraOrigins": [], - "webAuthnPolicyPasswordlessRpEntityName": "keycloak", - "webAuthnPolicyPasswordlessSignatureAlgorithms": ["ES256", "RS256"], - "webAuthnPolicyPasswordlessRpId": "", - "webAuthnPolicyPasswordlessAttestationConveyancePreference": "not specified", - "webAuthnPolicyPasswordlessAuthenticatorAttachment": "not specified", - "webAuthnPolicyPasswordlessRequireResidentKey": "not specified", - "webAuthnPolicyPasswordlessUserVerificationRequirement": "not specified", - "webAuthnPolicyPasswordlessCreateTimeout": 0, - "webAuthnPolicyPasswordlessAvoidSameAuthenticatorRegister": false, - "webAuthnPolicyPasswordlessAcceptableAaguids": [], - "webAuthnPolicyPasswordlessExtraOrigins": [], - "users": [ - { - "id": "75f5ae44-997a-4606-b3c6-edc27a2f7787", - "username": "admin", - "emailVerified": false, - "attributes": { - "is_temporary_admin": ["true"] - }, - "createdTimestamp": 1744804739968, - "enabled": true, - "totp": false, - "credentials": [ - { - "id": "1d248d21-9add-4ad8-8a7f-ff375c45ae2f", - "type": "password", - "createdDate": 1744804740051, - "secretData": "{\"value\":\"JtpjzkDeGtTuQ/cVHmYr8QtQfrwo5mP0GmZQyDhdlMs=\",\"salt\":\"lJtTvGs3GKcXgIcKnyJdlw==\",\"additionalParameters\":{}}", - "credentialData": "{\"hashIterations\":5,\"algorithm\":\"argon2\",\"additionalParameters\":{\"hashLength\":[\"32\"],\"memory\":[\"7168\"],\"type\":[\"id\"],\"version\":[\"1.3\"],\"parallelism\":[\"1\"]}}" - } - ], - "disableableCredentialTypes": [], - "requiredActions": [], - "realmRoles": ["admin", "default-roles-master"], - "notBefore": 0, - "groups": [] - } - ], - "scopeMappings": [ - { - "clientScope": "offline_access", - "roles": ["offline_access"] - } - ], - "clientScopeMappings": { - "account": [ - { - "client": "account-console", - "roles": ["manage-account", "view-groups"] - } - ] - }, - "clients": [ - { - "id": "17980fdb-0e2a-4eed-ba5d-32e621651d7e", - "clientId": "account", - "name": "${client_account}", - "rootUrl": "${authBaseUrl}", - "baseUrl": "/realms/master/account/", - "surrogateAuthRequired": false, - "enabled": true, - "alwaysDisplayInConsole": false, - "clientAuthenticatorType": "client-secret", - "redirectUris": ["/realms/master/account/*"], - "webOrigins": [], - "notBefore": 0, - "bearerOnly": false, - "consentRequired": false, - "standardFlowEnabled": true, - "implicitFlowEnabled": false, - "directAccessGrantsEnabled": false, - "serviceAccountsEnabled": false, - "publicClient": true, - "frontchannelLogout": false, - "protocol": "openid-connect", - "attributes": { - "realm_client": "false", - "post.logout.redirect.uris": "+" - }, - "authenticationFlowBindingOverrides": {}, - "fullScopeAllowed": false, - "nodeReRegistrationTimeout": 0, - "defaultClientScopes": [ - "web-origins", - "acr", - "profile", - "roles", - "basic", - "email" - ], - "optionalClientScopes": [ - "address", - "phone", - "organization", - "offline_access", - "microprofile-jwt" - ] - }, - { - "id": "30dd42d3-55a3-47c8-b3c3-5fa22567d360", - "clientId": "account-console", - "name": "${client_account-console}", - "rootUrl": "${authBaseUrl}", - "baseUrl": "/realms/master/account/", - "surrogateAuthRequired": false, - "enabled": true, - "alwaysDisplayInConsole": false, - "clientAuthenticatorType": "client-secret", - "redirectUris": ["/realms/master/account/*"], - "webOrigins": [], - "notBefore": 0, - "bearerOnly": false, - "consentRequired": false, - "standardFlowEnabled": true, - "implicitFlowEnabled": false, - "directAccessGrantsEnabled": false, - "serviceAccountsEnabled": false, - "publicClient": true, - "frontchannelLogout": false, - "protocol": "openid-connect", - "attributes": { - "realm_client": "false", - "post.logout.redirect.uris": "+", - "pkce.code.challenge.method": "S256" - }, - "authenticationFlowBindingOverrides": {}, - "fullScopeAllowed": false, - "nodeReRegistrationTimeout": 0, - "protocolMappers": [ - { - "id": "cce21460-bc9a-4ed7-9b67-49861a5fd50d", - "name": "audience resolve", - "protocol": "openid-connect", - "protocolMapper": "oidc-audience-resolve-mapper", - "consentRequired": false, - "config": {} - } - ], - "defaultClientScopes": [ - "web-origins", - "acr", - "profile", - "roles", - "basic", - "email" - ], - "optionalClientScopes": [ - "address", - "phone", - "organization", - "offline_access", - "microprofile-jwt" - ] - }, - { - "id": "7b717c60-fd62-46ae-b69a-028b2feca00d", - "clientId": "admin-cli", - "name": "${client_admin-cli}", - "surrogateAuthRequired": false, - "enabled": true, - "alwaysDisplayInConsole": false, - "clientAuthenticatorType": "client-secret", - "redirectUris": [], - "webOrigins": [], - "notBefore": 0, - "bearerOnly": false, - "consentRequired": false, - "standardFlowEnabled": false, - "implicitFlowEnabled": false, - "directAccessGrantsEnabled": true, - "serviceAccountsEnabled": false, - "publicClient": true, - "frontchannelLogout": false, - "protocol": "openid-connect", - "attributes": { - "realm_client": "false", - "client.use.lightweight.access.token.enabled": "true" - }, - "authenticationFlowBindingOverrides": {}, - "fullScopeAllowed": true, - "nodeReRegistrationTimeout": 0, - "defaultClientScopes": [ - "web-origins", - "acr", - "profile", - "roles", - "basic", - "email" - ], - "optionalClientScopes": [ - "address", - "phone", - "organization", - "offline_access", - "microprofile-jwt" - ] - }, - { - "id": "2a45fa0e-d1c8-4b7a-ba6c-bc268ebcd051", - "clientId": "broker", - "name": "${client_broker}", - "surrogateAuthRequired": false, - "enabled": true, - "alwaysDisplayInConsole": false, - "clientAuthenticatorType": "client-secret", - "redirectUris": [], - "webOrigins": [], - "notBefore": 0, - "bearerOnly": true, - "consentRequired": false, - "standardFlowEnabled": true, - "implicitFlowEnabled": false, - "directAccessGrantsEnabled": false, - "serviceAccountsEnabled": false, - "publicClient": false, - "frontchannelLogout": false, - "protocol": "openid-connect", - "attributes": { - "realm_client": "true" - }, - "authenticationFlowBindingOverrides": {}, - "fullScopeAllowed": false, - "nodeReRegistrationTimeout": 0, - "defaultClientScopes": [ - "web-origins", - "acr", - "profile", - "roles", - "basic", - "email" - ], - "optionalClientScopes": [ - "address", - "phone", - "organization", - "offline_access", - "microprofile-jwt" - ] - }, - { - "id": "68dcb411-1fa8-48f3-acf9-e6e8eeff62c8", - "clientId": "master-realm", - "name": "master Realm", - "surrogateAuthRequired": false, - "enabled": true, - "alwaysDisplayInConsole": false, - "clientAuthenticatorType": "client-secret", - "redirectUris": [], - "webOrigins": [], - "notBefore": 0, - "bearerOnly": true, - "consentRequired": false, - "standardFlowEnabled": true, - "implicitFlowEnabled": false, - "directAccessGrantsEnabled": false, - "serviceAccountsEnabled": false, - "publicClient": false, - "frontchannelLogout": false, - "attributes": { - "realm_client": "true" - }, - "authenticationFlowBindingOverrides": {}, - "fullScopeAllowed": false, - "nodeReRegistrationTimeout": 0, - "defaultClientScopes": [ - "web-origins", - "acr", - "profile", - "roles", - "basic", - "email" - ], - "optionalClientScopes": [ - "address", - "phone", - "organization", - "offline_access", - "microprofile-jwt" - ] - }, - { - "id": "59c2a59f-bbfe-414b-8d01-c507882da73c", - "clientId": "security-admin-console", - "name": "${client_security-admin-console}", - "rootUrl": "${authAdminUrl}", - "baseUrl": "/admin/master/console/", - "surrogateAuthRequired": false, - "enabled": true, - "alwaysDisplayInConsole": false, - "clientAuthenticatorType": "client-secret", - "redirectUris": ["/admin/master/console/*"], - "webOrigins": ["+"], - "notBefore": 0, - "bearerOnly": false, - "consentRequired": false, - "standardFlowEnabled": true, - "implicitFlowEnabled": false, - "directAccessGrantsEnabled": false, - "serviceAccountsEnabled": false, - "publicClient": true, - "frontchannelLogout": false, - "protocol": "openid-connect", - "attributes": { - "realm_client": "false", - "client.use.lightweight.access.token.enabled": "true", - "post.logout.redirect.uris": "+", - "pkce.code.challenge.method": "S256" - }, - "authenticationFlowBindingOverrides": {}, - "fullScopeAllowed": true, - "nodeReRegistrationTimeout": 0, - "protocolMappers": [ - { - "id": "0a6040d0-3720-4f04-a44d-7109206cb1b6", - "name": "locale", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "userinfo.token.claim": "true", - "user.attribute": "locale", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "locale", - "jsonType.label": "String" - } - } - ], - "defaultClientScopes": [ - "web-origins", - "acr", - "profile", - "roles", - "basic", - "email" - ], - "optionalClientScopes": [ - "address", - "phone", - "organization", - "offline_access", - "microprofile-jwt" - ] - }, - { - "id": "4b9bb14f-b9fa-4175-9421-e74b215d7cb1", - "clientId": "test-realm", - "name": "test Realm", - "surrogateAuthRequired": false, - "enabled": true, - "alwaysDisplayInConsole": false, - "clientAuthenticatorType": "client-secret", - "redirectUris": [], - "webOrigins": [], - "notBefore": 0, - "bearerOnly": true, - "consentRequired": false, - "standardFlowEnabled": true, - "implicitFlowEnabled": false, - "directAccessGrantsEnabled": false, - "serviceAccountsEnabled": false, - "publicClient": false, - "frontchannelLogout": false, - "attributes": { - "realm_client": "true" - }, - "authenticationFlowBindingOverrides": {}, - "fullScopeAllowed": false, - "nodeReRegistrationTimeout": 0, - "defaultClientScopes": [], - "optionalClientScopes": [] - } - ], - "clientScopes": [ - { - "id": "204cb677-238a-4da3-a823-f91759e7f9df", - "name": "web-origins", - "description": "OpenID Connect scope for add allowed web origins to the access token", - "protocol": "openid-connect", - "attributes": { - "include.in.token.scope": "false", - "consent.screen.text": "", - "display.on.consent.screen": "false" - }, - "protocolMappers": [ - { - "id": "c5d738cf-af5b-483e-9c6a-4deb4b28af3f", - "name": "allowed web origins", - "protocol": "openid-connect", - "protocolMapper": "oidc-allowed-origins-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "access.token.claim": "true" - } - } - ] - }, - { - "id": "6958bf2c-f31a-429b-b16c-3ed592d96e39", - "name": "organization", - "description": "Additional claims about the organization a subject belongs to", - "protocol": "openid-connect", - "attributes": { - "include.in.token.scope": "true", - "consent.screen.text": "${organizationScopeConsentText}", - "display.on.consent.screen": "true" - }, - "protocolMappers": [ - { - "id": "588144fa-ca22-4f87-9d48-d74c9ab7cce4", - "name": "organization", - "protocol": "openid-connect", - "protocolMapper": "oidc-organization-membership-mapper", - "consentRequired": false, - "config": { - "id.token.claim": "true", - "introspection.token.claim": "true", - "access.token.claim": "true", - "claim.name": "organization", - "jsonType.label": "String", - "multivalued": "true" - } - } - ] - }, - { - "id": "229df93f-214d-4845-a960-d96d836f27ed", - "name": "roles", - "description": "OpenID Connect scope for add user roles to the access token", - "protocol": "openid-connect", - "attributes": { - "include.in.token.scope": "false", - "consent.screen.text": "${rolesScopeConsentText}", - "display.on.consent.screen": "true" - }, - "protocolMappers": [ - { - "id": "ac7f28bd-43e0-47b7-ae4f-55af9a225ab4", - "name": "realm roles", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-realm-role-mapper", - "consentRequired": false, - "config": { - "user.attribute": "foo", - "introspection.token.claim": "true", - "access.token.claim": "true", - "claim.name": "realm_access.roles", - "jsonType.label": "String", - "multivalued": "true" - } - }, - { - "id": "7c60ef9d-4bcb-48fd-8418-84c65196c51e", - "name": "client roles", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-client-role-mapper", - "consentRequired": false, - "config": { - "user.attribute": "foo", - "introspection.token.claim": "true", - "access.token.claim": "true", - "claim.name": "resource_access.${client_id}.roles", - "jsonType.label": "String", - "multivalued": "true" - } - }, - { - "id": "099b0944-177f-44af-a6d2-c927d5eb9c9c", - "name": "audience resolve", - "protocol": "openid-connect", - "protocolMapper": "oidc-audience-resolve-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "access.token.claim": "true" - } - } - ] - }, - { - "id": "39f1ebfb-3912-4b66-a75c-3648bec0e37f", - "name": "basic", - "description": "OpenID Connect scope for add all basic claims to the token", - "protocol": "openid-connect", - "attributes": { - "include.in.token.scope": "false", - "display.on.consent.screen": "false" - }, - "protocolMappers": [ - { - "id": "11f60cd5-f906-4dad-83d2-be4eb22b3708", - "name": "sub", - "protocol": "openid-connect", - "protocolMapper": "oidc-sub-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "access.token.claim": "true" - } - }, - { - "id": "cd97a289-7cb9-4263-bc80-b28675a09d2c", - "name": "auth_time", - "protocol": "openid-connect", - "protocolMapper": "oidc-usersessionmodel-note-mapper", - "consentRequired": false, - "config": { - "user.session.note": "AUTH_TIME", - "id.token.claim": "true", - "introspection.token.claim": "true", - "access.token.claim": "true", - "claim.name": "auth_time", - "jsonType.label": "long" - } - } - ] - }, - { - "id": "44193e7b-b4f0-4545-bc1f-d113b1f689a2", - "name": "microprofile-jwt", - "description": "Microprofile - JWT built-in scope", - "protocol": "openid-connect", - "attributes": { - "include.in.token.scope": "true", - "display.on.consent.screen": "false" - }, - "protocolMappers": [ - { - "id": "33f84fa8-16a2-43af-ab1c-22287d86f4e1", - "name": "groups", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-realm-role-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "multivalued": "true", - "user.attribute": "foo", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "groups", - "jsonType.label": "String" - } - }, - { - "id": "0645a1f6-c545-43c5-91a8-67b451512486", - "name": "upn", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "userinfo.token.claim": "true", - "user.attribute": "username", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "upn", - "jsonType.label": "String" - } - } - ] - }, - { - "id": "500e314e-40c0-40f7-ad0c-004bb37ab8c0", - "name": "email", - "description": "OpenID Connect built-in scope: email", - "protocol": "openid-connect", - "attributes": { - "include.in.token.scope": "true", - "consent.screen.text": "${emailScopeConsentText}", - "display.on.consent.screen": "true" - }, - "protocolMappers": [ - { - "id": "b5b20994-930e-48ce-8382-5c5bfda58054", - "name": "email verified", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-property-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "userinfo.token.claim": "true", - "user.attribute": "emailVerified", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "email_verified", - "jsonType.label": "boolean" - } - }, - { - "id": "f1cbee3a-8b36-4d92-bb5a-d2f0741e2acd", - "name": "email", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "userinfo.token.claim": "true", - "user.attribute": "email", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "email", - "jsonType.label": "String" - } - } - ] - }, - { - "id": "8e9ee770-d4c7-49f9-b3e1-8b8839494249", - "name": "phone", - "description": "OpenID Connect built-in scope: phone", - "protocol": "openid-connect", - "attributes": { - "include.in.token.scope": "true", - "consent.screen.text": "${phoneScopeConsentText}", - "display.on.consent.screen": "true" - }, - "protocolMappers": [ - { - "id": "d2fbecc4-05cd-46d1-8c2d-76719b76675d", - "name": "phone number", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "userinfo.token.claim": "true", - "user.attribute": "phoneNumber", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "phone_number", - "jsonType.label": "String" - } - }, - { - "id": "3fe410b9-0d63-42c5-a044-02cd7ce27b8f", - "name": "phone number verified", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "userinfo.token.claim": "true", - "user.attribute": "phoneNumberVerified", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "phone_number_verified", - "jsonType.label": "boolean" - } - } - ] - }, - { - "id": "7f5c5b83-f705-4ec1-a8ea-03d991d893b9", - "name": "role_list", - "description": "SAML role list", - "protocol": "saml", - "attributes": { - "consent.screen.text": "${samlRoleListScopeConsentText}", - "display.on.consent.screen": "true" - }, - "protocolMappers": [ - { - "id": "98f97dec-2935-43f3-a87c-190154baf50e", - "name": "role list", - "protocol": "saml", - "protocolMapper": "saml-role-list-mapper", - "consentRequired": false, - "config": { - "single": "false", - "attribute.nameformat": "Basic", - "attribute.name": "Role" - } - } - ] - }, - { - "id": "87cadeba-210e-44d1-b788-8d044b389727", - "name": "address", - "description": "OpenID Connect built-in scope: address", - "protocol": "openid-connect", - "attributes": { - "include.in.token.scope": "true", - "consent.screen.text": "${addressScopeConsentText}", - "display.on.consent.screen": "true" - }, - "protocolMappers": [ - { - "id": "e561fbce-d658-4953-915a-8786f86b4da7", - "name": "address", - "protocol": "openid-connect", - "protocolMapper": "oidc-address-mapper", - "consentRequired": false, - "config": { - "user.attribute.formatted": "formatted", - "user.attribute.country": "country", - "introspection.token.claim": "true", - "user.attribute.postal_code": "postal_code", - "userinfo.token.claim": "true", - "user.attribute.street": "street", - "id.token.claim": "true", - "user.attribute.region": "region", - "access.token.claim": "true", - "user.attribute.locality": "locality" - } - } - ] - }, - { - "id": "0e17f3d3-c95d-4bfa-8905-fc2c46744796", - "name": "acr", - "description": "OpenID Connect scope for add acr (authentication context class reference) to the token", - "protocol": "openid-connect", - "attributes": { - "include.in.token.scope": "false", - "display.on.consent.screen": "false" - }, - "protocolMappers": [ - { - "id": "c9eb53cd-a36b-4090-aae5-35c56e92f140", - "name": "acr loa level", - "protocol": "openid-connect", - "protocolMapper": "oidc-acr-mapper", - "consentRequired": false, - "config": { - "id.token.claim": "true", - "introspection.token.claim": "true", - "access.token.claim": "true" - } - } - ] - }, - { - "id": "d1734bba-a423-4768-9037-973635f4d64e", - "name": "offline_access", - "description": "OpenID Connect built-in scope: offline_access", - "protocol": "openid-connect", - "attributes": { - "consent.screen.text": "${offlineAccessScopeConsentText}", - "display.on.consent.screen": "true" - } - }, - { - "id": "891ab605-54d0-4b71-b55e-d13e9138a8cc", - "name": "profile", - "description": "OpenID Connect built-in scope: profile", - "protocol": "openid-connect", - "attributes": { - "include.in.token.scope": "true", - "consent.screen.text": "${profileScopeConsentText}", - "display.on.consent.screen": "true" - }, - "protocolMappers": [ - { - "id": "78f4a125-2730-47a5-a429-62f37965f391", - "name": "nickname", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "userinfo.token.claim": "true", - "user.attribute": "nickname", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "nickname", - "jsonType.label": "String" - } - }, - { - "id": "8dd88372-60ac-45b5-aa3f-a7359bfe4721", - "name": "zoneinfo", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "userinfo.token.claim": "true", - "user.attribute": "zoneinfo", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "zoneinfo", - "jsonType.label": "String" - } - }, - { - "id": "f980949c-3187-43d5-914a-41ed3df28603", - "name": "username", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "userinfo.token.claim": "true", - "user.attribute": "username", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "preferred_username", - "jsonType.label": "String" - } - }, - { - "id": "86f666f4-b84f-4f90-b4da-466fc71131a7", - "name": "profile", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "userinfo.token.claim": "true", - "user.attribute": "profile", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "profile", - "jsonType.label": "String" - } - }, - { - "id": "551eb2e7-de26-424c-83fe-a0df535dc3a3", - "name": "website", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "userinfo.token.claim": "true", - "user.attribute": "website", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "website", - "jsonType.label": "String" - } - }, - { - "id": "708067ad-2112-43be-bb97-874cc2d3f6e5", - "name": "family name", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "userinfo.token.claim": "true", - "user.attribute": "lastName", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "family_name", - "jsonType.label": "String" - } - }, - { - "id": "bf9a553a-5688-4205-be3c-f39ab7c0ef44", - "name": "gender", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "userinfo.token.claim": "true", - "user.attribute": "gender", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "gender", - "jsonType.label": "String" - } - }, - { - "id": "6e65b3f2-4fb5-4a5e-bcb5-29d03422c14c", - "name": "given name", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "userinfo.token.claim": "true", - "user.attribute": "firstName", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "given_name", - "jsonType.label": "String" - } - }, - { - "id": "709afabd-6e20-46a2-91f1-eb37bf43a81e", - "name": "locale", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "userinfo.token.claim": "true", - "user.attribute": "locale", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "locale", - "jsonType.label": "String" - } - }, - { - "id": "2cef61ef-cb7e-43e7-b501-b57f060fb99e", - "name": "birthdate", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "userinfo.token.claim": "true", - "user.attribute": "birthdate", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "birthdate", - "jsonType.label": "String" - } - }, - { - "id": "24e00bfb-c1a3-4efb-ab16-62db6b00ab0f", - "name": "picture", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "userinfo.token.claim": "true", - "user.attribute": "picture", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "picture", - "jsonType.label": "String" - } - }, - { - "id": "599645cb-dc46-4c52-b366-5b0d21498aff", - "name": "full name", - "protocol": "openid-connect", - "protocolMapper": "oidc-full-name-mapper", - "consentRequired": false, - "config": { - "id.token.claim": "true", - "introspection.token.claim": "true", - "access.token.claim": "true", - "userinfo.token.claim": "true" - } - }, - { - "id": "c37dfd9e-9d03-4eb0-a531-8469e05002c5", - "name": "middle name", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "userinfo.token.claim": "true", - "user.attribute": "middleName", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "middle_name", - "jsonType.label": "String" - } - }, - { - "id": "3c9fd938-d90c-482b-8a3e-a2493c534981", - "name": "updated at", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "introspection.token.claim": "true", - "userinfo.token.claim": "true", - "user.attribute": "updatedAt", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "updated_at", - "jsonType.label": "long" - } - } - ] - }, - { - "id": "95f8cba8-d15d-4b95-acbc-7a89b40c329d", - "name": "saml_organization", - "description": "Organization Membership", - "protocol": "saml", - "attributes": { - "display.on.consent.screen": "false" - }, - "protocolMappers": [ - { - "id": "c6058070-af3e-4afd-9588-b79ea3085383", - "name": "organization", - "protocol": "saml", - "protocolMapper": "saml-organization-membership-mapper", - "consentRequired": false, - "config": {} - } - ] - } - ], - "defaultDefaultClientScopes": [ - "role_list", - "saml_organization", - "profile", - "email", - "roles", - "web-origins", - "acr", - "basic" - ], - "defaultOptionalClientScopes": [ - "offline_access", - "address", - "phone", - "microprofile-jwt", - "organization" - ], - "browserSecurityHeaders": { - "contentSecurityPolicyReportOnly": "", - "xContentTypeOptions": "nosniff", - "referrerPolicy": "no-referrer", - "xRobotsTag": "none", - "xFrameOptions": "SAMEORIGIN", - "contentSecurityPolicy": "frame-src 'self'; frame-ancestors 'self'; object-src 'none';", - "xXSSProtection": "1; mode=block", - "strictTransportSecurity": "max-age=31536000; includeSubDomains" - }, - "smtpServer": {}, - "eventsEnabled": false, - "eventsListeners": ["jboss-logging"], - "enabledEventTypes": [], - "adminEventsEnabled": false, - "adminEventsDetailsEnabled": false, - "identityProviders": [], - "identityProviderMappers": [], - "components": { - "org.keycloak.services.clientregistration.policy.ClientRegistrationPolicy": [ - { - "id": "eaaedd6a-cd62-4c3c-8e84-46349a6184d0", - "name": "Allowed Protocol Mapper Types", - "providerId": "allowed-protocol-mappers", - "subType": "anonymous", - "subComponents": {}, - "config": { - "allowed-protocol-mapper-types": [ - "saml-role-list-mapper", - "oidc-usermodel-attribute-mapper", - "saml-user-attribute-mapper", - "oidc-usermodel-property-mapper", - "oidc-full-name-mapper", - "oidc-sha256-pairwise-sub-mapper", - "saml-user-property-mapper", - "oidc-address-mapper" - ] - } - }, - { - "id": "9c00e8fc-20c6-4a1b-a800-55b6e859f365", - "name": "Allowed Client Scopes", - "providerId": "allowed-client-templates", - "subType": "anonymous", - "subComponents": {}, - "config": { - "allow-default-scopes": ["true"] - } - }, - { - "id": "2e694fd5-601c-4c0c-9d87-be9b0489c2c2", - "name": "Trusted Hosts", - "providerId": "trusted-hosts", - "subType": "anonymous", - "subComponents": {}, - "config": { - "host-sending-registration-request-must-match": ["true"], - "client-uris-must-match": ["true"] - } - }, - { - "id": "6ea1b304-94ae-4655-bc91-a46754ff3d26", - "name": "Allowed Client Scopes", - "providerId": "allowed-client-templates", - "subType": "authenticated", - "subComponents": {}, - "config": { - "allow-default-scopes": ["true"] - } - }, - { - "id": "e79c8888-128e-4876-9ebe-2856a1d042c2", - "name": "Consent Required", - "providerId": "consent-required", - "subType": "anonymous", - "subComponents": {}, - "config": {} - }, - { - "id": "584f41cb-39e6-42b2-af41-15a515268360", - "name": "Max Clients Limit", - "providerId": "max-clients", - "subType": "anonymous", - "subComponents": {}, - "config": { - "max-clients": ["200"] - } - }, - { - "id": "c6b0070e-d511-4005-9b42-dd175173fd89", - "name": "Full Scope Disabled", - "providerId": "scope", - "subType": "anonymous", - "subComponents": {}, - "config": {} - }, - { - "id": "56d7d42f-e443-4080-a644-fd523b3f34a5", - "name": "Allowed Protocol Mapper Types", - "providerId": "allowed-protocol-mappers", - "subType": "authenticated", - "subComponents": {}, - "config": { - "allowed-protocol-mapper-types": [ - "saml-role-list-mapper", - "oidc-address-mapper", - "oidc-full-name-mapper", - "oidc-sha256-pairwise-sub-mapper", - "oidc-usermodel-attribute-mapper", - "oidc-usermodel-property-mapper", - "saml-user-attribute-mapper", - "saml-user-property-mapper" - ] - } - } - ], - "org.keycloak.userprofile.UserProfileProvider": [ - { - "id": "174c56e9-46c0-4b2d-9507-5a5fc7b74929", - "providerId": "declarative-user-profile", - "subComponents": {}, - "config": { - "kc.user.profile.config": [ - "{\"attributes\":[{\"name\":\"username\",\"displayName\":\"${username}\",\"validations\":{\"length\":{\"min\":3,\"max\":255},\"username-prohibited-characters\":{},\"up-username-not-idn-homograph\":{}},\"permissions\":{\"view\":[\"admin\",\"user\"],\"edit\":[\"admin\",\"user\"]},\"multivalued\":false},{\"name\":\"email\",\"displayName\":\"${email}\",\"validations\":{\"email\":{},\"length\":{\"max\":255}},\"permissions\":{\"view\":[\"admin\",\"user\"],\"edit\":[\"admin\",\"user\"]},\"multivalued\":false},{\"name\":\"firstName\",\"displayName\":\"${firstName}\",\"validations\":{\"length\":{\"max\":255},\"person-name-prohibited-characters\":{}},\"permissions\":{\"view\":[\"admin\",\"user\"],\"edit\":[\"admin\",\"user\"]},\"multivalued\":false},{\"name\":\"lastName\",\"displayName\":\"${lastName}\",\"validations\":{\"length\":{\"max\":255},\"person-name-prohibited-characters\":{}},\"permissions\":{\"view\":[\"admin\",\"user\"],\"edit\":[\"admin\",\"user\"]},\"multivalued\":false}],\"groups\":[{\"name\":\"user-metadata\",\"displayHeader\":\"User metadata\",\"displayDescription\":\"Attributes, which refer to user metadata\"}]}" - ] - } - } - ], - "org.keycloak.keys.KeyProvider": [ - { - "id": "47bb7102-e487-4cc9-8154-515f20181108", - "name": "rsa-generated", - "providerId": "rsa-generated", - "subComponents": {}, - "config": { - "privateKey": [ - "MIIEpAIBAAKCAQEAtIenRRUFCtCyVHne6Ser5NiuRBLzZNvm64BWErtHfutq6+t5MjY2mnE8GdUfbX1/9k7tx+st3y1AeVgqCFsOKqGOk2Ikl+p5T2qLjYHAo86mTbGVoc5uC6GFwDmJV3Mq2vrVwdA1cvCWOR0he3Z3lOek3ZpRg66mIdAthNOmwn1vxjBXRkKEFzRIZK2GYnrwAMApaSCFqF8YYaW9mW2/Nt9ytNslC98yWFIe0dVLmgeD0K12pnnAoT19Quu0Oj9exofLUGTdRm8GKIPta9WGsRuRgE1/oiXoqb0nVpaDMBqz5cgs6TSdgr39v76cfakHSl8ozv5eeyjM6TYg3aE2kQIDAQABAoIBAA3IY41jJvDl8Q+BBHNBi56bqmZZGgsDvPQS5r9kW/eFKrMbVbPvLqkI5yFDw7P8xmW8Lew6+NQWpNr+z6q2pPS9Q+Ddt9R/Wsak6EWj99ypvMmmurlRRNaPfOIpomIyUT3Js8MpzcLaOmXe4v0FlOih7NTcYMfQcC+ZsLf43rzvbILAT/JLXb0r8rnBV2y81ao4U/zE912vv/jaNh8QgTiPkxhyN3F6qLYD1eylxUa3pTcb4sa4YDCjsrIik8b2iE62stuQ48rBKiYuWoZi4foPCxWDyeNfNPWRrifH2eFMGho+BYzyhSRX042UJJ6iZeIWIHEJGy/oWE7JE83OPT8CgYEA+h1zk/6HoDAv32CRI52r4w/N0i8V2GeC5/nUr4dW8oI8VSkqMWktFn/ZxC2tU93avxj8WgMA7xC/LbZ/lEIiphq0vcsSKTJd/UWugirbtXN76LSvYzoCeTWvwO2wS/YShDmzdapvsqYUa+oaVqZmbavLJlBl0Cz8ytcvDiFeQtcCgYEAuMcPqg0AzezqyD9urJg7RI3Kcpg2NeezWhlfXpbG5GQqlxXK//tOjyKaymkGo12tuzAgjaeiUT5uiPaZgxJ4s2OA57JpYF3L3ZvrguesabaGC1w20MCYr83C+GIYF7Ozikq8FZ5+aJrd6ns5e6bBb2joC6UEjVUg64ai/dCzDNcCgYEA45RIxjCjV66A4NANQEsHS+Plc4pEZlRJWKqKS+zpwF+gZhy+t5br370VeNvXCqijkZ46f+ybvOuQCRg1ncFPpbRHISrVq4aY3wu4bdhxcflSlbtSmwb9mSywbuvXrkaJMqcOE9KxL+zOSCMLNCzUppXak1I0UeedXTPPLRxPmKECgYEAnqLADwWU4DZ7pynWUbVshMGawmFtgUAIGd1YpHOcE+7vJcEfBD/0RSy3aflbKpw9kEyUVilKUKfh7BKS3xXXrGNMAx+IGqTMZtj7C+rseeGrGUu0/+mp7J0hu280Mf0ksiDRc1ocOqBiz3G1ezRCM+0D8yNcUh544dw4SOKJJgcCgYAQlnSOqosWVuVV7NPuqs9Twcm7Tm+/CjKeIr3FJE9zXzyBJ1UI+UV9i8356WWcTVCMOQEQ4mR+idmxalE5czctIie73ty2gxnSA5Iafpy0nn6qaEArtVbArBg350yueqng2RO60YyjNU0coyfh9dAfXkj5Az+V+wflX/2UZ4JJdw==" - ], - "keyUse": ["SIG"], - "certificate": [ - "MIICmzCCAYMCBgGWPnd60TANBgkqhkiG9w0BAQsFADARMQ8wDQYDVQQDDAZtYXN0ZXIwHhcNMjUwNDE2MTE1NzE5WhcNMzUwNDE2MTE1ODU5WjARMQ8wDQYDVQQDDAZtYXN0ZXIwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQC0h6dFFQUK0LJUed7pJ6vk2K5EEvNk2+brgFYSu0d+62rr63kyNjaacTwZ1R9tfX/2Tu3H6y3fLUB5WCoIWw4qoY6TYiSX6nlPaouNgcCjzqZNsZWhzm4LoYXAOYlXcyra+tXB0DVy8JY5HSF7dneU56TdmlGDrqYh0C2E06bCfW/GMFdGQoQXNEhkrYZievAAwClpIIWoXxhhpb2Zbb8233K02yUL3zJYUh7R1UuaB4PQrXamecChPX1C67Q6P17Gh8tQZN1GbwYog+1r1YaxG5GATX+iJeipvSdWloMwGrPlyCzpNJ2Cvf2/vpx9qQdKXyjO/l57KMzpNiDdoTaRAgMBAAEwDQYJKoZIhvcNAQELBQADggEBAI5nKcSg1AfgXRkubow1O4yPX1tJ5GaOyPTz4uIuadbtfMk0p6Q8LSdMHjtprJ3pAQjMaIxQBWpuedrBYf3XRyYvapmt6xnLO2RkGB2yxYYCpIf9/ovB+stmkKsWKxP+GA38HDsvw8pqHMVMPJvqaKnNk5r1u7ic/awNWqCAA2zFxtT2aRZCx15jE7fBc7uRbe1iLumJNQPZ3EPYaXYgeu+dFWpNSvwuPYRGc1Bm7VFHrSqk1jFr63llMAiyJujMJBdB3JJGws2zgBnQBVTp1eRrv6NkOiZT/WVRCkY263poC7aEbJFI3WcUkvKcPnHSNOfPbZkkI0ND3IeLUKK+dMg=" - ], - "priority": ["100"] - } - }, - { - "id": "bc5eb611-7d39-48d0-b08c-4f24fdfbc397", - "name": "hmac-generated-hs512", - "providerId": "hmac-generated", - "subComponents": {}, - "config": { - "kid": ["96709a88-f5c7-4869-9b75-ee92423e0a42"], - "secret": [ - "gh2Ge2AEf4e6u-ezQBqn1K-wgfSR4daGjRrMw0TQUSWccZ5piq6-AB4SqMXU9a4vdcEju7JSP-heOTlLsqdVNOgPbu0qiLdS-_tntcn8nZ7w8Pk-iOxgfbpq94RrU8StJMNR7WQfOlOeU5DwfjsbpgrErn5Oi3R3m37RZK48IAU" - ], - "priority": ["100"], - "algorithm": ["HS512"] - } - }, - { - "id": "dc3e105b-1ef5-4e46-bd2d-0614fa51ecc4", - "name": "aes-generated", - "providerId": "aes-generated", - "subComponents": {}, - "config": { - "kid": ["72aff008-5d1d-4271-9399-ca83b88c0b82"], - "secret": ["ekNo8k_fi2O0MjYMBW1Fxw"], - "priority": ["100"] - } - }, - { - "id": "5da54863-69d2-473d-9a8d-4a1f20fc87ef", - "name": "rsa-enc-generated", - "providerId": "rsa-enc-generated", - "subComponents": {}, - "config": { - "privateKey": [ - "MIIEpAIBAAKCAQEAsuAaMlm0k0Sx5948Kyxxvskqw3bLCUoqJ47zFzmRaXiDwR4t2bQe8eU6a7Xp3woQ4kg6gwXAwVHh0un3dab5QBomwf/gWyWJFTOAot/JE2QIX6FTtgBdr6y/XWgt32jw01EaDLMq2UT28u3ARGZ1OlXUM6k/wSgPRF26d4E+ZH+SiHBJWXe6DaUU6TLCNrk3L8GumwcVgh/93ffm/7xpb2XLt9v4Sh/GZ1enwDnnYiHZxJnTr4mbK1ZJSScNGRxlEKjo+zq1IS74hCLML3nBD1VeAf2L+i1ANIL69gK8+/tYnSnAF2hfeQN8xEu7/SiJmrip7s/nLc0+ATWNrPNtjwIDAQABAoIBAAii9DxHQ2GXyPBcNSU4gGso7jiBPUPRRlKiESanWTNxnL+B/4VOi6WpukgYgLseJQRDXs2UIKxrtkECvu6MKi+MuEQPYLKhWQp934hrYtJLbd+AKbkd52gal20O2BOX84Z74fk/AMd8NKp9exYtzWTn8bIeAQbj6R+noSjn+pwUqTNLwk+AHvS3IWUJRJbrjNW6nLhyp1C+3u5YT5CmoVNoKxb0teRmUtWr4HK3QUvwWooLV+q3s3TNCLMDfZOrVZpHQ93yC6HLqMcZq4JEcxre+QNXnYR7MYIPpXRpa0nGiwRnCEc8BiKmPLZobHkUkPwz65UcKIyoUCKlAigiy+ECgYEA5isjQxu7bNiUTcIaRRZUzP6TetKkJnDX4uVKJLK99BNV53evFAGeeGL9kiQ5PA1Iu+LBKBsWG8dL1sejz1i1kICXllVl3AvbB2MN3yTL5zSa+SozzqYZB/6yWLbK+y+EdRMGj0LugGDGYD8ap7h93lm9JkooMwvEWqBxQqlbXpcCgYEAxvNJYYNqddJ+47WjpiQCkLDd7u3z9EVSZQa/cwfRVu/mrvLfFkLBTZnxEA9fAEZ/sR3RBbNo/UIdR8MfAzMYNJFuO9+4AulT6yxlIeNRQaB+rH9YUD2Hy8qPU5TbpPhN6TIWg8qshX4B8SxoNPJoiAKpArdUeHP6Nx2vxXRpP8kCgYAcjm+SjOdFCt3jg9iEh8+/mzoq++VXy5pNUUtQoEiG9rsqu6OiJM1HfGifcBUVyUQj4285jZrBmYlkPWKqgAQOyJWGFlRL58Cl+vkmnUcbCWDM1xqUYfErF8OC1DL81Rlm+RRQQ+qZTOhv2oRxGKetJY8dKAgyxRv4bn1+2so2QwKBgQCKuBfyZi9U9/CB1aTFs1YWjTwx3Li9GZjZ2FqlWk4c0CmI0s+6NdGSykPLbuxOxNlEJgYYc4BBFlhUMTjugjHedYjnNpaXcRmSYOIjPtzpZX7tx91MFZsZ/aLyJFkCLiAk+Ue5nRet/K5d+xit0lgQfcpamnnLgxJ0W76zbvf0AQKBgQCn55Yh5KpSmPkDeChnRMX674Qmr8SS1+qG65U19OfXEF0ruzRltSGYSf1ifBd4o51Y7q/6TKdqh+kYH05AV1pJKbtFO8k5LOUzmbl6FoTsDMAzvbTpe3vOHZg0jAEdSw/zTlb0CSX6PCndY3NBxno9goOzB/PjSqritTgJOStq/w==" - ], - "keyUse": ["ENC"], - "certificate": [ - "MIICmzCCAYMCBgGWPnd7QDANBgkqhkiG9w0BAQsFADARMQ8wDQYDVQQDDAZtYXN0ZXIwHhcNMjUwNDE2MTE1NzE5WhcNMzUwNDE2MTE1ODU5WjARMQ8wDQYDVQQDDAZtYXN0ZXIwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCy4BoyWbSTRLHn3jwrLHG+ySrDdssJSionjvMXOZFpeIPBHi3ZtB7x5TprtenfChDiSDqDBcDBUeHS6fd1pvlAGibB/+BbJYkVM4Ci38kTZAhfoVO2AF2vrL9daC3faPDTURoMsyrZRPby7cBEZnU6VdQzqT/BKA9EXbp3gT5kf5KIcElZd7oNpRTpMsI2uTcvwa6bBxWCH/3d9+b/vGlvZcu32/hKH8ZnV6fAOediIdnEmdOviZsrVklJJw0ZHGUQqOj7OrUhLviEIswvecEPVV4B/Yv6LUA0gvr2Arz7+1idKcAXaF95A3zES7v9KImauKnuz+ctzT4BNY2s822PAgMBAAEwDQYJKoZIhvcNAQELBQADggEBADWyrt7oJoXz+vBurCWY9WZrJzh+4Rg4XYlUwpLdrjzOxOgII2bk8arn1pk9ZiAKE4WFJ3S4ixwM/q8xf4Hkgxp4dNMkbE+TUYJsu+zX5SGJXe+1neQlgVEG27ILnquUX5JkrJBmXuTcPz8q6c1HqG6HF9IibVRzLsyUYdyTEO0uhJrcn0ZZ9XS8YmkBfbbC589FQqcLRebte2+9zbVrUPOJaOmt9V9oM4jUHAi6Rrf+Boatb1hBD0uaOTzJJ0DgZZi8zEblLWyRo9Wts9CaQ1tLJ1Vg79wuwvErzee3kVlYb/p2TCOtP6WK9NDpwvJ/YW4CMy+a1/710xDGtaeg2oU=" - ], - "priority": ["100"], - "algorithm": ["RSA-OAEP"] - } - } - ] - }, - "internationalizationEnabled": false, - "supportedLocales": [], - "authenticationFlows": [ - { - "id": "abe67ec8-48d2-4edb-8517-2ab5885ea549", - "alias": "Account verification options", - "description": "Method with which to verity the existing account", - "providerId": "basic-flow", - "topLevel": false, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "idp-email-verification", - "authenticatorFlow": false, - "requirement": "ALTERNATIVE", - "priority": 10, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticatorFlow": true, - "requirement": "ALTERNATIVE", - "priority": 20, - "autheticatorFlow": true, - "flowAlias": "Verify Existing Account by Re-authentication", - "userSetupAllowed": false - } - ] - }, - { - "id": "0c5ba11d-163f-45e0-8146-22abc12f4fb5", - "alias": "Browser - Conditional OTP", - "description": "Flow to determine if the OTP is required for the authentication", - "providerId": "basic-flow", - "topLevel": false, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "conditional-user-configured", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 10, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticator": "auth-otp-form", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 20, - "autheticatorFlow": false, - "userSetupAllowed": false - } - ] - }, - { - "id": "3b6cd857-3807-4a62-97e0-a1384da77523", - "alias": "Direct Grant - Conditional OTP", - "description": "Flow to determine if the OTP is required for the authentication", - "providerId": "basic-flow", - "topLevel": false, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "conditional-user-configured", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 10, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticator": "direct-grant-validate-otp", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 20, - "autheticatorFlow": false, - "userSetupAllowed": false - } - ] - }, - { - "id": "306d3eeb-792d-4937-9860-b360ca34e764", - "alias": "First broker login - Conditional OTP", - "description": "Flow to determine if the OTP is required for the authentication", - "providerId": "basic-flow", - "topLevel": false, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "conditional-user-configured", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 10, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticator": "auth-otp-form", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 20, - "autheticatorFlow": false, - "userSetupAllowed": false - } - ] - }, - { - "id": "c03c34c3-da1e-4d08-8857-1e59c3dc279a", - "alias": "Handle Existing Account", - "description": "Handle what to do if there is existing account with same email/username like authenticated identity provider", - "providerId": "basic-flow", - "topLevel": false, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "idp-confirm-link", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 10, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticatorFlow": true, - "requirement": "REQUIRED", - "priority": 20, - "autheticatorFlow": true, - "flowAlias": "Account verification options", - "userSetupAllowed": false - } - ] - }, - { - "id": "52f7662e-3180-4ced-86ea-3dcc52fcf925", - "alias": "Reset - Conditional OTP", - "description": "Flow to determine if the OTP should be reset or not. Set to REQUIRED to force.", - "providerId": "basic-flow", - "topLevel": false, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "conditional-user-configured", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 10, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticator": "reset-otp", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 20, - "autheticatorFlow": false, - "userSetupAllowed": false - } - ] - }, - { - "id": "434f457f-5e1b-4a4d-af57-ab9a2013d68d", - "alias": "User creation or linking", - "description": "Flow for the existing/non-existing user alternatives", - "providerId": "basic-flow", - "topLevel": false, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticatorConfig": "create unique user config", - "authenticator": "idp-create-user-if-unique", - "authenticatorFlow": false, - "requirement": "ALTERNATIVE", - "priority": 10, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticatorFlow": true, - "requirement": "ALTERNATIVE", - "priority": 20, - "autheticatorFlow": true, - "flowAlias": "Handle Existing Account", - "userSetupAllowed": false - } - ] - }, - { - "id": "8410476c-6ba9-4e42-90ce-d492ce447a11", - "alias": "Verify Existing Account by Re-authentication", - "description": "Reauthentication of existing account", - "providerId": "basic-flow", - "topLevel": false, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "idp-username-password-form", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 10, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticatorFlow": true, - "requirement": "CONDITIONAL", - "priority": 20, - "autheticatorFlow": true, - "flowAlias": "First broker login - Conditional OTP", - "userSetupAllowed": false - } - ] - }, - { - "id": "b2be31f8-19de-4fbc-86d3-f4126d081514", - "alias": "browser", - "description": "Browser based authentication", - "providerId": "basic-flow", - "topLevel": true, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "auth-cookie", - "authenticatorFlow": false, - "requirement": "ALTERNATIVE", - "priority": 10, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticator": "auth-spnego", - "authenticatorFlow": false, - "requirement": "DISABLED", - "priority": 20, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticator": "identity-provider-redirector", - "authenticatorFlow": false, - "requirement": "ALTERNATIVE", - "priority": 25, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticatorFlow": true, - "requirement": "ALTERNATIVE", - "priority": 30, - "autheticatorFlow": true, - "flowAlias": "forms", - "userSetupAllowed": false - } - ] - }, - { - "id": "29fe5fc8-7a57-401a-b686-bc0a8ed3b975", - "alias": "clients", - "description": "Base authentication for clients", - "providerId": "client-flow", - "topLevel": true, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "client-secret", - "authenticatorFlow": false, - "requirement": "ALTERNATIVE", - "priority": 10, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticator": "client-jwt", - "authenticatorFlow": false, - "requirement": "ALTERNATIVE", - "priority": 20, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticator": "client-secret-jwt", - "authenticatorFlow": false, - "requirement": "ALTERNATIVE", - "priority": 30, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticator": "client-x509", - "authenticatorFlow": false, - "requirement": "ALTERNATIVE", - "priority": 40, - "autheticatorFlow": false, - "userSetupAllowed": false - } - ] - }, - { - "id": "0ac78504-b5a2-4c3d-9c37-902700a23363", - "alias": "direct grant", - "description": "OpenID Connect Resource Owner Grant", - "providerId": "basic-flow", - "topLevel": true, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "direct-grant-validate-username", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 10, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticator": "direct-grant-validate-password", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 20, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticatorFlow": true, - "requirement": "CONDITIONAL", - "priority": 30, - "autheticatorFlow": true, - "flowAlias": "Direct Grant - Conditional OTP", - "userSetupAllowed": false - } - ] - }, - { - "id": "a30731f4-0ef3-4fc5-9e4c-937e60388642", - "alias": "docker auth", - "description": "Used by Docker clients to authenticate against the IDP", - "providerId": "basic-flow", - "topLevel": true, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "docker-http-basic-authenticator", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 10, - "autheticatorFlow": false, - "userSetupAllowed": false - } - ] - }, - { - "id": "7f6e6a7c-09d0-4100-b6fe-3f2dfcd44274", - "alias": "first broker login", - "description": "Actions taken after first broker login with identity provider account, which is not yet linked to any Keycloak account", - "providerId": "basic-flow", - "topLevel": true, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticatorConfig": "review profile config", - "authenticator": "idp-review-profile", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 10, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticatorFlow": true, - "requirement": "REQUIRED", - "priority": 20, - "autheticatorFlow": true, - "flowAlias": "User creation or linking", - "userSetupAllowed": false - } - ] - }, - { - "id": "905f088c-5904-41d4-97fd-cdc11dcc8e6a", - "alias": "forms", - "description": "Username, password, otp and other auth forms.", - "providerId": "basic-flow", - "topLevel": false, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "auth-username-password-form", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 10, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticatorFlow": true, - "requirement": "CONDITIONAL", - "priority": 20, - "autheticatorFlow": true, - "flowAlias": "Browser - Conditional OTP", - "userSetupAllowed": false - } - ] - }, - { - "id": "93271f48-3852-4898-acb3-712c0ac29099", - "alias": "registration", - "description": "Registration flow", - "providerId": "basic-flow", - "topLevel": true, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "registration-page-form", - "authenticatorFlow": true, - "requirement": "REQUIRED", - "priority": 10, - "autheticatorFlow": true, - "flowAlias": "registration form", - "userSetupAllowed": false - } - ] - }, - { - "id": "c0b4f598-6721-4d06-9052-3b97267ce2c2", - "alias": "registration form", - "description": "Registration form", - "providerId": "form-flow", - "topLevel": false, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "registration-user-creation", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 20, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticator": "registration-password-action", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 50, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticator": "registration-recaptcha-action", - "authenticatorFlow": false, - "requirement": "DISABLED", - "priority": 60, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticator": "registration-terms-and-conditions", - "authenticatorFlow": false, - "requirement": "DISABLED", - "priority": 70, - "autheticatorFlow": false, - "userSetupAllowed": false - } - ] - }, - { - "id": "b867afc5-330e-45a3-b935-b82654640eb0", - "alias": "reset credentials", - "description": "Reset credentials for a user if they forgot their password or something", - "providerId": "basic-flow", - "topLevel": true, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "reset-credentials-choose-user", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 10, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticator": "reset-credential-email", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 20, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticator": "reset-password", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 30, - "autheticatorFlow": false, - "userSetupAllowed": false - }, - { - "authenticatorFlow": true, - "requirement": "CONDITIONAL", - "priority": 40, - "autheticatorFlow": true, - "flowAlias": "Reset - Conditional OTP", - "userSetupAllowed": false - } - ] - }, - { - "id": "88b9b0ca-da06-486c-857e-05c6532d4f42", - "alias": "saml ecp", - "description": "SAML ECP Profile Authentication Flow", - "providerId": "basic-flow", - "topLevel": true, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "http-basic-authenticator", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 10, - "autheticatorFlow": false, - "userSetupAllowed": false - } - ] - } - ], - "authenticatorConfig": [ - { - "id": "39e74390-4e8d-4c38-be83-58a3a73d5aa4", - "alias": "create unique user config", - "config": { - "require.password.update.after.registration": "false" - } - }, - { - "id": "c3950873-95c9-4094-8ec9-00897ab5d208", - "alias": "review profile config", - "config": { - "update.profile.on.first.login": "missing" - } - } - ], - "requiredActions": [ - { - "alias": "CONFIGURE_TOTP", - "name": "Configure OTP", - "providerId": "CONFIGURE_TOTP", - "enabled": true, - "defaultAction": false, - "priority": 10, - "config": {} - }, - { - "alias": "TERMS_AND_CONDITIONS", - "name": "Terms and Conditions", - "providerId": "TERMS_AND_CONDITIONS", - "enabled": false, - "defaultAction": false, - "priority": 20, - "config": {} - }, - { - "alias": "UPDATE_PASSWORD", - "name": "Update Password", - "providerId": "UPDATE_PASSWORD", - "enabled": true, - "defaultAction": false, - "priority": 30, - "config": {} - }, - { - "alias": "UPDATE_PROFILE", - "name": "Update Profile", - "providerId": "UPDATE_PROFILE", - "enabled": true, - "defaultAction": false, - "priority": 40, - "config": {} - }, - { - "alias": "VERIFY_EMAIL", - "name": "Verify Email", - "providerId": "VERIFY_EMAIL", - "enabled": true, - "defaultAction": false, - "priority": 50, - "config": {} - }, - { - "alias": "delete_account", - "name": "Delete Account", - "providerId": "delete_account", - "enabled": false, - "defaultAction": false, - "priority": 60, - "config": {} - }, - { - "alias": "webauthn-register", - "name": "Webauthn Register", - "providerId": "webauthn-register", - "enabled": true, - "defaultAction": false, - "priority": 70, - "config": {} - }, - { - "alias": "webauthn-register-passwordless", - "name": "Webauthn Register Passwordless", - "providerId": "webauthn-register-passwordless", - "enabled": true, - "defaultAction": false, - "priority": 80, - "config": {} - }, - { - "alias": "VERIFY_PROFILE", - "name": "Verify Profile", - "providerId": "VERIFY_PROFILE", - "enabled": true, - "defaultAction": false, - "priority": 90, - "config": {} - }, - { - "alias": "delete_credential", - "name": "Delete Credential", - "providerId": "delete_credential", - "enabled": true, - "defaultAction": false, - "priority": 100, - "config": {} - }, - { - "alias": "update_user_locale", - "name": "Update User Locale", - "providerId": "update_user_locale", - "enabled": true, - "defaultAction": false, - "priority": 1000, - "config": {} - } - ], - "browserFlow": "browser", - "registrationFlow": "registration", - "directGrantFlow": "direct grant", - "resetCredentialsFlow": "reset credentials", - "clientAuthenticationFlow": "clients", - "dockerAuthenticationFlow": "docker auth", - "firstBrokerLoginFlow": "first broker login", - "attributes": { - "cibaBackchannelTokenDeliveryMode": "poll", - "cibaExpiresIn": "120", - "cibaAuthRequestedUserHint": "login_hint", - "parRequestUriLifespan": "60", - "cibaInterval": "5", - "realmReusableOtpCode": "false" - }, - "keycloakVersion": "26.0.6", - "userManagedAccessAllowed": false, - "organizationsEnabled": false, - "clientProfiles": { - "profiles": [] - }, - "clientPolicies": { - "policies": [] - } -} diff --git a/nix/services/keycloak_test.nix b/nix/services/keycloak_test.nix index 7213762f..af3ffd36 100644 --- a/nix/services/keycloak_test.nix +++ b/nix/services/keycloak_test.nix @@ -13,15 +13,16 @@ in realms = { master = { - path = ./keycloak/test-realms/master.json; - export = true; - import = false; + export = { + enable = true; + }; }; test = { - path = realmSrc; - import = true; - export = true; + import = realmSrc; + export = { + enable = true; + }; }; }; };