Closed tkyjovsk closed 4 months ago
@tkyjovsk thanks a lot for adding this back in a proper way. I think we have to update the docs.
Ref., from last time when we modified them - https://github.com/keycloak/keycloak-benchmark/pull/751/files#diff-cdf53b413cfe9e2a53e09baeed0645f6744d883049fb1f458d6d8e4155921496L34
@tkyjovsk I am going to add the docs and test it.
Tested with different hashing algorithm values and iterations that are set for KC22, KC24, KC25 and users are created as expected in the specific realms.
argon2
pbkdf2-sha512
pbkdf2-sha256
> ./dataset-import.sh -a create-realms -r 1 -g argon2 -i 10 -c 100 -u 200 -l https://client.gh-keycloak-a-gh-keycloak-b-xxxxx.keycloak-benchmark.com/realms/master/dataset
Action: [create-realms]
Creating 1 realms with 100 clients and 200 users with 10 password-hashing iterations using the argon2 algorithm.
{"status":"Task started successfully","task":{"startTimeMs":"1713533453546","message":"Creation of 1 realms from realm-0 to realm-0"},"task-status-url":"https://client.gh-keycloak-a-gh-keycloak-b-xxxxx.keycloak-benchmark.com/realms/master/dataset/status"}
> ./dataset-import.sh -a create-realms -r 1 -g pbkdf2-sha512 -i 210000 -c 100 -u 200 -l https://client.gh-keycloak-a-gh-keycloak-b-xxxx.keycloak-benchmark.com/realms/master/dataset
Action: [create-realms]
Creating 1 realms with 100 clients and 200 users with 210000 password-hashing iterations using the pbkdf2-sha512 algorithm.
{"status":"Task started successfully","task":{"startTimeMs":"1713534853780","message":"Creation of 1 realms from realm-1 to realm-1"},"task-status-url":"https://client.gh-keycloak-a-gh-keycloak-b-xxxxx.keycloak-benchmark.com/realms/master/dataset/status"}
> ./dataset-import.sh -a create-realms -r 1 -g pbkdf2-sha256 -i 210000 -c 100 -u 200 -l https://client.gh-keycloak-a-gh-keycloak-b-xxxxx.keycloak-benchmark.com/realms/master/dataset
Action: [create-realms]
Creating 1 realms with 100 clients and 200 users with 210000 password-hashing iterations using the pbkdf2-sha256 algorithm.
{"status":"Task started successfully","task":{"startTimeMs":"1713535141813","message":"Creation of 1 realms from realm-2 to realm-2"},"task-status-url":"https://client.gh-keycloak-a-gh-keycloak-b-xxxx.keycloak-benchmark.com/realms/master/dataset/status"}
Added options
-g ALGORITHM
and-i ITERATIONS
to thedataset-import.sh
script for adjusting the realm password policy. Both are optional. TheDatasetResourceProvider
will only apply the options which were provided.