Camunda DB: Add new User via SQL

Hello,

I am trying to manually create a user in the Camunda 7 database and set the password for a user. I want to make sure that the password is correctly hashed and salted so that it is accepted by Camunda.

Procedure:

  1. Generate salt: First, I generate a random 16-byte salt value that is base64 encoded. This salt value is stored in the salt_ column of the ACT_ID_USER table in the Camunda database.

  2. Password hash: The password is hashed together with the Base64-decoded salt value using the SHA-512 algorithm. The result is stored in the pwd_ column of the ACT_ID_USER table of the database. The hash is saved in the format {SHA-512}hashedPassword.

hashSHA512(password + salt)

  1. Set rev_ , names / email

Password: test123456
Salt: hizsxOgmHufR6BFLui24YQ== (Base64-encoded)
Hash: {SHA-512}fggIdzB1Fg9jOA7thTTzuI8hJfxtU9Lhtl7APlIX1yk1gEbMBjtONM4LL1yWNUTrBgnh+OgHfkpqDTZoncrUQA==

Unfortunately, I cannot log in with this user. I have also assigned a group to the user. If I use a known pwd_ and salt_, which was generated by camunda, the login works.

can you tell me how to do it right?

Instead of using the Database i use now the Camunda API. Hows for me at the same way :slight_smile:

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.