From 12a3af7c312c3bd427c7957826553bac884d2e88 Mon Sep 17 00:00:00 2001 From: sam Date: Tue, 13 Feb 2024 08:26:07 +0100 Subject: [PATCH 01/19] missing env and appBundle removed --- .env.dist | 2 +- .env.test | 1 + src/Service/SearchUserFormHelper.php | 4 ++-- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.env.dist b/.env.dist index 23d6a35fa..6751685ae 100644 --- a/.env.dist +++ b/.env.dist @@ -182,7 +182,7 @@ LOGGING_MATTERMOST_CHANNEL=elefan # Open ID Client OIDC_ENABLE=false OIDC_PROFILE_CUSTOM_MESSAGE='vos informations personnelles sont éditables ici ' -OIDC_NO_ACCOUNT_MESSAGE='Vous n\'avez pas de compte. Veuillez contacter l\'administrateur.' +OIDC_NO_ACCOUNT_MESSAGE="Vous n\'avez pas de compte. Veuillez contacter le support." OIDC_ISSUER=http://host.docker.internal:8081/auth OIDC_REALM=elefan OIDC_CLIENT_ID=elefan diff --git a/.env.test b/.env.test index d0592fa68..66925b144 100644 --- a/.env.test +++ b/.env.test @@ -184,6 +184,7 @@ LOGGING_MATTERMOST_CHANNEL=elefan # Open ID Client OIDC_ENABLE=false OIDC_PROFILE_CUSTOM_MESSAGE='vos informations personnelles sont éditables ici ' +OIDC_NO_ACCOUNT_MESSAGE="Vous n\'avez pas de compte. Veuillez contacter le support." OIDC_ISSUER=http://host.docker.internal:8081/auth OIDC_REALM=elefan OIDC_CLIENT_ID=elefan diff --git a/src/Service/SearchUserFormHelper.php b/src/Service/SearchUserFormHelper.php index 9e9457cf1..6ad0b4a4e 100644 --- a/src/Service/SearchUserFormHelper.php +++ b/src/Service/SearchUserFormHelper.php @@ -2,8 +2,8 @@ //DependencyInjection/SearchUserFormHelper.php namespace App\Service; -use AppBundle\Repository\CommissionRepository; -use AppBundle\Repository\FormationRepository; +use App\Repository\CommissionRepository; +use App\Repository\FormationRepository; use Doctrine\ORM\EntityManager; use Doctrine\ORM\Query\Expr\Join; use Doctrine\ORM\QueryBuilder; From df7ff7a8f88c1f04417fb199a1e665722458ff7a Mon Sep 17 00:00:00 2001 From: sam Date: Tue, 13 Feb 2024 08:26:22 +0100 Subject: [PATCH 02/19] install cypress --- cypress.config.js | 9 + cypress/e2e/spec.cy.js | 5 + cypress/fixtures/example.json | 5 + cypress/support/commands.js | 25 + cypress/support/e2e.js | 20 + package-lock.json | 1536 +++++++++++++++++++++++++++++++-- package.json | 1 + 7 files changed, 1551 insertions(+), 50 deletions(-) create mode 100644 cypress.config.js create mode 100644 cypress/e2e/spec.cy.js create mode 100644 cypress/fixtures/example.json create mode 100644 cypress/support/commands.js create mode 100644 cypress/support/e2e.js diff --git a/cypress.config.js b/cypress.config.js new file mode 100644 index 000000000..97f47c412 --- /dev/null +++ b/cypress.config.js @@ -0,0 +1,9 @@ +const { defineConfig } = require("cypress"); + +module.exports = defineConfig({ + e2e: { + setupNodeEvents(on, config) { + // implement node event listeners here + }, + }, +}); diff --git a/cypress/e2e/spec.cy.js b/cypress/e2e/spec.cy.js new file mode 100644 index 000000000..322992ce1 --- /dev/null +++ b/cypress/e2e/spec.cy.js @@ -0,0 +1,5 @@ +describe('template spec', () => { + it('passes', () => { + cy.visit('https://example.cypress.io') + }) +}) \ No newline at end of file diff --git a/cypress/fixtures/example.json b/cypress/fixtures/example.json new file mode 100644 index 000000000..02e425437 --- /dev/null +++ b/cypress/fixtures/example.json @@ -0,0 +1,5 @@ +{ + "name": "Using fixtures to represent data", + "email": "hello@cypress.io", + "body": "Fixtures are a great way to mock data for responses to routes" +} diff --git a/cypress/support/commands.js b/cypress/support/commands.js new file mode 100644 index 000000000..66ea16ef0 --- /dev/null +++ b/cypress/support/commands.js @@ -0,0 +1,25 @@ +// *********************************************** +// This example commands.js shows you how to +// create various custom commands and overwrite +// existing commands. +// +// For more comprehensive examples of custom +// commands please read more here: +// https://on.cypress.io/custom-commands +// *********************************************** +// +// +// -- This is a parent command -- +// Cypress.Commands.add('login', (email, password) => { ... }) +// +// +// -- This is a child command -- +// Cypress.Commands.add('drag', { prevSubject: 'element'}, (subject, options) => { ... }) +// +// +// -- This is a dual command -- +// Cypress.Commands.add('dismiss', { prevSubject: 'optional'}, (subject, options) => { ... }) +// +// +// -- This will overwrite an existing command -- +// Cypress.Commands.overwrite('visit', (originalFn, url, options) => { ... }) \ No newline at end of file diff --git a/cypress/support/e2e.js b/cypress/support/e2e.js new file mode 100644 index 000000000..0e7290a13 --- /dev/null +++ b/cypress/support/e2e.js @@ -0,0 +1,20 @@ +// *********************************************************** +// This example support/e2e.js is processed and +// loaded automatically before your test files. +// +// This is a great place to put global configuration and +// behavior that modifies Cypress. +// +// You can change the location of this file or turn off +// automatically serving support files with the +// 'supportFile' configuration option. +// +// You can read more here: +// https://on.cypress.io/configuration +// *********************************************************** + +// Import commands.js using ES2015 syntax: +import './commands' + +// Alternatively you can use CommonJS syntax: +// require('./commands') \ No newline at end of file diff --git a/package-lock.json b/package-lock.json index 8277d9ce5..a148bafb2 100644 --- a/package-lock.json +++ b/package-lock.json @@ -21,6 +21,7 @@ "@symfony/stimulus-bridge": "^3.0.0", "@symfony/webpack-encore": "^1.7.0", "core-js": "^3.0.0", + "cypress": "^13.6.4", "file-loader": "^6.2.0", "less": "^4.2.0", "less-loader": "^11.1.3", @@ -1868,6 +1869,79 @@ "w3c-keyname": "^2.2.4" } }, + "node_modules/@colors/colors": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/@colors/colors/-/colors-1.5.0.tgz", + "integrity": "sha512-ooWCrlZP11i8GImSjTHYHLkvFDP48nS4+204nGb1RiX/WXYHmJA2III9/e2DWVabCESdW7hBAEzHRqUn9OUVvQ==", + "dev": true, + "optional": true, + "engines": { + "node": ">=0.1.90" + } + }, + "node_modules/@cypress/request": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@cypress/request/-/request-3.0.1.tgz", + "integrity": "sha512-TWivJlJi8ZDx2wGOw1dbLuHJKUYX7bWySw377nlnGOW3hP9/MUKIsEdXT/YngWxVdgNCHRBmFlBipE+5/2ZZlQ==", + "dev": true, + "dependencies": { + "aws-sign2": "~0.7.0", + "aws4": "^1.8.0", + "caseless": "~0.12.0", + "combined-stream": "~1.0.6", + "extend": "~3.0.2", + "forever-agent": "~0.6.1", + "form-data": "~2.3.2", + "http-signature": "~1.3.6", + "is-typedarray": "~1.0.0", + "isstream": "~0.1.2", + "json-stringify-safe": "~5.0.1", + "mime-types": "~2.1.19", + "performance-now": "^2.1.0", + "qs": "6.10.4", + "safe-buffer": "^5.1.2", + "tough-cookie": "^4.1.3", + "tunnel-agent": "^0.6.0", + "uuid": "^8.3.2" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/@cypress/request/node_modules/qs": { + "version": "6.10.4", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.10.4.tgz", + "integrity": "sha512-OQiU+C+Ds5qiH91qh/mg0w+8nwQuLjM4F4M/PbmhDOoYehPh+Fb0bDjtR1sOvy7YKxvj28Y/M0PhP5uVX0kB+g==", + "dev": true, + "dependencies": { + "side-channel": "^1.0.4" + }, + "engines": { + "node": ">=0.6" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/@cypress/xvfb": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/@cypress/xvfb/-/xvfb-1.2.4.tgz", + "integrity": "sha512-skbBzPggOVYCbnGgV+0dmBdW/s77ZkAOXIC1knS8NagwDjBrNC1LuXtQJeiN6l+m7lzmHtaoUw/ctJKdqkG57Q==", + "dev": true, + "dependencies": { + "debug": "^3.1.0", + "lodash.once": "^4.1.1" + } + }, + "node_modules/@cypress/xvfb/node_modules/debug": { + "version": "3.2.7", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", + "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", + "dev": true, + "dependencies": { + "ms": "^2.1.1" + } + }, "node_modules/@discoveryjs/json-ext": { "version": "0.5.7", "resolved": "https://registry.npmjs.org/@discoveryjs/json-ext/-/json-ext-0.5.7.tgz", @@ -2360,6 +2434,18 @@ "@types/node": "*" } }, + "node_modules/@types/sinonjs__fake-timers": { + "version": "8.1.1", + "resolved": "https://registry.npmjs.org/@types/sinonjs__fake-timers/-/sinonjs__fake-timers-8.1.1.tgz", + "integrity": "sha512-0kSuKjAS0TrGLJ0M/+8MaFkGsQhZpB6pxOmvS3K8FYI72K//YmdfoW9X2qPsAKh1mkwxGD5zib9s1FIFed6E8g==", + "dev": true + }, + "node_modules/@types/sizzle": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/@types/sizzle/-/sizzle-2.3.8.tgz", + "integrity": "sha512-0vWLNK2D5MT9dg0iOo8GlKguPAU02QjmZitPEsXRuJXU/OGIOt9vT9Fc26wtYuavLxtO45v9PGleoL9Z0k1LHg==", + "dev": true + }, "node_modules/@types/sockjs": { "version": "0.3.36", "resolved": "https://registry.npmjs.org/@types/sockjs/-/sockjs-0.3.36.tgz", @@ -2439,6 +2525,16 @@ "@types/node": "*" } }, + "node_modules/@types/yauzl": { + "version": "2.10.3", + "resolved": "https://registry.npmjs.org/@types/yauzl/-/yauzl-2.10.3.tgz", + "integrity": "sha512-oJoftv0LSuaDZE3Le4DbKX+KS9G36NzOeSap90UIK0yMA/NhKJhqlSGtNDORNRaIbQfzjXDrQa0ytJ6mNRGz/Q==", + "dev": true, + "optional": true, + "dependencies": { + "@types/node": "*" + } + }, "node_modules/@webassemblyjs/ast": { "version": "1.11.6", "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.11.6.tgz", @@ -2680,6 +2776,19 @@ "node": ">=8.9" } }, + "node_modules/aggregate-error": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/aggregate-error/-/aggregate-error-3.1.0.tgz", + "integrity": "sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==", + "dev": true, + "dependencies": { + "clean-stack": "^2.0.0", + "indent-string": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/ajv": { "version": "6.12.6", "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", @@ -2744,6 +2853,30 @@ "ajv": "^6.9.1" } }, + "node_modules/ansi-colors": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.3.tgz", + "integrity": "sha512-/6w/C21Pm1A7aZitlI5Ni/2J6FFQN8i1Cvz3kHABAAbw93v/NlvKdVOqz7CCWz/3iv/JplRSEEZ83XION15ovw==", + "dev": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/ansi-escapes": { + "version": "4.3.2", + "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", + "integrity": "sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ==", + "dev": true, + "dependencies": { + "type-fest": "^0.21.3" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/ansi-html-community": { "version": "0.0.8", "resolved": "https://registry.npmjs.org/ansi-html-community/-/ansi-html-community-0.0.8.tgz", @@ -2790,6 +2923,26 @@ "node": ">= 8" } }, + "node_modules/arch": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/arch/-/arch-2.2.0.tgz", + "integrity": "sha512-Of/R0wqp83cgHozfIYLbBMnej79U/SVGOOyuB3VVFv1NRM/PSFMK12x9KVtiYzJqmnU5WR2qp0Z5rHb7sWGnFQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, "node_modules/arity-n": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/arity-n/-/arity-n-1.0.4.tgz", @@ -2823,6 +2976,54 @@ "node": ">=0.10.0" } }, + "node_modules/asn1": { + "version": "0.2.6", + "resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.6.tgz", + "integrity": "sha512-ix/FxPn0MDjeyJ7i/yoHGFt/EX6LyNbxSEhPPXODPL+KB0VPk86UYfL0lMdy+KCnv+fmvIzySwaK5COwqVbWTQ==", + "dev": true, + "dependencies": { + "safer-buffer": "~2.1.0" + } + }, + "node_modules/assert-plus": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz", + "integrity": "sha512-NfJ4UzBCcQGLDlQq7nHxH+tv3kyZ0hHQqF5BO6J7tNJeP5do1llPr8dZ8zHonfhAu0PHAdMkSo+8o0wxg9lZWw==", + "dev": true, + "engines": { + "node": ">=0.8" + } + }, + "node_modules/astral-regex": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/astral-regex/-/astral-regex-2.0.0.tgz", + "integrity": "sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/async": { + "version": "3.2.5", + "resolved": "https://registry.npmjs.org/async/-/async-3.2.5.tgz", + "integrity": "sha512-baNZyqaaLhyLVKm/DlvdW051MSgO6b8eVfIezl9E5PqWxFgzLm/wQntEW4zOytVburDEr0JlALEpdOFwvErLsg==", + "dev": true + }, + "node_modules/asynckit": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", + "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==", + "dev": true + }, + "node_modules/at-least-node": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/at-least-node/-/at-least-node-1.0.0.tgz", + "integrity": "sha512-+q/t7Ekv1EDY2l6Gda6LLiX14rU9TV20Wa3ofeQmwPFZbOMo9DXrLbOjFaaclkXKWidIaopwAObQDqwWtGUjqg==", + "dev": true, + "engines": { + "node": ">= 4.0.0" + } + }, "node_modules/atob": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/atob/-/atob-2.1.2.tgz", @@ -2835,6 +3036,21 @@ "node": ">= 4.5.0" } }, + "node_modules/aws-sign2": { + "version": "0.7.0", + "resolved": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz", + "integrity": "sha512-08kcGqnYf/YmjoRhfxyu+CLxBjUtHLXLXX/vUfx9l2LYzG3c1m61nrpyFUZI6zeS+Li/wWMMidD9KgrqtGq3mA==", + "dev": true, + "engines": { + "node": "*" + } + }, + "node_modules/aws4": { + "version": "1.12.0", + "resolved": "https://registry.npmjs.org/aws4/-/aws4-1.12.0.tgz", + "integrity": "sha512-NmWvPnx0F1SfrQbYwOi7OeaNGokp9XhzNioJ/CSBs8Qa4vxug81mhJEAVZwxXuBmYB5KDRfMq/F3RR0BIU7sWg==", + "dev": true + }, "node_modules/babel-loader": { "version": "8.3.0", "resolved": "https://registry.npmjs.org/babel-loader/-/babel-loader-8.3.0.tgz", @@ -2926,12 +3142,41 @@ "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", "dev": true }, + "node_modules/base64-js": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", + "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, "node_modules/batch": { "version": "0.6.1", "resolved": "https://registry.npmjs.org/batch/-/batch-0.6.1.tgz", "integrity": "sha512-x+VAiMRL6UPkx+kudNvxTl6hB2XNNCG2r+7wixVfIYwu/2HKRXimwQyaumLjMveWvT2Hkd/cAJw+QBMfJ/EKVw==", "dev": true }, + "node_modules/bcrypt-pbkdf": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz", + "integrity": "sha512-qeFIXtP4MSoi6NLqO12WfqARWWuCKi2Rn/9hJLEmtB5yTNr9DqFWkJRCf2qShWzPeAMRnOgCrq0sg/KLv5ES9w==", + "dev": true, + "dependencies": { + "tweetnacl": "^0.14.3" + } + }, "node_modules/big.js": { "version": "5.2.2", "resolved": "https://registry.npmjs.org/big.js/-/big.js-5.2.2.tgz", @@ -2950,6 +3195,18 @@ "node": ">=8" } }, + "node_modules/blob-util": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/blob-util/-/blob-util-2.0.2.tgz", + "integrity": "sha512-T7JQa+zsXXEa6/8ZhHcQEW1UFfVM49Ts65uBkFL6fz2QmrElqmbajIDJvuA0tEhRe5eIjpV9ZF+0RfZR9voJFQ==", + "dev": true + }, + "node_modules/bluebird": { + "version": "3.7.2", + "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.7.2.tgz", + "integrity": "sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==", + "dev": true + }, "node_modules/body-parser": { "version": "1.20.1", "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz", @@ -3070,6 +3327,39 @@ "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7" } }, + "node_modules/buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, + "node_modules/buffer-crc32": { + "version": "0.2.13", + "resolved": "https://registry.npmjs.org/buffer-crc32/-/buffer-crc32-0.2.13.tgz", + "integrity": "sha512-VO9Ht/+p3SN7SKWqcrgEzjGbRSJYTx+Q1pTQC0wrWqHx0vpJraQ6GtHx8tvcg1rlK1byhU5gccxgOgj7B0TDkQ==", + "dev": true, + "engines": { + "node": "*" + } + }, "node_modules/buffer-from": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", @@ -3085,6 +3375,15 @@ "node": ">= 0.8" } }, + "node_modules/cachedir": { + "version": "2.4.0", + "resolved": "https://registry.npmjs.org/cachedir/-/cachedir-2.4.0.tgz", + "integrity": "sha512-9EtFOZR8g22CL7BWjJ9BUx1+A/djkofnyW3aOXZORNW2kxoUpx2h+uN2cOqwPmFhnpVmxg+KW2OjOSgChTEvsQ==", + "dev": true, + "engines": { + "node": ">=6" + } + }, "node_modules/call-bind": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.5.tgz", @@ -3148,6 +3447,12 @@ "resolved": "https://registry.npmjs.org/canvas-gauges/-/canvas-gauges-2.1.7.tgz", "integrity": "sha512-z9cXBVTZdaUIOh32g21NU8gwxEeaxpEMvkZr9t8Y0QDbZiCDq05SJ17aIt+DM12oTJAlWGluN21D+bQ0NCv5GA==" }, + "node_modules/caseless": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz", + "integrity": "sha512-4tYFyifaFfGacoiObjJegolkwSU4xQNGbVgUiNYVUxbQ2x2lUsFvY4hVgVzGiIe6WLOPqycWXA40l+PWsxthUw==", + "dev": true + }, "node_modules/chalk": { "version": "4.1.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", @@ -3218,6 +3523,15 @@ "node": ">=8" } }, + "node_modules/check-more-types": { + "version": "2.24.0", + "resolved": "https://registry.npmjs.org/check-more-types/-/check-more-types-2.24.0.tgz", + "integrity": "sha512-Pj779qHxV2tuapviy1bSZNEL1maXr13bPYpsvSDB68HlYcYuhlDrmGd63i0JHMCLKzc7rUSNIrpdJlhVlNwrxA==", + "dev": true, + "engines": { + "node": ">= 0.8.0" + } + }, "node_modules/chokidar": { "version": "3.5.3", "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.5.3.tgz", @@ -3254,6 +3568,30 @@ "node": ">=6.0" } }, + "node_modules/ci-info": { + "version": "3.9.0", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-3.9.0.tgz", + "integrity": "sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/sibiraj-s" + } + ], + "engines": { + "node": ">=8" + } + }, + "node_modules/clean-stack": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/clean-stack/-/clean-stack-2.2.0.tgz", + "integrity": "sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==", + "dev": true, + "engines": { + "node": ">=6" + } + }, "node_modules/clean-webpack-plugin": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/clean-webpack-plugin/-/clean-webpack-plugin-3.0.0.tgz", @@ -3270,6 +3608,49 @@ "webpack": "*" } }, + "node_modules/cli-cursor": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-3.1.0.tgz", + "integrity": "sha512-I/zHAwsKf9FqGoXM4WWRACob9+SNukZTd94DWF57E4toouRulbCxcUh6RKUEOQlYTHJnzkPMySvPNaaSLNfLZw==", + "dev": true, + "dependencies": { + "restore-cursor": "^3.1.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/cli-table3": { + "version": "0.6.3", + "resolved": "https://registry.npmjs.org/cli-table3/-/cli-table3-0.6.3.tgz", + "integrity": "sha512-w5Jac5SykAeZJKntOxJCrm63Eg5/4dhMWIcuTbo9rpE+brgaSZo0RuNJZeOyMgsUdhDeojvgyQLmjI+K50ZGyg==", + "dev": true, + "dependencies": { + "string-width": "^4.2.0" + }, + "engines": { + "node": "10.* || >= 12.*" + }, + "optionalDependencies": { + "@colors/colors": "1.5.0" + } + }, + "node_modules/cli-truncate": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/cli-truncate/-/cli-truncate-2.1.0.tgz", + "integrity": "sha512-n8fOixwDD6b/ObinzTrp1ZKFzbgvKZvuz/TvejnLn1aQfC6r52XEx85FmuC+3HI+JM7coBRXUvNqEU2PHVrHpg==", + "dev": true, + "dependencies": { + "slice-ansi": "^3.0.0", + "string-width": "^4.2.0" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/clone-deep": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/clone-deep/-/clone-deep-4.0.1.tgz", @@ -3333,6 +3714,18 @@ "integrity": "sha512-IfEDxwoWIjkeXL1eXcDiow4UbKjhLdq6/EuSVR9GMN7KVH3r9gQ83e73hsz1Nd1T3ijd5xv1wcWRYO+D6kCI2w==", "dev": true }, + "node_modules/combined-stream": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", + "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", + "dev": true, + "dependencies": { + "delayed-stream": "~1.0.0" + }, + "engines": { + "node": ">= 0.8" + } + }, "node_modules/commander": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/commander/-/commander-7.2.0.tgz", @@ -3342,6 +3735,15 @@ "node": ">= 10" } }, + "node_modules/common-tags": { + "version": "1.8.2", + "resolved": "https://registry.npmjs.org/common-tags/-/common-tags-1.8.2.tgz", + "integrity": "sha512-gk/Z852D2Wtb//0I+kRFNKKE9dIIVirjoqPoA1wJU+XePVXZfGeBpk45+A1rKO4Q43prqWBNY/MiIeRLbPWUaA==", + "dev": true, + "engines": { + "node": ">=4.0.0" + } + }, "node_modules/commondir": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz", @@ -3728,24 +4130,179 @@ "node": ">=8.0.0" } }, - "node_modules/d": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/d/-/d-1.0.1.tgz", - "integrity": "sha512-m62ShEObQ39CfralilEQRjH6oAMtNCV1xJyEx5LpRYUVN+EviphDgUc/F3hnYbADmkiNs67Y+3ylmlG7Lnu+FA==", + "node_modules/cypress": { + "version": "13.6.4", + "resolved": "https://registry.npmjs.org/cypress/-/cypress-13.6.4.tgz", + "integrity": "sha512-pYJjCfDYB+hoOoZuhysbbYhEmNW7DEDsqn+ToCLwuVowxUXppIWRr7qk4TVRIU471ksfzyZcH+mkoF0CQUKnpw==", "dev": true, + "hasInstallScript": true, "dependencies": { - "es5-ext": "^0.10.50", - "type": "^1.0.1" + "@cypress/request": "^3.0.0", + "@cypress/xvfb": "^1.2.4", + "@types/sinonjs__fake-timers": "8.1.1", + "@types/sizzle": "^2.3.2", + "arch": "^2.2.0", + "blob-util": "^2.0.2", + "bluebird": "^3.7.2", + "buffer": "^5.6.0", + "cachedir": "^2.3.0", + "chalk": "^4.1.0", + "check-more-types": "^2.24.0", + "cli-cursor": "^3.1.0", + "cli-table3": "~0.6.1", + "commander": "^6.2.1", + "common-tags": "^1.8.0", + "dayjs": "^1.10.4", + "debug": "^4.3.4", + "enquirer": "^2.3.6", + "eventemitter2": "6.4.7", + "execa": "4.1.0", + "executable": "^4.1.1", + "extract-zip": "2.0.1", + "figures": "^3.2.0", + "fs-extra": "^9.1.0", + "getos": "^3.2.1", + "is-ci": "^3.0.0", + "is-installed-globally": "~0.4.0", + "lazy-ass": "^1.6.0", + "listr2": "^3.8.3", + "lodash": "^4.17.21", + "log-symbols": "^4.0.0", + "minimist": "^1.2.8", + "ospath": "^1.2.2", + "pretty-bytes": "^5.6.0", + "process": "^0.11.10", + "proxy-from-env": "1.0.0", + "request-progress": "^3.0.0", + "semver": "^7.5.3", + "supports-color": "^8.1.1", + "tmp": "~0.2.1", + "untildify": "^4.0.0", + "yauzl": "^2.10.0" + }, + "bin": { + "cypress": "bin/cypress" + }, + "engines": { + "node": "^16.0.0 || ^18.0.0 || >=20.0.0" } }, - "node_modules/debug": { - "version": "4.3.4", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", - "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", + "node_modules/cypress/node_modules/commander": { + "version": "6.2.1", + "resolved": "https://registry.npmjs.org/commander/-/commander-6.2.1.tgz", + "integrity": "sha512-U7VdrJFnJgo4xjrHpTzu0yrHPGImdsmD95ZlgYSEajAn2JKzDhDTPG9kBTefmObL2w/ngeZnilk+OV9CG3d7UA==", "dev": true, - "dependencies": { - "ms": "2.1.2" - }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/cypress/node_modules/execa": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/execa/-/execa-4.1.0.tgz", + "integrity": "sha512-j5W0//W7f8UxAn8hXVnwG8tLwdiUy4FJLcSupCg6maBYZDpyBvTApK7KyuI4bKj8KOh1r2YH+6ucuYtJv1bTZA==", + "dev": true, + "dependencies": { + "cross-spawn": "^7.0.0", + "get-stream": "^5.0.0", + "human-signals": "^1.1.1", + "is-stream": "^2.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^4.0.0", + "onetime": "^5.1.0", + "signal-exit": "^3.0.2", + "strip-final-newline": "^2.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sindresorhus/execa?sponsor=1" + } + }, + "node_modules/cypress/node_modules/get-stream": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-5.2.0.tgz", + "integrity": "sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==", + "dev": true, + "dependencies": { + "pump": "^3.0.0" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/cypress/node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/cypress/node_modules/human-signals": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-1.1.1.tgz", + "integrity": "sha512-SEQu7vl8KjNL2eoGBLF3+wAjpsNfA9XMlXAYj/3EdaNfAlxKthD1xjEQfGOUhllCGGJVNY34bRr6lPINhNjyZw==", + "dev": true, + "engines": { + "node": ">=8.12.0" + } + }, + "node_modules/cypress/node_modules/supports-color": { + "version": "8.1.1", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", + "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/supports-color?sponsor=1" + } + }, + "node_modules/d": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/d/-/d-1.0.1.tgz", + "integrity": "sha512-m62ShEObQ39CfralilEQRjH6oAMtNCV1xJyEx5LpRYUVN+EviphDgUc/F3hnYbADmkiNs67Y+3ylmlG7Lnu+FA==", + "dev": true, + "dependencies": { + "es5-ext": "^0.10.50", + "type": "^1.0.1" + } + }, + "node_modules/dashdash": { + "version": "1.14.1", + "resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz", + "integrity": "sha512-jRFi8UDGo6j+odZiEpjazZaWqEal3w/basFjQHQEwVtZJGDpxbH1MeYluwCS8Xq5wmLJooDlMgvVarmWfGM44g==", + "dev": true, + "dependencies": { + "assert-plus": "^1.0.0" + }, + "engines": { + "node": ">=0.10" + } + }, + "node_modules/dayjs": { + "version": "1.11.10", + "resolved": "https://registry.npmjs.org/dayjs/-/dayjs-1.11.10.tgz", + "integrity": "sha512-vjAczensTgRcqDERK0SR2XMwsF/tSvnvlv6VcF2GIhg6Sx4yOIt/irsr1RDJsKiIyBzJDpCoXiWWq28MqH2cnQ==", + "dev": true + }, + "node_modules/debug": { + "version": "4.3.4", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", + "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", + "dev": true, + "dependencies": { + "ms": "2.1.2" + }, "engines": { "node": ">=6.0" }, @@ -3817,6 +4374,15 @@ "node": ">=6" } }, + "node_modules/delayed-stream": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", + "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", + "dev": true, + "engines": { + "node": ">=0.4.0" + } + }, "node_modules/depd": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", @@ -3924,6 +4490,16 @@ "url": "https://github.com/fb55/domutils?sponsor=1" } }, + "node_modules/ecc-jsbn": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz", + "integrity": "sha512-eh9O+hwRHNbG4BLTjEl3nw044CkGm5X6LoaCf7LPp7UU8Qrt47JYNi6nPX8xjW97TKGKm1ouctg0QSpZe9qrnw==", + "dev": true, + "dependencies": { + "jsbn": "~0.1.0", + "safer-buffer": "^2.1.0" + } + }, "node_modules/ee-first": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", @@ -3960,6 +4536,15 @@ "node": ">= 0.8" } }, + "node_modules/end-of-stream": { + "version": "1.4.4", + "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz", + "integrity": "sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==", + "dev": true, + "dependencies": { + "once": "^1.4.0" + } + }, "node_modules/enhanced-resolve": { "version": "5.15.0", "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.15.0.tgz", @@ -3973,6 +4558,19 @@ "node": ">=10.13.0" } }, + "node_modules/enquirer": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/enquirer/-/enquirer-2.4.1.tgz", + "integrity": "sha512-rRqJg/6gd538VHvR3PSrdRBb/1Vy2YfzHqzvbhGIQpDRKIa4FgV/54b5Q1xYSxOOwKvjXweS26E0Q+nAMwp2pQ==", + "dev": true, + "dependencies": { + "ansi-colors": "^4.1.1", + "strip-ansi": "^6.0.1" + }, + "engines": { + "node": ">=8.6" + } + }, "node_modules/entities": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz", @@ -4143,6 +4741,12 @@ "node": ">= 0.6" } }, + "node_modules/eventemitter2": { + "version": "6.4.7", + "resolved": "https://registry.npmjs.org/eventemitter2/-/eventemitter2-6.4.7.tgz", + "integrity": "sha512-tYUSVOGeQPKt/eC1ABfhHy5Xd96N3oIijJvN3O9+TsC28T5V9yX9oEfEK5faP0EFSNVOG97qtAS68GBrQB2hDg==", + "dev": true + }, "node_modules/eventemitter3": { "version": "4.0.7", "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.7.tgz", @@ -4181,6 +4785,27 @@ "url": "https://github.com/sindresorhus/execa?sponsor=1" } }, + "node_modules/executable": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/executable/-/executable-4.1.1.tgz", + "integrity": "sha512-8iA79xD3uAch729dUG8xaaBBFGaEa0wdD2VkYLFHwlqosEj/jT66AzcreRDSgV7ehnNLBW2WR5jIXwGKjVdTLg==", + "dev": true, + "dependencies": { + "pify": "^2.2.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/executable/node_modules/pify": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/pify/-/pify-2.3.0.tgz", + "integrity": "sha512-udgsAY+fTnvv7kI7aaxbqwWNb0AHiB0qBO89PZKPkoTmGOgdbrHDKD+0B2X4uTfJ/FT1R09r9gTsjUjNJotuog==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/express": { "version": "4.18.2", "resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz", @@ -4259,6 +4884,56 @@ "integrity": "sha512-dzlvlNlt6AXU7EBSfpAscydQ7gXB+pPGsPnfJnZpiNJBDj7IaJzQlBZYGdEi4R9HmPdBv2XmWJ6YUtoTa7lmCw==", "dev": true }, + "node_modules/extend": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.2.tgz", + "integrity": "sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==", + "dev": true + }, + "node_modules/extract-zip": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extract-zip/-/extract-zip-2.0.1.tgz", + "integrity": "sha512-GDhU9ntwuKyGXdZBUgTIe+vXnWj0fppUEtMDL0+idd5Sta8TGpHssn/eusA9mrPr9qNDym6SxAYZjNvCn/9RBg==", + "dev": true, + "dependencies": { + "debug": "^4.1.1", + "get-stream": "^5.1.0", + "yauzl": "^2.10.0" + }, + "bin": { + "extract-zip": "cli.js" + }, + "engines": { + "node": ">= 10.17.0" + }, + "optionalDependencies": { + "@types/yauzl": "^2.9.1" + } + }, + "node_modules/extract-zip/node_modules/get-stream": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-5.2.0.tgz", + "integrity": "sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==", + "dev": true, + "dependencies": { + "pump": "^3.0.0" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/extsprintf": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz", + "integrity": "sha512-11Ndz7Nv+mvAC1j0ktTa7fAb0vLyGGX+rMHNBYQviQDGU0Hw7lhctJANqbPhu9nV9/izT/IntTgZ7Im/9LJs9g==", + "dev": true, + "engines": [ + "node >=0.6.0" + ] + }, "node_modules/fast-deep-equal": { "version": "3.1.3", "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", @@ -4301,6 +4976,30 @@ "node": ">=0.8.0" } }, + "node_modules/fd-slicer": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/fd-slicer/-/fd-slicer-1.1.0.tgz", + "integrity": "sha512-cE1qsB/VwyQozZ+q1dGxR8LBYNZeofhEdUNGSMbQD3Gw2lAzX9Zb3uIU6Ebc/Fmyjo9AWWfnn0AUCHqtevs/8g==", + "dev": true, + "dependencies": { + "pend": "~1.2.0" + } + }, + "node_modules/figures": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/figures/-/figures-3.2.0.tgz", + "integrity": "sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg==", + "dev": true, + "dependencies": { + "escape-string-regexp": "^1.0.5" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/file-loader": { "version": "6.2.0", "resolved": "https://registry.npmjs.org/file-loader/-/file-loader-6.2.0.tgz", @@ -4425,6 +5124,29 @@ } } }, + "node_modules/forever-agent": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz", + "integrity": "sha512-j0KLYPhm6zeac4lz3oJ3o65qvgQCcPubiyotZrXqEaG4hNagNYO8qdlUrX5vwqv9ohqeT/Z3j6+yW067yWWdUw==", + "dev": true, + "engines": { + "node": "*" + } + }, + "node_modules/form-data": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/form-data/-/form-data-2.3.3.tgz", + "integrity": "sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ==", + "dev": true, + "dependencies": { + "asynckit": "^0.4.0", + "combined-stream": "^1.0.6", + "mime-types": "^2.1.12" + }, + "engines": { + "node": ">= 0.12" + } + }, "node_modules/forwarded": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.2.0.tgz", @@ -4443,6 +5165,21 @@ "node": ">= 0.6" } }, + "node_modules/fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "dev": true, + "dependencies": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/fs-monkey": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/fs-monkey/-/fs-monkey-1.0.5.tgz", @@ -4509,6 +5246,24 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/getos": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/getos/-/getos-3.2.1.tgz", + "integrity": "sha512-U56CfOK17OKgTVqozZjUKNdkfEv6jk5WISBJ8SHoagjE6L69zOwl3Z+O8myjY9MEW3i2HPWQBt/LTbCgcC973Q==", + "dev": true, + "dependencies": { + "async": "^3.2.0" + } + }, + "node_modules/getpass": { + "version": "0.1.7", + "resolved": "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz", + "integrity": "sha512-0fzj9JxOLfJ+XGLhR8ze3unN0KZCgZwiSSDz168VERjK8Wl8kVSdcu2kspd4s4wtAa1y/qrVRiAA0WclVsu0ng==", + "dev": true, + "dependencies": { + "assert-plus": "^1.0.0" + } + }, "node_modules/glob": { "version": "7.2.3", "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", @@ -4547,6 +5302,21 @@ "integrity": "sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw==", "dev": true }, + "node_modules/global-dirs": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/global-dirs/-/global-dirs-3.0.1.tgz", + "integrity": "sha512-NBcGGFbBA9s1VzD41QXDG+3++t9Mn5t1FpLdhESY6oKY4gYTFpX4wO3sqGUa0Srjtbfj3szX0RnemmrVRUdULA==", + "dev": true, + "dependencies": { + "ini": "2.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/globals": { "version": "11.12.0", "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", @@ -4802,6 +5572,20 @@ } } }, + "node_modules/http-signature": { + "version": "1.3.6", + "resolved": "https://registry.npmjs.org/http-signature/-/http-signature-1.3.6.tgz", + "integrity": "sha512-3adrsD6zqo4GsTqtO7FyrejHNv+NgiIfAfv68+jVlFmSr9OGy7zrxONceFRLKvnnZA5jbxQBX1u9PpB6Wi32Gw==", + "dev": true, + "dependencies": { + "assert-plus": "^1.0.0", + "jsprim": "^2.0.2", + "sshpk": "^1.14.1" + }, + "engines": { + "node": ">=0.10" + } + }, "node_modules/human-signals": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz", @@ -4835,6 +5619,26 @@ "postcss": "^8.1.0" } }, + "node_modules/ieee754": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", + "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, "node_modules/image-size": { "version": "0.5.5", "resolved": "https://registry.npmjs.org/image-size/-/image-size-0.5.5.tgz", @@ -4867,6 +5671,15 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/indent-string": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-4.0.0.tgz", + "integrity": "sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg==", + "dev": true, + "engines": { + "node": ">=8" + } + }, "node_modules/inflight": { "version": "1.0.6", "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", @@ -4883,6 +5696,15 @@ "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", "dev": true }, + "node_modules/ini": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ini/-/ini-2.0.0.tgz", + "integrity": "sha512-7PnF4oN3CvZF23ADhA5wRaYEQpJ8qygSkbtTXWBeXWXmEVRXK+1ITciHWwHhsjv1TmW0MgacIv6hEi5pX5NQdA==", + "dev": true, + "engines": { + "node": ">=10" + } + }, "node_modules/interpret": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/interpret/-/interpret-2.2.0.tgz", @@ -4913,6 +5735,18 @@ "node": ">=8" } }, + "node_modules/is-ci": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/is-ci/-/is-ci-3.0.1.tgz", + "integrity": "sha512-ZYvCgrefwqoQ6yTyYUbQu64HsITZ3NfKX1lzaEYdkTDcfKzzCI/wthRRYKkdjHKFVgNiXKAKm65Zo1pk2as/QQ==", + "dev": true, + "dependencies": { + "ci-info": "^3.2.0" + }, + "bin": { + "is-ci": "bin.js" + } + }, "node_modules/is-core-module": { "version": "2.13.1", "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.13.1.tgz", @@ -4970,6 +5804,31 @@ "node": ">=0.10.0" } }, + "node_modules/is-installed-globally": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/is-installed-globally/-/is-installed-globally-0.4.0.tgz", + "integrity": "sha512-iwGqO3J21aaSkC7jWnHP/difazwS7SFeIqxv6wEtLU8Y5KlzFTjyqcSIT0d8s4+dDhKytsk9PJZ2BkS5eZwQRQ==", + "dev": true, + "dependencies": { + "global-dirs": "^3.0.0", + "is-path-inside": "^3.0.2" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-installed-globally/node_modules/is-path-inside": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/is-path-inside/-/is-path-inside-3.0.3.tgz", + "integrity": "sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==", + "dev": true, + "engines": { + "node": ">=8" + } + }, "node_modules/is-number": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", @@ -5048,6 +5907,24 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/is-typedarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz", + "integrity": "sha512-cyA56iCMHAh5CdzjJIa4aohJyeO1YbwLi3Jc35MmRU6poroFjIGZzUzupGiRPOjgHg9TLu43xbpwXk523fMxKA==", + "dev": true + }, + "node_modules/is-unicode-supported": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz", + "integrity": "sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/is-what": { "version": "3.14.1", "resolved": "https://registry.npmjs.org/is-what/-/is-what-3.14.1.tgz", @@ -5087,6 +5964,12 @@ "node": ">=0.10.0" } }, + "node_modules/isstream": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz", + "integrity": "sha512-Yljz7ffyPbrLpLngrMtZ7NduUgVvi6wG9RJ9IUcyCd59YQ911PBJphODUcbOVbqYfxe1wuYf/LJ8PauMRwsM/g==", + "dev": true + }, "node_modules/jest-worker": { "version": "26.6.2", "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-26.6.2.tgz", @@ -5133,6 +6016,12 @@ "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", "dev": true }, + "node_modules/jsbn": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz", + "integrity": "sha512-UVU9dibq2JcFWxQPA6KCqj5O42VOmAY3zQUfEKxU0KpTGXwNoCjkX1e13eHNvw/xPynt6pU0rZ1htjWTNTSXsg==", + "dev": true + }, "node_modules/jsesc": { "version": "2.5.2", "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz", @@ -5151,12 +6040,24 @@ "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==", "dev": true }, + "node_modules/json-schema": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/json-schema/-/json-schema-0.4.0.tgz", + "integrity": "sha512-es94M3nTIfsEPisRafak+HDLfHXnKBhV3vU5eqPcS3flIWqcxJWgXHXiey3YrpaNsanY5ei1VoYEbOzijuq9BA==", + "dev": true + }, "node_modules/json-schema-traverse": { "version": "0.4.1", "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", "dev": true }, + "node_modules/json-stringify-safe": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz", + "integrity": "sha512-ZClg6AaYvamvYEE82d3Iyd3vSSIjQ+odgjaTzRuO3s7toCdFKczob2i0zCh7JE8kWn17yvAWhUVxvqGwUalsRA==", + "dev": true + }, "node_modules/json5": { "version": "2.2.3", "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.3.tgz", @@ -5169,6 +6070,33 @@ "node": ">=6" } }, + "node_modules/jsonfile": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.1.0.tgz", + "integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==", + "dev": true, + "dependencies": { + "universalify": "^2.0.0" + }, + "optionalDependencies": { + "graceful-fs": "^4.1.6" + } + }, + "node_modules/jsprim": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/jsprim/-/jsprim-2.0.2.tgz", + "integrity": "sha512-gqXddjPqQ6G40VdnI6T6yObEC+pDNvyP95wdQhkWkg7crHH3km5qP1FsOXEkzEQwnz6gz5qGTn1c2Y52wP3OyQ==", + "dev": true, + "engines": [ + "node >=0.6.0" + ], + "dependencies": { + "assert-plus": "1.0.0", + "extsprintf": "1.3.0", + "json-schema": "0.4.0", + "verror": "1.10.0" + } + }, "node_modules/kind-of": { "version": "6.0.3", "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.3.tgz", @@ -5188,6 +6116,15 @@ "shell-quote": "^1.8.1" } }, + "node_modules/lazy-ass": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/lazy-ass/-/lazy-ass-1.6.0.tgz", + "integrity": "sha512-cc8oEVoctTvsFZ/Oje/kGnHbpWHYBe8IAJe4C0QNc3t8uM/0Y8+erSz/7Y1ALuXTEZTMvxXwO6YbX1ey3ujiZw==", + "dev": true, + "engines": { + "node": "> 0.8" + } + }, "node_modules/less": { "version": "4.2.0", "resolved": "https://registry.npmjs.org/less/-/less-4.2.0.tgz", @@ -5264,6 +6201,48 @@ "node": ">=10" } }, + "node_modules/listr2": { + "version": "3.14.0", + "resolved": "https://registry.npmjs.org/listr2/-/listr2-3.14.0.tgz", + "integrity": "sha512-TyWI8G99GX9GjE54cJ+RrNMcIFBfwMPxc3XTFiAYGN4s10hWROGtOg7+O6u6LE3mNkyld7RSLE6nrKBvTfcs3g==", + "dev": true, + "dependencies": { + "cli-truncate": "^2.1.0", + "colorette": "^2.0.16", + "log-update": "^4.0.0", + "p-map": "^4.0.0", + "rfdc": "^1.3.0", + "rxjs": "^7.5.1", + "through": "^2.3.8", + "wrap-ansi": "^7.0.0" + }, + "engines": { + "node": ">=10.0.0" + }, + "peerDependencies": { + "enquirer": ">= 2.3.0 < 3" + }, + "peerDependenciesMeta": { + "enquirer": { + "optional": true + } + } + }, + "node_modules/listr2/node_modules/p-map": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/p-map/-/p-map-4.0.0.tgz", + "integrity": "sha512-/bjOqmgETBYB5BoEeGVea8dmvHb2m9GLy1E9W43yeyfP6QQCZGFNa+XRceJEuDB6zqr+gKpIAmlLebMpykw/MQ==", + "dev": true, + "dependencies": { + "aggregate-error": "^3.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/loader-runner": { "version": "4.3.0", "resolved": "https://registry.npmjs.org/loader-runner/-/loader-runner-4.3.0.tgz", @@ -5273,56 +6252,160 @@ "node": ">=6.11.5" } }, - "node_modules/loader-utils": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-2.0.4.tgz", - "integrity": "sha512-xXqpXoINfFhgua9xiqD8fPFHgkoq1mmmpE92WlDbm9rNRd/EbRb+Gqf908T2DMfuHjjJlksiK2RbHVOdD/MqSw==", + "node_modules/loader-utils": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-2.0.4.tgz", + "integrity": "sha512-xXqpXoINfFhgua9xiqD8fPFHgkoq1mmmpE92WlDbm9rNRd/EbRb+Gqf908T2DMfuHjjJlksiK2RbHVOdD/MqSw==", + "dev": true, + "dependencies": { + "big.js": "^5.2.2", + "emojis-list": "^3.0.0", + "json5": "^2.1.2" + }, + "engines": { + "node": ">=8.9.0" + } + }, + "node_modules/locate-path": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", + "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", + "dev": true, + "dependencies": { + "p-locate": "^4.1.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/lodash": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", + "dev": true + }, + "node_modules/lodash.debounce": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/lodash.debounce/-/lodash.debounce-4.0.8.tgz", + "integrity": "sha512-FT1yDzDYEoYWhnSGnpE/4Kj1fLZkDFyqRb7fNt6FdYOSxlUWAtp42Eh6Wb0rGIv/m9Bgo7x4GhQbm5Ys4SG5ow==", + "dev": true + }, + "node_modules/lodash.memoize": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/lodash.memoize/-/lodash.memoize-4.1.2.tgz", + "integrity": "sha512-t7j+NzmgnQzTAYXcsHYLgimltOV1MXHtlOWf6GjL9Kj8GK5FInw5JotxvbOs+IvV1/Dzo04/fCGfLVs7aXb4Ag==", + "dev": true + }, + "node_modules/lodash.once": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/lodash.once/-/lodash.once-4.1.1.tgz", + "integrity": "sha512-Sb487aTOCr9drQVL8pIxOzVhafOjZN9UU54hiN8PU3uAiSV7lx1yYNpbNmex2PK6dSJoNTSJUUswT651yww3Mg==", + "dev": true + }, + "node_modules/lodash.uniq": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/lodash.uniq/-/lodash.uniq-4.5.0.tgz", + "integrity": "sha512-xfBaXQd9ryd9dlSDvnvI0lvxfLJlYAZzXomUYzLKtUeOQvOP5piqAWuGtrhWeqaXK9hhoM/iyJc5AV+XfsX3HQ==", + "dev": true + }, + "node_modules/log-symbols": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz", + "integrity": "sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==", + "dev": true, + "dependencies": { + "chalk": "^4.1.0", + "is-unicode-supported": "^0.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/log-update": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/log-update/-/log-update-4.0.0.tgz", + "integrity": "sha512-9fkkDevMefjg0mmzWFBW8YkFP91OrizzkW3diF7CpG+S2EYdy4+TVfGwz1zeF8x7hCx1ovSPTOE9Ngib74qqUg==", + "dev": true, + "dependencies": { + "ansi-escapes": "^4.3.0", + "cli-cursor": "^3.1.0", + "slice-ansi": "^4.0.0", + "wrap-ansi": "^6.2.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/log-update/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/log-update/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/log-update/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, + "node_modules/log-update/node_modules/slice-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-4.0.0.tgz", + "integrity": "sha512-qMCMfhY040cVHT43K9BFygqYbUPFZKHOg7K73mtTWJRb8pyP3fzf4Ixd5SzdEJQ6MRUg/WBnOLxghZtKKurENQ==", "dev": true, "dependencies": { - "big.js": "^5.2.2", - "emojis-list": "^3.0.0", - "json5": "^2.1.2" + "ansi-styles": "^4.0.0", + "astral-regex": "^2.0.0", + "is-fullwidth-code-point": "^3.0.0" }, "engines": { - "node": ">=8.9.0" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/slice-ansi?sponsor=1" } }, - "node_modules/locate-path": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", - "integrity": "sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==", + "node_modules/log-update/node_modules/wrap-ansi": { + "version": "6.2.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-6.2.0.tgz", + "integrity": "sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA==", "dev": true, "dependencies": { - "p-locate": "^4.1.0" + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" }, "engines": { "node": ">=8" } }, - "node_modules/lodash": { - "version": "4.17.21", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", - "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", - "dev": true - }, - "node_modules/lodash.debounce": { - "version": "4.0.8", - "resolved": "https://registry.npmjs.org/lodash.debounce/-/lodash.debounce-4.0.8.tgz", - "integrity": "sha512-FT1yDzDYEoYWhnSGnpE/4Kj1fLZkDFyqRb7fNt6FdYOSxlUWAtp42Eh6Wb0rGIv/m9Bgo7x4GhQbm5Ys4SG5ow==", - "dev": true - }, - "node_modules/lodash.memoize": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/lodash.memoize/-/lodash.memoize-4.1.2.tgz", - "integrity": "sha512-t7j+NzmgnQzTAYXcsHYLgimltOV1MXHtlOWf6GjL9Kj8GK5FInw5JotxvbOs+IvV1/Dzo04/fCGfLVs7aXb4Ag==", - "dev": true - }, - "node_modules/lodash.uniq": { - "version": "4.5.0", - "resolved": "https://registry.npmjs.org/lodash.uniq/-/lodash.uniq-4.5.0.tgz", - "integrity": "sha512-xfBaXQd9ryd9dlSDvnvI0lvxfLJlYAZzXomUYzLKtUeOQvOP5piqAWuGtrhWeqaXK9hhoM/iyJc5AV+XfsX3HQ==", - "dev": true - }, "node_modules/lru-cache": { "version": "5.1.1", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-5.1.1.tgz", @@ -5776,6 +6859,12 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/ospath": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/ospath/-/ospath-1.2.2.tgz", + "integrity": "sha512-o6E5qJV5zkAbIDNhGSIlyOhScKXgQrSRMilfph0clDfM0nEnBOlKlH4sWDmG95BW/CvwNz0vmm7dJVtU2KlMiA==", + "dev": true + }, "node_modules/p-limit": { "version": "2.3.0", "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", @@ -5897,6 +6986,18 @@ "integrity": "sha512-5DFkuoqlv1uYQKxy8omFBeJPQcdoE07Kv2sferDCrAq1ohOU+MSDswDIbnx3YAM60qIOnYa53wBhXW0EbMonrQ==", "dev": true }, + "node_modules/pend": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/pend/-/pend-1.2.0.tgz", + "integrity": "sha512-F3asv42UuXchdzt+xXqfW1OGlVBe+mxa2mqI0pg5yAHZPvFmY3Y6drSf/GQ1A86WgWEN9Kzh/WrgKa6iGcHXLg==", + "dev": true + }, + "node_modules/performance-now": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz", + "integrity": "sha512-7EAHlyLHI56VEIdK57uwHdHKIaAGbnXPiw0yWbarQZOKaKpvUIgW0jWRVLiatnM+XXlSwsanIBH/hzGMJulMow==", + "dev": true + }, "node_modules/picocolors": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz", @@ -6526,6 +7627,18 @@ "integrity": "sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ==", "dev": true }, + "node_modules/pretty-bytes": { + "version": "5.6.0", + "resolved": "https://registry.npmjs.org/pretty-bytes/-/pretty-bytes-5.6.0.tgz", + "integrity": "sha512-FFw039TmrBqFK8ma/7OL3sDz/VytdtJr044/QUJtH0wK9lb9jLq9tJyIxUwtQJHwar2BqtiA4iCWSwo9JLkzFg==", + "dev": true, + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/pretty-error": { "version": "3.0.4", "resolved": "https://registry.npmjs.org/pretty-error/-/pretty-error-3.0.4.tgz", @@ -6536,6 +7649,15 @@ "renderkid": "^2.0.6" } }, + "node_modules/process": { + "version": "0.11.10", + "resolved": "https://registry.npmjs.org/process/-/process-0.11.10.tgz", + "integrity": "sha512-cdGef/drWFoydD1JsMzuFf8100nZl+GT+yacc2bEced5f9Rjk4z+WtFUTBu9PhOi9j/jfmBPu0mMEY4wIdAF8A==", + "dev": true, + "engines": { + "node": ">= 0.6.0" + } + }, "node_modules/process-nextick-args": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", @@ -6564,6 +7686,12 @@ "node": ">= 0.10" } }, + "node_modules/proxy-from-env": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/proxy-from-env/-/proxy-from-env-1.0.0.tgz", + "integrity": "sha512-F2JHgJQ1iqwnHDcQjVBsq3n/uoaFL+iPW/eAeL7kVxy/2RrWaN4WroKjjvbsoRtv0ftelNyC01bjRhn/bhcf4A==", + "dev": true + }, "node_modules/prr": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/prr/-/prr-1.0.1.tgz", @@ -6571,6 +7699,22 @@ "dev": true, "optional": true }, + "node_modules/psl": { + "version": "1.9.0", + "resolved": "https://registry.npmjs.org/psl/-/psl-1.9.0.tgz", + "integrity": "sha512-E/ZsdU4HLs/68gYzgGTkMicWTLPdAftJLfJFlLUAAKZGkStNU72sZjT66SnMDVOfOWY/YAoiD7Jxa9iHvngcag==", + "dev": true + }, + "node_modules/pump": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", + "integrity": "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==", + "dev": true, + "dependencies": { + "end-of-stream": "^1.1.0", + "once": "^1.3.1" + } + }, "node_modules/punycode": { "version": "2.3.1", "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.1.tgz", @@ -6595,6 +7739,12 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/querystringify": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz", + "integrity": "sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ==", + "dev": true + }, "node_modules/randombytes": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", @@ -6786,6 +7936,15 @@ "node": ">=0.10.0" } }, + "node_modules/request-progress": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/request-progress/-/request-progress-3.0.0.tgz", + "integrity": "sha512-MnWzEHHaxHO2iWiQuHrUPBi/1WeBf5PkxQqNyNvLl9VAYSdXkP8tQ3pBSeCPD+yw0v0Aq1zosWLz0BdeXpWwZg==", + "dev": true, + "dependencies": { + "throttleit": "^1.0.0" + } + }, "node_modules/require-from-string": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz", @@ -6973,6 +8132,19 @@ "node": ">=6" } }, + "node_modules/restore-cursor": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/restore-cursor/-/restore-cursor-3.1.0.tgz", + "integrity": "sha512-l+sSefzHpj5qimhFSE5a8nufZYAM3sBSVMAPtYkmC+4EH2anSGaEMXSD0izRQbu9nfyQ9y5JrVmp7E8oZrUjvA==", + "dev": true, + "dependencies": { + "onetime": "^5.1.0", + "signal-exit": "^3.0.2" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/retry": { "version": "0.13.1", "resolved": "https://registry.npmjs.org/retry/-/retry-0.13.1.tgz", @@ -7004,6 +8176,12 @@ "integrity": "sha512-+4nRk0k3oEpwUB7/CalD7xE2z4VmtEnnq0GO2IPTkrooTrAhEsWvuLF5iWP1dXrwluki/azwXV1ve7gtYuPldg==", "dev": true }, + "node_modules/rfdc": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/rfdc/-/rfdc-1.3.1.tgz", + "integrity": "sha512-r5a3l5HzYlIC68TpmYKlxWjmOP6wiPJ1vWv2HeLhNsRZMrCkxeqxiHlQ21oXmQ4F3SiryXBHhAD7JZqvOJjFmg==", + "dev": true + }, "node_modules/rimraf": { "version": "2.7.1", "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.7.1.tgz", @@ -7016,6 +8194,15 @@ "rimraf": "bin.js" } }, + "node_modules/rxjs": { + "version": "7.8.1", + "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-7.8.1.tgz", + "integrity": "sha512-AA3TVj+0A2iuIoQkWEK/tqFjBq2j+6PO6Y0zJcvzLAFhEFIO3HL0vls9hWLncZbAAbK0mar7oZ4V079I/qPMxg==", + "dev": true, + "dependencies": { + "tslib": "^2.1.0" + } + }, "node_modules/safe-buffer": { "version": "5.2.1", "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", @@ -7365,6 +8552,53 @@ "marked": "*" } }, + "node_modules/slice-ansi": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-3.0.0.tgz", + "integrity": "sha512-pSyv7bSTC7ig9Dcgbw9AuRNUb5k5V6oDudjZoMBSr13qpLBG7tB+zgCkARjq7xIUgdz5P1Qe8u+rSGdouOOIyQ==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.0.0", + "astral-regex": "^2.0.0", + "is-fullwidth-code-point": "^3.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/slice-ansi/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/slice-ansi/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/slice-ansi/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, "node_modules/sockjs": { "version": "0.3.24", "resolved": "https://registry.npmjs.org/sockjs/-/sockjs-0.3.24.tgz", @@ -7461,6 +8695,31 @@ "wbuf": "^1.7.3" } }, + "node_modules/sshpk": { + "version": "1.18.0", + "resolved": "https://registry.npmjs.org/sshpk/-/sshpk-1.18.0.tgz", + "integrity": "sha512-2p2KJZTSqQ/I3+HX42EpYOa2l3f8Erv8MWKsy2I9uf4wA7yFIkXRffYdsx86y6z4vHtV8u7g+pPlr8/4ouAxsQ==", + "dev": true, + "dependencies": { + "asn1": "~0.2.3", + "assert-plus": "^1.0.0", + "bcrypt-pbkdf": "^1.0.0", + "dashdash": "^1.12.0", + "ecc-jsbn": "~0.1.1", + "getpass": "^0.1.1", + "jsbn": "~0.1.0", + "safer-buffer": "^2.0.2", + "tweetnacl": "~0.14.0" + }, + "bin": { + "sshpk-conv": "bin/sshpk-conv", + "sshpk-sign": "bin/sshpk-sign", + "sshpk-verify": "bin/sshpk-verify" + }, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/stable": { "version": "0.1.8", "resolved": "https://registry.npmjs.org/stable/-/stable-0.1.8.tgz", @@ -7733,6 +8992,21 @@ "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==", "dev": true }, + "node_modules/throttleit": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/throttleit/-/throttleit-1.0.1.tgz", + "integrity": "sha512-vDZpf9Chs9mAdfY046mcPt8fg5QSZr37hEH4TXYBnDF+izxgrbRGUAAaBvIk/fJm9aOFCGFd1EsNg5AZCbnQCQ==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==", + "dev": true + }, "node_modules/thunky": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/thunky/-/thunky-1.1.0.tgz", @@ -7796,18 +9070,72 @@ "node": ">=0.6" } }, + "node_modules/tough-cookie": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-4.1.3.tgz", + "integrity": "sha512-aX/y5pVRkfRnfmuX+OdbSdXvPe6ieKX/G2s7e98f4poJHnqH3281gDPm/metm6E/WRamfx7WC4HUqkWHfQHprw==", + "dev": true, + "dependencies": { + "psl": "^1.1.33", + "punycode": "^2.1.1", + "universalify": "^0.2.0", + "url-parse": "^1.5.3" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/tough-cookie/node_modules/universalify": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/universalify/-/universalify-0.2.0.tgz", + "integrity": "sha512-CJ1QgKmNg3CwvAv/kOFmtnEN05f0D/cn9QntgNOQlQF9dgvVTHj3t+8JPdjqawCHk7V/KA+fbUqzZ9XWhcqPUg==", + "dev": true, + "engines": { + "node": ">= 4.0.0" + } + }, "node_modules/tslib": { "version": "2.6.2", "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.2.tgz", "integrity": "sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==", "dev": true }, + "node_modules/tunnel-agent": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz", + "integrity": "sha512-McnNiV1l8RYeY8tBgEpuodCC1mLUdbSN+CYBL7kJsJNInOP8UjDDEwdk6Mw60vdLLrr5NHKZhMAOSrR2NZuQ+w==", + "dev": true, + "dependencies": { + "safe-buffer": "^5.0.1" + }, + "engines": { + "node": "*" + } + }, + "node_modules/tweetnacl": { + "version": "0.14.5", + "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz", + "integrity": "sha512-KXXFFdAbFXY4geFIwoyNK+f5Z1b7swfXABfL7HXCmoIWMKU3dmS26672A4EeQtDzLKy7SXmfBu51JolvEKwtGA==", + "dev": true + }, "node_modules/type": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/type/-/type-1.2.0.tgz", "integrity": "sha512-+5nt5AAniqsCnu2cEQQdpzCAh33kVx8n0VoFidKpB1dVVLAN/F+bgVOqOJqOnEnrhp222clB5p3vUlD+1QAnfg==", "dev": true }, + "node_modules/type-fest": { + "version": "0.21.3", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.21.3.tgz", + "integrity": "sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/type-is": { "version": "1.6.18", "resolved": "https://registry.npmjs.org/type-is/-/type-is-1.6.18.tgz", @@ -7872,6 +9200,15 @@ "node": ">=4" } }, + "node_modules/universalify": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz", + "integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==", + "dev": true, + "engines": { + "node": ">= 10.0.0" + } + }, "node_modules/unpipe": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", @@ -7881,6 +9218,15 @@ "node": ">= 0.8" } }, + "node_modules/untildify": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/untildify/-/untildify-4.0.0.tgz", + "integrity": "sha512-KK8xQ1mkzZeg9inewmFVDNkg3l5LUhoq9kN6iWYB/CC9YMG8HA+c1Q8HwDe6dEX7kErrEVNVBO3fWsVq5iDgtw==", + "dev": true, + "engines": { + "node": ">=8" + } + }, "node_modules/update-browserslist-db": { "version": "1.0.13", "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.13.tgz", @@ -7927,6 +9273,16 @@ "deprecated": "Please see https://github.com/lydell/urix#deprecated", "dev": true }, + "node_modules/url-parse": { + "version": "1.5.10", + "resolved": "https://registry.npmjs.org/url-parse/-/url-parse-1.5.10.tgz", + "integrity": "sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ==", + "dev": true, + "dependencies": { + "querystringify": "^2.1.1", + "requires-port": "^1.0.0" + } + }, "node_modules/util-deprecate": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", @@ -7966,6 +9322,26 @@ "node": ">= 0.8" } }, + "node_modules/verror": { + "version": "1.10.0", + "resolved": "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz", + "integrity": "sha512-ZZKSmDAEFOijERBLkmYfJ+vmk3w+7hOLYDNkRCuRuMJGEmqYNCNLyBBFwWKVMhfwaEF3WOd0Zlw86U/WC/+nYw==", + "dev": true, + "engines": [ + "node >=0.6.0" + ], + "dependencies": { + "assert-plus": "^1.0.0", + "core-util-is": "1.0.2", + "extsprintf": "^1.2.0" + } + }, + "node_modules/verror/node_modules/core-util-is": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", + "integrity": "sha512-3lqz5YjWTYnW6dlDa5TLaTCcShfar1e40rmcJVwCBJC6mWlFuj0eCHIElmG1g5kyuJ/GD+8Wn4FFCcz4gJPfaQ==", + "dev": true + }, "node_modules/w3c-keyname": { "version": "2.2.8", "resolved": "https://registry.npmjs.org/w3c-keyname/-/w3c-keyname-2.2.8.tgz", @@ -8385,6 +9761,56 @@ "integrity": "sha512-CC1bOL87PIWSBhDcTrdeLo6eGT7mCFtrg0uIJtqJUFyK+eJnzl8A1niH56uu7KMa5XFrtiV+AQuHO3n7DsHnLQ==", "dev": true }, + "node_modules/wrap-ansi": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", + "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", + "dev": true, + "dependencies": { + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/wrap-ansi?sponsor=1" + } + }, + "node_modules/wrap-ansi/node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/wrap-ansi/node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/wrap-ansi/node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true + }, "node_modules/wrappy": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", @@ -8436,6 +9862,16 @@ "node": ">=10" } }, + "node_modules/yauzl": { + "version": "2.10.0", + "resolved": "https://registry.npmjs.org/yauzl/-/yauzl-2.10.0.tgz", + "integrity": "sha512-p4a9I6X6nu6IhoGmBqAcbJy1mlC4j27vEPZX9F4L4/vZT3Lyq1VkFHw/V/PUcB9Buo+DG3iHkT0x3Qya58zc3g==", + "dev": true, + "dependencies": { + "buffer-crc32": "~0.2.3", + "fd-slicer": "~1.1.0" + } + }, "node_modules/yocto-queue": { "version": "0.1.0", "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", diff --git a/package.json b/package.json index a4e02870f..c63499e1b 100644 --- a/package.json +++ b/package.json @@ -20,6 +20,7 @@ "@symfony/stimulus-bridge": "^3.0.0", "@symfony/webpack-encore": "^1.7.0", "core-js": "^3.0.0", + "cypress": "^13.6.4", "file-loader": "^6.2.0", "less": "^4.2.0", "less-loader": "^11.1.3", From 20c9392a63c0985bc617e9904f799563a5b9c419 Mon Sep 17 00:00:00 2001 From: sam Date: Tue, 13 Feb 2024 09:47:29 +0100 Subject: [PATCH 03/19] add first e2e passing test --- cypress.config.js | 6 +-- cypress/e2e/spec.cy.js | 5 -- ...super_admin_can_freeze_unfreeze_user.cy.js | 52 +++++++++++++++++++ templates/_partial/header.html.twig | 2 +- templates/admin/index.html.twig | 2 +- templates/default/index_anon.html.twig | 2 +- templates/member/show.html.twig | 8 +-- 7 files changed, 62 insertions(+), 15 deletions(-) delete mode 100644 cypress/e2e/spec.cy.js create mode 100644 cypress/e2e/super_admin/super_admin_can_freeze_unfreeze_user.cy.js diff --git a/cypress.config.js b/cypress.config.js index 97f47c412..6d143e41f 100644 --- a/cypress.config.js +++ b/cypress.config.js @@ -2,8 +2,8 @@ const { defineConfig } = require("cypress"); module.exports = defineConfig({ e2e: { - setupNodeEvents(on, config) { - // implement node event listeners here - }, + baseUrl: 'http://membres.yourcoop.local:8000', + viewportWidth: 1920, + viewportHeight: 1080, }, }); diff --git a/cypress/e2e/spec.cy.js b/cypress/e2e/spec.cy.js deleted file mode 100644 index 322992ce1..000000000 --- a/cypress/e2e/spec.cy.js +++ /dev/null @@ -1,5 +0,0 @@ -describe('template spec', () => { - it('passes', () => { - cy.visit('https://example.cypress.io') - }) -}) \ No newline at end of file diff --git a/cypress/e2e/super_admin/super_admin_can_freeze_unfreeze_user.cy.js b/cypress/e2e/super_admin/super_admin_can_freeze_unfreeze_user.cy.js new file mode 100644 index 000000000..82519a140 --- /dev/null +++ b/cypress/e2e/super_admin/super_admin_can_freeze_unfreeze_user.cy.js @@ -0,0 +1,52 @@ +// NO PERMANENT CHANGE TO DATABASE + +const base_url = Cypress.config('baseUrl') + +// temporarily disable uncaught exception handling +Cypress.on('uncaught:exception', (err, runnable) => { + return false +}) + +describe('super admin can freeze and unfreeze user', function () { + it('super admin path', function () { + cy.visit(base_url) + cy.get('#login').click() + + cy.log("fill in the login form") + cy.get('#username').type('admin', {force: true}) + cy.get('#password').type('password', {force: true}) + cy.get('button[type=submit]').click() + + // navigate to admin page + cy.get('#admin_link').click() + + // navigate to users page + cy.get('#users_link').click() + + cy.get('#member_9').click() + + // open on freeze options + cy.get('#freeze').click() + cy.log('click on freeze immediately option') + cy.get('#open_freeze_member_confirmation_modal').click() + + cy.log('click on modal confirmation button') + cy.get('#freeze_member_confirmation_modal_confirm').click() + + cy.log('search for "gelé" text') + cy.contains('gelé') + + cy.log('open on freeze options') + cy.get('#freeze').click() + + cy.log('click on unfreeze button') + cy.get('#open_unfreeze_member_confirmation_modal').click() + + cy.log('click on modal confirmation button') + cy.get('#unfreeze_member_confirmation_modal_confirm').click() + + cy.log('the text "gelé" should not be on the page') + cy.contains(/(? {% if is_granted("ROLE_ADMIN_PANEL") %}
  • - + build Administration diff --git a/templates/admin/index.html.twig b/templates/admin/index.html.twig index 7e0565470..496adf381 100644 --- a/templates/admin/index.html.twig +++ b/templates/admin/index.html.twig @@ -25,7 +25,7 @@ {% if is_granted("ROLE_USER_MANAGER") %}
    people Membres
    - + peopleGérer les membres diff --git a/templates/default/index_anon.html.twig b/templates/default/index_anon.html.twig index 64cfbab12..a09943d0a 100644 --- a/templates/default/index_anon.html.twig +++ b/templates/default/index_anon.html.twig @@ -6,7 +6,7 @@

    Bienvenue sur l'espace membre

    diff --git a/templates/member/show.html.twig b/templates/member/show.html.twig index a70589b10..2ceeb20ee 100644 --- a/templates/member/show.html.twig +++ b/templates/member/show.html.twig @@ -211,7 +211,7 @@ {% endif %} {% if is_granted("freeze", member) %} {% if not member.frozen %} - + pausedtimer_offGeler le compte immédiatement {{ form_start(freeze_form) }} @@ -231,14 +231,14 @@ {{ form_end(freeze_form) }} {% else %} - + play_arrowtimer_off Dégeler le compte immédiatement {{ form_start(unfreeze_form) }} @@ -252,7 +252,7 @@ From 4f82fd45ce4ce399f3d398b1314159ce4c7d3bd3 Mon Sep 17 00:00:00 2001 From: sam Date: Wed, 14 Feb 2024 11:55:20 +0100 Subject: [PATCH 04/19] install cypress and add first tests --- .env.dist | 4 +- .env.oidc | 226 ++ .env.test | 5 +- config/packages/twig.yaml | 5 +- config/services.yaml | 37 +- .../e2e/keycloak/admin/admin1_can_login.cy.js | 29 + .../keycloak/keycloak_reusables.cytools.js | 24 + cypress/e2e/login/login_reusables.cytools.js | 11 + ...super_admin_can_freeze_unfreeze_user.cy.js | 27 +- .../super_admin/super_admin_can_login.cy.js | 26 + docker-compose.symfony_server.yml.dist | 4 +- package-lock.json | 69 + package.json | 5 +- realm-export.json | 2432 ----------------- src/Security/KeycloakAuthenticator.php | 4 +- templates/Profile/show_content.html.twig | 2 +- templates/_partial/header.html.twig | 4 +- templates/admin/index.html.twig | 2 +- templates/admin/user/list.html.twig | 4 +- templates/beneficiary/_partial/info.html.twig | 2 +- .../Security/login_content.html.twig | 4 +- templates/default/index.html.twig | 4 +- templates/default/index_anon.html.twig | 2 +- templates/member/show.html.twig | 10 +- 24 files changed, 456 insertions(+), 2486 deletions(-) create mode 100644 .env.oidc create mode 100644 cypress/e2e/keycloak/admin/admin1_can_login.cy.js create mode 100644 cypress/e2e/keycloak/keycloak_reusables.cytools.js create mode 100644 cypress/e2e/login/login_reusables.cytools.js rename cypress/e2e/{ => login}/super_admin/super_admin_can_freeze_unfreeze_user.cy.js (54%) create mode 100644 cypress/e2e/login/super_admin/super_admin_can_login.cy.js delete mode 100644 realm-export.json diff --git a/.env.dist b/.env.dist index 6751685ae..d159f647a 100644 --- a/.env.dist +++ b/.env.dist @@ -181,9 +181,9 @@ LOGGING_MATTERMOST_CHANNEL=elefan # Open ID Client OIDC_ENABLE=false -OIDC_PROFILE_CUSTOM_MESSAGE='vos informations personnelles sont éditables ici ' +OIDC_PROFILE_CUSTOM_MESSAGE='vos informations personnelles sont éditables ici ' OIDC_NO_ACCOUNT_MESSAGE="Vous n\'avez pas de compte. Veuillez contacter le support." -OIDC_ISSUER=http://host.docker.internal:8081/auth +OIDC_ISSUER=http://keycloak:8080/auth OIDC_REALM=elefan OIDC_CLIENT_ID=elefan OIDC_CLIENT_SECRET=secret diff --git a/.env.oidc b/.env.oidc new file mode 100644 index 000000000..dc4d045f2 --- /dev/null +++ b/.env.oidc @@ -0,0 +1,226 @@ +SYMFONY_ENV='dev' +APP_SECRET='$ecretf0rt3st' +PHP_USER='www-data' +PHP_IDE_CONFIG='serverName=membres.yourcoop.local' +PHP_MEMORY_LIMIT=512M +PHP_SERVICE_NAME='php7.4-fpm' +###> symfony/framework-bundle ### +SYMFONY_DEPRECATIONS_HELPER=999999 +APP_ENV=dev +#TRUSTED_PROXIES=127.0.0.0/8,10.0.0.0/8,172.16.0.0/12,192.168.0.0/16 +#TRUSTED_HOSTS='^(localhost|example\.com)$' +###< symfony/framework-bundle ### + +###> doctrine/doctrine-bundle ### +DATABASE_URL="mysql://root:secret@database:3306/symfony?serverVersion=5.7&charset=utf8" +DATABASE_TEST_HOST=127.0.0.1 +###< doctrine/doctrine-bundle ### + +###> symfony/swiftmailer-bundle ### +# For Gmail as a transport, use: "gmail://username:password@localhost" +# For a generic SMTP server, use: "smtp://localhost:25?encryption=&auth_mode=" +# Delivery is disabled by default via "null://localhost" +MAILER_URL=null://localhost +###< symfony/swiftmailer-bundle ### + +# SUPER_ADMIN User +SUPER_ADMIN_USERNAME=admin +SUPER_ADMIN_INITIAL_PASSWORD=password + +# Mailer Configuration +MAILER_TRANSPORT=smtp +MAILER_HOST=mailcatcher +MAILER_PORT=1025 +MAILER_USER=null +MAILER_PASSWORD=null +MAILER_ENCRYPTION=null + +# Transactional Mailer User +TRANSACTIONAL_MAILER_USER=contact@yourcoop.local +TRANSACTIONAL_MAILER_USER_NAME='espace membre' + +# Base Domain for Emails +EMAILS_BASE_DOMAIN=yourcoop.local + +# Email Addresses +EMAILS_CONTACT_NAME='Contact Localcoop' +EMAILS_CONTACT_ADDRESS=contact@yourcoop.local +EMAILS_MEMBER_NAME='Membres Localcoop' +EMAILS_MEMBER_ADDRESS=membres@yourcoop.local +EMAILS_SHIFT_NAME='Créneaux Localcoop' +EMAILS_SHIFT_ADDRESS=creneaux@yourcoop.local +EMAILS_FORMATION_NAME='Formation Localcoop' +EMAILS_FORMATION_ADDRESS=formations@yourcoop.local +EMAILS_ADMIN_NAME='Admin Localcoop' +EMAILS_ADMIN_ADDRESS=admin@yourcoop.local +EMAILS_NOREPLY_NAME='Ne pas répondre' +EMAILS_NOREPLY_ADDRESS=noreply@yourcoop.local + +# Router Configuration +ROUTER_REQUEST_CONTEXT_HOST=membres.yourcoop.local +ROUTER_REQUEST_CONTEXT_SCHEME=https +ROUTER_REQUEST_CONTEXT_BASE_URL= + +# Security: IP check +ENABLE_PLACE_LOCAL_IP_ADDRESS_CHECK=true +PLACE_LOCAL_IP_ADDRESS='127.0.0.1,192.168.0.x' + +# Branding +SITE_NAME="Espace membre @ MyLocalCoop" +PROJECT_NAME="My Local Coop" +PROJECT_URL=https://yourcoop.local/ +PROJECT_URL_DISPLAY=yourcoop.local +MAIN_COLOR=#51CAE9 +LOCAL_CURRENCY_NAME="monnaie locale" + +# Registration +REGISTRATION_DURATION='1 year' +REGISTRATION_EVERY_CIVIL_YEAR=false +REGISTRATION_MANUAL_ENABLED=true +HELLOASSO_REGISTRATION_CAMPAIGN_URL=https://www.helloasso.com/associations/my-local-coop/adhesions/re-adhesion +HELLOASSO_API_KEY= +HELLOASSO_API_PASSWORD= +HELLOASSO_API_BASE_URL=https://api.helloasso.com/v3/ + +# Shifting Configuration +DUE_DURATION_BY_CYCLE=180 +MIN_SHIFT_DURATION=90 +CYCLE_DURATION='28 days' +CYCLE_TYPE=abcd +NEW_USERS_START_AS_BEGINNER=true +ALLOW_EXTRA_SHIFTS=true +MAX_TIME_IN_ADVANCE_TO_BOOK_EXTRA_SHIFTS='3 days' +TIME_AFTER_WHICH_MEMBERS_ARE_LATE_WITH_SHIFTS=-9 +RESERVE_NEW_SHIFT_TO_PRIOR_SHIFTER=true +RESERVE_NEW_SHIFT_TO_PRIOR_SHIFTER_DELAY=7 +FORBID_SHIFT_OVERLAP_TIME=30 +MAX_TIME_AT_END_OF_SHIFT=0 +DISPLAY_NAME_SHIFTERS=false + +# shift fly and fixed +USE_FLY_AND_FIXED=false +FLY_AND_FIXED_ENTITY_FLYING=Beneficiary +FLY_AND_FIXED_ALLOW_FIXED_SHIFT_FREE=false + +# Swipe card +USE_CARD_READER_TO_VALIDATE_SHIFTS=false +SWIPE_CARD_LOGGING=true +SWIPE_CARD_LOGGING_ANONYMOUS=true +DISPLAY_SWIPE_CARDS_SETTINGS=true + +# Shifting: time log saving +USE_TIME_LOG_SAVING=false +TIME_LOG_SAVING_SHIFT_FREE_MIN_TIME_IN_ADVANCE_DAYS=null +TIME_LOG_SAVING_SHIFT_FREE_ALLOW_ONLY_IF_ENOUGH_SAVING=false + +# Profile Configuration +DISPLAY_GAUGE=true +PROFILE_DISPLAY_TASK_LIST=true +PROFILE_DISPLAY_TIME_LOG=true +PROFILE_DISPLAY_SHIFT_FREE_LOG=true +PROFILE_DISPLAY_PERIOD_POSITION_FREE_LOG=true +DISPLAY_FREEZE_ACCOUNT=true +DISPLAY_FREEZE_ACCOUNT_FALSE_MESSAGE="Le gel de compte n'est pas autorisé." +MAX_NB_OF_PAST_CYCLES_TO_DISPLAY=3 + +# User Configuration +USER_ACCOUNT_NOT_ENABLED_MATERIAL_ICON=phonelink_off +USER_ACCOUNT_ENABLED_ICON=☑ +USER_ACCOUNT_ENABLED_MATERIAL_ICON=devices + +# Member Configuration +MAXIMUM_NB_OF_BENEFICIARIES_IN_MEMBERSHIP=2 +MEMBER_WITHDRAWN_ICON=∅ +MEMBER_WITHDRAWN_MATERIAL_ICON=block +MEMBER_WITHDRAWN_BACKGROUND_COLOR='rgba(255, 50, 0, 0.2)' +MEMBER_FROZEN_ICON=❄️ +MEMBER_FROZEN_MATERIAL_ICON=ac_unit +MEMBER_FROZEN_BACKGROUND_COLOR='rgba(0, 138, 255, 0.1)' +MEMBER_EXEMPTED_ICON=☂ +MEMBER_EXEMPTED_MATERIAL_ICON=beach_access +MEMBER_EXEMPTED_BACKGROUND_COLOR='rgb(0, 150, 136, 0.1)' +MEMBER_FLYING_ICON=✈ +MEMBER_FLYING_MATERIAL_ICON=flightsmode +MEMBER_REGISTRATION_MISSING_ICON=$ +MEMBER_REGISTRATION_MISSING_MATERIAL_ICON=attach_money +MEMBER_REGISTRATION_MISSING_BACKGROUND_COLOR='rgb(0, 150, 136, 0.1)' + +# Beneficiary Configuration +BENEFICIARY_MAIN_ICON=⚐ +BENEFICIARY_NEW_ICON=★ +BENEFICIARY_FLYING_ICON=✈ + +# Admin: Member +ADMIN_MEMBER_DISPLAY_SHIFT_FREE_LOG=true +ADMIN_MEMBER_DISPLAY_PERIOD_POSITION_FREE_LOG=true +FORBID_OWN_SHIFT_BOOK_ADMIN=false +FORBID_OWN_SHIFT_FREE_ADMIN=false +FORBID_OWN_SHIFT_VALIDATE_ADMIN=false +FORBID_OWN_TIMELOG_NEW_ADMIN=false + +# Events +MAX_EVENT_PROXY_PER_MEMBER=1 + +# Opening Hours +DISPLAY_OPENING_HOUR_OPEN_CLOSED_HEADER=true +OPENING_HOUR_OPEN_CLOSED_HEADER_OPEN_MESSAGE="Ouvert" +OPENING_HOUR_OPEN_CLOSED_HEADER_CLOSED_MESSAGE="Fermé" + +# Code Generation +CODE_GENERATION_ENABLED=true +DISPLAY_KEYS_SHOP=true +WIKI_KEYS_URL= + +# Logging +LOGGING_MATTERMOST_ENABLED=false +LOGGING_MATTERMOST_LEVEL=critical +LOGGING_MATTERMOST_URL=http://mattermost.yourcoop.local +LOGGING_SWIFTMAILER_ENABLED=false +LOGGING_SWIFTMAILER_LEVEL=critical +LOGGING_SWIFTMAILER_RECIPIENT=email@example.com +LOGGING_MATTERMOST_CHANNEL=elefan + +# Open ID Client +OIDC_ENABLE=true +OIDC_PROFILE_CUSTOM_MESSAGE='vos informations personnelles sont éditables ici ' +OIDC_NO_ACCOUNT_MESSAGE="Vous n\'avez pas de compte. Veuillez contacter le support." +OIDC_ISSUER=http://keycloak:8080/auth +OIDC_REALM=elefan +OIDC_CLIENT_ID=elefan +OIDC_CLIENT_SECRET=secret +OIDC_ROLES_CLAIM=groups + +# OIDC User Attributes Map +OIDC_USER_ATTRIBUTE_FIRSTNAME=firstName +OIDC_USER_ATTRIBUTE_LASTNAME=lastName +OIDC_USER_ATTRIBUTE_MEMBER_NUMBER=member_number +OIDC_USER_ATTRIBUTE_EMAIL=email +OIDC_USER_ATTRIBUTE_PHONE=phone +OIDC_USER_ATTRIBUTE_FLYING=flying +OIDC_USER_ATTRIBUTE_ADDRESS_STREET1=address.street1 +OIDC_USER_ATTRIBUTE_ADDRESS_STREET2=address.street2 +OIDC_USER_ATTRIBUTE_ADDRESS_ZIPCODE=address.zipcode +OIDC_USER_ATTRIBUTE_ADDRESS_CITY=address.city +OIDC_USER_ATTRIBUTE_CO_MEMBER_NUMBER=co_member_number + +# OIDC Roles Map +OIDC_ROLE_USER=/cooperate +OIDC_ROLE_ADMIN_PANEL=/infrastructure/informatique/elefan/admin +OIDC_ROLE_USER_VIEWER=/infrastructure/informatique/elefan/admin +OIDC_ROLE_USER_MANAGER=/infrastructure/informatique/elefan/admin +OIDC_ROLE_SHIFT_MANAGER=/infrastructure/informatique/elefan/admin +OIDC_ROLE_FINANCE_MANAGER=/infrastructure/informatique/elefan/admin +OIDC_ROLE_PROCESS_MANAGER=/infrastructure/informatique/elefan/admin +OIDC_ROLE_ADMIN=/infrastructure/informatique/elefan/admin +OIDC_ROLE_SUPER_ADMIN=/infrastructure/informatique/elefan/super_admin +OIDC_ROLE_OAUTH_LOGIN= + +OIDC_FORMATIONS_CLAIM=groups + +# OIDC Formations Map in JSON +OIDC_FORMATIONS_MAP='{"Accueil magasin": "/infrastructure/informatique/elefan/formations/accueil_magasin", "Caisse": "/infrastructure/informatique/elefan/formations/caisse"}' + +OIDC_COMMISSIONS_CLAIM=groups + +# OIDC Commissions Map in JSON +OIDC_COMMISSIONS_MAP='{"foo": "/grouvernance/foo", "bar": "/grouvernance/bar"}' diff --git a/.env.test b/.env.test index 66925b144..ef4a0afe6 100644 --- a/.env.test +++ b/.env.test @@ -7,7 +7,6 @@ PHP_SERVICE_NAME='php7.4-fpm' ###> symfony/framework-bundle ### SYMFONY_DEPRECATIONS_HELPER=999999 APP_ENV=dev -APP_SECRET=ThisTokenIsNotSoSecretChangeIt #TRUSTED_PROXIES=127.0.0.0/8,10.0.0.0/8,172.16.0.0/12,192.168.0.0/16 #TRUSTED_HOSTS='^(localhost|example\.com)$' ###< symfony/framework-bundle ### @@ -183,9 +182,9 @@ LOGGING_MATTERMOST_CHANNEL=elefan # Open ID Client OIDC_ENABLE=false -OIDC_PROFILE_CUSTOM_MESSAGE='vos informations personnelles sont éditables ici ' +OIDC_PROFILE_CUSTOM_MESSAGE='vos informations personnelles sont éditables ici ' OIDC_NO_ACCOUNT_MESSAGE="Vous n\'avez pas de compte. Veuillez contacter le support." -OIDC_ISSUER=http://host.docker.internal:8081/auth +OIDC_ISSUER=http://keycloak:8080/auth OIDC_REALM=elefan OIDC_CLIENT_ID=elefan OIDC_CLIENT_SECRET=secret diff --git a/config/packages/twig.yaml b/config/packages/twig.yaml index 016089136..e9eec2dd9 100644 --- a/config/packages/twig.yaml +++ b/config/packages/twig.yaml @@ -104,9 +104,10 @@ twig: oidc_enable: '%env(bool:OIDC_ENABLE)%' oidc_issuer: '%env(OIDC_ISSUER)%' oidc_client_id: "%env(OIDC_CLIENT_ID)%" - oidc_roles_claim: "%env(OIDC_ROLES_CLAIM)%" + oidc_roles_claim: "%oidc_roles_claim%" oidc_roles_map: "%oidc_roles_map%" - oidc_formations_claim: "%env(OIDC_FORMATIONS_CLAIM)%" + oidc_user_attributes_map: "%oidc_user_attributes_map%" + oidc_formations_claim: "%oidc_formations_claim%" oidc_formations_map: "%env(OIDC_FORMATIONS_MAP)%" oidc_commissions_claim: "%env(OIDC_COMMISSIONS_CLAIM)%" oidc_commissions_map: "%env(OIDC_COMMISSIONS_MAP)%" diff --git a/config/services.yaml b/config/services.yaml index 215dcad77..29403f200 100644 --- a/config/services.yaml +++ b/config/services.yaml @@ -92,17 +92,34 @@ parameters: opening_hour_open_closed_header_closed_message: '%env(OPENING_HOUR_OPEN_CLOSED_HEADER_CLOSED_MESSAGE)%' opening_hour_open_closed_header_open_message: '%env(OPENING_HOUR_OPEN_CLOSED_HEADER_OPEN_MESSAGE)%' oidc_enable: '%env(bool:OIDC_ENABLE)%' + oidc_user_attributes_map: + firstname: "%env(OIDC_USER_ATTRIBUTE_FIRSTNAME)%" + lastname: "%env(OIDC_USER_ATTRIBUTE_LASTNAME)%" + member_number: "%env(OIDC_USER_ATTRIBUTE_MEMBER_NUMBER)%" + email: "%env(OIDC_USER_ATTRIBUTE_EMAIL)%" + phone: "%env(OIDC_USER_ATTRIBUTE_PHONE)%" + flying: "%env(OIDC_USER_ATTRIBUTE_FLYING)%" + address_street1: "%env(OIDC_USER_ATTRIBUTE_ADDRESS_STREET1)%" + address_street2: "%env(OIDC_USER_ATTRIBUTE_ADDRESS_STREET2)%" + address_zipcode: "%env(OIDC_USER_ATTRIBUTE_ADDRESS_ZIPCODE)%" + address_city: "%env(OIDC_USER_ATTRIBUTE_ADDRESS_CITY)%" + co_member_number: "%env(OIDC_USER_ATTRIBUTE_CO_MEMBER_NUMBER)%" oidc_roles_map: - ROLE_USER: '%env(OIDC_ROLE_USER)%' - ROLE_ADMIN_PANEL: '%env(OIDC_ROLE_ADMIN_PANEL)%' - ROLE_FINANCE_MANAGER: '%env(OIDC_ROLE_FINANCE_MANAGER)%' - ROLE_SHIFT_MANAGER: '%env(OIDC_ROLE_SHIFT_MANAGER)%' - ROLE_PROCESS_MANAGER: '%env(OIDC_ROLE_PROCESS_MANAGER)%' - ROLE_USER_MANAGER: '%env(OIDC_ROLE_USER_MANAGER)%' - ROLE_USER_VIEWER: '%env(OIDC_ROLE_USER_VIEWER)%' - ROLE_ADMIN: '%env(OIDC_ROLE_ADMIN)%' - ROLE_SUPER_ADMIN: '%env(OIDC_ROLE_SUPER_ADMIN)%' - ROLE_OAUTH_LOGIN: '%env(OIDC_ROLE_OAUTH_LOGIN)%' + USER: '%env(OIDC_ROLE_USER)%' + ADMIN_PANEL: '%env(OIDC_ROLE_ADMIN_PANEL)%' + FINANCE_MANAGER: '%env(OIDC_ROLE_FINANCE_MANAGER)%' + SHIFT_MANAGER: '%env(OIDC_ROLE_SHIFT_MANAGER)%' + PROCESS_MANAGER: '%env(OIDC_ROLE_PROCESS_MANAGER)%' + USER_MANAGER: '%env(OIDC_ROLE_USER_MANAGER)%' + USER_VIEWER: '%env(OIDC_ROLE_USER_VIEWER)%' + ADMIN: '%env(OIDC_ROLE_ADMIN)%' + SUPER_ADMIN: '%env(OIDC_ROLE_SUPER_ADMIN)%' + OAUTH_LOGIN: '%env(OIDC_ROLE_OAUTH_LOGIN)%' + oidc_roles_claim: '%env(OIDC_ROLES_CLAIM)%' + oidc_formations_claim: '%env(OIDC_FORMATIONS_CLAIM)%' + oidc_formations_map: '%env(OIDC_FORMATIONS_MAP)%' + oidc_commissions_claim: '%env(OIDC_COMMISSIONS_CLAIM)%' + oidc_commissions_map: '%env(OIDC_COMMISSIONS_MAP)%' place_local_ip_address: '%env(PLACE_LOCAL_IP_ADDRESS)%' profile_display_period_position_free_log: '%env(bool:PROFILE_DISPLAY_PERIOD_POSITION_FREE_LOG)%' profile_display_shift_free_log: '%env(bool:PROFILE_DISPLAY_SHIFT_FREE_LOG)%' diff --git a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js new file mode 100644 index 000000000..7f526f03d --- /dev/null +++ b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js @@ -0,0 +1,29 @@ +// NO PERMANENT CHANGE TO DATABASE + + +// temporarily disable uncaught exception handling +import {login} from "../keycloak_reusables"; + +Cypress.on('uncaught:exception', (err, runnable) => { + return false +}) + +describe('admin1 can login', function () { + it('admin story', function () { + + login("admin1", "password") + + cy.log('home page banner contains "admin"') + cy.get('[data-cy=home_welcome_message]').contains('admin') + + cy.log('go to settings page') + cy.get('[data-cy=settings_link]').click() + + cy.log('display informations') + cy.get('[data-cy=open_my_informations]').click() + + cy.log('check if role_admin in the page') + cy.get('[data-cy=user_roles_container]').contains('role_admin') + + }) +}) diff --git a/cypress/e2e/keycloak/keycloak_reusables.cytools.js b/cypress/e2e/keycloak/keycloak_reusables.cytools.js new file mode 100644 index 000000000..41a1702b7 --- /dev/null +++ b/cypress/e2e/keycloak/keycloak_reusables.cytools.js @@ -0,0 +1,24 @@ +export function login(username, password) { + + cy.visit("/") + cy.get('#login').click() + + cy.origin('http://keycloak:8080', { args : { username, password }}, ({ username, password }) => { + cy.log("fill in the login form") + cy.get('#username').type(username, {force: true}) + cy.get('#password').type(password, {force: true}) + + // submit + cy.get('#kc-login').click() + + cy.location().then((location) => { + if (location !== null && location.origin === 'http://keycloak:8080') { + cy.get('#kc-login').click() + } else { + cy.log("not asked for access to user data") + } + }) + }) +} + + diff --git a/cypress/e2e/login/login_reusables.cytools.js b/cypress/e2e/login/login_reusables.cytools.js new file mode 100644 index 000000000..dfbf3daa3 --- /dev/null +++ b/cypress/e2e/login/login_reusables.cytools.js @@ -0,0 +1,11 @@ +export function login(username, password) { + cy.visit('') + cy.get('[data-cy=login]').click() + + cy.log("fill in the login form") + cy.get('[data-cy=username]').type(username, {force: true}) + cy.get('[data-cy=password]').type(password, {force: true}) + cy.get('button[type=submit]').click() +} + + diff --git a/cypress/e2e/super_admin/super_admin_can_freeze_unfreeze_user.cy.js b/cypress/e2e/login/super_admin/super_admin_can_freeze_unfreeze_user.cy.js similarity index 54% rename from cypress/e2e/super_admin/super_admin_can_freeze_unfreeze_user.cy.js rename to cypress/e2e/login/super_admin/super_admin_can_freeze_unfreeze_user.cy.js index 82519a140..736bc9772 100644 --- a/cypress/e2e/super_admin/super_admin_can_freeze_unfreeze_user.cy.js +++ b/cypress/e2e/login/super_admin/super_admin_can_freeze_unfreeze_user.cy.js @@ -1,5 +1,7 @@ // NO PERMANENT CHANGE TO DATABASE +import {login} from "../login_reusables.cytools"; + const base_url = Cypress.config('baseUrl') // temporarily disable uncaught exception handling @@ -9,41 +11,36 @@ Cypress.on('uncaught:exception', (err, runnable) => { describe('super admin can freeze and unfreeze user', function () { it('super admin path', function () { - cy.visit(base_url) - cy.get('#login').click() - cy.log("fill in the login form") - cy.get('#username').type('admin', {force: true}) - cy.get('#password').type('password', {force: true}) - cy.get('button[type=submit]').click() + login("admin", "password") // navigate to admin page - cy.get('#admin_link').click() + cy.get('[data-cy=admin_link]').click() // navigate to users page - cy.get('#users_link').click() + cy.get('[data-cy=users_link]').click() - cy.get('#member_9').click() + cy.get('[data-cy=member_9]').click() // open on freeze options - cy.get('#freeze').click() + cy.get('[data-cy=freeze]').click() cy.log('click on freeze immediately option') - cy.get('#open_freeze_member_confirmation_modal').click() + cy.get('[data-cy=open_freeze_member_confirmation_modal]').click() cy.log('click on modal confirmation button') - cy.get('#freeze_member_confirmation_modal_confirm').click() + cy.get('[data-cy=freeze_member_confirmation_modal_confirm]').click() cy.log('search for "gelé" text') cy.contains('gelé') cy.log('open on freeze options') - cy.get('#freeze').click() + cy.get('[data-cy=freeze]').click() cy.log('click on unfreeze button') - cy.get('#open_unfreeze_member_confirmation_modal').click() + cy.get('[data-cy=open_unfreeze_member_confirmation_modal]').click() cy.log('click on modal confirmation button') - cy.get('#unfreeze_member_confirmation_modal_confirm').click() + cy.get('[data-cy=unfreeze_member_confirmation_modal_confirm]').click() cy.log('the text "gelé" should not be on the page') cy.contains(/(? { + return false +}) + +describe('super admin can login', function () { + it('super admin path', function () { + + login("admin", "password") + + cy.log('go to settings page') + cy.get('[data-cy=settings_link]').click() + + cy.log('display informations') + cy.get('[data-cy=open_my_informations]').click() + + cy.log('check if role_admin in the page') + cy.get('[data-cy=user_roles_container]').contains('role_super_admin') + + }) + +}) diff --git a/docker-compose.symfony_server.yml.dist b/docker-compose.symfony_server.yml.dist index 5e09b05af..6ecba843f 100644 --- a/docker-compose.symfony_server.yml.dist +++ b/docker-compose.symfony_server.yml.dist @@ -63,8 +63,8 @@ services: - .docker/keycloak/data:/opt/jboss/keycloak/standalone/data/ - .docker/keycloak/config/realm-export.json:/config/realm-export.json environment: - - KEYCLOAK_USER=admin - - KEYCLOAK_PASSWORD=admin + - KEYCLOAK_USER=keycloak_admin + - KEYCLOAK_PASSWORD=password - DB_VENDOR=h2 - KEYCLOAK_IMPORT=/config/realm-export.json user: root diff --git a/package-lock.json b/package-lock.json index a148bafb2..9b8c817fa 100644 --- a/package-lock.json +++ b/package-lock.json @@ -22,6 +22,7 @@ "@symfony/webpack-encore": "^1.7.0", "core-js": "^3.0.0", "cypress": "^13.6.4", + "cypress-dotenv": "^2.0.0", "file-loader": "^6.2.0", "less": "^4.2.0", "less-loader": "^11.1.3", @@ -4187,6 +4188,24 @@ "node": "^16.0.0 || ^18.0.0 || >=20.0.0" } }, + "node_modules/cypress-dotenv": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/cypress-dotenv/-/cypress-dotenv-2.0.0.tgz", + "integrity": "sha512-MHCkWuTU51n/Q6LT2FgjNVZx/OmnrP3Jve7TUGZvSbjgGOpBOVZTbm3tomjvn+2S6HhloRXSAOmT5fY9pvWkpQ==", + "dev": true, + "dependencies": { + "camelcase": "^6.2.0", + "dotenv-parse-variables": "^2.0.0", + "lodash.clonedeep": "^4.5.0" + }, + "engines": { + "node": ">=10.x" + }, + "peerDependencies": { + "cypress": ">= 8.x", + "dotenv": ">= 10.x" + } + }, "node_modules/cypress/node_modules/commander": { "version": "6.2.1", "resolved": "https://registry.npmjs.org/commander/-/commander-6.2.1.tgz", @@ -4490,6 +4509,32 @@ "url": "https://github.com/fb55/domutils?sponsor=1" } }, + "node_modules/dotenv": { + "version": "16.4.3", + "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.4.3.tgz", + "integrity": "sha512-II98GFrje5psQTSve0E7bnwMFybNLqT8Vu8JIFWRjsE3khyNUm/loZupuy5DVzG2IXf/ysxvrixYOQnM6mjD3A==", + "dev": true, + "peer": true, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://dotenvx.com" + } + }, + "node_modules/dotenv-parse-variables": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/dotenv-parse-variables/-/dotenv-parse-variables-2.0.0.tgz", + "integrity": "sha512-/Tezlx6xpDqR6zKg1V4vLCeQtHWiELhWoBz5A/E0+A1lXN9iIkNbbfc4THSymS0LQUo8F1PMiIwVG8ai/HrnSA==", + "dev": true, + "dependencies": { + "debug": "^4.3.1", + "is-string-and-not-blank": "^0.0.2" + }, + "engines": { + "node": ">= 8.3.0" + } + }, "node_modules/ecc-jsbn": { "version": "0.1.2", "resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz", @@ -5907,6 +5952,24 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/is-string-and-not-blank": { + "version": "0.0.2", + "resolved": "https://registry.npmjs.org/is-string-and-not-blank/-/is-string-and-not-blank-0.0.2.tgz", + "integrity": "sha512-FyPGAbNVyZpTeDCTXnzuwbu9/WpNXbCfbHXLpCRpN4GANhS00eEIP5Ef+k5HYSNIzIhdN9zRDoBj6unscECvtQ==", + "dev": true, + "dependencies": { + "is-string-blank": "^1.0.1" + }, + "engines": { + "node": ">=6.4.0" + } + }, + "node_modules/is-string-blank": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-string-blank/-/is-string-blank-1.0.1.tgz", + "integrity": "sha512-9H+ZBCVs3L9OYqv8nuUAzpcT9OTgMD1yAWrG7ihlnibdkbtB850heAmYWxHuXc4CHy4lKeK69tN+ny1K7gBIrw==", + "dev": true + }, "node_modules/is-typedarray": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz", @@ -6284,6 +6347,12 @@ "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", "dev": true }, + "node_modules/lodash.clonedeep": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/lodash.clonedeep/-/lodash.clonedeep-4.5.0.tgz", + "integrity": "sha512-H5ZhCF25riFd9uB5UCkVKo61m3S/xZk1x4wA6yp/L3RFP6Z/eHH1ymQcGLo7J3GMPfm0V/7m1tryHuGVxpqEBQ==", + "dev": true + }, "node_modules/lodash.debounce": { "version": "4.0.8", "resolved": "https://registry.npmjs.org/lodash.debounce/-/lodash.debounce-4.0.8.tgz", diff --git a/package.json b/package.json index c63499e1b..e07b088b8 100644 --- a/package.json +++ b/package.json @@ -21,6 +21,7 @@ "@symfony/webpack-encore": "^1.7.0", "core-js": "^3.0.0", "cypress": "^13.6.4", + "cypress-dotenv": "^2.0.0", "file-loader": "^6.2.0", "less": "^4.2.0", "less-loader": "^11.1.3", @@ -31,7 +32,9 @@ "dev-server": "encore dev-server --disable-host-check", "dev": "encore dev", "watch": "encore dev --watch", - "build": "encore production --progress" + "build": "encore production --progress", + "cy:run:oidc": "cypress run --env configFile=oidc --spec 'cypress/e2e/oidc/*'", + "cy:run:cookie": "cypress run --env configFile=test --spec 'cypress/e2e/cookie/*'" }, "repository": { "type": "git", diff --git a/realm-export.json b/realm-export.json deleted file mode 100644 index d29119128..000000000 --- a/realm-export.json +++ /dev/null @@ -1,2432 +0,0 @@ -{ - "id": "master", - "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": 600, - "enabled": true, - "sslRequired": "external", - "registrationAllowed": false, - "registrationEmailAsUsername": false, - "rememberMe": false, - "verifyEmail": false, - "loginWithEmailAllowed": true, - "duplicateEmailsAllowed": false, - "resetPasswordAllowed": false, - "editUsernameAllowed": false, - "bruteForceProtected": false, - "permanentLockout": false, - "maxFailureWaitSeconds": 900, - "minimumQuickLoginWaitSeconds": 60, - "waitIncrementSeconds": 60, - "quickLoginCheckMilliSeconds": 1000, - "maxDeltaTimeSeconds": 43200, - "failureFactor": 30, - "roles": { - "realm": [ - { - "id": "7941610d-25c2-49fb-8e20-486785db4b93", - "name": "uma_authorization", - "description": "${role_uma_authorization}", - "composite": false, - "clientRole": false, - "containerId": "master", - "attributes": {} - }, - { - "id": "87098cab-8164-44e6-8094-6fb37f827929", - "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": "master", - "attributes": {} - }, - { - "id": "77c165b0-0343-4b67-ad26-c874381973cf", - "name": "admin", - "description": "${role_admin}", - "composite": true, - "composites": { - "realm": [ - "create-realm" - ], - "client": { - "master-realm": [ - "view-realm", - "query-users", - "manage-events", - "create-client", - "manage-authorization", - "view-authorization", - "view-identity-providers", - "view-clients", - "manage-realm", - "query-clients", - "view-events", - "query-groups", - "query-realms", - "manage-clients", - "view-users", - "manage-identity-providers", - "impersonation", - "manage-users" - ] - } - }, - "clientRole": false, - "containerId": "master", - "attributes": {} - }, - { - "id": "eb44483b-0a72-473d-9bd1-267a50f41867", - "name": "create-realm", - "description": "${role_create-realm}", - "composite": false, - "clientRole": false, - "containerId": "master", - "attributes": {} - }, - { - "id": "6814f985-45b1-46e8-8bfb-89ac33c804af", - "name": "offline_access", - "description": "${role_offline-access}", - "composite": false, - "clientRole": false, - "containerId": "master", - "attributes": {} - } - ], - "client": { - "security-admin-console": [], - "admin-cli": [], - "account-console": [], - "broker": [ - { - "id": "5acb761f-b76f-4612-8bd4-f557d2859805", - "name": "read-token", - "description": "${role_read-token}", - "composite": false, - "clientRole": true, - "containerId": "5f0f1b3e-fd08-4508-8e72-7e6f0e1016e5", - "attributes": {} - } - ], - "master-realm": [ - { - "id": "0fd2c359-8ffe-4e3e-a952-a58df7d75f39", - "name": "view-realm", - "description": "${role_view-realm}", - "composite": false, - "clientRole": true, - "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", - "attributes": {} - }, - { - "id": "09d3e063-0393-4adf-bea8-b1491d457c11", - "name": "query-users", - "description": "${role_query-users}", - "composite": false, - "clientRole": true, - "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", - "attributes": {} - }, - { - "id": "fe78105a-2c1b-4597-b45e-1d05032a78c6", - "name": "manage-events", - "description": "${role_manage-events}", - "composite": false, - "clientRole": true, - "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", - "attributes": {} - }, - { - "id": "1a8f121a-52b4-4a13-95f6-b17b3725d148", - "name": "create-client", - "description": "${role_create-client}", - "composite": false, - "clientRole": true, - "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", - "attributes": {} - }, - { - "id": "55b29443-d838-4371-8186-958a7915feea", - "name": "manage-authorization", - "description": "${role_manage-authorization}", - "composite": false, - "clientRole": true, - "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", - "attributes": {} - }, - { - "id": "84c5bb90-5a1b-42b1-be76-baf1a1b897d9", - "name": "view-authorization", - "description": "${role_view-authorization}", - "composite": false, - "clientRole": true, - "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", - "attributes": {} - }, - { - "id": "4895a90a-1732-4eb0-a7d1-c9df062d88a7", - "name": "view-clients", - "description": "${role_view-clients}", - "composite": true, - "composites": { - "client": { - "master-realm": [ - "query-clients" - ] - } - }, - "clientRole": true, - "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", - "attributes": {} - }, - { - "id": "31aa071e-8048-4160-b24a-a2555f5f0316", - "name": "view-identity-providers", - "description": "${role_view-identity-providers}", - "composite": false, - "clientRole": true, - "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", - "attributes": {} - }, - { - "id": "4c38f8e3-1945-4578-8979-ba034018682d", - "name": "manage-realm", - "description": "${role_manage-realm}", - "composite": false, - "clientRole": true, - "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", - "attributes": {} - }, - { - "id": "ac26d491-af04-484a-a9b8-7a2633d9f55f", - "name": "query-clients", - "description": "${role_query-clients}", - "composite": false, - "clientRole": true, - "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", - "attributes": {} - }, - { - "id": "95db5be0-e8e7-46d8-9764-eac24ccab670", - "name": "query-groups", - "description": "${role_query-groups}", - "composite": false, - "clientRole": true, - "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", - "attributes": {} - }, - { - "id": "50fbc31a-5854-46e6-a562-70deb80b836f", - "name": "view-events", - "description": "${role_view-events}", - "composite": false, - "clientRole": true, - "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", - "attributes": {} - }, - { - "id": "2c3409f0-99a0-47ff-aec1-51959ba259d6", - "name": "query-realms", - "description": "${role_query-realms}", - "composite": false, - "clientRole": true, - "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", - "attributes": {} - }, - { - "id": "6a7a60a5-a5f7-437b-991d-283c1e63317b", - "name": "manage-clients", - "description": "${role_manage-clients}", - "composite": false, - "clientRole": true, - "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", - "attributes": {} - }, - { - "id": "9a6276bc-9291-4b55-a1ad-3c2dd8436428", - "name": "view-users", - "description": "${role_view-users}", - "composite": true, - "composites": { - "client": { - "master-realm": [ - "query-groups", - "query-users" - ] - } - }, - "clientRole": true, - "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", - "attributes": {} - }, - { - "id": "4ad38cc2-847f-457f-8940-782e9545d3fa", - "name": "manage-identity-providers", - "description": "${role_manage-identity-providers}", - "composite": false, - "clientRole": true, - "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", - "attributes": {} - }, - { - "id": "01bdc0c6-c4d7-48a7-b076-2ba7815ba3a8", - "name": "impersonation", - "description": "${role_impersonation}", - "composite": false, - "clientRole": true, - "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", - "attributes": {} - }, - { - "id": "4d34c1f6-732d-416b-bdf0-b9d20d4b46ac", - "name": "manage-users", - "description": "${role_manage-users}", - "composite": false, - "clientRole": true, - "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", - "attributes": {} - } - ], - "account": [ - { - "id": "87d670ff-4058-496c-afae-7bf3e98f121a", - "name": "manage-consent", - "description": "${role_manage-consent}", - "composite": true, - "composites": { - "client": { - "account": [ - "view-consent" - ] - } - }, - "clientRole": true, - "containerId": "a61bd6c8-faaa-4fbd-8752-09f14115d521", - "attributes": {} - }, - { - "id": "1a76fcf3-f713-43f5-95bb-8899e2b3a727", - "name": "view-consent", - "description": "${role_view-consent}", - "composite": false, - "clientRole": true, - "containerId": "a61bd6c8-faaa-4fbd-8752-09f14115d521", - "attributes": {} - }, - { - "id": "3e2f441a-d466-4348-83ef-8acb8d6f116d", - "name": "delete-account", - "description": "${role_delete-account}", - "composite": false, - "clientRole": true, - "containerId": "a61bd6c8-faaa-4fbd-8752-09f14115d521", - "attributes": {} - }, - { - "id": "402bb844-10be-458a-9e58-0b5a41295e7e", - "name": "manage-account-links", - "description": "${role_manage-account-links}", - "composite": false, - "clientRole": true, - "containerId": "a61bd6c8-faaa-4fbd-8752-09f14115d521", - "attributes": {} - }, - { - "id": "3ade3216-f686-4f72-b6d7-96d4eb59117b", - "name": "view-applications", - "description": "${role_view-applications}", - "composite": false, - "clientRole": true, - "containerId": "a61bd6c8-faaa-4fbd-8752-09f14115d521", - "attributes": {} - }, - { - "id": "fabd291e-7074-486e-ad25-98dd8b5e3449", - "name": "manage-account", - "description": "${role_manage-account}", - "composite": true, - "composites": { - "client": { - "account": [ - "manage-account-links" - ] - } - }, - "clientRole": true, - "containerId": "a61bd6c8-faaa-4fbd-8752-09f14115d521", - "attributes": {} - }, - { - "id": "83d0b65c-66c4-4b70-aaef-4324e36a863a", - "name": "view-profile", - "description": "${role_view-profile}", - "composite": false, - "clientRole": true, - "containerId": "a61bd6c8-faaa-4fbd-8752-09f14115d521", - "attributes": {} - } - ], - "elefan": [] - } - }, - "defaultRole": { - "id": "87098cab-8164-44e6-8094-6fb37f827929", - "name": "default-roles-master", - "description": "${role_default-roles}", - "composite": true, - "clientRole": false, - "containerId": "master" - }, - "requiredCredentials": [ - "password" - ], - "otpPolicyType": "totp", - "otpPolicyAlgorithm": "HmacSHA1", - "otpPolicyInitialCounter": 0, - "otpPolicyDigits": 6, - "otpPolicyLookAheadWindow": 1, - "otpPolicyPeriod": 30, - "otpSupportedApplications": [ - "FreeOTP", - "Google Authenticator" - ], - "webAuthnPolicyRpEntityName": "keycloak", - "webAuthnPolicySignatureAlgorithms": [ - "ES256" - ], - "webAuthnPolicyRpId": "", - "webAuthnPolicyAttestationConveyancePreference": "not specified", - "webAuthnPolicyAuthenticatorAttachment": "not specified", - "webAuthnPolicyRequireResidentKey": "not specified", - "webAuthnPolicyUserVerificationRequirement": "not specified", - "webAuthnPolicyCreateTimeout": 0, - "webAuthnPolicyAvoidSameAuthenticatorRegister": false, - "webAuthnPolicyAcceptableAaguids": [], - "webAuthnPolicyPasswordlessRpEntityName": "keycloak", - "webAuthnPolicyPasswordlessSignatureAlgorithms": [ - "ES256" - ], - "webAuthnPolicyPasswordlessRpId": "", - "webAuthnPolicyPasswordlessAttestationConveyancePreference": "not specified", - "webAuthnPolicyPasswordlessAuthenticatorAttachment": "not specified", - "webAuthnPolicyPasswordlessRequireResidentKey": "not specified", - "webAuthnPolicyPasswordlessUserVerificationRequirement": "not specified", - "webAuthnPolicyPasswordlessCreateTimeout": 0, - "webAuthnPolicyPasswordlessAvoidSameAuthenticatorRegister": false, - "webAuthnPolicyPasswordlessAcceptableAaguids": [], - "scopeMappings": [ - { - "clientScope": "offline_access", - "roles": [ - "offline_access" - ] - } - ], - "clientScopeMappings": { - "account": [ - { - "client": "account-console", - "roles": [ - "manage-account" - ] - } - ] - }, - "clients": [ - { - "id": "a61bd6c8-faaa-4fbd-8752-09f14115d521", - "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": {}, - "authenticationFlowBindingOverrides": {}, - "fullScopeAllowed": false, - "nodeReRegistrationTimeout": 0, - "defaultClientScopes": [ - "web-origins", - "profile", - "roles", - "email" - ], - "optionalClientScopes": [ - "address", - "phone", - "offline_access", - "microprofile-jwt" - ] - }, - { - "id": "af2c05db-5d5d-4b62-8f25-d276fc718d81", - "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": { - "pkce.code.challenge.method": "S256" - }, - "authenticationFlowBindingOverrides": {}, - "fullScopeAllowed": false, - "nodeReRegistrationTimeout": 0, - "protocolMappers": [ - { - "id": "ddfb2545-8d24-40b4-acf5-a2fd55a296a1", - "name": "audience resolve", - "protocol": "openid-connect", - "protocolMapper": "oidc-audience-resolve-mapper", - "consentRequired": false, - "config": {} - } - ], - "defaultClientScopes": [ - "web-origins", - "profile", - "roles", - "email" - ], - "optionalClientScopes": [ - "address", - "phone", - "offline_access", - "microprofile-jwt" - ] - }, - { - "id": "dcfbb83b-428a-4f78-a155-afc940754033", - "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": {}, - "authenticationFlowBindingOverrides": {}, - "fullScopeAllowed": false, - "nodeReRegistrationTimeout": 0, - "defaultClientScopes": [ - "web-origins", - "profile", - "roles", - "email" - ], - "optionalClientScopes": [ - "address", - "phone", - "offline_access", - "microprofile-jwt" - ] - }, - { - "id": "5f0f1b3e-fd08-4508-8e72-7e6f0e1016e5", - "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": {}, - "authenticationFlowBindingOverrides": {}, - "fullScopeAllowed": false, - "nodeReRegistrationTimeout": 0, - "defaultClientScopes": [ - "web-origins", - "profile", - "roles", - "email" - ], - "optionalClientScopes": [ - "address", - "phone", - "offline_access", - "microprofile-jwt" - ] - }, - { - "clientId": "elefan", - "name": "membres.yourcoop.local", - "secret": "secret", - "description": "membres.yourcoop.local", - "rootUrl": "", - "adminUrl": "http://membres.yourcoop.local:8000/", - "baseUrl": "http://membres.yourcoop.local:8000/", - "surrogateAuthRequired": false, - "enabled": true, - "alwaysDisplayInConsole": false, - "clientAuthenticatorType": "client-secret", - "redirectUris": [ - "http://membres.yourcoop.local:8000/*" - ], - "webOrigins": [ - "http://membres.yourcoop.local:8000/" - ], - "notBefore": 0, - "bearerOnly": false, - "consentRequired": true, - "standardFlowEnabled": true, - "implicitFlowEnabled": true, - "directAccessGrantsEnabled": true, - "serviceAccountsEnabled": false, - "publicClient": false, - "frontchannelLogout": false, - "protocol": "openid-connect", - "attributes": { - "access.token.lifespan": "300", - "saml.force.post.binding": "false", - "saml.multivalued.roles": "false", - "oauth2.device.authorization.grant.enabled": "false", - "backchannel.logout.revoke.offline.tokens": "true", - "saml.server.signature.keyinfo.ext": "false", - "use.refresh.tokens": "true", - "oidc.ciba.grant.enabled": "false", - "backchannel.logout.session.required": "true", - "backchannel.logout.url": "http://membres.yourcoop.local:8000/logout", - "client_credentials.use_refresh_token": "false", - "require.pushed.authorization.requests": "false", - "saml.client.signature": "false", - "id.token.as.detached.signature": "false", - "saml.assertion.signature": "false", - "saml.encrypt": "false", - "login_theme": "keycloak", - "saml.server.signature": "false", - "exclude.session.state.from.auth.response": "false", - "saml.artifact.binding": "false", - "saml_force_name_id_format": "false", - "tls.client.certificate.bound.access.tokens": "false", - "saml.authnstatement": "false", - "display.on.consent.screen": "true", - "saml.onetimeuse.condition": "false", - }, - "authenticationFlowBindingOverrides": {}, - "fullScopeAllowed": true, - "nodeReRegistrationTimeout": -1, - "protocolMappers": [ - { - "name": "adresse.ville", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "adresse.ville", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "adresse.ville", - "jsonType.label": "String" - } - }, - { - "name": "flying", - "protocol": "openid-connect", - "protocolMapper": "oidc-hardcoded-claim-mapper", - "consentRequired": false, - "config": { - "claim.value": "false", - "userinfo.token.claim": "true", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "flying", - "jsonType.label": "boolean", - "access.tokenResponse.claim": "false" - } - }, - { - "name": "email", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-property-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "email", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "email", - "jsonType.label": "String" - } - }, - { - "name": "lastName", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-property-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "lastName", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "lastName", - "jsonType.label": "String" - } - }, - { - "name": "adresse.adresse", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "adresse.adresse", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "adresse.adresse", - "jsonType.label": "String" - } - }, - { - "name": "co_member_number", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "conjoint", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "co_member_number", - "jsonType.label": "String" - } - }, - { - "name": "firstName", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-property-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "firstName", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "firstName", - "jsonType.label": "String" - } - }, - { - "name": "adresse.complement", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "adresse.complement", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "adresse.complement", - "jsonType.label": "String" - } - }, - { - "name": "groups", - "protocol": "openid-connect", - "protocolMapper": "oidc-group-membership-mapper", - "consentRequired": false, - "config": { - "full.path": "true", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "groups", - "userinfo.token.claim": "true" - } - }, - { - "name": "phone", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "telephone", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "phone", - "jsonType.label": "String" - } - }, - { - "name": "adresse.code_postal", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "adresse.code_postal", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "adresse.code_postal", - "jsonType.label": "String" - } - }, - { - "name": "member_number", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "id", - "id.token.claim": "false", - "access.token.claim": "false", - "claim.name": "member_number", - "jsonType.label": "String" - } - } - ], - "defaultClientScopes": [ - "profile", - "roles", - "groups", - "email" - ], - "optionalClientScopes": [ - "address", - "phone", - "offline_access", - "microprofile-jwt" - ], - "access": { - "view": true, - "configure": true, - "manage": true - } - }, - { - "id": "4730ccdf-efe7-4173-b495-ac95da51a474", - "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": {}, - "authenticationFlowBindingOverrides": {}, - "fullScopeAllowed": false, - "nodeReRegistrationTimeout": 0, - "defaultClientScopes": [ - "web-origins", - "profile", - "roles", - "email" - ], - "optionalClientScopes": [ - "address", - "phone", - "offline_access", - "microprofile-jwt" - ] - }, - { - "id": "f26b120b-dcfb-4d49-ad84-c4944398ab2e", - "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": { - "pkce.code.challenge.method": "S256" - }, - "authenticationFlowBindingOverrides": {}, - "fullScopeAllowed": false, - "nodeReRegistrationTimeout": 0, - "protocolMappers": [ - { - "id": "e62f462c-3199-4bb1-b1a2-7230c7341118", - "name": "locale", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "locale", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "locale", - "jsonType.label": "String" - } - } - ], - "defaultClientScopes": [ - "web-origins", - "profile", - "roles", - "email" - ], - "optionalClientScopes": [ - "address", - "phone", - "offline_access", - "microprofile-jwt" - ] - } - ], - "clientScopes": [ - { - "id": "d1d587be-4f3c-4818-b851-8b300e7c20bc", - "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", - "display.on.consent.screen": "false", - "consent.screen.text": "" - }, - "protocolMappers": [ - { - "id": "d52198b9-3700-48d0-b4ec-a67eb8530a51", - "name": "allowed web origins", - "protocol": "openid-connect", - "protocolMapper": "oidc-allowed-origins-mapper", - "consentRequired": false, - "config": {} - } - ] - }, - { - "id": "bd698edc-7366-4c39-9218-181f2a03473d", - "name": "email", - "description": "OpenID Connect built-in scope: email", - "protocol": "openid-connect", - "attributes": { - "include.in.token.scope": "true", - "display.on.consent.screen": "true", - "consent.screen.text": "${emailScopeConsentText}" - }, - "protocolMappers": [ - { - "id": "4dc063b3-b42a-4033-9911-f9aeb070d53b", - "name": "email verified", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-property-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "emailVerified", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "email_verified", - "jsonType.label": "boolean" - } - }, - { - "id": "4fe784e3-5b2d-48d4-860b-2041adcc5029", - "name": "email", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-property-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "email", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "email", - "jsonType.label": "String" - } - } - ] - }, - { - "id": "f34509c6-1b30-4bce-bdcc-9e51330889aa", - "name": "profile", - "description": "OpenID Connect built-in scope: profile", - "protocol": "openid-connect", - "attributes": { - "include.in.token.scope": "true", - "display.on.consent.screen": "true", - "consent.screen.text": "${profileScopeConsentText}" - }, - "protocolMappers": [ - { - "id": "f38ecc21-5776-43f4-af5d-1896425a17a8", - "name": "username", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-property-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "username", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "preferred_username", - "jsonType.label": "String" - } - }, - { - "id": "b8a7a437-15f2-44dd-a3b1-433727ff3705", - "name": "gender", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "gender", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "gender", - "jsonType.label": "String" - } - }, - { - "id": "ac1fea4e-52a1-4888-95e8-efbe59f093c1", - "name": "birthdate", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "birthdate", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "birthdate", - "jsonType.label": "String" - } - }, - { - "id": "e6258de1-bdb0-4422-9202-a571f23e409a", - "name": "picture", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "picture", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "picture", - "jsonType.label": "String" - } - }, - { - "id": "538bb3d9-9602-4d8d-b243-2f0e1f2402fc", - "name": "middle name", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "middleName", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "middle_name", - "jsonType.label": "String" - } - }, - { - "id": "2a982137-e525-46e6-abca-659186bb87fb", - "name": "locale", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "locale", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "locale", - "jsonType.label": "String" - } - }, - { - "id": "d536c945-ca64-422f-aa93-0c26f2b727d1", - "name": "website", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "website", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "website", - "jsonType.label": "String" - } - }, - { - "id": "14b1b459-1bd7-493b-a80b-e426c36a6b78", - "name": "updated at", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "updatedAt", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "updated_at", - "jsonType.label": "String" - } - }, - { - "id": "9a941be0-2a3f-4aa0-b962-6c63fc0b2ff8", - "name": "family name", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-property-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "lastName", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "family_name", - "jsonType.label": "String" - } - }, - { - "id": "edfb6c4d-722c-4c52-8d24-12a47c60e9bd", - "name": "given name", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-property-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "firstName", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "given_name", - "jsonType.label": "String" - } - }, - { - "id": "efc86270-a3ae-4a64-9425-38f7a2e43ad0", - "name": "nickname", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "nickname", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "nickname", - "jsonType.label": "String" - } - }, - { - "id": "9b7d13f9-5d2f-428d-b334-eb4e0a54b0e1", - "name": "profile", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "profile", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "profile", - "jsonType.label": "String" - } - }, - { - "id": "f6b9a7e1-cad5-4fcb-84c9-0ffb5eb5bd1b", - "name": "zoneinfo", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "zoneinfo", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "zoneinfo", - "jsonType.label": "String" - } - }, - { - "id": "d607cc9a-5029-46f5-b0e7-f58ed6126532", - "name": "full name", - "protocol": "openid-connect", - "protocolMapper": "oidc-full-name-mapper", - "consentRequired": false, - "config": { - "id.token.claim": "true", - "access.token.claim": "true", - "userinfo.token.claim": "true" - } - } - ] - }, - { - "id": "bc1a75cc-bc76-4c5d-99d2-b231ea5d0f5f", - "name": "address", - "description": "OpenID Connect built-in scope: address", - "protocol": "openid-connect", - "attributes": { - "include.in.token.scope": "true", - "display.on.consent.screen": "true", - "consent.screen.text": "${addressScopeConsentText}" - }, - "protocolMappers": [ - { - "id": "26a2831c-d0e0-4a0f-96b2-d2d336eaaef5", - "name": "address", - "protocol": "openid-connect", - "protocolMapper": "oidc-address-mapper", - "consentRequired": false, - "config": { - "user.attribute.formatted": "formatted", - "user.attribute.country": "country", - "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": "5d7d24e3-8a14-4a3a-a44e-78edb78e861f", - "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": "f31c28ac-a88a-490d-885e-7d9c0fd7b022", - "name": "upn", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-property-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "username", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "upn", - "jsonType.label": "String" - } - }, - { - "id": "323e0230-0924-4113-89e9-3838cd74c75a", - "name": "groups", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-realm-role-mapper", - "consentRequired": false, - "config": { - "multivalued": "true", - "user.attribute": "foo", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "groups", - "jsonType.label": "String" - } - } - ] - }, - { - "id": "f28b9300-e4e5-45df-ba34-e41d22133786", - "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": "dc682314-0ba1-40a2-8349-5fdee9356fc3", - "name": "phone", - "description": "OpenID Connect built-in scope: phone", - "protocol": "openid-connect", - "attributes": { - "include.in.token.scope": "true", - "display.on.consent.screen": "true", - "consent.screen.text": "${phoneScopeConsentText}" - }, - "protocolMappers": [ - { - "id": "db6e6be6-cb06-4f3b-89ee-d322e86885e9", - "name": "phone number", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "phoneNumber", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "phone_number", - "jsonType.label": "String" - } - }, - { - "id": "d2b2879b-4db1-47d9-a5be-1ee9580e7ad5", - "name": "phone number verified", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-attribute-mapper", - "consentRequired": false, - "config": { - "userinfo.token.claim": "true", - "user.attribute": "phoneNumberVerified", - "id.token.claim": "true", - "access.token.claim": "true", - "claim.name": "phone_number_verified", - "jsonType.label": "boolean" - } - } - ] - }, - { - "id": "85069ac7-9bd7-400c-9041-0b0ef30d33f1", - "name": "roles", - "description": "OpenID Connect scope for add user roles to the access token", - "protocol": "openid-connect", - "attributes": { - "include.in.token.scope": "false", - "display.on.consent.screen": "true", - "consent.screen.text": "${rolesScopeConsentText}" - }, - "protocolMappers": [ - { - "id": "65914269-6d64-4644-acd7-e71caab56f5d", - "name": "audience resolve", - "protocol": "openid-connect", - "protocolMapper": "oidc-audience-resolve-mapper", - "consentRequired": false, - "config": {} - }, - { - "id": "01dac415-fcef-4816-8af7-227dc23b36ce", - "name": "realm roles", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-realm-role-mapper", - "consentRequired": false, - "config": { - "user.attribute": "foo", - "access.token.claim": "true", - "claim.name": "realm_access.roles", - "jsonType.label": "String", - "multivalued": "true" - } - }, - { - "id": "e37babb7-6a34-4230-ab7f-07f108bace5a", - "name": "client roles", - "protocol": "openid-connect", - "protocolMapper": "oidc-usermodel-client-role-mapper", - "consentRequired": false, - "config": { - "user.attribute": "foo", - "access.token.claim": "true", - "claim.name": "resource_access.${client_id}.roles", - "jsonType.label": "String", - "multivalued": "true" - } - } - ] - }, - { - "id": "96347b38-f073-4cdc-be4a-eb90c8b03554", - "name": "role_list", - "description": "SAML role list", - "protocol": "saml", - "attributes": { - "consent.screen.text": "${samlRoleListScopeConsentText}", - "display.on.consent.screen": "true" - }, - "protocolMappers": [ - { - "id": "6bca928a-4514-48e1-8a03-c69d88347fbf", - "name": "role list", - "protocol": "saml", - "protocolMapper": "saml-role-list-mapper", - "consentRequired": false, - "config": { - "single": "false", - "attribute.nameformat": "Basic", - "attribute.name": "Role" - } - } - ] - } - ], - "defaultDefaultClientScopes": [ - "role_list", - "profile", - "email", - "roles", - "web-origins" - ], - "defaultOptionalClientScopes": [ - "offline_access", - "address", - "phone", - "microprofile-jwt" - ], - "browserSecurityHeaders": { - "contentSecurityPolicyReportOnly": "", - "xContentTypeOptions": "nosniff", - "xRobotsTag": "none", - "xFrameOptions": "SAMEORIGIN", - "xXSSProtection": "1; mode=block", - "contentSecurityPolicy": "frame-src 'self'; frame-ancestors 'self'; object-src 'none';", - "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": "49b0604e-498a-4018-bece-101bfe682873", - "name": "Allowed Client Scopes", - "providerId": "allowed-client-templates", - "subType": "anonymous", - "subComponents": {}, - "config": { - "allow-default-scopes": [ - "true" - ] - } - }, - { - "id": "929f2e40-6989-4e32-8a3f-689fc7af7fd6", - "name": "Consent Required", - "providerId": "consent-required", - "subType": "anonymous", - "subComponents": {}, - "config": {} - }, - { - "id": "b2f7f88a-cf56-4bcd-8555-3e7737faddc9", - "name": "Max Clients Limit", - "providerId": "max-clients", - "subType": "anonymous", - "subComponents": {}, - "config": { - "max-clients": [ - "200" - ] - } - }, - { - "id": "6655930a-0cf4-4b60-bc14-40ba36d1139b", - "name": "Allowed Protocol Mapper Types", - "providerId": "allowed-protocol-mappers", - "subType": "anonymous", - "subComponents": {}, - "config": { - "allowed-protocol-mapper-types": [ - "oidc-usermodel-property-mapper", - "oidc-full-name-mapper", - "saml-user-property-mapper", - "oidc-usermodel-attribute-mapper", - "saml-user-attribute-mapper", - "saml-role-list-mapper", - "oidc-address-mapper", - "oidc-sha256-pairwise-sub-mapper" - ] - } - }, - { - "id": "cbb366f3-0574-43fa-919a-1624a8e0b552", - "name": "Allowed Protocol Mapper Types", - "providerId": "allowed-protocol-mappers", - "subType": "authenticated", - "subComponents": {}, - "config": { - "allowed-protocol-mapper-types": [ - "oidc-address-mapper", - "oidc-sha256-pairwise-sub-mapper", - "saml-user-attribute-mapper", - "saml-user-property-mapper", - "oidc-usermodel-property-mapper", - "saml-role-list-mapper", - "oidc-usermodel-attribute-mapper", - "oidc-full-name-mapper" - ] - } - }, - { - "id": "f03cd9e7-a460-4dad-8dc3-358ed47d79b5", - "name": "Trusted Hosts", - "providerId": "trusted-hosts", - "subType": "anonymous", - "subComponents": {}, - "config": { - "host-sending-registration-request-must-match": [ - "true" - ], - "client-uris-must-match": [ - "true" - ] - } - }, - { - "id": "477593a1-0dd5-44bf-b876-045c034d0703", - "name": "Allowed Client Scopes", - "providerId": "allowed-client-templates", - "subType": "authenticated", - "subComponents": {}, - "config": { - "allow-default-scopes": [ - "true" - ] - } - }, - { - "id": "bcd8a353-a195-4e7b-ab4d-1a015bbfacc9", - "name": "Full Scope Disabled", - "providerId": "scope", - "subType": "anonymous", - "subComponents": {}, - "config": {} - } - ], - "org.keycloak.keys.KeyProvider": [ - { - "id": "056c01fc-8886-45e5-91e9-b338ed7c2838", - "name": "rsa-generated", - "providerId": "rsa-generated", - "subComponents": {}, - "config": { - "priority": [ - "100" - ] - } - }, - { - "id": "61a7d918-1c29-42cb-9f76-9120f7c9c2cc", - "name": "aes-generated", - "providerId": "aes-generated", - "subComponents": {}, - "config": { - "priority": [ - "100" - ] - } - }, - { - "id": "54a306bf-5214-44c4-96df-73e8d54dee72", - "name": "rsa-enc-generated", - "providerId": "rsa-enc-generated", - "subComponents": {}, - "config": { - "priority": [ - "100" - ], - "algorithm": [ - "RSA-OAEP" - ] - } - }, - { - "id": "4c76c80b-7fb2-4379-bbe6-2d6758d0d6cc", - "name": "hmac-generated", - "providerId": "hmac-generated", - "subComponents": {}, - "config": { - "priority": [ - "100" - ], - "algorithm": [ - "HS256" - ] - } - } - ] - }, - "internationalizationEnabled": false, - "supportedLocales": [], - "authenticationFlows": [ - { - "id": "5764d6a6-9ab9-49c0-b0d1-4a3b6bf91a79", - "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, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticatorFlow": true, - "requirement": "ALTERNATIVE", - "priority": 20, - "flowAlias": "Verify Existing Account by Re-authentication", - "userSetupAllowed": false, - "autheticatorFlow": true - } - ] - }, - { - "id": "d237385d-de20-4d56-9138-1081fbf6920b", - "alias": "Authentication Options", - "description": "Authentication options.", - "providerId": "basic-flow", - "topLevel": false, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "basic-auth", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 10, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticator": "basic-auth-otp", - "authenticatorFlow": false, - "requirement": "DISABLED", - "priority": 20, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticator": "auth-spnego", - "authenticatorFlow": false, - "requirement": "DISABLED", - "priority": 30, - "userSetupAllowed": false, - "autheticatorFlow": false - } - ] - }, - { - "id": "1209281d-d4bf-4b96-acb6-7283c952c86d", - "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, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticator": "auth-otp-form", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 20, - "userSetupAllowed": false, - "autheticatorFlow": false - } - ] - }, - { - "id": "609780f8-c50f-4a96-9827-ef5704aa0f81", - "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, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticator": "direct-grant-validate-otp", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 20, - "userSetupAllowed": false, - "autheticatorFlow": false - } - ] - }, - { - "id": "c570b8b9-e693-432c-96c9-34203e00e601", - "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, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticator": "auth-otp-form", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 20, - "userSetupAllowed": false, - "autheticatorFlow": false - } - ] - }, - { - "id": "ea66ade5-1db4-43db-a88a-7533a4da29ce", - "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, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticatorFlow": true, - "requirement": "REQUIRED", - "priority": 20, - "flowAlias": "Account verification options", - "userSetupAllowed": false, - "autheticatorFlow": true - } - ] - }, - { - "id": "8b88580a-a02e-4367-9a60-0bbf705c9619", - "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, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticator": "reset-otp", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 20, - "userSetupAllowed": false, - "autheticatorFlow": false - } - ] - }, - { - "id": "54d7249d-c82b-4c2e-9908-f6abd3601237", - "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, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticatorFlow": true, - "requirement": "ALTERNATIVE", - "priority": 20, - "flowAlias": "Handle Existing Account", - "userSetupAllowed": false, - "autheticatorFlow": true - } - ] - }, - { - "id": "9ae359e9-8575-4ff9-b8db-84f085cea1b3", - "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, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticatorFlow": true, - "requirement": "CONDITIONAL", - "priority": 20, - "flowAlias": "First broker login - Conditional OTP", - "userSetupAllowed": false, - "autheticatorFlow": true - } - ] - }, - { - "id": "9e8f6123-18af-435f-93be-a137e2bf9774", - "alias": "browser", - "description": "browser based authentication", - "providerId": "basic-flow", - "topLevel": true, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "auth-cookie", - "authenticatorFlow": false, - "requirement": "ALTERNATIVE", - "priority": 10, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticator": "auth-spnego", - "authenticatorFlow": false, - "requirement": "DISABLED", - "priority": 20, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticator": "identity-provider-redirector", - "authenticatorFlow": false, - "requirement": "ALTERNATIVE", - "priority": 25, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticatorFlow": true, - "requirement": "ALTERNATIVE", - "priority": 30, - "flowAlias": "forms", - "userSetupAllowed": false, - "autheticatorFlow": true - } - ] - }, - { - "id": "806d760e-dd1d-478d-bbc3-f2d9d84801d0", - "alias": "clients", - "description": "Base authentication for clients", - "providerId": "client-flow", - "topLevel": true, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "client-secret", - "authenticatorFlow": false, - "requirement": "ALTERNATIVE", - "priority": 10, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticator": "client-jwt", - "authenticatorFlow": false, - "requirement": "ALTERNATIVE", - "priority": 20, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticator": "client-secret-jwt", - "authenticatorFlow": false, - "requirement": "ALTERNATIVE", - "priority": 30, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticator": "client-x509", - "authenticatorFlow": false, - "requirement": "ALTERNATIVE", - "priority": 40, - "userSetupAllowed": false, - "autheticatorFlow": false - } - ] - }, - { - "id": "cdc6d76f-632b-49e8-898d-16856d50a848", - "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, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticator": "direct-grant-validate-password", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 20, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticatorFlow": true, - "requirement": "CONDITIONAL", - "priority": 30, - "flowAlias": "Direct Grant - Conditional OTP", - "userSetupAllowed": false, - "autheticatorFlow": true - } - ] - }, - { - "id": "738ede8d-0a07-433c-958d-a102c42e7363", - "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, - "userSetupAllowed": false, - "autheticatorFlow": false - } - ] - }, - { - "id": "2ac00703-fade-42bd-9e83-fea39906f062", - "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, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticatorFlow": true, - "requirement": "REQUIRED", - "priority": 20, - "flowAlias": "User creation or linking", - "userSetupAllowed": false, - "autheticatorFlow": true - } - ] - }, - { - "id": "36e2bca3-cbd1-4b56-a51b-69887538ee0a", - "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, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticatorFlow": true, - "requirement": "CONDITIONAL", - "priority": 20, - "flowAlias": "Browser - Conditional OTP", - "userSetupAllowed": false, - "autheticatorFlow": true - } - ] - }, - { - "id": "ba2ac86e-154d-4742-b9d8-2fbe5ab2bc16", - "alias": "http challenge", - "description": "An authentication flow based on challenge-response HTTP Authentication Schemes", - "providerId": "basic-flow", - "topLevel": true, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "no-cookie-redirect", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 10, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticatorFlow": true, - "requirement": "REQUIRED", - "priority": 20, - "flowAlias": "Authentication Options", - "userSetupAllowed": false, - "autheticatorFlow": true - } - ] - }, - { - "id": "e25de487-442b-4c96-a9a8-cd5a6a44d1fc", - "alias": "registration", - "description": "registration flow", - "providerId": "basic-flow", - "topLevel": true, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "registration-page-form", - "authenticatorFlow": true, - "requirement": "REQUIRED", - "priority": 10, - "flowAlias": "registration form", - "userSetupAllowed": false, - "autheticatorFlow": true - } - ] - }, - { - "id": "f4334b65-3337-48bd-bbf4-ae56f84314e8", - "alias": "registration form", - "description": "registration form", - "providerId": "form-flow", - "topLevel": false, - "builtIn": true, - "authenticationExecutions": [ - { - "authenticator": "registration-user-creation", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 20, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticator": "registration-profile-action", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 40, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticator": "registration-password-action", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 50, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticator": "registration-recaptcha-action", - "authenticatorFlow": false, - "requirement": "DISABLED", - "priority": 60, - "userSetupAllowed": false, - "autheticatorFlow": false - } - ] - }, - { - "id": "366052fb-7e33-48a1-a721-46567df5f11e", - "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, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticator": "reset-credential-email", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 20, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticator": "reset-password", - "authenticatorFlow": false, - "requirement": "REQUIRED", - "priority": 30, - "userSetupAllowed": false, - "autheticatorFlow": false - }, - { - "authenticatorFlow": true, - "requirement": "CONDITIONAL", - "priority": 40, - "flowAlias": "Reset - Conditional OTP", - "userSetupAllowed": false, - "autheticatorFlow": true - } - ] - }, - { - "id": "3955dfa6-2e46-4fbc-96b7-88999e82a9c1", - "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, - "userSetupAllowed": false, - "autheticatorFlow": false - } - ] - } - ], - "authenticatorConfig": [ - { - "id": "9cd88a5a-351f-431e-a550-5c9846e0addd", - "alias": "create unique user config", - "config": { - "require.password.update.after.registration": "false" - } - }, - { - "id": "4e54c84b-2ff7-481d-b5f5-76aab72140c8", - "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": "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", - "attributes": { - "cibaBackchannelTokenDeliveryMode": "poll", - "cibaExpiresIn": "120", - "cibaAuthRequestedUserHint": "login_hint", - "parRequestUriLifespan": "60", - "cibaInterval": "5" - }, - "keycloakVersion": "16.1.1", - "userManagedAccessAllowed": false, - "clientProfiles": { - "profiles": [] - }, - "clientPolicies": { - "policies": [] - }, - "users": [ - { - "username": "admin2", - "enabled": true, - "emailVerified": true, - "firstName": "Sebastian (admin)", - "lastName": "Johnson", - "email": "admin2@example.com", - "credentials": [ - { - "type": "password", - "hashedSaltedValue": "xjNR06W/ur5nBS8KFTrDgE81vLjb/t4A5LG2ubs/rII=", - "salt": "dyyLTNS/D+Ukspy5xgIa4w==", - "hashIterations": 27500, - "algorithm": "pbkdf2-sha256" - } - ], - "clientRoles": { - "elefan": ["admin"] - }, - "attributes": { - "member_number": ["12345"], - "phone": ["0685428468"], - "flying": [true], - "address.street1": ["123 Main St"], - "address.street2": ["Apt 4"], - "address.zipcode": ["12345"], - "address.city": ["Anytown"], - "co_member_number": ["67890"] - }, - "groups": [ - "/coopérateur", - "/infrastructure/informatique/elefan/admin" - ] - } - ], - "groups": [ - { - "name": "coopérateur", - "path": "/coopérateur" - }, - { - "name": "infrastructure", - "path": "/infrastructure", - "subGroups": [ - { - "name": "informatique", - "path": "/infrastructure/informatique", - "subGroups": [ - { - "name": "elefan", - "subGroups": [ - { - "name": "admin", - "path": "/infrastructure/informatique/elefan/admin" - }, - { - "name": "super_admin", - "path": "/infrastructure/informatique/elefan/super_admin" - }, - { - "name": "formations", - "path": "/infrastructure/informatique/elefan/formations", - "subGroups": [ - { - "name": "Accueil magasin", - "path": "/infrastructure/informatique/elefan/formations/accueil_magasin" - }, - { - "name": "Caisse", - "path": "/infrastructure/informatique/elefan/formations/caisse" - } - ] - } - ] - } - ] - } - ] - } - ] -} \ No newline at end of file diff --git a/src/Security/KeycloakAuthenticator.php b/src/Security/KeycloakAuthenticator.php index 035d28a98..22d3524c5 100644 --- a/src/Security/KeycloakAuthenticator.php +++ b/src/Security/KeycloakAuthenticator.php @@ -346,7 +346,7 @@ private function updateBeneficiary(KeycloakResourceOwner $keycloakUser, Benefici // formations $formations_claim = $this->container->getParameter('oidc_formations_claim'); $formations_from_keycloak = (isset($keycloakUser->toArray()[$formations_claim])) ? $keycloakUser->toArray()[$formations_claim] : []; - $formations_map = $this->container->getParameter('oidc_formations_map'); + $formations_map = json_decode($this->container->getParameter('oidc_formations_map')); foreach ($beneficiary->getFormations() as $formation){ $beneficiary->removeFormation($formation); } @@ -368,7 +368,7 @@ private function updateBeneficiary(KeycloakResourceOwner $keycloakUser, Benefici // commissions $commissions_claim = $this->container->getParameter('oidc_commissions_claim'); $commissions_from_keycloak = (isset($keycloakUser->toArray()[$commissions_claim])) ? $keycloakUser->toArray()[$commissions_claim] : []; - $commissions_map = $this->container->getParameter('oidc_commissions_map'); + $commissions_map = json_decode($this->container->getParameter('oidc_commissions_map')); foreach ($beneficiary->getCommissions() as $commission){ $beneficiary->removeCommission($commission); } diff --git a/templates/Profile/show_content.html.twig b/templates/Profile/show_content.html.twig index 730290ad7..9f4f62a6e 100644 --- a/templates/Profile/show_content.html.twig +++ b/templates/Profile/show_content.html.twig @@ -12,7 +12,7 @@
    • -
      +
      personMes informations
      diff --git a/templates/_partial/header.html.twig b/templates/_partial/header.html.twig index 0c335e0f4..6a6c14b37 100644 --- a/templates/_partial/header.html.twig +++ b/templates/_partial/header.html.twig @@ -33,7 +33,7 @@
      {% endif %} {% if beneficiary.user and beneficiary.user.roles | length %} -
    • +
    • @@ -211,7 +211,7 @@ {% endif %} {% if is_granted("freeze", member) %} {% if not member.frozen %} - + pausedtimer_offGeler le compte immédiatement {{ form_start(freeze_form) }} @@ -231,14 +231,14 @@ {{ form_end(freeze_form) }} {% else %} - + play_arrowtimer_off Dégeler le compte immédiatement {{ form_start(unfreeze_form) }} @@ -252,7 +252,7 @@ From 5dd364c0fa951600679759f0f3e0d73ca04f7d21 Mon Sep 17 00:00:00 2001 From: sam Date: Thu, 15 Feb 2024 13:30:33 +0100 Subject: [PATCH 05/19] adapt ci.yaml --- .env.oidc | 1 + .env.oidc.test | 228 +++++++++++++++++ .env.test | 16 +- .github/workflows/ci.yaml | 239 +++++++++++++++--- config/packages/test/doctrine.yaml | 3 - config/packages/test/framework.yaml | 2 + config/packages/test/monolog.yaml | 20 +- .../e2e/keycloak/admin/admin1_can_login.cy.js | 2 +- .../super_admin/super_admin_can_login.cy.js | 2 +- package.json | 7 +- 10 files changed, 461 insertions(+), 59 deletions(-) create mode 100644 .env.oidc.test delete mode 100644 config/packages/test/doctrine.yaml diff --git a/.env.oidc b/.env.oidc index dc4d045f2..1c9a94cc6 100644 --- a/.env.oidc +++ b/.env.oidc @@ -7,6 +7,7 @@ PHP_SERVICE_NAME='php7.4-fpm' ###> symfony/framework-bundle ### SYMFONY_DEPRECATIONS_HELPER=999999 APP_ENV=dev +APP_SECRET=ThisTokenIsNotSoSecretChangeIt #TRUSTED_PROXIES=127.0.0.0/8,10.0.0.0/8,172.16.0.0/12,192.168.0.0/16 #TRUSTED_HOSTS='^(localhost|example\.com)$' ###< symfony/framework-bundle ### diff --git a/.env.oidc.test b/.env.oidc.test new file mode 100644 index 000000000..f9cf7238d --- /dev/null +++ b/.env.oidc.test @@ -0,0 +1,228 @@ +# This is used with the github ci + + +SYMFONY_ENV='test' +APP_SECRET='$ecretf0rt3st' +PHP_USER='www-data' +PHP_IDE_CONFIG='serverName=membres.yourcoop.local' +PHP_MEMORY_LIMIT=512M +PHP_SERVICE_NAME='php7.4-fpm' +###> symfony/framework-bundle ### +SYMFONY_DEPRECATIONS_HELPER=999999 +APP_ENV=test +#TRUSTED_PROXIES=127.0.0.0/8,10.0.0.0/8,172.16.0.0/12,192.168.0.0/16 +#TRUSTED_HOSTS='^(localhost|example\.com)$' +###< symfony/framework-bundle ### + +###> doctrine/doctrine-bundle ### +DATABASE_URL="mysql://root:secret@127.0.0.1:3306/symfony?serverVersion=5.7&charset=utf8" +###< doctrine/doctrine-bundle ### + +###> symfony/swiftmailer-bundle ### +# For Gmail as a transport, use: "gmail://username:password@localhost" +# For a generic SMTP server, use: "smtp://localhost:25?encryption=&auth_mode=" +# Delivery is disabled by default via "null://localhost" +MAILER_URL=null://localhost +###< symfony/swiftmailer-bundle ### + +# SUPER_ADMIN User +SUPER_ADMIN_USERNAME=admin +SUPER_ADMIN_INITIAL_PASSWORD=password + +# Mailer Configuration +MAILER_TRANSPORT=smtp +MAILER_HOST=mailcatcher +MAILER_PORT=1025 +MAILER_USER=null +MAILER_PASSWORD=null +MAILER_ENCRYPTION=null + +# Transactional Mailer User +TRANSACTIONAL_MAILER_USER=contact@yourcoop.local +TRANSACTIONAL_MAILER_USER_NAME='espace membre' + +# Base Domain for Emails +EMAILS_BASE_DOMAIN=yourcoop.local + +# Email Addresses +EMAILS_CONTACT_NAME='Contact Localcoop' +EMAILS_CONTACT_ADDRESS=contact@yourcoop.local +EMAILS_MEMBER_NAME='Membres Localcoop' +EMAILS_MEMBER_ADDRESS=membres@yourcoop.local +EMAILS_SHIFT_NAME='Créneaux Localcoop' +EMAILS_SHIFT_ADDRESS=creneaux@yourcoop.local +EMAILS_FORMATION_NAME='Formation Localcoop' +EMAILS_FORMATION_ADDRESS=formations@yourcoop.local +EMAILS_ADMIN_NAME='Admin Localcoop' +EMAILS_ADMIN_ADDRESS=admin@yourcoop.local +EMAILS_NOREPLY_NAME='Ne pas répondre' +EMAILS_NOREPLY_ADDRESS=noreply@yourcoop.local + +# Router Configuration +ROUTER_REQUEST_CONTEXT_HOST=membres.yourcoop.local +ROUTER_REQUEST_CONTEXT_SCHEME=https +ROUTER_REQUEST_CONTEXT_BASE_URL= + +# Security: IP check +ENABLE_PLACE_LOCAL_IP_ADDRESS_CHECK=true +PLACE_LOCAL_IP_ADDRESS='127.0.0.1,192.168.0.x' + +# Branding +SITE_NAME="Espace membre @ MyLocalCoop" +PROJECT_NAME="My Local Coop" +PROJECT_URL=https://yourcoop.local/ +PROJECT_URL_DISPLAY=yourcoop.local +MAIN_COLOR=#51CAE9 +LOCAL_CURRENCY_NAME="monnaie locale" + +# Registration +REGISTRATION_DURATION='1 year' +REGISTRATION_EVERY_CIVIL_YEAR=false +REGISTRATION_MANUAL_ENABLED=true +HELLOASSO_REGISTRATION_CAMPAIGN_URL=https://www.helloasso.com/associations/my-local-coop/adhesions/re-adhesion +HELLOASSO_API_KEY= +HELLOASSO_API_PASSWORD= +HELLOASSO_API_BASE_URL=https://api.helloasso.com/v3/ + +# Shifting Configuration +DUE_DURATION_BY_CYCLE=180 +MIN_SHIFT_DURATION=90 +CYCLE_DURATION='28 days' +CYCLE_TYPE=abcd +NEW_USERS_START_AS_BEGINNER=true +ALLOW_EXTRA_SHIFTS=true +MAX_TIME_IN_ADVANCE_TO_BOOK_EXTRA_SHIFTS='3 days' +TIME_AFTER_WHICH_MEMBERS_ARE_LATE_WITH_SHIFTS=-9 +RESERVE_NEW_SHIFT_TO_PRIOR_SHIFTER=true +RESERVE_NEW_SHIFT_TO_PRIOR_SHIFTER_DELAY=7 +FORBID_SHIFT_OVERLAP_TIME=30 +MAX_TIME_AT_END_OF_SHIFT=0 +DISPLAY_NAME_SHIFTERS=false + +# shift fly and fixed +USE_FLY_AND_FIXED=false +FLY_AND_FIXED_ENTITY_FLYING=Beneficiary +FLY_AND_FIXED_ALLOW_FIXED_SHIFT_FREE=false + +# Swipe card +USE_CARD_READER_TO_VALIDATE_SHIFTS=false +SWIPE_CARD_LOGGING=true +SWIPE_CARD_LOGGING_ANONYMOUS=true +DISPLAY_SWIPE_CARDS_SETTINGS=true + +# Shifting: time log saving +USE_TIME_LOG_SAVING=false +TIME_LOG_SAVING_SHIFT_FREE_MIN_TIME_IN_ADVANCE_DAYS=null +TIME_LOG_SAVING_SHIFT_FREE_ALLOW_ONLY_IF_ENOUGH_SAVING=false + +# Profile Configuration +DISPLAY_GAUGE=true +PROFILE_DISPLAY_TASK_LIST=true +PROFILE_DISPLAY_TIME_LOG=true +PROFILE_DISPLAY_SHIFT_FREE_LOG=true +PROFILE_DISPLAY_PERIOD_POSITION_FREE_LOG=true +DISPLAY_FREEZE_ACCOUNT=true +DISPLAY_FREEZE_ACCOUNT_FALSE_MESSAGE="Le gel de compte n'est pas autorisé." +MAX_NB_OF_PAST_CYCLES_TO_DISPLAY=3 + +# User Configuration +USER_ACCOUNT_NOT_ENABLED_MATERIAL_ICON=phonelink_off +USER_ACCOUNT_ENABLED_ICON=☑ +USER_ACCOUNT_ENABLED_MATERIAL_ICON=devices + +# Member Configuration +MAXIMUM_NB_OF_BENEFICIARIES_IN_MEMBERSHIP=2 +MEMBER_WITHDRAWN_ICON=∅ +MEMBER_WITHDRAWN_MATERIAL_ICON=block +MEMBER_WITHDRAWN_BACKGROUND_COLOR='rgba(255, 50, 0, 0.2)' +MEMBER_FROZEN_ICON=❄️ +MEMBER_FROZEN_MATERIAL_ICON=ac_unit +MEMBER_FROZEN_BACKGROUND_COLOR='rgba(0, 138, 255, 0.1)' +MEMBER_EXEMPTED_ICON=☂ +MEMBER_EXEMPTED_MATERIAL_ICON=beach_access +MEMBER_EXEMPTED_BACKGROUND_COLOR='rgb(0, 150, 136, 0.1)' +MEMBER_FLYING_ICON=✈ +MEMBER_FLYING_MATERIAL_ICON=flightsmode +MEMBER_REGISTRATION_MISSING_ICON=$ +MEMBER_REGISTRATION_MISSING_MATERIAL_ICON=attach_money +MEMBER_REGISTRATION_MISSING_BACKGROUND_COLOR='rgb(0, 150, 136, 0.1)' + +# Beneficiary Configuration +BENEFICIARY_MAIN_ICON=⚐ +BENEFICIARY_NEW_ICON=★ +BENEFICIARY_FLYING_ICON=✈ + +# Admin: Member +ADMIN_MEMBER_DISPLAY_SHIFT_FREE_LOG=true +ADMIN_MEMBER_DISPLAY_PERIOD_POSITION_FREE_LOG=true +FORBID_OWN_SHIFT_BOOK_ADMIN=false +FORBID_OWN_SHIFT_FREE_ADMIN=false +FORBID_OWN_SHIFT_VALIDATE_ADMIN=false +FORBID_OWN_TIMELOG_NEW_ADMIN=false + +# Events +MAX_EVENT_PROXY_PER_MEMBER=1 + +# Opening Hours +DISPLAY_OPENING_HOUR_OPEN_CLOSED_HEADER=true +OPENING_HOUR_OPEN_CLOSED_HEADER_OPEN_MESSAGE="Ouvert" +OPENING_HOUR_OPEN_CLOSED_HEADER_CLOSED_MESSAGE="Fermé" + +# Code Generation +CODE_GENERATION_ENABLED=true +DISPLAY_KEYS_SHOP=true +WIKI_KEYS_URL= + +# Logging +LOGGING_MATTERMOST_ENABLED=false +LOGGING_MATTERMOST_LEVEL=critical +LOGGING_MATTERMOST_URL=http://mattermost.yourcoop.local +LOGGING_SWIFTMAILER_ENABLED=false +LOGGING_SWIFTMAILER_LEVEL=critical +LOGGING_SWIFTMAILER_RECIPIENT=email@example.com +LOGGING_MATTERMOST_CHANNEL=elefan + +# Open ID Client +OIDC_ENABLE=true +OIDC_PROFILE_CUSTOM_MESSAGE='vos informations personnelles sont éditables ici ' +OIDC_NO_ACCOUNT_MESSAGE="Vous n\'avez pas de compte. Veuillez contacter le support." +OIDC_ISSUER=http://keycloak:8080/auth +OIDC_REALM=elefan +OIDC_CLIENT_ID=elefan +OIDC_CLIENT_SECRET=secret +OIDC_ROLES_CLAIM=groups + +# OIDC User Attributes Map +OIDC_USER_ATTRIBUTE_FIRSTNAME=firstName +OIDC_USER_ATTRIBUTE_LASTNAME=lastName +OIDC_USER_ATTRIBUTE_MEMBER_NUMBER=member_number +OIDC_USER_ATTRIBUTE_EMAIL=email +OIDC_USER_ATTRIBUTE_PHONE=phone +OIDC_USER_ATTRIBUTE_FLYING=flying +OIDC_USER_ATTRIBUTE_ADDRESS_STREET1=address.street1 +OIDC_USER_ATTRIBUTE_ADDRESS_STREET2=address.street2 +OIDC_USER_ATTRIBUTE_ADDRESS_ZIPCODE=address.zipcode +OIDC_USER_ATTRIBUTE_ADDRESS_CITY=address.city +OIDC_USER_ATTRIBUTE_CO_MEMBER_NUMBER=co_member_number + +# OIDC Roles Map +OIDC_ROLE_USER=/cooperate +OIDC_ROLE_ADMIN_PANEL=/infrastructure/informatique/elefan/admin +OIDC_ROLE_USER_VIEWER=/infrastructure/informatique/elefan/admin +OIDC_ROLE_USER_MANAGER=/infrastructure/informatique/elefan/admin +OIDC_ROLE_SHIFT_MANAGER=/infrastructure/informatique/elefan/admin +OIDC_ROLE_FINANCE_MANAGER=/infrastructure/informatique/elefan/admin +OIDC_ROLE_PROCESS_MANAGER=/infrastructure/informatique/elefan/admin +OIDC_ROLE_ADMIN=/infrastructure/informatique/elefan/admin +OIDC_ROLE_SUPER_ADMIN=/infrastructure/informatique/elefan/super_admin +OIDC_ROLE_OAUTH_LOGIN= + +OIDC_FORMATIONS_CLAIM=groups + +# OIDC Formations Map in JSON +OIDC_FORMATIONS_MAP='{"Accueil magasin": "/infrastructure/informatique/elefan/formations/accueil_magasin", "Caisse": "/infrastructure/informatique/elefan/formations/caisse"}' + +OIDC_COMMISSIONS_CLAIM=groups + +# OIDC Commissions Map in JSON +OIDC_COMMISSIONS_MAP='{"foo": "/grouvernance/foo", "bar": "/grouvernance/bar"}' diff --git a/.env.test b/.env.test index ef4a0afe6..d70e2d911 100644 --- a/.env.test +++ b/.env.test @@ -1,19 +1,21 @@ -SYMFONY_ENV='dev' +# This is used with the github ci + + +APP_ENV=test +SYMFONY_ENV='test' APP_SECRET='$ecretf0rt3st' PHP_USER='www-data' -PHP_IDE_CONFIG='serverName=membres.yourcoop.local' +PHP_IDE_CONFIG='serverName=localhost' PHP_MEMORY_LIMIT=512M PHP_SERVICE_NAME='php7.4-fpm' ###> symfony/framework-bundle ### SYMFONY_DEPRECATIONS_HELPER=999999 -APP_ENV=dev #TRUSTED_PROXIES=127.0.0.0/8,10.0.0.0/8,172.16.0.0/12,192.168.0.0/16 #TRUSTED_HOSTS='^(localhost|example\.com)$' ###< symfony/framework-bundle ### ###> doctrine/doctrine-bundle ### -DATABASE_URL="mysql://root:secret@database:3306/symfony?serverVersion=5.7&charset=utf8" -DATABASE_TEST_HOST=127.0.0.1 +DATABASE_URL="mysql://root:secret@127.0.0.1:3306/symfony?serverVersion=5.7&charset=utf8" ###< doctrine/doctrine-bundle ### ###> symfony/swiftmailer-bundle ### @@ -57,8 +59,8 @@ EMAILS_NOREPLY_NAME='Ne pas répondre' EMAILS_NOREPLY_ADDRESS=noreply@yourcoop.local # Router Configuration -ROUTER_REQUEST_CONTEXT_HOST=membres.yourcoop.local -ROUTER_REQUEST_CONTEXT_SCHEME=https +ROUTER_REQUEST_CONTEXT_HOST=localhost +ROUTER_REQUEST_CONTEXT_SCHEME=http ROUTER_REQUEST_CONTEXT_BASE_URL= # Security: IP check diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 0b17fad87..3307a81db 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -2,26 +2,135 @@ name: Integration and Functional tests on: pull_request: - branches: [ master ] + branches: + - master + - staging + - dev jobs: - symfony: - name: main - # https://hub.docker.com/_/ubuntu/ - runs-on: ubuntu-20.04 + setup: + runs-on: ubuntu-22.04 strategy: fail-fast: true matrix: php-versions: ['7.4'] steps: -# # clean ( for local debug ) -# - name: Remove all mysql containers -# run: docker rm -f $(docker ps -a -q --filter ancestor=mariadb:10.4.10) +# REMOVE RESIDUAL CONTAINERS ( for local debug with act only ) + - name: Remove all mysql containers when working with act + if: ${{ env.ACT }} + run: | + CONTAINERS=$(docker ps -a -q --filter ancestor=mariadb:10.4.10) + if [ ! -z "$CONTAINERS" ]; then + docker rm -f $CONTAINERS + else + echo "No containers to remove." + fi - name: Checkout code - uses: actions/checkout@v3 + uses: actions/checkout@v4 + +# INSTALL DEPENDENCIES ---------------- + - name: Setup PHP, extensions and composer with shivammathur/setup-php + uses: shivammathur/setup-php@verbose + with: + php-version: ${{ matrix.php-versions }} + tools: composer:2.2 + extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json + + - name: Setup Node.js + uses: actions/setup-node@v4 + with: + node-version: '20.11.0' + + - name: Get composer cache directory + id: composer-cache + run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_ENV + + - name: Cache composer dependencies + uses: actions/cache@v4 + with: + path: | + ${{ env.dir }} + ./vendor + key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} + restore-keys: ${{ runner.os }}-composer- + +# INSTALL PACKAGES ---------------- + - name: Clean node_modules + run: rm -rf node_modules + + - name: Install NPM packages + run: npm ci + + - name: Install Composer dependencies + run: composer install --no-progress --prefer-dist --optimize-autoloader + + +# UPLOAD CACHED DIRECTORIES ---------------- + - name: Upload Vendor Directory as Artifact + uses: actions/upload-artifact@v4 + with: + name: vendor-dir + path: vendor/ + + phpStan: + needs: setup + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v4 + +# GET CACHED DIRECTORIES ---------------- + - name: Download Vendor Directory + uses: actions/download-artifact@v4 + with: + name: vendor-dir + path: vendor/ + +# INSTALL DEPENDENCIES ---------------- + - name: Setup PHP, extensions and composer with shivammathur/setup-php + uses: shivammathur/setup-php@verbose + with: + php-version: ${{ matrix.php-versions }} + tools: composer:2.2 + extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json + + - name: Set executable permissions for PHPStan + run: chmod +x ./vendor/bin/phpstan + +# RUN PHPSTAN ---------------- + - name: Run PHPStan + run: ./vendor/bin/phpstan analyse src + + + symfony-tests: + needs: setup + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v4 + +# GET CACHED DIRECTORIES ---------------- + - name: Download Vendor Directory + uses: actions/download-artifact@v4 + with: + name: vendor-dir + path: vendor/ + +# INSTALL DEPENDENCIES ---------------- + - name: Install MySQL Client + run: sudo apt-get update && sudo apt-get install -y mysql-client + + - name: Setup PHP, extensions and composer with shivammathur/setup-php + uses: shivammathur/setup-php@verbose + with: + php-version: ${{ matrix.php-versions }} + tools: composer:2.2 + extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json - # Start database service +# SET ENVIRONMENT VARIABLES ---------------- + - name: Set up test environment variables + run: cp .env.test .env + +# START SERVICES ---------------- - name: Set up MySQL uses: getong/mariadb-action@v1.1 with: @@ -35,10 +144,43 @@ jobs: mysql user: 'user' # Required if "mysql root password" is empty, default is empty. The superuser for the specified database. Can use secrets, too mysql password: 'password' # Required if "mysql user" exists. The password for the "mysql user" + - name: Wait for MySQL to become available + run: | + until mysql -h 127.0.0.1 -u root -psecret -e "SELECT 1"; do + echo 'Waiting for MySQL...' + sleep 1 + done + +# RUN MIGRATIONS ---------------- + - name: Run migrations + run: php bin/console doctrine:migrations:migrate --no-interaction + +# RUN TESTS ---------------- + - name: Run unit and functional tests + run: | + php ./vendor/bin/phpunit --configuration phpunit.xml.dist + + + cypress-tests: + needs: setup + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v4 + +# GET CACHED DIRECTORIES ---------------- + - name: Download Vendor Directory + uses: actions/download-artifact@v4 + with: + name: vendor-dir + path: vendor/ + +# INSTALL DEPENDENCIES ---------------- - name: Install MySQL Client run: sudo apt-get update && sudo apt-get install -y mysql-client - # https://github.com/shivammathur/setup-php (community) + - name: Install Cypress dependencies + run: sudo apt-get install -y xvfb libgtk2.0-0 libgtk-3-0 libgbm-dev libnotify-dev libnss3 libxss1 libasound2 libxtst6 xauth + - name: Setup PHP, extensions and composer with shivammathur/setup-php uses: shivammathur/setup-php@verbose with: @@ -46,33 +188,62 @@ jobs: tools: composer:2.2 extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json - # Composer - - name: Get composer cache directory - id: composer-cache - run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_ENV + - name: Setup Node.js + uses: actions/setup-node@v4 + with: + node-version: '20.11.0' - - name: Cache composer dependencies - uses: actions/cache@v3 + - name: Install Symfony CLI globally + run: | + curl -sS https://get.symfony.com/cli/installer | bash + sudo mv /home/runner/.symfony5/bin/symfony /usr/local/bin/symfony + +# SET ENVIRONMENT VARIABLES ---------------- + - name: Set up test environment variables + run: cp .env.test .env + +# START SERVICES ---------------- + - name: Set up MySQL + uses: getong/mariadb-action@v1.1 with: - path: | - ${{ env.dir }} - ./vendor - key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} - restore-keys: ${{ runner.os }}-composer- + host port: 3306 # Optional, default value is 3306. The port of host + container port: 3306 # Optional, default value is 3306. The port of container + character set server: 'utf8mb4' # Optional, default value is 'utf8mb4'. The '--character-set-server' option for mysqld + collation server: 'utf8mb4_general_ci' # Optional, default value is 'utf8mb4_general_ci'. The '--collation-server' option for mysqld + mariadb version: '10.4.10' # Optional, default value is "latest". The version of the MySQL + mysql database: 'symfony' # Optional, default value is "test". The specified database which will be created + mysql root password: 'secret' # Required if "mysql user" is empty, default is empty. The root superuser password + mysql user: 'user' # Required if "mysql root password" is empty, default is empty. The superuser for the specified database. Can use secrets, too + mysql password: 'password' # Required if "mysql user" exists. The password for the "mysql user" - - name: Install Composer dependencies - run: composer install --no-progress --prefer-dist --optimize-autoloader + - name: Wait for MySQL to become available + run: | + until mysql -h 127.0.0.1 -u root -psecret -e "SELECT 1"; do + echo 'Waiting for MySQL...' + sleep 1 + done - # PHPStan finds bugs in your code without writing tests - # https://github.com/phpstan/phpstan - - name: Run PHPStan code scan - run: vendor/bin/phpstan analyse src + - name: Start Symfony server + run: symfony server:start --no-tls -d --port=8000 - # Create database +# RUN MIGRATIONS ---------------- - name: Run migrations - run: php bin/console doctrine:migrations:migrate --no-interaction --env=test + run: php bin/console doctrine:migrations:migrate --no-interaction - # Tests - - name: Run unit and functional tests - run: | - php ./vendor/bin/phpunit --configuration phpunit.xml.dist +# FILL DATABASE ---------------- + - name: Run fixture + run: php bin/console doctrine:fixtures:load --no-interaction + +# BUILD FRONT ---------------- + - name : install packages + run: npm install + + - name: Enable verbose npm logging + run: npm config set loglevel verbose + + - name: Build front-end assets + run: ./node_modules/.bin/encore production --progress + +# RUN CYPRESS TESTS ---------------- + - name: Run Cypress tests + run: npm run cy:test:main \ No newline at end of file diff --git a/config/packages/test/doctrine.yaml b/config/packages/test/doctrine.yaml deleted file mode 100644 index 6dbee844d..000000000 --- a/config/packages/test/doctrine.yaml +++ /dev/null @@ -1,3 +0,0 @@ -doctrine: - dbal: - host: '%env(DATABASE_TEST_HOST)%' \ No newline at end of file diff --git a/config/packages/test/framework.yaml b/config/packages/test/framework.yaml index 2ee7eb4a7..5094c6d28 100644 --- a/config/packages/test/framework.yaml +++ b/config/packages/test/framework.yaml @@ -1,2 +1,4 @@ framework: test: true + session: + cookie_domain: "localhost" diff --git a/config/packages/test/monolog.yaml b/config/packages/test/monolog.yaml index 82548da1e..71cd1ed26 100644 --- a/config/packages/test/monolog.yaml +++ b/config/packages/test/monolog.yaml @@ -5,16 +5,16 @@ monolog: path: '%kernel.logs_dir%/%kernel.environment%.log' level: debug channels: ['!event'] - mattermost: - type: slackwebhook - webhook_url: "%logging.mattermost.url%" - channel: '%logging.mattermost.channel%' - bot_name: 'Monolog' - use_attachment: true, - icon_emoji: '' - use_short_attachment: true - include_extra: true - level: '%logging.mattermost.level%' +# mattermost: +# type: slackwebhook +# webhook_url: "%logging.mattermost.url%" +# channel: '%logging.mattermost.channel%' +# bot_name: 'Monolog' +# use_attachment: true, +# icon_emoji: '' +# use_short_attachment: true +# include_extra: true +# level: '%logging.mattermost.level%' console: type: console process_psr_3_messages: false diff --git a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js index 7f526f03d..a7a5ab867 100644 --- a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js +++ b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js @@ -23,7 +23,7 @@ describe('admin1 can login', function () { cy.get('[data-cy=open_my_informations]').click() cy.log('check if role_admin in the page') - cy.get('[data-cy=user_roles_container]').contains('role_admin') + cy.get('[data-cy=user_roles_container]').contains('ROLE_ADMIN', {timeout: 2000}) }) }) diff --git a/cypress/e2e/login/super_admin/super_admin_can_login.cy.js b/cypress/e2e/login/super_admin/super_admin_can_login.cy.js index 6b8ec0c5b..fa3b84f90 100644 --- a/cypress/e2e/login/super_admin/super_admin_can_login.cy.js +++ b/cypress/e2e/login/super_admin/super_admin_can_login.cy.js @@ -19,7 +19,7 @@ describe('super admin can login', function () { cy.get('[data-cy=open_my_informations]').click() cy.log('check if role_admin in the page') - cy.get('[data-cy=user_roles_container]').contains('role_super_admin') + cy.get('[data-cy=user_roles_container]').contains('ROLE_SUPER_ADMIN', {timeout: 2000}) }) diff --git a/package.json b/package.json index e07b088b8..3e4d840c4 100644 --- a/package.json +++ b/package.json @@ -32,9 +32,10 @@ "dev-server": "encore dev-server --disable-host-check", "dev": "encore dev", "watch": "encore dev --watch", - "build": "encore production --progress", - "cy:run:oidc": "cypress run --env configFile=oidc --spec 'cypress/e2e/oidc/*'", - "cy:run:cookie": "cypress run --env configFile=test --spec 'cypress/e2e/cookie/*'" + "build": "npx encore production --progress", + "cy:open": "cypress open", + "cy:test:oidc": "CYPRESS_BASE_URL=http://127.0.0.1:8000 cypress run --spec 'cypress/e2e/oidc/*'", + "cy:test:main": "CYPRESS_BASE_URL=http://localhost:8000 cypress run --spec 'cypress/e2e/login/**/*'" }, "repository": { "type": "git", From 117db0b0ce4e57798c8c005301c95e96a84c8a42 Mon Sep 17 00:00:00 2001 From: sam Date: Sun, 18 Feb 2024 19:27:01 +0100 Subject: [PATCH 06/19] add keycloak test in ci --- .../config/realm-export.localhost.json | 2610 +++++++++++++++++ .env.oidc | 227 -- .env.oidc.test | 10 +- .env.test | 2 +- .github/workflows/ci.yaml | 40 +- cypress.config.js | 3 + .../e2e/keycloak/admin/admin1_can_login.cy.js | 6 +- .../keycloak/keycloak_reusables.cytools.js | 10 +- package.json | 4 +- 9 files changed, 2670 insertions(+), 242 deletions(-) create mode 100644 .docker/keycloak/config/realm-export.localhost.json delete mode 100644 .env.oidc diff --git a/.docker/keycloak/config/realm-export.localhost.json b/.docker/keycloak/config/realm-export.localhost.json new file mode 100644 index 000000000..0cb23baa3 --- /dev/null +++ b/.docker/keycloak/config/realm-export.localhost.json @@ -0,0 +1,2610 @@ +{ + "id": "elefan", + "realm": "elefan", + "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": 600, + "enabled": true, + "sslRequired": "external", + "registrationAllowed": false, + "registrationEmailAsUsername": false, + "rememberMe": false, + "verifyEmail": false, + "loginWithEmailAllowed": true, + "duplicateEmailsAllowed": false, + "resetPasswordAllowed": false, + "editUsernameAllowed": false, + "bruteForceProtected": false, + "permanentLockout": false, + "maxFailureWaitSeconds": 900, + "minimumQuickLoginWaitSeconds": 60, + "waitIncrementSeconds": 60, + "quickLoginCheckMilliSeconds": 1000, + "maxDeltaTimeSeconds": 43200, + "failureFactor": 30, + "roles": { + "realm": [ + { + "id": "7941610d-25c2-49fb-8e20-486785db4b93", + "name": "uma_authorization", + "description": "${role_uma_authorization}", + "composite": false, + "clientRole": false, + "containerId": "master", + "attributes": {} + }, + { + "id": "87098cab-8164-44e6-8094-6fb37f827929", + "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": "master", + "attributes": {} + }, + { + "id": "77c165b0-0343-4b67-ad26-c874381973cf", + "name": "admin", + "description": "${role_admin}", + "composite": true, + "composites": { + "realm": [ + "create-realm" + ], + "client": { + "master-realm": [ + "view-realm", + "query-users", + "manage-events", + "create-client", + "manage-authorization", + "view-authorization", + "view-identity-providers", + "view-clients", + "manage-realm", + "query-clients", + "view-events", + "query-groups", + "query-realms", + "manage-clients", + "view-users", + "manage-identity-providers", + "impersonation", + "manage-users" + ] + } + }, + "clientRole": false, + "containerId": "master", + "attributes": {} + }, + { + "id": "eb44483b-0a72-473d-9bd1-267a50f41867", + "name": "create-realm", + "description": "${role_create-realm}", + "composite": false, + "clientRole": false, + "containerId": "master", + "attributes": {} + }, + { + "id": "6814f985-45b1-46e8-8bfb-89ac33c804af", + "name": "offline_access", + "description": "${role_offline-access}", + "composite": false, + "clientRole": false, + "containerId": "master", + "attributes": {} + } + ], + "client": { + "security-admin-console": [], + "admin-cli": [], + "account-console": [], + "broker": [ + { + "id": "5acb761f-b76f-4612-8bd4-f557d2859805", + "name": "read-token", + "description": "${role_read-token}", + "composite": false, + "clientRole": true, + "containerId": "5f0f1b3e-fd08-4508-8e72-7e6f0e1016e5", + "attributes": {} + } + ], + "master-realm": [ + { + "id": "0fd2c359-8ffe-4e3e-a952-a58df7d75f39", + "name": "view-realm", + "description": "${role_view-realm}", + "composite": false, + "clientRole": true, + "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", + "attributes": {} + }, + { + "id": "09d3e063-0393-4adf-bea8-b1491d457c11", + "name": "query-users", + "description": "${role_query-users}", + "composite": false, + "clientRole": true, + "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", + "attributes": {} + }, + { + "id": "fe78105a-2c1b-4597-b45e-1d05032a78c6", + "name": "manage-events", + "description": "${role_manage-events}", + "composite": false, + "clientRole": true, + "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", + "attributes": {} + }, + { + "id": "1a8f121a-52b4-4a13-95f6-b17b3725d148", + "name": "create-client", + "description": "${role_create-client}", + "composite": false, + "clientRole": true, + "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", + "attributes": {} + }, + { + "id": "55b29443-d838-4371-8186-958a7915feea", + "name": "manage-authorization", + "description": "${role_manage-authorization}", + "composite": false, + "clientRole": true, + "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", + "attributes": {} + }, + { + "id": "84c5bb90-5a1b-42b1-be76-baf1a1b897d9", + "name": "view-authorization", + "description": "${role_view-authorization}", + "composite": false, + "clientRole": true, + "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", + "attributes": {} + }, + { + "id": "4895a90a-1732-4eb0-a7d1-c9df062d88a7", + "name": "view-clients", + "description": "${role_view-clients}", + "composite": true, + "composites": { + "client": { + "master-realm": [ + "query-clients" + ] + } + }, + "clientRole": true, + "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", + "attributes": {} + }, + { + "id": "31aa071e-8048-4160-b24a-a2555f5f0316", + "name": "view-identity-providers", + "description": "${role_view-identity-providers}", + "composite": false, + "clientRole": true, + "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", + "attributes": {} + }, + { + "id": "4c38f8e3-1945-4578-8979-ba034018682d", + "name": "manage-realm", + "description": "${role_manage-realm}", + "composite": false, + "clientRole": true, + "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", + "attributes": {} + }, + { + "id": "ac26d491-af04-484a-a9b8-7a2633d9f55f", + "name": "query-clients", + "description": "${role_query-clients}", + "composite": false, + "clientRole": true, + "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", + "attributes": {} + }, + { + "id": "95db5be0-e8e7-46d8-9764-eac24ccab670", + "name": "query-groups", + "description": "${role_query-groups}", + "composite": false, + "clientRole": true, + "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", + "attributes": {} + }, + { + "id": "50fbc31a-5854-46e6-a562-70deb80b836f", + "name": "view-events", + "description": "${role_view-events}", + "composite": false, + "clientRole": true, + "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", + "attributes": {} + }, + { + "id": "2c3409f0-99a0-47ff-aec1-51959ba259d6", + "name": "query-realms", + "description": "${role_query-realms}", + "composite": false, + "clientRole": true, + "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", + "attributes": {} + }, + { + "id": "6a7a60a5-a5f7-437b-991d-283c1e63317b", + "name": "manage-clients", + "description": "${role_manage-clients}", + "composite": false, + "clientRole": true, + "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", + "attributes": {} + }, + { + "id": "9a6276bc-9291-4b55-a1ad-3c2dd8436428", + "name": "view-users", + "description": "${role_view-users}", + "composite": true, + "composites": { + "client": { + "master-realm": [ + "query-groups", + "query-users" + ] + } + }, + "clientRole": true, + "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", + "attributes": {} + }, + { + "id": "4ad38cc2-847f-457f-8940-782e9545d3fa", + "name": "manage-identity-providers", + "description": "${role_manage-identity-providers}", + "composite": false, + "clientRole": true, + "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", + "attributes": {} + }, + { + "id": "01bdc0c6-c4d7-48a7-b076-2ba7815ba3a8", + "name": "impersonation", + "description": "${role_impersonation}", + "composite": false, + "clientRole": true, + "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", + "attributes": {} + }, + { + "id": "4d34c1f6-732d-416b-bdf0-b9d20d4b46ac", + "name": "manage-users", + "description": "${role_manage-users}", + "composite": false, + "clientRole": true, + "containerId": "4730ccdf-efe7-4173-b495-ac95da51a474", + "attributes": {} + } + ], + "account": [ + { + "id": "87d670ff-4058-496c-afae-7bf3e98f121a", + "name": "manage-consent", + "description": "${role_manage-consent}", + "composite": true, + "composites": { + "client": { + "account": [ + "view-consent" + ] + } + }, + "clientRole": true, + "containerId": "a61bd6c8-faaa-4fbd-8752-09f14115d521", + "attributes": {} + }, + { + "id": "1a76fcf3-f713-43f5-95bb-8899e2b3a727", + "name": "view-consent", + "description": "${role_view-consent}", + "composite": false, + "clientRole": true, + "containerId": "a61bd6c8-faaa-4fbd-8752-09f14115d521", + "attributes": {} + }, + { + "id": "3e2f441a-d466-4348-83ef-8acb8d6f116d", + "name": "delete-account", + "description": "${role_delete-account}", + "composite": false, + "clientRole": true, + "containerId": "a61bd6c8-faaa-4fbd-8752-09f14115d521", + "attributes": {} + }, + { + "id": "402bb844-10be-458a-9e58-0b5a41295e7e", + "name": "manage-account-links", + "description": "${role_manage-account-links}", + "composite": false, + "clientRole": true, + "containerId": "a61bd6c8-faaa-4fbd-8752-09f14115d521", + "attributes": {} + }, + { + "id": "3ade3216-f686-4f72-b6d7-96d4eb59117b", + "name": "view-applications", + "description": "${role_view-applications}", + "composite": false, + "clientRole": true, + "containerId": "a61bd6c8-faaa-4fbd-8752-09f14115d521", + "attributes": {} + }, + { + "id": "fabd291e-7074-486e-ad25-98dd8b5e3449", + "name": "manage-account", + "description": "${role_manage-account}", + "composite": true, + "composites": { + "client": { + "account": [ + "manage-account-links" + ] + } + }, + "clientRole": true, + "containerId": "a61bd6c8-faaa-4fbd-8752-09f14115d521", + "attributes": {} + }, + { + "id": "83d0b65c-66c4-4b70-aaef-4324e36a863a", + "name": "view-profile", + "description": "${role_view-profile}", + "composite": false, + "clientRole": true, + "containerId": "a61bd6c8-faaa-4fbd-8752-09f14115d521", + "attributes": {} + } + ], + "elefan": [] + } + }, + "defaultRole": { + "id": "87098cab-8164-44e6-8094-6fb37f827929", + "name": "default-roles-master", + "description": "${role_default-roles}", + "composite": true, + "clientRole": false, + "containerId": "master" + }, + "requiredCredentials": [ + "password" + ], + "otpPolicyType": "totp", + "otpPolicyAlgorithm": "HmacSHA1", + "otpPolicyInitialCounter": 0, + "otpPolicyDigits": 6, + "otpPolicyLookAheadWindow": 1, + "otpPolicyPeriod": 30, + "otpSupportedApplications": [ + "FreeOTP", + "Google Authenticator" + ], + "webAuthnPolicyRpEntityName": "keycloak", + "webAuthnPolicySignatureAlgorithms": [ + "ES256" + ], + "webAuthnPolicyRpId": "", + "webAuthnPolicyAttestationConveyancePreference": "not specified", + "webAuthnPolicyAuthenticatorAttachment": "not specified", + "webAuthnPolicyRequireResidentKey": "not specified", + "webAuthnPolicyUserVerificationRequirement": "not specified", + "webAuthnPolicyCreateTimeout": 0, + "webAuthnPolicyAvoidSameAuthenticatorRegister": false, + "webAuthnPolicyAcceptableAaguids": [], + "webAuthnPolicyPasswordlessRpEntityName": "keycloak", + "webAuthnPolicyPasswordlessSignatureAlgorithms": [ + "ES256" + ], + "webAuthnPolicyPasswordlessRpId": "", + "webAuthnPolicyPasswordlessAttestationConveyancePreference": "not specified", + "webAuthnPolicyPasswordlessAuthenticatorAttachment": "not specified", + "webAuthnPolicyPasswordlessRequireResidentKey": "not specified", + "webAuthnPolicyPasswordlessUserVerificationRequirement": "not specified", + "webAuthnPolicyPasswordlessCreateTimeout": 0, + "webAuthnPolicyPasswordlessAvoidSameAuthenticatorRegister": false, + "webAuthnPolicyPasswordlessAcceptableAaguids": [], + "scopeMappings": [ + { + "clientScope": "offline_access", + "roles": [ + "offline_access" + ] + } + ], + "clientScopeMappings": { + "account": [ + { + "client": "account-console", + "roles": [ + "manage-account" + ] + } + ] + }, + "clients": [ + { + "id": "a61bd6c8-faaa-4fbd-8752-09f14115d521", + "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": {}, + "authenticationFlowBindingOverrides": {}, + "fullScopeAllowed": false, + "nodeReRegistrationTimeout": 0, + "defaultClientScopes": [ + "web-origins", + "profile", + "roles", + "email" + ], + "optionalClientScopes": [ + "address", + "phone", + "offline_access", + "microprofile-jwt" + ] + }, + { + "id": "af2c05db-5d5d-4b62-8f25-d276fc718d81", + "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": { + "pkce.code.challenge.method": "S256" + }, + "authenticationFlowBindingOverrides": {}, + "fullScopeAllowed": false, + "nodeReRegistrationTimeout": 0, + "protocolMappers": [ + { + "id": "ddfb2545-8d24-40b4-acf5-a2fd55a296a1", + "name": "audience resolve", + "protocol": "openid-connect", + "protocolMapper": "oidc-audience-resolve-mapper", + "consentRequired": false, + "config": {} + } + ], + "defaultClientScopes": [ + "web-origins", + "profile", + "roles", + "email" + ], + "optionalClientScopes": [ + "address", + "phone", + "offline_access", + "microprofile-jwt" + ] + }, + { + "id": "dcfbb83b-428a-4f78-a155-afc940754033", + "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": {}, + "authenticationFlowBindingOverrides": {}, + "fullScopeAllowed": false, + "nodeReRegistrationTimeout": 0, + "defaultClientScopes": [ + "web-origins", + "profile", + "roles", + "email" + ], + "optionalClientScopes": [ + "address", + "phone", + "offline_access", + "microprofile-jwt" + ] + }, + { + "id": "5f0f1b3e-fd08-4508-8e72-7e6f0e1016e5", + "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": {}, + "authenticationFlowBindingOverrides": {}, + "fullScopeAllowed": false, + "nodeReRegistrationTimeout": 0, + "defaultClientScopes": [ + "web-origins", + "profile", + "roles", + "email" + ], + "optionalClientScopes": [ + "address", + "phone", + "offline_access", + "microprofile-jwt" + ] + }, + { + "clientId": "elefan", + "name": "membres.yourcoop.local", + "secret": "secret", + "description": "membres.yourcoop.local", + "rootUrl": "", + "adminUrl": "http://localhost:8000/", + "baseUrl": "http://localhost:8000/", + "surrogateAuthRequired": false, + "enabled": true, + "alwaysDisplayInConsole": false, + "clientAuthenticatorType": "client-secret", + "redirectUris": [ + "http://localhost:8000/*" + ], + "webOrigins": [ + "http://localhost:8000/" + ], + "notBefore": 0, + "bearerOnly": false, + "consentRequired": true, + "standardFlowEnabled": true, + "implicitFlowEnabled": true, + "directAccessGrantsEnabled": true, + "serviceAccountsEnabled": false, + "publicClient": false, + "frontchannelLogout": false, + "protocol": "openid-connect", + "attributes": { + "access.token.lifespan": "300", + "saml.force.post.binding": "false", + "saml.multivalued.roles": "false", + "oauth2.device.authorization.grant.enabled": "false", + "backchannel.logout.revoke.offline.tokens": "true", + "saml.server.signature.keyinfo.ext": "false", + "use.refresh.tokens": "true", + "oidc.ciba.grant.enabled": "false", + "backchannel.logout.session.required": "true", + "backchannel.logout.url": "http://localhost:8000/logout", + "client_credentials.use_refresh_token": "false", + "require.pushed.authorization.requests": "false", + "saml.client.signature": "false", + "id.token.as.detached.signature": "false", + "saml.assertion.signature": "false", + "saml.encrypt": "false", + "login_theme": "keycloak", + "saml.server.signature": "false", + "exclude.session.state.from.auth.response": "false", + "saml.artifact.binding": "false", + "saml_force_name_id_format": "false", + "tls.client.certificate.bound.access.tokens": "false", + "saml.authnstatement": "false", + "display.on.consent.screen": "true", + "saml.onetimeuse.condition": "false" + }, + "authenticationFlowBindingOverrides": {}, + "fullScopeAllowed": true, + "nodeReRegistrationTimeout": -1, + "protocolMappers": [ + { + "name": "address_city", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "address.city", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "address_city", + "jsonType.label": "String" + } + }, + { + "name": "flying", + "protocol": "openid-connect", + "protocolMapper": "oidc-hardcoded-claim-mapper", + "consentRequired": false, + "config": { + "claim.value": "false", + "userinfo.token.claim": "true", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "flying", + "jsonType.label": "boolean", + "access.tokenResponse.claim": "false" + } + }, + { + "name": "email", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-property-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "email", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "email", + "jsonType.label": "String" + } + }, + { + "name": "lastName", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-property-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "lastName", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "lastName", + "jsonType.label": "String" + } + }, + { + "name": "address_street1", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "address.street1", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "address_street1", + "jsonType.label": "String" + } + }, + { + "name": "co_member_number", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "co_member_number", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "co_member_number", + "jsonType.label": "String" + } + }, + { + "name": "firstName", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-property-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "firstName", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "firstName", + "jsonType.label": "String" + } + }, + { + "name": "address_street2", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "address.street2", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "address_street2", + "jsonType.label": "String" + } + }, + { + "name": "groups", + "protocol": "openid-connect", + "protocolMapper": "oidc-group-membership-mapper", + "consentRequired": false, + "config": { + "full.path": "true", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "groups", + "userinfo.token.claim": "true" + } + }, + { + "name": "phone", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "phone", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "phone", + "jsonType.label": "String" + } + }, + { + "name": "address_zipcode", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "address.zipcode", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "address_zipcode", + "jsonType.label": "String" + } + }, + { + "name": "member_number", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "member_number", + "id.token.claim": "false", + "access.token.claim": "false", + "claim.name": "member_number", + "jsonType.label": "String" + } + } + ], + "defaultClientScopes": [ + "profile", + "roles", + "groups", + "email" + ], + "optionalClientScopes": [ + "address", + "phone", + "offline_access", + "microprofile-jwt" + ], + "access": { + "view": true, + "configure": true, + "manage": true + } + }, + { + "id": "4730ccdf-efe7-4173-b495-ac95da51a474", + "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": {}, + "authenticationFlowBindingOverrides": {}, + "fullScopeAllowed": false, + "nodeReRegistrationTimeout": 0, + "defaultClientScopes": [ + "web-origins", + "profile", + "roles", + "email" + ], + "optionalClientScopes": [ + "address", + "phone", + "offline_access", + "microprofile-jwt" + ] + }, + { + "id": "f26b120b-dcfb-4d49-ad84-c4944398ab2e", + "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": { + "pkce.code.challenge.method": "S256" + }, + "authenticationFlowBindingOverrides": {}, + "fullScopeAllowed": false, + "nodeReRegistrationTimeout": 0, + "protocolMappers": [ + { + "id": "e62f462c-3199-4bb1-b1a2-7230c7341118", + "name": "locale", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "locale", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "locale", + "jsonType.label": "String" + } + } + ], + "defaultClientScopes": [ + "web-origins", + "profile", + "roles", + "email" + ], + "optionalClientScopes": [ + "address", + "phone", + "offline_access", + "microprofile-jwt" + ] + } + ], + "clientScopes": [ + { + "id": "d1d587be-4f3c-4818-b851-8b300e7c20bc", + "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", + "display.on.consent.screen": "false", + "consent.screen.text": "" + }, + "protocolMappers": [ + { + "id": "d52198b9-3700-48d0-b4ec-a67eb8530a51", + "name": "allowed web origins", + "protocol": "openid-connect", + "protocolMapper": "oidc-allowed-origins-mapper", + "consentRequired": false, + "config": {} + } + ] + }, + { + "id": "bd698edc-7366-4c39-9218-181f2a03473d", + "name": "email", + "description": "OpenID Connect built-in scope: email", + "protocol": "openid-connect", + "attributes": { + "include.in.token.scope": "true", + "display.on.consent.screen": "true", + "consent.screen.text": "${emailScopeConsentText}" + }, + "protocolMappers": [ + { + "id": "4dc063b3-b42a-4033-9911-f9aeb070d53b", + "name": "email verified", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-property-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "emailVerified", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "email_verified", + "jsonType.label": "boolean" + } + }, + { + "id": "4fe784e3-5b2d-48d4-860b-2041adcc5029", + "name": "email", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-property-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "email", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "email", + "jsonType.label": "String" + } + } + ] + }, + { + "id": "f34509c6-1b30-4bce-bdcc-9e51330889aa", + "name": "profile", + "description": "OpenID Connect built-in scope: profile", + "protocol": "openid-connect", + "attributes": { + "include.in.token.scope": "true", + "display.on.consent.screen": "true", + "consent.screen.text": "${profileScopeConsentText}" + }, + "protocolMappers": [ + { + "id": "f38ecc21-5776-43f4-af5d-1896425a17a8", + "name": "username", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-property-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "username", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "preferred_username", + "jsonType.label": "String" + } + }, + { + "id": "b8a7a437-15f2-44dd-a3b1-433727ff3705", + "name": "gender", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "gender", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "gender", + "jsonType.label": "String" + } + }, + { + "id": "ac1fea4e-52a1-4888-95e8-efbe59f093c1", + "name": "birthdate", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "birthdate", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "birthdate", + "jsonType.label": "String" + } + }, + { + "id": "e6258de1-bdb0-4422-9202-a571f23e409a", + "name": "picture", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "picture", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "picture", + "jsonType.label": "String" + } + }, + { + "id": "538bb3d9-9602-4d8d-b243-2f0e1f2402fc", + "name": "middle name", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "middleName", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "middle_name", + "jsonType.label": "String" + } + }, + { + "id": "2a982137-e525-46e6-abca-659186bb87fb", + "name": "locale", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "locale", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "locale", + "jsonType.label": "String" + } + }, + { + "id": "d536c945-ca64-422f-aa93-0c26f2b727d1", + "name": "website", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "website", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "website", + "jsonType.label": "String" + } + }, + { + "id": "14b1b459-1bd7-493b-a80b-e426c36a6b78", + "name": "updated at", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "updatedAt", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "updated_at", + "jsonType.label": "String" + } + }, + { + "id": "9a941be0-2a3f-4aa0-b962-6c63fc0b2ff8", + "name": "family name", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-property-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "lastName", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "family_name", + "jsonType.label": "String" + } + }, + { + "id": "edfb6c4d-722c-4c52-8d24-12a47c60e9bd", + "name": "given name", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-property-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "firstName", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "given_name", + "jsonType.label": "String" + } + }, + { + "id": "efc86270-a3ae-4a64-9425-38f7a2e43ad0", + "name": "nickname", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "nickname", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "nickname", + "jsonType.label": "String" + } + }, + { + "id": "9b7d13f9-5d2f-428d-b334-eb4e0a54b0e1", + "name": "profile", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "profile", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "profile", + "jsonType.label": "String" + } + }, + { + "id": "f6b9a7e1-cad5-4fcb-84c9-0ffb5eb5bd1b", + "name": "zoneinfo", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "zoneinfo", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "zoneinfo", + "jsonType.label": "String" + } + }, + { + "id": "d607cc9a-5029-46f5-b0e7-f58ed6126532", + "name": "full name", + "protocol": "openid-connect", + "protocolMapper": "oidc-full-name-mapper", + "consentRequired": false, + "config": { + "id.token.claim": "true", + "access.token.claim": "true", + "userinfo.token.claim": "true" + } + } + ] + }, + { + "id": "bc1a75cc-bc76-4c5d-99d2-b231ea5d0f5f", + "name": "address", + "description": "OpenID Connect built-in scope: address", + "protocol": "openid-connect", + "attributes": { + "include.in.token.scope": "true", + "display.on.consent.screen": "true", + "consent.screen.text": "${addressScopeConsentText}" + }, + "protocolMappers": [ + { + "id": "26a2831c-d0e0-4a0f-96b2-d2d336eaaef5", + "name": "address", + "protocol": "openid-connect", + "protocolMapper": "oidc-address-mapper", + "consentRequired": false, + "config": { + "user.attribute.formatted": "formatted", + "user.attribute.country": "country", + "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": "5d7d24e3-8a14-4a3a-a44e-78edb78e861f", + "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": "f31c28ac-a88a-490d-885e-7d9c0fd7b022", + "name": "upn", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-property-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "username", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "upn", + "jsonType.label": "String" + } + }, + { + "id": "323e0230-0924-4113-89e9-3838cd74c75a", + "name": "groups", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-realm-role-mapper", + "consentRequired": false, + "config": { + "multivalued": "true", + "user.attribute": "foo", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "groups", + "jsonType.label": "String" + } + } + ] + }, + { + "id": "f28b9300-e4e5-45df-ba34-e41d22133786", + "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": "dc682314-0ba1-40a2-8349-5fdee9356fc3", + "name": "phone", + "description": "OpenID Connect built-in scope: phone", + "protocol": "openid-connect", + "attributes": { + "include.in.token.scope": "true", + "display.on.consent.screen": "true", + "consent.screen.text": "${phoneScopeConsentText}" + }, + "protocolMappers": [ + { + "id": "db6e6be6-cb06-4f3b-89ee-d322e86885e9", + "name": "phone number", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "phoneNumber", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "phone_number", + "jsonType.label": "String" + } + }, + { + "id": "d2b2879b-4db1-47d9-a5be-1ee9580e7ad5", + "name": "phone number verified", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-attribute-mapper", + "consentRequired": false, + "config": { + "userinfo.token.claim": "true", + "user.attribute": "phoneNumberVerified", + "id.token.claim": "true", + "access.token.claim": "true", + "claim.name": "phone_number_verified", + "jsonType.label": "boolean" + } + } + ] + }, + { + "id": "85069ac7-9bd7-400c-9041-0b0ef30d33f1", + "name": "roles", + "description": "OpenID Connect scope for add user roles to the access token", + "protocol": "openid-connect", + "attributes": { + "include.in.token.scope": "false", + "display.on.consent.screen": "true", + "consent.screen.text": "${rolesScopeConsentText}" + }, + "protocolMappers": [ + { + "id": "65914269-6d64-4644-acd7-e71caab56f5d", + "name": "audience resolve", + "protocol": "openid-connect", + "protocolMapper": "oidc-audience-resolve-mapper", + "consentRequired": false, + "config": {} + }, + { + "id": "01dac415-fcef-4816-8af7-227dc23b36ce", + "name": "realm roles", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-realm-role-mapper", + "consentRequired": false, + "config": { + "user.attribute": "foo", + "access.token.claim": "true", + "claim.name": "realm_access.roles", + "jsonType.label": "String", + "multivalued": "true" + } + }, + { + "id": "e37babb7-6a34-4230-ab7f-07f108bace5a", + "name": "client roles", + "protocol": "openid-connect", + "protocolMapper": "oidc-usermodel-client-role-mapper", + "consentRequired": false, + "config": { + "user.attribute": "foo", + "access.token.claim": "true", + "claim.name": "resource_access.${client_id}.roles", + "jsonType.label": "String", + "multivalued": "true" + } + } + ] + }, + { + "id": "96347b38-f073-4cdc-be4a-eb90c8b03554", + "name": "role_list", + "description": "SAML role list", + "protocol": "saml", + "attributes": { + "consent.screen.text": "${samlRoleListScopeConsentText}", + "display.on.consent.screen": "true" + }, + "protocolMappers": [ + { + "id": "6bca928a-4514-48e1-8a03-c69d88347fbf", + "name": "role list", + "protocol": "saml", + "protocolMapper": "saml-role-list-mapper", + "consentRequired": false, + "config": { + "single": "false", + "attribute.nameformat": "Basic", + "attribute.name": "Role" + } + } + ] + } + ], + "defaultDefaultClientScopes": [ + "role_list", + "profile", + "email", + "roles", + "web-origins" + ], + "defaultOptionalClientScopes": [ + "offline_access", + "address", + "phone", + "microprofile-jwt" + ], + "browserSecurityHeaders": { + "contentSecurityPolicyReportOnly": "", + "xContentTypeOptions": "nosniff", + "xRobotsTag": "none", + "xFrameOptions": "SAMEORIGIN", + "xXSSProtection": "1; mode=block", + "contentSecurityPolicy": "frame-src 'self'; frame-ancestors 'self'; object-src 'none';", + "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": "49b0604e-498a-4018-bece-101bfe682873", + "name": "Allowed Client Scopes", + "providerId": "allowed-client-templates", + "subType": "anonymous", + "subComponents": {}, + "config": { + "allow-default-scopes": [ + "true" + ] + } + }, + { + "id": "929f2e40-6989-4e32-8a3f-689fc7af7fd6", + "name": "Consent Required", + "providerId": "consent-required", + "subType": "anonymous", + "subComponents": {}, + "config": {} + }, + { + "id": "b2f7f88a-cf56-4bcd-8555-3e7737faddc9", + "name": "Max Clients Limit", + "providerId": "max-clients", + "subType": "anonymous", + "subComponents": {}, + "config": { + "max-clients": [ + "200" + ] + } + }, + { + "id": "6655930a-0cf4-4b60-bc14-40ba36d1139b", + "name": "Allowed Protocol Mapper Types", + "providerId": "allowed-protocol-mappers", + "subType": "anonymous", + "subComponents": {}, + "config": { + "allowed-protocol-mapper-types": [ + "oidc-usermodel-property-mapper", + "oidc-full-name-mapper", + "saml-user-property-mapper", + "oidc-usermodel-attribute-mapper", + "saml-user-attribute-mapper", + "saml-role-list-mapper", + "oidc-address-mapper", + "oidc-sha256-pairwise-sub-mapper" + ] + } + }, + { + "id": "cbb366f3-0574-43fa-919a-1624a8e0b552", + "name": "Allowed Protocol Mapper Types", + "providerId": "allowed-protocol-mappers", + "subType": "authenticated", + "subComponents": {}, + "config": { + "allowed-protocol-mapper-types": [ + "oidc-address-mapper", + "oidc-sha256-pairwise-sub-mapper", + "saml-user-attribute-mapper", + "saml-user-property-mapper", + "oidc-usermodel-property-mapper", + "saml-role-list-mapper", + "oidc-usermodel-attribute-mapper", + "oidc-full-name-mapper" + ] + } + }, + { + "id": "f03cd9e7-a460-4dad-8dc3-358ed47d79b5", + "name": "Trusted Hosts", + "providerId": "trusted-hosts", + "subType": "anonymous", + "subComponents": {}, + "config": { + "host-sending-registration-request-must-match": [ + "true" + ], + "client-uris-must-match": [ + "true" + ] + } + }, + { + "id": "477593a1-0dd5-44bf-b876-045c034d0703", + "name": "Allowed Client Scopes", + "providerId": "allowed-client-templates", + "subType": "authenticated", + "subComponents": {}, + "config": { + "allow-default-scopes": [ + "true" + ] + } + }, + { + "id": "bcd8a353-a195-4e7b-ab4d-1a015bbfacc9", + "name": "Full Scope Disabled", + "providerId": "scope", + "subType": "anonymous", + "subComponents": {}, + "config": {} + } + ], + "org.keycloak.keys.KeyProvider": [ + { + "id": "056c01fc-8886-45e5-91e9-b338ed7c2838", + "name": "rsa-generated", + "providerId": "rsa-generated", + "subComponents": {}, + "config": { + "priority": [ + "100" + ] + } + }, + { + "id": "61a7d918-1c29-42cb-9f76-9120f7c9c2cc", + "name": "aes-generated", + "providerId": "aes-generated", + "subComponents": {}, + "config": { + "priority": [ + "100" + ] + } + }, + { + "id": "54a306bf-5214-44c4-96df-73e8d54dee72", + "name": "rsa-enc-generated", + "providerId": "rsa-enc-generated", + "subComponents": {}, + "config": { + "priority": [ + "100" + ], + "algorithm": [ + "RSA-OAEP" + ] + } + }, + { + "id": "4c76c80b-7fb2-4379-bbe6-2d6758d0d6cc", + "name": "hmac-generated", + "providerId": "hmac-generated", + "subComponents": {}, + "config": { + "priority": [ + "100" + ], + "algorithm": [ + "HS256" + ] + } + } + ] + }, + "internationalizationEnabled": false, + "supportedLocales": [], + "authenticationFlows": [ + { + "id": "5764d6a6-9ab9-49c0-b0d1-4a3b6bf91a79", + "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, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticatorFlow": true, + "requirement": "ALTERNATIVE", + "priority": 20, + "flowAlias": "Verify Existing Account by Re-authentication", + "userSetupAllowed": false, + "autheticatorFlow": true + } + ] + }, + { + "id": "d237385d-de20-4d56-9138-1081fbf6920b", + "alias": "Authentication Options", + "description": "Authentication options.", + "providerId": "basic-flow", + "topLevel": false, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "basic-auth", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 10, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticator": "basic-auth-otp", + "authenticatorFlow": false, + "requirement": "DISABLED", + "priority": 20, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticator": "auth-spnego", + "authenticatorFlow": false, + "requirement": "DISABLED", + "priority": 30, + "userSetupAllowed": false, + "autheticatorFlow": false + } + ] + }, + { + "id": "1209281d-d4bf-4b96-acb6-7283c952c86d", + "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, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticator": "auth-otp-form", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 20, + "userSetupAllowed": false, + "autheticatorFlow": false + } + ] + }, + { + "id": "609780f8-c50f-4a96-9827-ef5704aa0f81", + "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, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticator": "direct-grant-validate-otp", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 20, + "userSetupAllowed": false, + "autheticatorFlow": false + } + ] + }, + { + "id": "c570b8b9-e693-432c-96c9-34203e00e601", + "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, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticator": "auth-otp-form", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 20, + "userSetupAllowed": false, + "autheticatorFlow": false + } + ] + }, + { + "id": "ea66ade5-1db4-43db-a88a-7533a4da29ce", + "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, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticatorFlow": true, + "requirement": "REQUIRED", + "priority": 20, + "flowAlias": "Account verification options", + "userSetupAllowed": false, + "autheticatorFlow": true + } + ] + }, + { + "id": "8b88580a-a02e-4367-9a60-0bbf705c9619", + "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, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticator": "reset-otp", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 20, + "userSetupAllowed": false, + "autheticatorFlow": false + } + ] + }, + { + "id": "54d7249d-c82b-4c2e-9908-f6abd3601237", + "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, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticatorFlow": true, + "requirement": "ALTERNATIVE", + "priority": 20, + "flowAlias": "Handle Existing Account", + "userSetupAllowed": false, + "autheticatorFlow": true + } + ] + }, + { + "id": "9ae359e9-8575-4ff9-b8db-84f085cea1b3", + "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, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticatorFlow": true, + "requirement": "CONDITIONAL", + "priority": 20, + "flowAlias": "First broker login - Conditional OTP", + "userSetupAllowed": false, + "autheticatorFlow": true + } + ] + }, + { + "id": "9e8f6123-18af-435f-93be-a137e2bf9774", + "alias": "browser", + "description": "browser based authentication", + "providerId": "basic-flow", + "topLevel": true, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "auth-cookie", + "authenticatorFlow": false, + "requirement": "ALTERNATIVE", + "priority": 10, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticator": "auth-spnego", + "authenticatorFlow": false, + "requirement": "DISABLED", + "priority": 20, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticator": "identity-provider-redirector", + "authenticatorFlow": false, + "requirement": "ALTERNATIVE", + "priority": 25, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticatorFlow": true, + "requirement": "ALTERNATIVE", + "priority": 30, + "flowAlias": "forms", + "userSetupAllowed": false, + "autheticatorFlow": true + } + ] + }, + { + "id": "806d760e-dd1d-478d-bbc3-f2d9d84801d0", + "alias": "clients", + "description": "Base authentication for clients", + "providerId": "client-flow", + "topLevel": true, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "client-secret", + "authenticatorFlow": false, + "requirement": "ALTERNATIVE", + "priority": 10, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticator": "client-jwt", + "authenticatorFlow": false, + "requirement": "ALTERNATIVE", + "priority": 20, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticator": "client-secret-jwt", + "authenticatorFlow": false, + "requirement": "ALTERNATIVE", + "priority": 30, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticator": "client-x509", + "authenticatorFlow": false, + "requirement": "ALTERNATIVE", + "priority": 40, + "userSetupAllowed": false, + "autheticatorFlow": false + } + ] + }, + { + "id": "cdc6d76f-632b-49e8-898d-16856d50a848", + "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, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticator": "direct-grant-validate-password", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 20, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticatorFlow": true, + "requirement": "CONDITIONAL", + "priority": 30, + "flowAlias": "Direct Grant - Conditional OTP", + "userSetupAllowed": false, + "autheticatorFlow": true + } + ] + }, + { + "id": "738ede8d-0a07-433c-958d-a102c42e7363", + "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, + "userSetupAllowed": false, + "autheticatorFlow": false + } + ] + }, + { + "id": "2ac00703-fade-42bd-9e83-fea39906f062", + "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, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticatorFlow": true, + "requirement": "REQUIRED", + "priority": 20, + "flowAlias": "User creation or linking", + "userSetupAllowed": false, + "autheticatorFlow": true + } + ] + }, + { + "id": "36e2bca3-cbd1-4b56-a51b-69887538ee0a", + "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, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticatorFlow": true, + "requirement": "CONDITIONAL", + "priority": 20, + "flowAlias": "Browser - Conditional OTP", + "userSetupAllowed": false, + "autheticatorFlow": true + } + ] + }, + { + "id": "ba2ac86e-154d-4742-b9d8-2fbe5ab2bc16", + "alias": "http challenge", + "description": "An authentication flow based on challenge-response HTTP Authentication Schemes", + "providerId": "basic-flow", + "topLevel": true, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "no-cookie-redirect", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 10, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticatorFlow": true, + "requirement": "REQUIRED", + "priority": 20, + "flowAlias": "Authentication Options", + "userSetupAllowed": false, + "autheticatorFlow": true + } + ] + }, + { + "id": "e25de487-442b-4c96-a9a8-cd5a6a44d1fc", + "alias": "registration", + "description": "registration flow", + "providerId": "basic-flow", + "topLevel": true, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "registration-page-form", + "authenticatorFlow": true, + "requirement": "REQUIRED", + "priority": 10, + "flowAlias": "registration form", + "userSetupAllowed": false, + "autheticatorFlow": true + } + ] + }, + { + "id": "f4334b65-3337-48bd-bbf4-ae56f84314e8", + "alias": "registration form", + "description": "registration form", + "providerId": "form-flow", + "topLevel": false, + "builtIn": true, + "authenticationExecutions": [ + { + "authenticator": "registration-user-creation", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 20, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticator": "registration-profile-action", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 40, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticator": "registration-password-action", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 50, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticator": "registration-recaptcha-action", + "authenticatorFlow": false, + "requirement": "DISABLED", + "priority": 60, + "userSetupAllowed": false, + "autheticatorFlow": false + } + ] + }, + { + "id": "366052fb-7e33-48a1-a721-46567df5f11e", + "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, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticator": "reset-credential-email", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 20, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticator": "reset-password", + "authenticatorFlow": false, + "requirement": "REQUIRED", + "priority": 30, + "userSetupAllowed": false, + "autheticatorFlow": false + }, + { + "authenticatorFlow": true, + "requirement": "CONDITIONAL", + "priority": 40, + "flowAlias": "Reset - Conditional OTP", + "userSetupAllowed": false, + "autheticatorFlow": true + } + ] + }, + { + "id": "3955dfa6-2e46-4fbc-96b7-88999e82a9c1", + "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, + "userSetupAllowed": false, + "autheticatorFlow": false + } + ] + } + ], + "authenticatorConfig": [ + { + "id": "9cd88a5a-351f-431e-a550-5c9846e0addd", + "alias": "create unique user config", + "config": { + "require.password.update.after.registration": "false" + } + }, + { + "id": "4e54c84b-2ff7-481d-b5f5-76aab72140c8", + "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": "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", + "attributes": { + "cibaBackchannelTokenDeliveryMode": "poll", + "cibaExpiresIn": "120", + "cibaAuthRequestedUserHint": "login_hint", + "parRequestUriLifespan": "60", + "cibaInterval": "5" + }, + "keycloakVersion": "16.1.1", + "userManagedAccessAllowed": false, + "clientProfiles": { + "profiles": [] + }, + "clientPolicies": { + "policies": [] + }, + "users": [ + { + "username": "newfromkeycloak", + "enabled": true, + "emailVerified": true, + "firstName": "Jimmy (new keycloak)", + "lastName": "flake", + "email": "newfromkeycloak@mail.com", + "credentials": [ + { + "type": "password", + "hashedSaltedValue": "xjNR06W/ur5nBS8KFTrDgE81vLjb/t4A5LG2ubs/rII=", + "salt": "dyyLTNS/D+Ukspy5xgIa4w==", + "hashIterations": 27500, + "algorithm": "pbkdf2-sha256" + } + ], + "attributes": { + "member_number": ["11111"], + "phone": ["0612345651"], + "flying": [true], + "address.street1": ["123 Main St"], + "address.street2": ["Apt 4"], + "address.zipcode": ["12345"], + "address.city": ["Anytown"], + "co_member_number": ["11111"] + }, + "groups": [ + "/coopérateur" + ] + }, + { + "username": "admin1", + "enabled": true, + "emailVerified": true, + "firstName": "Samuel (admin)", + "lastName": "Smith", + "email": "admin1@email.com", + "credentials": [ + { + "type": "password", + "hashedSaltedValue": "xjNR06W/ur5nBS8KFTrDgE81vLjb/t4A5LG2ubs/rII=", + "salt": "dyyLTNS/D+Ukspy5xgIa4w==", + "hashIterations": 27500, + "algorithm": "pbkdf2-sha256" + } + ], + "attributes": { + "member_number": ["11111"], + "phone": ["0612345651"], + "flying": [true], + "address.street1": ["123 Main St"], + "address.street2": ["Apt 4"], + "address.zipcode": ["12345"], + "address.city": ["Anytown"] + }, + "groups": [ + "/coopérateur", + "/infrastructure/informatique/elefan/admin" + ] + }, + { + "username": "admin2", + "enabled": true, + "emailVerified": true, + "firstName": "Sebastian (admin)", + "lastName": "Johnson", + "email": "admin2@email.com", + "credentials": [ + { + "type": "password", + "hashedSaltedValue": "xjNR06W/ur5nBS8KFTrDgE81vLjb/t4A5LG2ubs/rII=", + "salt": "dyyLTNS/D+Ukspy5xgIa4w==", + "hashIterations": 27500, + "algorithm": "pbkdf2-sha256" + } + ], + "attributes": { + "member_number": ["11112"], + "phone": ["0612345652"], + "flying": [true], + "address.street1": ["123 Main St"], + "address.street2": ["Apt 4"], + "address.zipcode": ["12345"], + "address.city": ["Anytown"] + }, + "groups": [ + "/coopérateur", + "/infrastructure/informatique/elefan/admin" + ] + }, + { + "username": "admin3", + "enabled": true, + "emailVerified": true, + "firstName": "David (admin)", + "lastName": "Williams", + "email": "admin3@email.com", + "credentials": [ + { + "type": "password", + "hashedSaltedValue": "xjNR06W/ur5nBS8KFTrDgE81vLjb/t4A5LG2ubs/rII=", + "salt": "dyyLTNS/D+Ukspy5xgIa4w==", + "hashIterations": 27500, + "algorithm": "pbkdf2-sha256" + } + ], + "attributes": { + "member_number": ["12345"], + "phone": ["0612345653"], + "flying": [true], + "address.street1": ["123 Main St"], + "address.street2": ["Apt 4"], + "address.zipcode": ["11113"], + "address.city": ["Anytown"] + }, + "groups": [ + "/coopérateur", + "/infrastructure/informatique/elefan/admin" + ] + }, + { + "username": "admin4", + "enabled": true, + "emailVerified": true, + "firstName": "Carter (admin)", + "lastName": "Brown", + "email": "admin4@email.com", + "credentials": [ + { + "type": "password", + "hashedSaltedValue": "xjNR06W/ur5nBS8KFTrDgE81vLjb/t4A5LG2ubs/rII=", + "salt": "dyyLTNS/D+Ukspy5xgIa4w==", + "hashIterations": 27500, + "algorithm": "pbkdf2-sha256" + } + ], + "attributes": { + "member_number": ["12345"], + "phone": ["0612345654"], + "flying": [true], + "address.street1": ["123 Main St"], + "address.street2": ["Apt 4"], + "address.zipcode": ["11114"], + "address.city": ["Anytown"] + }, + "groups": [ + "/coopérateur", + "/infrastructure/informatique/elefan/admin" + ] + }, + { + "username": "admin5", + "enabled": true, + "emailVerified": true, + "firstName": "Wyatt (admin)", + "lastName": "Jones", + "email": "admin5@email.com", + "credentials": [ + { + "type": "password", + "hashedSaltedValue": "xjNR06W/ur5nBS8KFTrDgE81vLjb/t4A5LG2ubs/rII=", + "salt": "dyyLTNS/D+Ukspy5xgIa4w==", + "hashIterations": 27500, + "algorithm": "pbkdf2-sha256" + } + ], + "attributes": { + "member_number": ["11115"], + "phone": ["0612345655"], + "flying": [true], + "address.street1": ["123 Main St"], + "address.street2": ["Apt 4"], + "address.zipcode": ["12345"], + "address.city": ["Anytown"] + }, + "groups": [ + "/coopérateur", + "/infrastructure/informatique/elefan/admin" + ] + }, + { + "username": "admin", + "enabled": true, + "emailVerified": true, + "firstName": "Jayden (super admin)", + "lastName": "Garcia", + "email": "superadmin@email.com", + "credentials": [ + { + "type": "password", + "hashedSaltedValue": "xjNR06W/ur5nBS8KFTrDgE81vLjb/t4A5LG2ubs/rII=", + "salt": "dyyLTNS/D+Ukspy5xgIa4w==", + "hashIterations": 27500, + "algorithm": "pbkdf2-sha256" + } + ], + "attributes": { + "member_number": ["12345"], + "phone": ["0685428468"], + "flying": [true], + "address.street1": ["123 Main St"], + "address.street2": ["Apt 4"], + "address.zipcode": ["12345"], + "address.city": ["Anytown"], + "co_member_number": ["67890"] + }, + "groups": [ + "/coopérateur", + "/infrastructure/informatique/elefan/super_admin" + ] + } + + ], + "groups": [ + { + "name": "coopérateur", + "path": "/coopérateur" + }, + { + "name": "infrastructure", + "path": "/infrastructure", + "subGroups": [ + { + "name": "informatique", + "path": "/infrastructure/informatique", + "subGroups": [ + { + "name": "elefan", + "subGroups": [ + { + "name": "admin", + "path": "/infrastructure/informatique/elefan/admin" + }, + { + "name": "super_admin", + "path": "/infrastructure/informatique/elefan/super_admin" + }, + { + "name": "formations", + "path": "/infrastructure/informatique/elefan/formations", + "subGroups": [ + { + "name": "Accueil magasin", + "path": "/infrastructure/informatique/elefan/formations/accueil_magasin" + }, + { + "name": "Caisse", + "path": "/infrastructure/informatique/elefan/formations/caisse" + } + ] + } + ] + } + ] + } + ] + } + ] +} \ No newline at end of file diff --git a/.env.oidc b/.env.oidc deleted file mode 100644 index 1c9a94cc6..000000000 --- a/.env.oidc +++ /dev/null @@ -1,227 +0,0 @@ -SYMFONY_ENV='dev' -APP_SECRET='$ecretf0rt3st' -PHP_USER='www-data' -PHP_IDE_CONFIG='serverName=membres.yourcoop.local' -PHP_MEMORY_LIMIT=512M -PHP_SERVICE_NAME='php7.4-fpm' -###> symfony/framework-bundle ### -SYMFONY_DEPRECATIONS_HELPER=999999 -APP_ENV=dev -APP_SECRET=ThisTokenIsNotSoSecretChangeIt -#TRUSTED_PROXIES=127.0.0.0/8,10.0.0.0/8,172.16.0.0/12,192.168.0.0/16 -#TRUSTED_HOSTS='^(localhost|example\.com)$' -###< symfony/framework-bundle ### - -###> doctrine/doctrine-bundle ### -DATABASE_URL="mysql://root:secret@database:3306/symfony?serverVersion=5.7&charset=utf8" -DATABASE_TEST_HOST=127.0.0.1 -###< doctrine/doctrine-bundle ### - -###> symfony/swiftmailer-bundle ### -# For Gmail as a transport, use: "gmail://username:password@localhost" -# For a generic SMTP server, use: "smtp://localhost:25?encryption=&auth_mode=" -# Delivery is disabled by default via "null://localhost" -MAILER_URL=null://localhost -###< symfony/swiftmailer-bundle ### - -# SUPER_ADMIN User -SUPER_ADMIN_USERNAME=admin -SUPER_ADMIN_INITIAL_PASSWORD=password - -# Mailer Configuration -MAILER_TRANSPORT=smtp -MAILER_HOST=mailcatcher -MAILER_PORT=1025 -MAILER_USER=null -MAILER_PASSWORD=null -MAILER_ENCRYPTION=null - -# Transactional Mailer User -TRANSACTIONAL_MAILER_USER=contact@yourcoop.local -TRANSACTIONAL_MAILER_USER_NAME='espace membre' - -# Base Domain for Emails -EMAILS_BASE_DOMAIN=yourcoop.local - -# Email Addresses -EMAILS_CONTACT_NAME='Contact Localcoop' -EMAILS_CONTACT_ADDRESS=contact@yourcoop.local -EMAILS_MEMBER_NAME='Membres Localcoop' -EMAILS_MEMBER_ADDRESS=membres@yourcoop.local -EMAILS_SHIFT_NAME='Créneaux Localcoop' -EMAILS_SHIFT_ADDRESS=creneaux@yourcoop.local -EMAILS_FORMATION_NAME='Formation Localcoop' -EMAILS_FORMATION_ADDRESS=formations@yourcoop.local -EMAILS_ADMIN_NAME='Admin Localcoop' -EMAILS_ADMIN_ADDRESS=admin@yourcoop.local -EMAILS_NOREPLY_NAME='Ne pas répondre' -EMAILS_NOREPLY_ADDRESS=noreply@yourcoop.local - -# Router Configuration -ROUTER_REQUEST_CONTEXT_HOST=membres.yourcoop.local -ROUTER_REQUEST_CONTEXT_SCHEME=https -ROUTER_REQUEST_CONTEXT_BASE_URL= - -# Security: IP check -ENABLE_PLACE_LOCAL_IP_ADDRESS_CHECK=true -PLACE_LOCAL_IP_ADDRESS='127.0.0.1,192.168.0.x' - -# Branding -SITE_NAME="Espace membre @ MyLocalCoop" -PROJECT_NAME="My Local Coop" -PROJECT_URL=https://yourcoop.local/ -PROJECT_URL_DISPLAY=yourcoop.local -MAIN_COLOR=#51CAE9 -LOCAL_CURRENCY_NAME="monnaie locale" - -# Registration -REGISTRATION_DURATION='1 year' -REGISTRATION_EVERY_CIVIL_YEAR=false -REGISTRATION_MANUAL_ENABLED=true -HELLOASSO_REGISTRATION_CAMPAIGN_URL=https://www.helloasso.com/associations/my-local-coop/adhesions/re-adhesion -HELLOASSO_API_KEY= -HELLOASSO_API_PASSWORD= -HELLOASSO_API_BASE_URL=https://api.helloasso.com/v3/ - -# Shifting Configuration -DUE_DURATION_BY_CYCLE=180 -MIN_SHIFT_DURATION=90 -CYCLE_DURATION='28 days' -CYCLE_TYPE=abcd -NEW_USERS_START_AS_BEGINNER=true -ALLOW_EXTRA_SHIFTS=true -MAX_TIME_IN_ADVANCE_TO_BOOK_EXTRA_SHIFTS='3 days' -TIME_AFTER_WHICH_MEMBERS_ARE_LATE_WITH_SHIFTS=-9 -RESERVE_NEW_SHIFT_TO_PRIOR_SHIFTER=true -RESERVE_NEW_SHIFT_TO_PRIOR_SHIFTER_DELAY=7 -FORBID_SHIFT_OVERLAP_TIME=30 -MAX_TIME_AT_END_OF_SHIFT=0 -DISPLAY_NAME_SHIFTERS=false - -# shift fly and fixed -USE_FLY_AND_FIXED=false -FLY_AND_FIXED_ENTITY_FLYING=Beneficiary -FLY_AND_FIXED_ALLOW_FIXED_SHIFT_FREE=false - -# Swipe card -USE_CARD_READER_TO_VALIDATE_SHIFTS=false -SWIPE_CARD_LOGGING=true -SWIPE_CARD_LOGGING_ANONYMOUS=true -DISPLAY_SWIPE_CARDS_SETTINGS=true - -# Shifting: time log saving -USE_TIME_LOG_SAVING=false -TIME_LOG_SAVING_SHIFT_FREE_MIN_TIME_IN_ADVANCE_DAYS=null -TIME_LOG_SAVING_SHIFT_FREE_ALLOW_ONLY_IF_ENOUGH_SAVING=false - -# Profile Configuration -DISPLAY_GAUGE=true -PROFILE_DISPLAY_TASK_LIST=true -PROFILE_DISPLAY_TIME_LOG=true -PROFILE_DISPLAY_SHIFT_FREE_LOG=true -PROFILE_DISPLAY_PERIOD_POSITION_FREE_LOG=true -DISPLAY_FREEZE_ACCOUNT=true -DISPLAY_FREEZE_ACCOUNT_FALSE_MESSAGE="Le gel de compte n'est pas autorisé." -MAX_NB_OF_PAST_CYCLES_TO_DISPLAY=3 - -# User Configuration -USER_ACCOUNT_NOT_ENABLED_MATERIAL_ICON=phonelink_off -USER_ACCOUNT_ENABLED_ICON=☑ -USER_ACCOUNT_ENABLED_MATERIAL_ICON=devices - -# Member Configuration -MAXIMUM_NB_OF_BENEFICIARIES_IN_MEMBERSHIP=2 -MEMBER_WITHDRAWN_ICON=∅ -MEMBER_WITHDRAWN_MATERIAL_ICON=block -MEMBER_WITHDRAWN_BACKGROUND_COLOR='rgba(255, 50, 0, 0.2)' -MEMBER_FROZEN_ICON=❄️ -MEMBER_FROZEN_MATERIAL_ICON=ac_unit -MEMBER_FROZEN_BACKGROUND_COLOR='rgba(0, 138, 255, 0.1)' -MEMBER_EXEMPTED_ICON=☂ -MEMBER_EXEMPTED_MATERIAL_ICON=beach_access -MEMBER_EXEMPTED_BACKGROUND_COLOR='rgb(0, 150, 136, 0.1)' -MEMBER_FLYING_ICON=✈ -MEMBER_FLYING_MATERIAL_ICON=flightsmode -MEMBER_REGISTRATION_MISSING_ICON=$ -MEMBER_REGISTRATION_MISSING_MATERIAL_ICON=attach_money -MEMBER_REGISTRATION_MISSING_BACKGROUND_COLOR='rgb(0, 150, 136, 0.1)' - -# Beneficiary Configuration -BENEFICIARY_MAIN_ICON=⚐ -BENEFICIARY_NEW_ICON=★ -BENEFICIARY_FLYING_ICON=✈ - -# Admin: Member -ADMIN_MEMBER_DISPLAY_SHIFT_FREE_LOG=true -ADMIN_MEMBER_DISPLAY_PERIOD_POSITION_FREE_LOG=true -FORBID_OWN_SHIFT_BOOK_ADMIN=false -FORBID_OWN_SHIFT_FREE_ADMIN=false -FORBID_OWN_SHIFT_VALIDATE_ADMIN=false -FORBID_OWN_TIMELOG_NEW_ADMIN=false - -# Events -MAX_EVENT_PROXY_PER_MEMBER=1 - -# Opening Hours -DISPLAY_OPENING_HOUR_OPEN_CLOSED_HEADER=true -OPENING_HOUR_OPEN_CLOSED_HEADER_OPEN_MESSAGE="Ouvert" -OPENING_HOUR_OPEN_CLOSED_HEADER_CLOSED_MESSAGE="Fermé" - -# Code Generation -CODE_GENERATION_ENABLED=true -DISPLAY_KEYS_SHOP=true -WIKI_KEYS_URL= - -# Logging -LOGGING_MATTERMOST_ENABLED=false -LOGGING_MATTERMOST_LEVEL=critical -LOGGING_MATTERMOST_URL=http://mattermost.yourcoop.local -LOGGING_SWIFTMAILER_ENABLED=false -LOGGING_SWIFTMAILER_LEVEL=critical -LOGGING_SWIFTMAILER_RECIPIENT=email@example.com -LOGGING_MATTERMOST_CHANNEL=elefan - -# Open ID Client -OIDC_ENABLE=true -OIDC_PROFILE_CUSTOM_MESSAGE='vos informations personnelles sont éditables ici ' -OIDC_NO_ACCOUNT_MESSAGE="Vous n\'avez pas de compte. Veuillez contacter le support." -OIDC_ISSUER=http://keycloak:8080/auth -OIDC_REALM=elefan -OIDC_CLIENT_ID=elefan -OIDC_CLIENT_SECRET=secret -OIDC_ROLES_CLAIM=groups - -# OIDC User Attributes Map -OIDC_USER_ATTRIBUTE_FIRSTNAME=firstName -OIDC_USER_ATTRIBUTE_LASTNAME=lastName -OIDC_USER_ATTRIBUTE_MEMBER_NUMBER=member_number -OIDC_USER_ATTRIBUTE_EMAIL=email -OIDC_USER_ATTRIBUTE_PHONE=phone -OIDC_USER_ATTRIBUTE_FLYING=flying -OIDC_USER_ATTRIBUTE_ADDRESS_STREET1=address.street1 -OIDC_USER_ATTRIBUTE_ADDRESS_STREET2=address.street2 -OIDC_USER_ATTRIBUTE_ADDRESS_ZIPCODE=address.zipcode -OIDC_USER_ATTRIBUTE_ADDRESS_CITY=address.city -OIDC_USER_ATTRIBUTE_CO_MEMBER_NUMBER=co_member_number - -# OIDC Roles Map -OIDC_ROLE_USER=/cooperate -OIDC_ROLE_ADMIN_PANEL=/infrastructure/informatique/elefan/admin -OIDC_ROLE_USER_VIEWER=/infrastructure/informatique/elefan/admin -OIDC_ROLE_USER_MANAGER=/infrastructure/informatique/elefan/admin -OIDC_ROLE_SHIFT_MANAGER=/infrastructure/informatique/elefan/admin -OIDC_ROLE_FINANCE_MANAGER=/infrastructure/informatique/elefan/admin -OIDC_ROLE_PROCESS_MANAGER=/infrastructure/informatique/elefan/admin -OIDC_ROLE_ADMIN=/infrastructure/informatique/elefan/admin -OIDC_ROLE_SUPER_ADMIN=/infrastructure/informatique/elefan/super_admin -OIDC_ROLE_OAUTH_LOGIN= - -OIDC_FORMATIONS_CLAIM=groups - -# OIDC Formations Map in JSON -OIDC_FORMATIONS_MAP='{"Accueil magasin": "/infrastructure/informatique/elefan/formations/accueil_magasin", "Caisse": "/infrastructure/informatique/elefan/formations/caisse"}' - -OIDC_COMMISSIONS_CLAIM=groups - -# OIDC Commissions Map in JSON -OIDC_COMMISSIONS_MAP='{"foo": "/grouvernance/foo", "bar": "/grouvernance/bar"}' diff --git a/.env.oidc.test b/.env.oidc.test index f9cf7238d..eca6fa359 100644 --- a/.env.oidc.test +++ b/.env.oidc.test @@ -4,7 +4,7 @@ SYMFONY_ENV='test' APP_SECRET='$ecretf0rt3st' PHP_USER='www-data' -PHP_IDE_CONFIG='serverName=membres.yourcoop.local' +PHP_IDE_CONFIG='serverName=localhost' PHP_MEMORY_LIMIT=512M PHP_SERVICE_NAME='php7.4-fpm' ###> symfony/framework-bundle ### @@ -59,8 +59,8 @@ EMAILS_NOREPLY_NAME='Ne pas répondre' EMAILS_NOREPLY_ADDRESS=noreply@yourcoop.local # Router Configuration -ROUTER_REQUEST_CONTEXT_HOST=membres.yourcoop.local -ROUTER_REQUEST_CONTEXT_SCHEME=https +ROUTER_REQUEST_CONTEXT_HOST=localhost +ROUTER_REQUEST_CONTEXT_SCHEME=http ROUTER_REQUEST_CONTEXT_BASE_URL= # Security: IP check @@ -184,9 +184,9 @@ LOGGING_MATTERMOST_CHANNEL=elefan # Open ID Client OIDC_ENABLE=true -OIDC_PROFILE_CUSTOM_MESSAGE='vos informations personnelles sont éditables ici ' +OIDC_PROFILE_CUSTOM_MESSAGE='vos informations personnelles sont éditables ici ' OIDC_NO_ACCOUNT_MESSAGE="Vous n\'avez pas de compte. Veuillez contacter le support." -OIDC_ISSUER=http://keycloak:8080/auth +OIDC_ISSUER=http://localhost:8080/auth OIDC_REALM=elefan OIDC_CLIENT_ID=elefan OIDC_CLIENT_SECRET=secret diff --git a/.env.test b/.env.test index d70e2d911..431f1d18d 100644 --- a/.env.test +++ b/.env.test @@ -186,7 +186,7 @@ LOGGING_MATTERMOST_CHANNEL=elefan OIDC_ENABLE=false OIDC_PROFILE_CUSTOM_MESSAGE='vos informations personnelles sont éditables ici ' OIDC_NO_ACCOUNT_MESSAGE="Vous n\'avez pas de compte. Veuillez contacter le support." -OIDC_ISSUER=http://keycloak:8080/auth +OIDC_ISSUER=http://localhost:8080/auth OIDC_REALM=elefan OIDC_CLIENT_ID=elefan OIDC_CLIENT_SECRET=secret diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 3307a81db..397a4c79b 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -246,4 +246,42 @@ jobs: # RUN CYPRESS TESTS ---------------- - name: Run Cypress tests - run: npm run cy:test:main \ No newline at end of file + run: CYPRESS_BASE_URL=http://localhost:8000 npm run cy:test:main + + +# CHANGE ENV VARIABLES ---------------- + - name: Set up test environment variables + run: cp .env.oidc.test .env.test + +# START KEYCLOAK ---------------- + - name: Start Keycloak + run: | + docker run -d \ + --name keycloak \ + -e KEYCLOAK_USER=admin \ + -e KEYCLOAK_PASSWORD=admin \ + -e DB_VENDOR=h2 \ + -e KEYCLOAK_IMPORT=/config/realm-export.json \ + -v ${{ github.workspace }}/.docker/keycloak/config/realm-export.localhost.json:/config/realm-export.json \ + -p 8080:8080 \ + --user root \ + jboss/keycloak:16.1.1 + +# Wait for Keycloak to start + - name: Wait for Keycloak to be ready + run: | + until $(curl --output /dev/null --silent --head --fail http://localhost:8080/auth); do + printf '.' + sleep 5 + done + +# RUN CYPRESS TESTS ---------------- + - name: Run Cypress keycloak tests + uses: cypress-io/github-action@v6 + with: + start: npm run cy:test:oidc + env: + CYPRESS_BASE_URL: http://localhost:8000 + CYPRESS_KEYCLOAK_URL: http://localhost:8080 + + diff --git a/cypress.config.js b/cypress.config.js index 6d143e41f..45f9f0a90 100644 --- a/cypress.config.js +++ b/cypress.config.js @@ -6,4 +6,7 @@ module.exports = defineConfig({ viewportWidth: 1920, viewportHeight: 1080, }, + env: { + keycloakUrl: 'http://localhost:8080', + }, }); diff --git a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js index a7a5ab867..7a1f62385 100644 --- a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js +++ b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js @@ -2,7 +2,9 @@ // temporarily disable uncaught exception handling -import {login} from "../keycloak_reusables"; +import {login} from "../keycloak_reusables.cytools"; + +const keycloakUrl = Cypress.env('keycloakUrl') || 'http://localhost:8080' Cypress.on('uncaught:exception', (err, runnable) => { return false @@ -11,7 +13,7 @@ Cypress.on('uncaught:exception', (err, runnable) => { describe('admin1 can login', function () { it('admin story', function () { - login("admin1", "password") + login(keycloakUrl, "admin1", "password") cy.log('home page banner contains "admin"') cy.get('[data-cy=home_welcome_message]').contains('admin') diff --git a/cypress/e2e/keycloak/keycloak_reusables.cytools.js b/cypress/e2e/keycloak/keycloak_reusables.cytools.js index 41a1702b7..210d5b7b5 100644 --- a/cypress/e2e/keycloak/keycloak_reusables.cytools.js +++ b/cypress/e2e/keycloak/keycloak_reusables.cytools.js @@ -1,9 +1,11 @@ -export function login(username, password) { + +export function login(keycloakUrl, username, password) { cy.visit("/") cy.get('#login').click() - - cy.origin('http://keycloak:8080', { args : { username, password }}, ({ username, password }) => { + console.log(Cypress.config()); + console.log(Cypress.env()); + cy.origin(keycloakUrl, { args : { username, password }}, ({ username, password }) => { cy.log("fill in the login form") cy.get('#username').type(username, {force: true}) cy.get('#password').type(password, {force: true}) @@ -12,7 +14,7 @@ export function login(username, password) { cy.get('#kc-login').click() cy.location().then((location) => { - if (location !== null && location.origin === 'http://keycloak:8080') { + if (location !== null && location.origin === keycloakUrl) { cy.get('#kc-login').click() } else { cy.log("not asked for access to user data") diff --git a/package.json b/package.json index 3e4d840c4..2323e047b 100644 --- a/package.json +++ b/package.json @@ -34,8 +34,8 @@ "watch": "encore dev --watch", "build": "npx encore production --progress", "cy:open": "cypress open", - "cy:test:oidc": "CYPRESS_BASE_URL=http://127.0.0.1:8000 cypress run --spec 'cypress/e2e/oidc/*'", - "cy:test:main": "CYPRESS_BASE_URL=http://localhost:8000 cypress run --spec 'cypress/e2e/login/**/*'" + "cy:test:oidc": "cypress run --spec 'cypress/e2e/keycloak/**/*'", + "cy:test:main": "cypress run --spec 'cypress/e2e/login/**/*'" }, "repository": { "type": "git", From 9c737e1100b3fb2cab0e143087ec737a7f01f220 Mon Sep 17 00:00:00 2001 From: sam Date: Sat, 24 Feb 2024 11:09:23 +0100 Subject: [PATCH 07/19] debug cypress ci --- .github/workflows/ci-test.yaml | 30 +++++++++++++++++++ .github/workflows/ci-test2.yaml | 26 ++++++++++++++++ cypress.config.js | 2 +- .../e2e/keycloak/admin/admin1_can_login.cy.js | 4 +++ 4 files changed, 61 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/ci-test.yaml create mode 100644 .github/workflows/ci-test2.yaml diff --git a/.github/workflows/ci-test.yaml b/.github/workflows/ci-test.yaml new file mode 100644 index 000000000..7441a54d7 --- /dev/null +++ b/.github/workflows/ci-test.yaml @@ -0,0 +1,30 @@ +name: testing cypress envs + +on: + pull_request: + branches: + - master + - staging + - dev + +jobs: + setup: + runs-on: ubuntu-22.04 + strategy: + fail-fast: true + matrix: + php-versions: ['7.4'] + steps: + - name: Checkout code + uses: actions/checkout@v4 + +# RUN CYPRESS TESTS ---------------- + - name: Run Cypress keycloak tests + uses: cypress-io/github-action@v6 + with: + start: npm run cy:test:oidc + env: + CYPRESS_BASE_URL: http://localhost:8000 + CYPRESS_KEYCLOAK_URL: http://localhost:8080 + + diff --git a/.github/workflows/ci-test2.yaml b/.github/workflows/ci-test2.yaml new file mode 100644 index 000000000..2cb65aee3 --- /dev/null +++ b/.github/workflows/ci-test2.yaml @@ -0,0 +1,26 @@ +name: testing cypress envs + +on: + pull_request: + branches: + - master + - staging + - dev + +jobs: + setup: + runs-on: ubuntu-22.04 + strategy: + fail-fast: true + matrix: + php-versions: ['7.4'] + steps: + - name: Checkout code + uses: actions/checkout@v4 + +# RUN CYPRESS TESTS ---------------- + - name: Run Cypress keycloak tests + uses: cypress-io/github-action@v6 + with: + start: npm run cy:test:oidc + diff --git a/cypress.config.js b/cypress.config.js index 45f9f0a90..e7b2d9ccd 100644 --- a/cypress.config.js +++ b/cypress.config.js @@ -7,6 +7,6 @@ module.exports = defineConfig({ viewportHeight: 1080, }, env: { - keycloakUrl: 'http://localhost:8080', + keycloakUrl: 'http://keycloak:8080', }, }); diff --git a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js index 7a1f62385..c96506152 100644 --- a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js +++ b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js @@ -6,6 +6,10 @@ import {login} from "../keycloak_reusables.cytools"; const keycloakUrl = Cypress.env('keycloakUrl') || 'http://localhost:8080' +if (!keycloakUrl) { + throw new Error('keycloakUrl is not defined') +} + Cypress.on('uncaught:exception', (err, runnable) => { return false }) From 7628431d630bb13175af2c396584b2c00d122978 Mon Sep 17 00:00:00 2001 From: sam Date: Sat, 24 Feb 2024 11:55:40 +0100 Subject: [PATCH 08/19] debug cypress ga --- .github/workflows/ci-test.yaml | 262 ++++++++++++++++- .github/workflows/ci-test2.yaml | 265 +++++++++++++++++- cypress.config.js | 2 +- .../e2e/keycloak/admin/admin1_can_login.cy.js | 2 +- cypress/screenshots/.gitignore | 1 + 5 files changed, 521 insertions(+), 11 deletions(-) create mode 100644 cypress/screenshots/.gitignore diff --git a/.github/workflows/ci-test.yaml b/.github/workflows/ci-test.yaml index 7441a54d7..c9b51bb7e 100644 --- a/.github/workflows/ci-test.yaml +++ b/.github/workflows/ci-test.yaml @@ -1,4 +1,4 @@ -name: testing cypress envs +name: Integration and Functional tests on: pull_request: @@ -15,16 +15,270 @@ jobs: matrix: php-versions: ['7.4'] steps: +# REMOVE RESIDUAL CONTAINERS ( for local debug with act only ) + - name: Remove all mysql containers when working with act + if: ${{ env.ACT }} + run: | + CONTAINERS=$(docker ps -a -q --filter ancestor=mariadb:10.4.10) + if [ ! -z "$CONTAINERS" ]; then + docker rm -f $CONTAINERS + else + echo "No containers to remove." + fi + - name: Checkout code uses: actions/checkout@v4 +# INSTALL DEPENDENCIES ---------------- + - name: Setup PHP, extensions and composer with shivammathur/setup-php + uses: shivammathur/setup-php@verbose + with: + php-version: ${{ matrix.php-versions }} + tools: composer:2.2 + extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json + + - name: Setup Node.js + uses: actions/setup-node@v4 + with: + node-version: '20.11.0' + + - name: Get composer cache directory + id: composer-cache + run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_ENV + + - name: Cache composer dependencies + uses: actions/cache@v4 + with: + path: | + ${{ env.dir }} + ./vendor + key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} + restore-keys: ${{ runner.os }}-composer- + +# INSTALL PACKAGES ---------------- + - name: Clean node_modules + run: rm -rf node_modules + + - name: Install NPM packages + run: npm ci + + - name: Install Composer dependencies + run: composer install --no-progress --prefer-dist --optimize-autoloader + + +# UPLOAD CACHED DIRECTORIES ---------------- + - name: Upload Vendor Directory as Artifact + uses: actions/upload-artifact@v4 + with: + name: vendor-dir + path: vendor/ + + phpStan: + needs: setup + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v4 + +# GET CACHED DIRECTORIES ---------------- + - name: Download Vendor Directory + uses: actions/download-artifact@v4 + with: + name: vendor-dir + path: vendor/ + +# INSTALL DEPENDENCIES ---------------- + - name: Setup PHP, extensions and composer with shivammathur/setup-php + uses: shivammathur/setup-php@verbose + with: + php-version: ${{ matrix.php-versions }} + tools: composer:2.2 + extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json + + - name: Set executable permissions for PHPStan + run: chmod +x ./vendor/bin/phpstan + +# RUN PHPSTAN ---------------- + - name: Run PHPStan + run: ./vendor/bin/phpstan analyse src + + + symfony-tests: + needs: setup + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v4 + +# GET CACHED DIRECTORIES ---------------- + - name: Download Vendor Directory + uses: actions/download-artifact@v4 + with: + name: vendor-dir + path: vendor/ + +# INSTALL DEPENDENCIES ---------------- + - name: Install MySQL Client + run: sudo apt-get update && sudo apt-get install -y mysql-client + + - name: Setup PHP, extensions and composer with shivammathur/setup-php + uses: shivammathur/setup-php@verbose + with: + php-version: ${{ matrix.php-versions }} + tools: composer:2.2 + extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json + +# SET ENVIRONMENT VARIABLES ---------------- + - name: Set up test environment variables + run: cp .env.test .env + +# START SERVICES ---------------- + - name: Set up MySQL + uses: getong/mariadb-action@v1.1 + with: + host port: 3306 # Optional, default value is 3306. The port of host + container port: 3306 # Optional, default value is 3306. The port of container + character set server: 'utf8mb4' # Optional, default value is 'utf8mb4'. The '--character-set-server' option for mysqld + collation server: 'utf8mb4_general_ci' # Optional, default value is 'utf8mb4_general_ci'. The '--collation-server' option for mysqld + mariadb version: '10.4.10' # Optional, default value is "latest". The version of the MySQL + mysql database: 'symfony' # Optional, default value is "test". The specified database which will be created + mysql root password: 'secret' # Required if "mysql user" is empty, default is empty. The root superuser password + mysql user: 'user' # Required if "mysql root password" is empty, default is empty. The superuser for the specified database. Can use secrets, too + mysql password: 'password' # Required if "mysql user" exists. The password for the "mysql user" + + - name: Wait for MySQL to become available + run: | + until mysql -h 127.0.0.1 -u root -psecret -e "SELECT 1"; do + echo 'Waiting for MySQL...' + sleep 1 + done + +# RUN MIGRATIONS ---------------- + - name: Run migrations + run: php bin/console doctrine:migrations:migrate --no-interaction + +# RUN TESTS ---------------- + - name: Run unit and functional tests + run: | + php ./vendor/bin/phpunit --configuration phpunit.xml.dist + + + cypress-tests: + needs: setup + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v4 + +# GET CACHED DIRECTORIES ---------------- + - name: Download Vendor Directory + uses: actions/download-artifact@v4 + with: + name: vendor-dir + path: vendor/ + +# INSTALL DEPENDENCIES ---------------- + - name: Install MySQL Client + run: sudo apt-get update && sudo apt-get install -y mysql-client + + - name: Install Cypress dependencies + run: sudo apt-get install -y xvfb libgtk2.0-0 libgtk-3-0 libgbm-dev libnotify-dev libnss3 libxss1 libasound2 libxtst6 xauth + + - name: Setup PHP, extensions and composer with shivammathur/setup-php + uses: shivammathur/setup-php@verbose + with: + php-version: ${{ matrix.php-versions }} + tools: composer:2.2 + extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json + + - name: Setup Node.js + uses: actions/setup-node@v4 + with: + node-version: '20.11.0' + + - name: Install Symfony CLI globally + run: | + curl -sS https://get.symfony.com/cli/installer | bash + sudo mv /home/runner/.symfony5/bin/symfony /usr/local/bin/symfony + +# SET ENVIRONMENT VARIABLES ---------------- + - name: Set up test environment variables + run: cp .env.test .env + +# START SERVICES ---------------- + - name: Set up MySQL + uses: getong/mariadb-action@v1.1 + with: + host port: 3306 # Optional, default value is 3306. The port of host + container port: 3306 # Optional, default value is 3306. The port of container + character set server: 'utf8mb4' # Optional, default value is 'utf8mb4'. The '--character-set-server' option for mysqld + collation server: 'utf8mb4_general_ci' # Optional, default value is 'utf8mb4_general_ci'. The '--collation-server' option for mysqld + mariadb version: '10.4.10' # Optional, default value is "latest". The version of the MySQL + mysql database: 'symfony' # Optional, default value is "test". The specified database which will be created + mysql root password: 'secret' # Required if "mysql user" is empty, default is empty. The root superuser password + mysql user: 'user' # Required if "mysql root password" is empty, default is empty. The superuser for the specified database. Can use secrets, too + mysql password: 'password' # Required if "mysql user" exists. The password for the "mysql user" + + - name: Wait for MySQL to become available + run: | + until mysql -h 127.0.0.1 -u root -psecret -e "SELECT 1"; do + echo 'Waiting for MySQL...' + sleep 1 + done + + - name: Start Symfony server + run: symfony server:start --no-tls -d --port=8000 + +# RUN MIGRATIONS ---------------- + - name: Run migrations + run: php bin/console doctrine:migrations:migrate --no-interaction + +# FILL DATABASE ---------------- + - name: Run fixture + run: php bin/console doctrine:fixtures:load --no-interaction + +# BUILD FRONT ---------------- + - name : install packages + run: npm install + + - name: Enable verbose npm logging + run: npm config set loglevel verbose + + - name: Build front-end assets + run: ./node_modules/.bin/encore production --progress + +# RUN CYPRESS TESTS ---------------- + - name: Run Cypress tests + run: CYPRESS_BASE_URL=http://localhost:8000 npm run cy:test:main + + +# CHANGE ENV VARIABLES ---------------- + - name: Set up test environment variables + run: cp .env.oidc.test .env.test + +# START KEYCLOAK ---------------- + - name: Start Keycloak + run: | + docker run -d \ + --name keycloak \ + -e KEYCLOAK_USER=admin \ + -e KEYCLOAK_PASSWORD=admin \ + -e DB_VENDOR=h2 \ + -e KEYCLOAK_IMPORT=/config/realm-export.json \ + -v ${{ github.workspace }}/.docker/keycloak/config/realm-export.localhost.json:/config/realm-export.json \ + -p 8080:8080 \ + --user root \ + jboss/keycloak:16.1.1 + +# Wait for Keycloak to start + - name: Wait for Keycloak to be ready + run: | + until $(curl --output /dev/null --silent --head --fail http://localhost:8080/auth); do + printf '.' + sleep 5 + done + # RUN CYPRESS TESTS ---------------- - name: Run Cypress keycloak tests uses: cypress-io/github-action@v6 with: start: npm run cy:test:oidc - env: - CYPRESS_BASE_URL: http://localhost:8000 - CYPRESS_KEYCLOAK_URL: http://localhost:8080 diff --git a/.github/workflows/ci-test2.yaml b/.github/workflows/ci-test2.yaml index 2cb65aee3..73796baec 100644 --- a/.github/workflows/ci-test2.yaml +++ b/.github/workflows/ci-test2.yaml @@ -1,4 +1,4 @@ -name: testing cypress envs +name: Integration and Functional tests on: pull_request: @@ -15,12 +15,267 @@ jobs: matrix: php-versions: ['7.4'] steps: +# REMOVE RESIDUAL CONTAINERS ( for local debug with act only ) + - name: Remove all mysql containers when working with act + if: ${{ env.ACT }} + run: | + CONTAINERS=$(docker ps -a -q --filter ancestor=mariadb:10.4.10) + if [ ! -z "$CONTAINERS" ]; then + docker rm -f $CONTAINERS + else + echo "No containers to remove." + fi + - name: Checkout code uses: actions/checkout@v4 -# RUN CYPRESS TESTS ---------------- - - name: Run Cypress keycloak tests - uses: cypress-io/github-action@v6 +# INSTALL DEPENDENCIES ---------------- + - name: Setup PHP, extensions and composer with shivammathur/setup-php + uses: shivammathur/setup-php@verbose + with: + php-version: ${{ matrix.php-versions }} + tools: composer:2.2 + extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json + + - name: Setup Node.js + uses: actions/setup-node@v4 + with: + node-version: '20.11.0' + + - name: Get composer cache directory + id: composer-cache + run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_ENV + + - name: Cache composer dependencies + uses: actions/cache@v4 + with: + path: | + ${{ env.dir }} + ./vendor + key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} + restore-keys: ${{ runner.os }}-composer- + +# INSTALL PACKAGES ---------------- + - name: Clean node_modules + run: rm -rf node_modules + + - name: Install NPM packages + run: npm ci + + - name: Install Composer dependencies + run: composer install --no-progress --prefer-dist --optimize-autoloader + + +# UPLOAD CACHED DIRECTORIES ---------------- + - name: Upload Vendor Directory as Artifact + uses: actions/upload-artifact@v4 + with: + name: vendor-dir + path: vendor/ + + phpStan: + needs: setup + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v4 + +# GET CACHED DIRECTORIES ---------------- + - name: Download Vendor Directory + uses: actions/download-artifact@v4 + with: + name: vendor-dir + path: vendor/ + +# INSTALL DEPENDENCIES ---------------- + - name: Setup PHP, extensions and composer with shivammathur/setup-php + uses: shivammathur/setup-php@verbose + with: + php-version: ${{ matrix.php-versions }} + tools: composer:2.2 + extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json + + - name: Set executable permissions for PHPStan + run: chmod +x ./vendor/bin/phpstan + +# RUN PHPSTAN ---------------- + - name: Run PHPStan + run: ./vendor/bin/phpstan analyse src + + + symfony-tests: + needs: setup + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v4 + +# GET CACHED DIRECTORIES ---------------- + - name: Download Vendor Directory + uses: actions/download-artifact@v4 with: - start: npm run cy:test:oidc + name: vendor-dir + path: vendor/ + +# INSTALL DEPENDENCIES ---------------- + - name: Install MySQL Client + run: sudo apt-get update && sudo apt-get install -y mysql-client + + - name: Setup PHP, extensions and composer with shivammathur/setup-php + uses: shivammathur/setup-php@verbose + with: + php-version: ${{ matrix.php-versions }} + tools: composer:2.2 + extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json + +# SET ENVIRONMENT VARIABLES ---------------- + - name: Set up test environment variables + run: cp .env.test .env + +# START SERVICES ---------------- + - name: Set up MySQL + uses: getong/mariadb-action@v1.1 + with: + host port: 3306 # Optional, default value is 3306. The port of host + container port: 3306 # Optional, default value is 3306. The port of container + character set server: 'utf8mb4' # Optional, default value is 'utf8mb4'. The '--character-set-server' option for mysqld + collation server: 'utf8mb4_general_ci' # Optional, default value is 'utf8mb4_general_ci'. The '--collation-server' option for mysqld + mariadb version: '10.4.10' # Optional, default value is "latest". The version of the MySQL + mysql database: 'symfony' # Optional, default value is "test". The specified database which will be created + mysql root password: 'secret' # Required if "mysql user" is empty, default is empty. The root superuser password + mysql user: 'user' # Required if "mysql root password" is empty, default is empty. The superuser for the specified database. Can use secrets, too + mysql password: 'password' # Required if "mysql user" exists. The password for the "mysql user" + + - name: Wait for MySQL to become available + run: | + until mysql -h 127.0.0.1 -u root -psecret -e "SELECT 1"; do + echo 'Waiting for MySQL...' + sleep 1 + done + +# RUN MIGRATIONS ---------------- + - name: Run migrations + run: php bin/console doctrine:migrations:migrate --no-interaction + +# RUN TESTS ---------------- + - name: Run unit and functional tests + run: | + php ./vendor/bin/phpunit --configuration phpunit.xml.dist + + + cypress-tests: + needs: setup + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v4 + +# GET CACHED DIRECTORIES ---------------- + - name: Download Vendor Directory + uses: actions/download-artifact@v4 + with: + name: vendor-dir + path: vendor/ + +# INSTALL DEPENDENCIES ---------------- + - name: Install MySQL Client + run: sudo apt-get update && sudo apt-get install -y mysql-client + + - name: Install Cypress dependencies + run: sudo apt-get install -y xvfb libgtk2.0-0 libgtk-3-0 libgbm-dev libnotify-dev libnss3 libxss1 libasound2 libxtst6 xauth + + - name: Setup PHP, extensions and composer with shivammathur/setup-php + uses: shivammathur/setup-php@verbose + with: + php-version: ${{ matrix.php-versions }} + tools: composer:2.2 + extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json + + - name: Setup Node.js + uses: actions/setup-node@v4 + with: + node-version: '20.11.0' + + - name: Install Symfony CLI globally + run: | + curl -sS https://get.symfony.com/cli/installer | bash + sudo mv /home/runner/.symfony5/bin/symfony /usr/local/bin/symfony + +# SET ENVIRONMENT VARIABLES ---------------- + - name: Set up test environment variables + run: cp .env.test .env + +# START SERVICES ---------------- + - name: Set up MySQL + uses: getong/mariadb-action@v1.1 + with: + host port: 3306 # Optional, default value is 3306. The port of host + container port: 3306 # Optional, default value is 3306. The port of container + character set server: 'utf8mb4' # Optional, default value is 'utf8mb4'. The '--character-set-server' option for mysqld + collation server: 'utf8mb4_general_ci' # Optional, default value is 'utf8mb4_general_ci'. The '--collation-server' option for mysqld + mariadb version: '10.4.10' # Optional, default value is "latest". The version of the MySQL + mysql database: 'symfony' # Optional, default value is "test". The specified database which will be created + mysql root password: 'secret' # Required if "mysql user" is empty, default is empty. The root superuser password + mysql user: 'user' # Required if "mysql root password" is empty, default is empty. The superuser for the specified database. Can use secrets, too + mysql password: 'password' # Required if "mysql user" exists. The password for the "mysql user" + + - name: Wait for MySQL to become available + run: | + until mysql -h 127.0.0.1 -u root -psecret -e "SELECT 1"; do + echo 'Waiting for MySQL...' + sleep 1 + done + + - name: Start Symfony server + run: symfony server:start --no-tls -d --port=8000 + +# RUN MIGRATIONS ---------------- + - name: Run migrations + run: php bin/console doctrine:migrations:migrate --no-interaction + +# FILL DATABASE ---------------- + - name: Run fixture + run: php bin/console doctrine:fixtures:load --no-interaction + +# BUILD FRONT ---------------- + - name : install packages + run: npm install + + - name: Enable verbose npm logging + run: npm config set loglevel verbose + + - name: Build front-end assets + run: ./node_modules/.bin/encore production --progress + +# RUN CYPRESS TESTS ---------------- + - name: Run Cypress tests + run: CYPRESS_BASE_URL=http://localhost:8000 npm run cy:test:main + + +# CHANGE ENV VARIABLES ---------------- + - name: Set up test environment variables + run: cp .env.oidc.test .env.test + +# START KEYCLOAK ---------------- + - name: Start Keycloak + run: | + docker run -d \ + --name keycloak \ + -e KEYCLOAK_USER=admin \ + -e KEYCLOAK_PASSWORD=admin \ + -e DB_VENDOR=h2 \ + -e KEYCLOAK_IMPORT=/config/realm-export.json \ + -v ${{ github.workspace }}/.docker/keycloak/config/realm-export.localhost.json:/config/realm-export.json \ + -p 8080:8080 \ + --user root \ + jboss/keycloak:16.1.1 + +# Wait for Keycloak to start + - name: Wait for Keycloak to be ready + run: | + until $(curl --output /dev/null --silent --head --fail http://localhost:8080/auth); do + printf '.' + sleep 5 + done + + # RUN CYPRESS TESTS ---------------- + - name: Run Cypress tests + run: CYPRESS_BASE_URL=http://localhost:8000 CYPRESS_KEYCLOAK_URL=http://localhost:8080 npm run cy:test:main diff --git a/cypress.config.js b/cypress.config.js index e7b2d9ccd..6f00d1a6e 100644 --- a/cypress.config.js +++ b/cypress.config.js @@ -7,6 +7,6 @@ module.exports = defineConfig({ viewportHeight: 1080, }, env: { - keycloakUrl: 'http://keycloak:8080', + KEYCLOAK_URL: 'http://keycloak:8080', }, }); diff --git a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js index c96506152..7ee0818c5 100644 --- a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js +++ b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js @@ -4,7 +4,7 @@ // temporarily disable uncaught exception handling import {login} from "../keycloak_reusables.cytools"; -const keycloakUrl = Cypress.env('keycloakUrl') || 'http://localhost:8080' +const keycloakUrl = Cypress.env('KEYCLOAK_URL') || 'http://localhost:8080' if (!keycloakUrl) { throw new Error('keycloakUrl is not defined') diff --git a/cypress/screenshots/.gitignore b/cypress/screenshots/.gitignore new file mode 100644 index 000000000..72e8ffc0d --- /dev/null +++ b/cypress/screenshots/.gitignore @@ -0,0 +1 @@ +* From da393c5d591de3a03dbafb39c7619afb7d8043e4 Mon Sep 17 00:00:00 2001 From: sam Date: Sat, 24 Feb 2024 19:39:43 +0100 Subject: [PATCH 09/19] debug cypress ga --- .github/workflows/ci-test2.yaml | 2 +- .github/workflows/{ci-test.yaml => ci-test3.yaml} | 9 +++------ cypress.env.json | 3 +++ cypress/e2e/keycloak/admin/admin1_can_login.cy.js | 7 ++++--- 4 files changed, 11 insertions(+), 10 deletions(-) rename .github/workflows/{ci-test.yaml => ci-test3.yaml} (97%) create mode 100644 cypress.env.json diff --git a/.github/workflows/ci-test2.yaml b/.github/workflows/ci-test2.yaml index 73796baec..c7e8eb89f 100644 --- a/.github/workflows/ci-test2.yaml +++ b/.github/workflows/ci-test2.yaml @@ -277,5 +277,5 @@ jobs: # RUN CYPRESS TESTS ---------------- - name: Run Cypress tests - run: CYPRESS_BASE_URL=http://localhost:8000 CYPRESS_KEYCLOAK_URL=http://localhost:8080 npm run cy:test:main + run: CYPRESS_BASE_URL=http://localhost:8000 CYPRESS_KEYCLOAK_URL=http://localhost:8080 npm run cy:test:oidc diff --git a/.github/workflows/ci-test.yaml b/.github/workflows/ci-test3.yaml similarity index 97% rename from .github/workflows/ci-test.yaml rename to .github/workflows/ci-test3.yaml index c9b51bb7e..fbe3e440e 100644 --- a/.github/workflows/ci-test.yaml +++ b/.github/workflows/ci-test3.yaml @@ -275,10 +275,7 @@ jobs: sleep 5 done -# RUN CYPRESS TESTS ---------------- - - name: Run Cypress keycloak tests - uses: cypress-io/github-action@v6 - with: - start: npm run cy:test:oidc - + # RUN CYPRESS TESTS ---------------- + - name: Run Cypress tests + run: CYPRESS_BASE_URL=http://localhost:8000 npx cypress run --spec 'cypress/e2e/keycloak/**/*'" --env CYPRESS_KEYCLOAK_URL=http://localhost:8080 diff --git a/cypress.env.json b/cypress.env.json new file mode 100644 index 000000000..03044a282 --- /dev/null +++ b/cypress.env.json @@ -0,0 +1,3 @@ +{ + "KEYCLOAK_URL": "http://localhost:8080", +} \ No newline at end of file diff --git a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js index 7ee0818c5..4800b6acb 100644 --- a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js +++ b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js @@ -4,10 +4,11 @@ // temporarily disable uncaught exception handling import {login} from "../keycloak_reusables.cytools"; -const keycloakUrl = Cypress.env('KEYCLOAK_URL') || 'http://localhost:8080' +let keycloakUrl = Cypress.env('KEYCLOAK_URL') -if (!keycloakUrl) { - throw new Error('keycloakUrl is not defined') +// check if there is no reference error +if (keycloakUrl === undefined) { + keycloakUrl = 'http://localhost:8080' // default value need for CI } Cypress.on('uncaught:exception', (err, runnable) => { From 0fec458f87204100570a95bb0a0613a3d4b2520d Mon Sep 17 00:00:00 2001 From: sam Date: Sun, 25 Feb 2024 10:24:30 +0100 Subject: [PATCH 10/19] debug cypress --- cypress.env.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cypress.env.json b/cypress.env.json index 03044a282..1fc4c2b29 100644 --- a/cypress.env.json +++ b/cypress.env.json @@ -1,3 +1,3 @@ { - "KEYCLOAK_URL": "http://localhost:8080", + "KEYCLOAK_URL": "http://localhost:8080" } \ No newline at end of file From aa5b25ff07694872eb867c57cde7182e87363d21 Mon Sep 17 00:00:00 2001 From: sam Date: Sun, 25 Feb 2024 12:05:43 +0100 Subject: [PATCH 11/19] debug cypress' --- .github/workflows/ci-test3.yaml | 2 +- cypress/e2e/keycloak/admin/admin1_can_login.cy.js | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci-test3.yaml b/.github/workflows/ci-test3.yaml index fbe3e440e..3e9f6e75f 100644 --- a/.github/workflows/ci-test3.yaml +++ b/.github/workflows/ci-test3.yaml @@ -277,5 +277,5 @@ jobs: # RUN CYPRESS TESTS ---------------- - name: Run Cypress tests - run: CYPRESS_BASE_URL=http://localhost:8000 npx cypress run --spec 'cypress/e2e/keycloak/**/*'" --env CYPRESS_KEYCLOAK_URL=http://localhost:8080 + run: CYPRESS_BASE_URL=http://localhost:8000 npx cypress run --spec 'cypress/e2e/keycloak/**/*' --env CYPRESS_KEYCLOAK_URL=http://localhost:8080 diff --git a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js index 4800b6acb..c25be7888 100644 --- a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js +++ b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js @@ -11,6 +11,10 @@ if (keycloakUrl === undefined) { keycloakUrl = 'http://localhost:8080' // default value need for CI } +if (!['http://localhost:8080', 'http://keycloak:8080'].includes(keycloakUrl)) { + keycloakUrl = 'http://localhost:8080' // default value need for CI +} + Cypress.on('uncaught:exception', (err, runnable) => { return false }) From caa87ed8d98a6b270fb1f6d8e2bfedbbeff5a28d Mon Sep 17 00:00:00 2001 From: sam Date: Sun, 25 Feb 2024 12:21:36 +0100 Subject: [PATCH 12/19] =?UTF-8?q?debug=C3=A9=20=C3=A9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/ci-test4.yaml | 0 .github/workflows/ci.yaml | 2 +- 2 files changed, 1 insertion(+), 1 deletion(-) create mode 100644 .github/workflows/ci-test4.yaml diff --git a/.github/workflows/ci-test4.yaml b/.github/workflows/ci-test4.yaml new file mode 100644 index 000000000..e69de29bb diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 397a4c79b..9f334cd6e 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -279,7 +279,7 @@ jobs: - name: Run Cypress keycloak tests uses: cypress-io/github-action@v6 with: - start: npm run cy:test:oidc + command: npm run cy:test:oidc env: CYPRESS_BASE_URL: http://localhost:8000 CYPRESS_KEYCLOAK_URL: http://localhost:8080 From 6aad4988b73757420eda2114cf6bc3cfdb1d27ca Mon Sep 17 00:00:00 2001 From: sam Date: Sun, 25 Feb 2024 13:49:56 +0100 Subject: [PATCH 13/19] debug --- .github/workflows/ci-test4.yaml | 34 +++++++++++++++++++ .../e2e/keycloak/admin/admin1_can_login.cy.js | 33 +++++++++++------- .../keycloak/keycloak_reusables.cytools.js | 3 +- 3 files changed, 55 insertions(+), 15 deletions(-) diff --git a/.github/workflows/ci-test4.yaml b/.github/workflows/ci-test4.yaml index e69de29bb..c0ec40be7 100644 --- a/.github/workflows/ci-test4.yaml +++ b/.github/workflows/ci-test4.yaml @@ -0,0 +1,34 @@ +name: Integration and Functional tests + +on: + pull_request: + branches: + - master + - staging + - dev + +jobs: + setup: + runs-on: ubuntu-22.04 + strategy: + fail-fast: true + matrix: + php-versions: ['7.4'] + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Install Cypress dependencies + run: sudo apt update && sudo apt-get install -y xvfb libgtk2.0-0 libgtk-3-0 libgbm-dev libnotify-dev libnss3 libxss1 libasound2 libxtst6 xauth + +# RUN CYPRESS TESTS ---------------- + - name: Run Cypress keycloak tests + uses: cypress-io/github-action@v6 + with: + start: npx http-server -p 8000 -c-1 + command: npm run cy:test:oidc + env: + CYPRESS_BASE_URL: http://localhost:8000 + CYPRESS_KEYCLOAK_URL: http://localhost:8080 + + diff --git a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js index c25be7888..96da687ba 100644 --- a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js +++ b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js @@ -22,19 +22,26 @@ Cypress.on('uncaught:exception', (err, runnable) => { describe('admin1 can login', function () { it('admin story', function () { - login(keycloakUrl, "admin1", "password") - - cy.log('home page banner contains "admin"') - cy.get('[data-cy=home_welcome_message]').contains('admin') - - cy.log('go to settings page') - cy.get('[data-cy=settings_link]').click() - - cy.log('display informations') - cy.get('[data-cy=open_my_informations]').click() - - cy.log('check if role_admin in the page') - cy.get('[data-cy=user_roles_container]').contains('ROLE_ADMIN', {timeout: 2000}) + cy.visit("/") + cy.get('#login').click() + + cy.origin(keycloakUrl, () => { + cy.get('#username').type('test', {force: true}) + }) + + // login(keycloakUrl, "admin1", "password") + // + // cy.log('home page banner contains "admin"') + // cy.get('[data-cy=home_welcome_message]').contains('admin') + // + // cy.log('go to settings page') + // cy.get('[data-cy=settings_link]').click() + // + // cy.log('display informations') + // cy.get('[data-cy=open_my_informations]').click() + // + // cy.log('check if role_admin in the page') + // cy.get('[data-cy=user_roles_container]').contains('ROLE_ADMIN', {timeout: 2000}) }) }) diff --git a/cypress/e2e/keycloak/keycloak_reusables.cytools.js b/cypress/e2e/keycloak/keycloak_reusables.cytools.js index 210d5b7b5..8ea986b53 100644 --- a/cypress/e2e/keycloak/keycloak_reusables.cytools.js +++ b/cypress/e2e/keycloak/keycloak_reusables.cytools.js @@ -3,8 +3,7 @@ export function login(keycloakUrl, username, password) { cy.visit("/") cy.get('#login').click() - console.log(Cypress.config()); - console.log(Cypress.env()); + cy.origin(keycloakUrl, { args : { username, password }}, ({ username, password }) => { cy.log("fill in the login form") cy.get('#username').type(username, {force: true}) From 4744ea53f9cbdb43b6a728109e2736de1c611a62 Mon Sep 17 00:00:00 2001 From: sam Date: Sun, 25 Feb 2024 13:56:01 +0100 Subject: [PATCH 14/19] debug --- cypress/e2e/keycloak/admin/admin1_can_login.cy.js | 2 -- 1 file changed, 2 deletions(-) diff --git a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js index 96da687ba..7ee9be502 100644 --- a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js +++ b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js @@ -23,8 +23,6 @@ describe('admin1 can login', function () { it('admin story', function () { cy.visit("/") - cy.get('#login').click() - cy.origin(keycloakUrl, () => { cy.get('#username').type('test', {force: true}) }) From ccda8267ceab5c5014d2a05ded819b9fdd65f4c0 Mon Sep 17 00:00:00 2001 From: sam Date: Sun, 25 Feb 2024 14:18:05 +0100 Subject: [PATCH 15/19] debug --- .../e2e/keycloak/admin/admin1_can_login.cy.js | 55 +++++++++++-------- 1 file changed, 31 insertions(+), 24 deletions(-) diff --git a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js index 7ee9be502..78d595cc5 100644 --- a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js +++ b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js @@ -1,20 +1,11 @@ // NO PERMANENT CHANGE TO DATABASE - -// temporarily disable uncaught exception handling import {login} from "../keycloak_reusables.cytools"; let keycloakUrl = Cypress.env('KEYCLOAK_URL') -// check if there is no reference error -if (keycloakUrl === undefined) { - keycloakUrl = 'http://localhost:8080' // default value need for CI -} - -if (!['http://localhost:8080', 'http://keycloak:8080'].includes(keycloakUrl)) { - keycloakUrl = 'http://localhost:8080' // default value need for CI -} +// temporarily disable uncaught exception handling Cypress.on('uncaught:exception', (err, runnable) => { return false }) @@ -23,23 +14,39 @@ describe('admin1 can login', function () { it('admin story', function () { cy.visit("/") + cy.get('#login').click() + + cy.visit("/") + cy.get('#login').click() + cy.origin(keycloakUrl, () => { - cy.get('#username').type('test', {force: true}) + cy.log("fill in the login form") + cy.get('#username').type('admin1', {force: true}) + cy.get('#password').type('password', {force: true}) + + // submit + cy.get('#kc-login').click() + + cy.location().then((location) => { + if (location !== null && location.origin === keycloakUrl) { + cy.get('#kc-login').click() + } else { + cy.log("not asked for access to user data") + } + }) }) - // login(keycloakUrl, "admin1", "password") - // - // cy.log('home page banner contains "admin"') - // cy.get('[data-cy=home_welcome_message]').contains('admin') - // - // cy.log('go to settings page') - // cy.get('[data-cy=settings_link]').click() - // - // cy.log('display informations') - // cy.get('[data-cy=open_my_informations]').click() - // - // cy.log('check if role_admin in the page') - // cy.get('[data-cy=user_roles_container]').contains('ROLE_ADMIN', {timeout: 2000}) + cy.log('home page banner contains "admin"') + cy.get('[data-cy=home_welcome_message]').contains('admin') + + cy.log('go to settings page') + cy.get('[data-cy=settings_link]').click() + + cy.log('display informations') + cy.get('[data-cy=open_my_informations]').click() + + cy.log('check if role_admin in the page') + cy.get('[data-cy=user_roles_container]').contains('ROLE_ADMIN', {timeout: 2000}) }) }) From a4c809b936b8318f50e6ae8167be552d18a6e018 Mon Sep 17 00:00:00 2001 From: sam Date: Sun, 25 Feb 2024 14:27:42 +0100 Subject: [PATCH 16/19] debug --- cypress/e2e/keycloak/admin/admin1_can_login.cy.js | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js index 78d595cc5..a1c18d073 100644 --- a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js +++ b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js @@ -27,13 +27,13 @@ describe('admin1 can login', function () { // submit cy.get('#kc-login').click() - cy.location().then((location) => { - if (location !== null && location.origin === keycloakUrl) { - cy.get('#kc-login').click() - } else { - cy.log("not asked for access to user data") - } - }) + // cy.location().then((location) => { + // if (location !== null && location.origin === keycloakUrl) { + // cy.get('#kc-login').click() + // } else { + // cy.log("not asked for access to user data") + // } + // }) }) cy.log('home page banner contains "admin"') From 391a87c0c84c5be987913663cd39244af947518c Mon Sep 17 00:00:00 2001 From: sam Date: Sun, 25 Feb 2024 14:49:24 +0100 Subject: [PATCH 17/19] debug --- .../e2e/keycloak/admin/admin1_can_login.cy.js | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js index a1c18d073..3a5863575 100644 --- a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js +++ b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js @@ -19,7 +19,7 @@ describe('admin1 can login', function () { cy.visit("/") cy.get('#login').click() - cy.origin(keycloakUrl, () => { + cy.origin(keycloakUrl, { args: { keycloakUrl } }, ({ keycloakUrl }) => { cy.log("fill in the login form") cy.get('#username').type('admin1', {force: true}) cy.get('#password').type('password', {force: true}) @@ -27,13 +27,13 @@ describe('admin1 can login', function () { // submit cy.get('#kc-login').click() - // cy.location().then((location) => { - // if (location !== null && location.origin === keycloakUrl) { - // cy.get('#kc-login').click() - // } else { - // cy.log("not asked for access to user data") - // } - // }) + cy.location().then((location) => { + if (location !== null && location.origin === keycloakUrl) { + cy.get('#kc-login').click() + } else { + cy.log("not asked for access to user data") + } + }) }) cy.log('home page banner contains "admin"') From 2b2c616ddf2af048183b96d0e2beda2ea50692c7 Mon Sep 17 00:00:00 2001 From: sam Date: Sun, 25 Feb 2024 15:22:05 +0100 Subject: [PATCH 18/19] debug --- .github/workflows/ci-test2.yaml | 281 ------------------ .github/workflows/ci-test3.yaml | 281 ------------------ .github/workflows/ci-test4.yaml | 34 --- .github/workflows/ci.yaml | 10 +- .../e2e/keycloak/admin/admin1_can_login.cy.js | 23 +- .../keycloak/keycloak_reusables.cytools.js | 2 +- 6 files changed, 4 insertions(+), 627 deletions(-) delete mode 100644 .github/workflows/ci-test2.yaml delete mode 100644 .github/workflows/ci-test3.yaml delete mode 100644 .github/workflows/ci-test4.yaml diff --git a/.github/workflows/ci-test2.yaml b/.github/workflows/ci-test2.yaml deleted file mode 100644 index c7e8eb89f..000000000 --- a/.github/workflows/ci-test2.yaml +++ /dev/null @@ -1,281 +0,0 @@ -name: Integration and Functional tests - -on: - pull_request: - branches: - - master - - staging - - dev - -jobs: - setup: - runs-on: ubuntu-22.04 - strategy: - fail-fast: true - matrix: - php-versions: ['7.4'] - steps: -# REMOVE RESIDUAL CONTAINERS ( for local debug with act only ) - - name: Remove all mysql containers when working with act - if: ${{ env.ACT }} - run: | - CONTAINERS=$(docker ps -a -q --filter ancestor=mariadb:10.4.10) - if [ ! -z "$CONTAINERS" ]; then - docker rm -f $CONTAINERS - else - echo "No containers to remove." - fi - - - name: Checkout code - uses: actions/checkout@v4 - -# INSTALL DEPENDENCIES ---------------- - - name: Setup PHP, extensions and composer with shivammathur/setup-php - uses: shivammathur/setup-php@verbose - with: - php-version: ${{ matrix.php-versions }} - tools: composer:2.2 - extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json - - - name: Setup Node.js - uses: actions/setup-node@v4 - with: - node-version: '20.11.0' - - - name: Get composer cache directory - id: composer-cache - run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_ENV - - - name: Cache composer dependencies - uses: actions/cache@v4 - with: - path: | - ${{ env.dir }} - ./vendor - key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} - restore-keys: ${{ runner.os }}-composer- - -# INSTALL PACKAGES ---------------- - - name: Clean node_modules - run: rm -rf node_modules - - - name: Install NPM packages - run: npm ci - - - name: Install Composer dependencies - run: composer install --no-progress --prefer-dist --optimize-autoloader - - -# UPLOAD CACHED DIRECTORIES ---------------- - - name: Upload Vendor Directory as Artifact - uses: actions/upload-artifact@v4 - with: - name: vendor-dir - path: vendor/ - - phpStan: - needs: setup - runs-on: ubuntu-22.04 - steps: - - uses: actions/checkout@v4 - -# GET CACHED DIRECTORIES ---------------- - - name: Download Vendor Directory - uses: actions/download-artifact@v4 - with: - name: vendor-dir - path: vendor/ - -# INSTALL DEPENDENCIES ---------------- - - name: Setup PHP, extensions and composer with shivammathur/setup-php - uses: shivammathur/setup-php@verbose - with: - php-version: ${{ matrix.php-versions }} - tools: composer:2.2 - extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json - - - name: Set executable permissions for PHPStan - run: chmod +x ./vendor/bin/phpstan - -# RUN PHPSTAN ---------------- - - name: Run PHPStan - run: ./vendor/bin/phpstan analyse src - - - symfony-tests: - needs: setup - runs-on: ubuntu-22.04 - steps: - - uses: actions/checkout@v4 - -# GET CACHED DIRECTORIES ---------------- - - name: Download Vendor Directory - uses: actions/download-artifact@v4 - with: - name: vendor-dir - path: vendor/ - -# INSTALL DEPENDENCIES ---------------- - - name: Install MySQL Client - run: sudo apt-get update && sudo apt-get install -y mysql-client - - - name: Setup PHP, extensions and composer with shivammathur/setup-php - uses: shivammathur/setup-php@verbose - with: - php-version: ${{ matrix.php-versions }} - tools: composer:2.2 - extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json - -# SET ENVIRONMENT VARIABLES ---------------- - - name: Set up test environment variables - run: cp .env.test .env - -# START SERVICES ---------------- - - name: Set up MySQL - uses: getong/mariadb-action@v1.1 - with: - host port: 3306 # Optional, default value is 3306. The port of host - container port: 3306 # Optional, default value is 3306. The port of container - character set server: 'utf8mb4' # Optional, default value is 'utf8mb4'. The '--character-set-server' option for mysqld - collation server: 'utf8mb4_general_ci' # Optional, default value is 'utf8mb4_general_ci'. The '--collation-server' option for mysqld - mariadb version: '10.4.10' # Optional, default value is "latest". The version of the MySQL - mysql database: 'symfony' # Optional, default value is "test". The specified database which will be created - mysql root password: 'secret' # Required if "mysql user" is empty, default is empty. The root superuser password - mysql user: 'user' # Required if "mysql root password" is empty, default is empty. The superuser for the specified database. Can use secrets, too - mysql password: 'password' # Required if "mysql user" exists. The password for the "mysql user" - - - name: Wait for MySQL to become available - run: | - until mysql -h 127.0.0.1 -u root -psecret -e "SELECT 1"; do - echo 'Waiting for MySQL...' - sleep 1 - done - -# RUN MIGRATIONS ---------------- - - name: Run migrations - run: php bin/console doctrine:migrations:migrate --no-interaction - -# RUN TESTS ---------------- - - name: Run unit and functional tests - run: | - php ./vendor/bin/phpunit --configuration phpunit.xml.dist - - - cypress-tests: - needs: setup - runs-on: ubuntu-22.04 - steps: - - uses: actions/checkout@v4 - -# GET CACHED DIRECTORIES ---------------- - - name: Download Vendor Directory - uses: actions/download-artifact@v4 - with: - name: vendor-dir - path: vendor/ - -# INSTALL DEPENDENCIES ---------------- - - name: Install MySQL Client - run: sudo apt-get update && sudo apt-get install -y mysql-client - - - name: Install Cypress dependencies - run: sudo apt-get install -y xvfb libgtk2.0-0 libgtk-3-0 libgbm-dev libnotify-dev libnss3 libxss1 libasound2 libxtst6 xauth - - - name: Setup PHP, extensions and composer with shivammathur/setup-php - uses: shivammathur/setup-php@verbose - with: - php-version: ${{ matrix.php-versions }} - tools: composer:2.2 - extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json - - - name: Setup Node.js - uses: actions/setup-node@v4 - with: - node-version: '20.11.0' - - - name: Install Symfony CLI globally - run: | - curl -sS https://get.symfony.com/cli/installer | bash - sudo mv /home/runner/.symfony5/bin/symfony /usr/local/bin/symfony - -# SET ENVIRONMENT VARIABLES ---------------- - - name: Set up test environment variables - run: cp .env.test .env - -# START SERVICES ---------------- - - name: Set up MySQL - uses: getong/mariadb-action@v1.1 - with: - host port: 3306 # Optional, default value is 3306. The port of host - container port: 3306 # Optional, default value is 3306. The port of container - character set server: 'utf8mb4' # Optional, default value is 'utf8mb4'. The '--character-set-server' option for mysqld - collation server: 'utf8mb4_general_ci' # Optional, default value is 'utf8mb4_general_ci'. The '--collation-server' option for mysqld - mariadb version: '10.4.10' # Optional, default value is "latest". The version of the MySQL - mysql database: 'symfony' # Optional, default value is "test". The specified database which will be created - mysql root password: 'secret' # Required if "mysql user" is empty, default is empty. The root superuser password - mysql user: 'user' # Required if "mysql root password" is empty, default is empty. The superuser for the specified database. Can use secrets, too - mysql password: 'password' # Required if "mysql user" exists. The password for the "mysql user" - - - name: Wait for MySQL to become available - run: | - until mysql -h 127.0.0.1 -u root -psecret -e "SELECT 1"; do - echo 'Waiting for MySQL...' - sleep 1 - done - - - name: Start Symfony server - run: symfony server:start --no-tls -d --port=8000 - -# RUN MIGRATIONS ---------------- - - name: Run migrations - run: php bin/console doctrine:migrations:migrate --no-interaction - -# FILL DATABASE ---------------- - - name: Run fixture - run: php bin/console doctrine:fixtures:load --no-interaction - -# BUILD FRONT ---------------- - - name : install packages - run: npm install - - - name: Enable verbose npm logging - run: npm config set loglevel verbose - - - name: Build front-end assets - run: ./node_modules/.bin/encore production --progress - -# RUN CYPRESS TESTS ---------------- - - name: Run Cypress tests - run: CYPRESS_BASE_URL=http://localhost:8000 npm run cy:test:main - - -# CHANGE ENV VARIABLES ---------------- - - name: Set up test environment variables - run: cp .env.oidc.test .env.test - -# START KEYCLOAK ---------------- - - name: Start Keycloak - run: | - docker run -d \ - --name keycloak \ - -e KEYCLOAK_USER=admin \ - -e KEYCLOAK_PASSWORD=admin \ - -e DB_VENDOR=h2 \ - -e KEYCLOAK_IMPORT=/config/realm-export.json \ - -v ${{ github.workspace }}/.docker/keycloak/config/realm-export.localhost.json:/config/realm-export.json \ - -p 8080:8080 \ - --user root \ - jboss/keycloak:16.1.1 - -# Wait for Keycloak to start - - name: Wait for Keycloak to be ready - run: | - until $(curl --output /dev/null --silent --head --fail http://localhost:8080/auth); do - printf '.' - sleep 5 - done - - # RUN CYPRESS TESTS ---------------- - - name: Run Cypress tests - run: CYPRESS_BASE_URL=http://localhost:8000 CYPRESS_KEYCLOAK_URL=http://localhost:8080 npm run cy:test:oidc - diff --git a/.github/workflows/ci-test3.yaml b/.github/workflows/ci-test3.yaml deleted file mode 100644 index 3e9f6e75f..000000000 --- a/.github/workflows/ci-test3.yaml +++ /dev/null @@ -1,281 +0,0 @@ -name: Integration and Functional tests - -on: - pull_request: - branches: - - master - - staging - - dev - -jobs: - setup: - runs-on: ubuntu-22.04 - strategy: - fail-fast: true - matrix: - php-versions: ['7.4'] - steps: -# REMOVE RESIDUAL CONTAINERS ( for local debug with act only ) - - name: Remove all mysql containers when working with act - if: ${{ env.ACT }} - run: | - CONTAINERS=$(docker ps -a -q --filter ancestor=mariadb:10.4.10) - if [ ! -z "$CONTAINERS" ]; then - docker rm -f $CONTAINERS - else - echo "No containers to remove." - fi - - - name: Checkout code - uses: actions/checkout@v4 - -# INSTALL DEPENDENCIES ---------------- - - name: Setup PHP, extensions and composer with shivammathur/setup-php - uses: shivammathur/setup-php@verbose - with: - php-version: ${{ matrix.php-versions }} - tools: composer:2.2 - extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json - - - name: Setup Node.js - uses: actions/setup-node@v4 - with: - node-version: '20.11.0' - - - name: Get composer cache directory - id: composer-cache - run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_ENV - - - name: Cache composer dependencies - uses: actions/cache@v4 - with: - path: | - ${{ env.dir }} - ./vendor - key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} - restore-keys: ${{ runner.os }}-composer- - -# INSTALL PACKAGES ---------------- - - name: Clean node_modules - run: rm -rf node_modules - - - name: Install NPM packages - run: npm ci - - - name: Install Composer dependencies - run: composer install --no-progress --prefer-dist --optimize-autoloader - - -# UPLOAD CACHED DIRECTORIES ---------------- - - name: Upload Vendor Directory as Artifact - uses: actions/upload-artifact@v4 - with: - name: vendor-dir - path: vendor/ - - phpStan: - needs: setup - runs-on: ubuntu-22.04 - steps: - - uses: actions/checkout@v4 - -# GET CACHED DIRECTORIES ---------------- - - name: Download Vendor Directory - uses: actions/download-artifact@v4 - with: - name: vendor-dir - path: vendor/ - -# INSTALL DEPENDENCIES ---------------- - - name: Setup PHP, extensions and composer with shivammathur/setup-php - uses: shivammathur/setup-php@verbose - with: - php-version: ${{ matrix.php-versions }} - tools: composer:2.2 - extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json - - - name: Set executable permissions for PHPStan - run: chmod +x ./vendor/bin/phpstan - -# RUN PHPSTAN ---------------- - - name: Run PHPStan - run: ./vendor/bin/phpstan analyse src - - - symfony-tests: - needs: setup - runs-on: ubuntu-22.04 - steps: - - uses: actions/checkout@v4 - -# GET CACHED DIRECTORIES ---------------- - - name: Download Vendor Directory - uses: actions/download-artifact@v4 - with: - name: vendor-dir - path: vendor/ - -# INSTALL DEPENDENCIES ---------------- - - name: Install MySQL Client - run: sudo apt-get update && sudo apt-get install -y mysql-client - - - name: Setup PHP, extensions and composer with shivammathur/setup-php - uses: shivammathur/setup-php@verbose - with: - php-version: ${{ matrix.php-versions }} - tools: composer:2.2 - extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json - -# SET ENVIRONMENT VARIABLES ---------------- - - name: Set up test environment variables - run: cp .env.test .env - -# START SERVICES ---------------- - - name: Set up MySQL - uses: getong/mariadb-action@v1.1 - with: - host port: 3306 # Optional, default value is 3306. The port of host - container port: 3306 # Optional, default value is 3306. The port of container - character set server: 'utf8mb4' # Optional, default value is 'utf8mb4'. The '--character-set-server' option for mysqld - collation server: 'utf8mb4_general_ci' # Optional, default value is 'utf8mb4_general_ci'. The '--collation-server' option for mysqld - mariadb version: '10.4.10' # Optional, default value is "latest". The version of the MySQL - mysql database: 'symfony' # Optional, default value is "test". The specified database which will be created - mysql root password: 'secret' # Required if "mysql user" is empty, default is empty. The root superuser password - mysql user: 'user' # Required if "mysql root password" is empty, default is empty. The superuser for the specified database. Can use secrets, too - mysql password: 'password' # Required if "mysql user" exists. The password for the "mysql user" - - - name: Wait for MySQL to become available - run: | - until mysql -h 127.0.0.1 -u root -psecret -e "SELECT 1"; do - echo 'Waiting for MySQL...' - sleep 1 - done - -# RUN MIGRATIONS ---------------- - - name: Run migrations - run: php bin/console doctrine:migrations:migrate --no-interaction - -# RUN TESTS ---------------- - - name: Run unit and functional tests - run: | - php ./vendor/bin/phpunit --configuration phpunit.xml.dist - - - cypress-tests: - needs: setup - runs-on: ubuntu-22.04 - steps: - - uses: actions/checkout@v4 - -# GET CACHED DIRECTORIES ---------------- - - name: Download Vendor Directory - uses: actions/download-artifact@v4 - with: - name: vendor-dir - path: vendor/ - -# INSTALL DEPENDENCIES ---------------- - - name: Install MySQL Client - run: sudo apt-get update && sudo apt-get install -y mysql-client - - - name: Install Cypress dependencies - run: sudo apt-get install -y xvfb libgtk2.0-0 libgtk-3-0 libgbm-dev libnotify-dev libnss3 libxss1 libasound2 libxtst6 xauth - - - name: Setup PHP, extensions and composer with shivammathur/setup-php - uses: shivammathur/setup-php@verbose - with: - php-version: ${{ matrix.php-versions }} - tools: composer:2.2 - extensions: mbstring, xml, ctype, iconv, intl, pdo_mysql, dom, filter, gd, iconv, json - - - name: Setup Node.js - uses: actions/setup-node@v4 - with: - node-version: '20.11.0' - - - name: Install Symfony CLI globally - run: | - curl -sS https://get.symfony.com/cli/installer | bash - sudo mv /home/runner/.symfony5/bin/symfony /usr/local/bin/symfony - -# SET ENVIRONMENT VARIABLES ---------------- - - name: Set up test environment variables - run: cp .env.test .env - -# START SERVICES ---------------- - - name: Set up MySQL - uses: getong/mariadb-action@v1.1 - with: - host port: 3306 # Optional, default value is 3306. The port of host - container port: 3306 # Optional, default value is 3306. The port of container - character set server: 'utf8mb4' # Optional, default value is 'utf8mb4'. The '--character-set-server' option for mysqld - collation server: 'utf8mb4_general_ci' # Optional, default value is 'utf8mb4_general_ci'. The '--collation-server' option for mysqld - mariadb version: '10.4.10' # Optional, default value is "latest". The version of the MySQL - mysql database: 'symfony' # Optional, default value is "test". The specified database which will be created - mysql root password: 'secret' # Required if "mysql user" is empty, default is empty. The root superuser password - mysql user: 'user' # Required if "mysql root password" is empty, default is empty. The superuser for the specified database. Can use secrets, too - mysql password: 'password' # Required if "mysql user" exists. The password for the "mysql user" - - - name: Wait for MySQL to become available - run: | - until mysql -h 127.0.0.1 -u root -psecret -e "SELECT 1"; do - echo 'Waiting for MySQL...' - sleep 1 - done - - - name: Start Symfony server - run: symfony server:start --no-tls -d --port=8000 - -# RUN MIGRATIONS ---------------- - - name: Run migrations - run: php bin/console doctrine:migrations:migrate --no-interaction - -# FILL DATABASE ---------------- - - name: Run fixture - run: php bin/console doctrine:fixtures:load --no-interaction - -# BUILD FRONT ---------------- - - name : install packages - run: npm install - - - name: Enable verbose npm logging - run: npm config set loglevel verbose - - - name: Build front-end assets - run: ./node_modules/.bin/encore production --progress - -# RUN CYPRESS TESTS ---------------- - - name: Run Cypress tests - run: CYPRESS_BASE_URL=http://localhost:8000 npm run cy:test:main - - -# CHANGE ENV VARIABLES ---------------- - - name: Set up test environment variables - run: cp .env.oidc.test .env.test - -# START KEYCLOAK ---------------- - - name: Start Keycloak - run: | - docker run -d \ - --name keycloak \ - -e KEYCLOAK_USER=admin \ - -e KEYCLOAK_PASSWORD=admin \ - -e DB_VENDOR=h2 \ - -e KEYCLOAK_IMPORT=/config/realm-export.json \ - -v ${{ github.workspace }}/.docker/keycloak/config/realm-export.localhost.json:/config/realm-export.json \ - -p 8080:8080 \ - --user root \ - jboss/keycloak:16.1.1 - -# Wait for Keycloak to start - - name: Wait for Keycloak to be ready - run: | - until $(curl --output /dev/null --silent --head --fail http://localhost:8080/auth); do - printf '.' - sleep 5 - done - - # RUN CYPRESS TESTS ---------------- - - name: Run Cypress tests - run: CYPRESS_BASE_URL=http://localhost:8000 npx cypress run --spec 'cypress/e2e/keycloak/**/*' --env CYPRESS_KEYCLOAK_URL=http://localhost:8080 - diff --git a/.github/workflows/ci-test4.yaml b/.github/workflows/ci-test4.yaml deleted file mode 100644 index c0ec40be7..000000000 --- a/.github/workflows/ci-test4.yaml +++ /dev/null @@ -1,34 +0,0 @@ -name: Integration and Functional tests - -on: - pull_request: - branches: - - master - - staging - - dev - -jobs: - setup: - runs-on: ubuntu-22.04 - strategy: - fail-fast: true - matrix: - php-versions: ['7.4'] - steps: - - name: Checkout code - uses: actions/checkout@v4 - - - name: Install Cypress dependencies - run: sudo apt update && sudo apt-get install -y xvfb libgtk2.0-0 libgtk-3-0 libgbm-dev libnotify-dev libnss3 libxss1 libasound2 libxtst6 xauth - -# RUN CYPRESS TESTS ---------------- - - name: Run Cypress keycloak tests - uses: cypress-io/github-action@v6 - with: - start: npx http-server -p 8000 -c-1 - command: npm run cy:test:oidc - env: - CYPRESS_BASE_URL: http://localhost:8000 - CYPRESS_KEYCLOAK_URL: http://localhost:8080 - - diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 9f334cd6e..8aab710f4 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -276,12 +276,6 @@ jobs: done # RUN CYPRESS TESTS ---------------- - - name: Run Cypress keycloak tests - uses: cypress-io/github-action@v6 - with: - command: npm run cy:test:oidc - env: - CYPRESS_BASE_URL: http://localhost:8000 - CYPRESS_KEYCLOAK_URL: http://localhost:8080 - + - name: Run Cypress tests + run: CYPRESS_BASE_URL=http://localhost:8000 CYPRESS_KEYCLOAK_URL=http://localhost:8080 npm run cy:test:oidc diff --git a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js index 3a5863575..e0bc509e7 100644 --- a/cypress/e2e/keycloak/admin/admin1_can_login.cy.js +++ b/cypress/e2e/keycloak/admin/admin1_can_login.cy.js @@ -13,28 +13,7 @@ Cypress.on('uncaught:exception', (err, runnable) => { describe('admin1 can login', function () { it('admin story', function () { - cy.visit("/") - cy.get('#login').click() - - cy.visit("/") - cy.get('#login').click() - - cy.origin(keycloakUrl, { args: { keycloakUrl } }, ({ keycloakUrl }) => { - cy.log("fill in the login form") - cy.get('#username').type('admin1', {force: true}) - cy.get('#password').type('password', {force: true}) - - // submit - cy.get('#kc-login').click() - - cy.location().then((location) => { - if (location !== null && location.origin === keycloakUrl) { - cy.get('#kc-login').click() - } else { - cy.log("not asked for access to user data") - } - }) - }) + login(keycloakUrl, 'admin1', 'password'); cy.log('home page banner contains "admin"') cy.get('[data-cy=home_welcome_message]').contains('admin') diff --git a/cypress/e2e/keycloak/keycloak_reusables.cytools.js b/cypress/e2e/keycloak/keycloak_reusables.cytools.js index 8ea986b53..90186d914 100644 --- a/cypress/e2e/keycloak/keycloak_reusables.cytools.js +++ b/cypress/e2e/keycloak/keycloak_reusables.cytools.js @@ -4,7 +4,7 @@ export function login(keycloakUrl, username, password) { cy.visit("/") cy.get('#login').click() - cy.origin(keycloakUrl, { args : { username, password }}, ({ username, password }) => { + cy.origin(keycloakUrl, { args : { username, password, keycloakUrl }}, ({ username, password, keycloakUrl }) => { cy.log("fill in the login form") cy.get('#username').type(username, {force: true}) cy.get('#password').type(password, {force: true}) From fd59248a4b57244bebee02c9d9ee747928f7205f Mon Sep 17 00:00:00 2001 From: sam Date: Sun, 25 Feb 2024 15:29:13 +0100 Subject: [PATCH 19/19] remove cypress.env.json --- cypress.env.json | 3 --- 1 file changed, 3 deletions(-) delete mode 100644 cypress.env.json diff --git a/cypress.env.json b/cypress.env.json deleted file mode 100644 index 1fc4c2b29..000000000 --- a/cypress.env.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "KEYCLOAK_URL": "http://localhost:8080" -} \ No newline at end of file