Genesys CTI User Forum

Genesys CTI User Forum => Genesys CTI Technical Discussion => Topic started by: DANIEL.DOUSSET on March 02, 2021, 01:45:02 PM

Title: Decrypt Person Passord
Post by: DANIEL.DOUSSET on March 02, 2021, 01:45:02 PM
Hello i'm writin a programme to copy Person config from an install of Genesys to a new install.
I arrive to read all information but the password is crypted and i don't found a function to decrypt this password for the new person in the new config.

                    objects = confService.retrieveObject(ICfgObject.class, myQuery);
                    CfgPerson thePerson=(CfgPerson)objects; 
                    int passwordHashAlgorithm=thePerson.getPasswordHashAlgorithm();
                    String password=thePerson.getPassword();

I obtain those informations but i can't find how decrypt  their.

'password' [str] = "C221F5B008E433C8445D500894D54104FDB108A3CB265E716717538B69FE73E2"
'passwordHashAlgorithm' [int] = 1

Can you help me ?
Thank you


Title: Re: Decrypt Person Passord
Post by: René on March 03, 2021, 08:33:42 AM
Hi Daniel,

As far as I know password stored in Genesys Configuration DB is not password itself (even encrypted) but its hash. It means you cannot retrieve (recover) password from configuration.

Please see 'Password Encryption' section for more details - [url=https://docs.genesys.com/Documentation/System/8.5.x/SDG/UserPswds]https://docs.genesys.com/Documentation/System/8.5.x/SDG/UserPswds[/url]

R.
Title: Re: Decrypt Person Passord
Post by: hsujdik on March 03, 2021, 12:31:26 PM
[quote author=René link=topic=11965.msg53788#msg53788 date=1614760422]
Hi Daniel,

As far as I know password stored in Genesys Configuration DB is not password itself (even encrypted) but its hash. It means you cannot retrieve (recover) password from configuration.

Please see 'Password Encryption' section for more details - [url=https://docs.genesys.com/Documentation/System/8.5.x/SDG/UserPswds]https://docs.genesys.com/Documentation/System/8.5.x/SDG/UserPswds[/url]

R.
[/quote]

Yes, that is correct.

In 8+ framework the password is Hashed AND Salted. This cannot be reversed and is the security method for storing password hashes used by most of the systems.

However, up to 7.6, the password is only hashed in MD5 format (not salted). That means that, if you are trying to recover the password from a very old environment (up to 7.6), you might be able to do so by pasting the hash in a large online MD5 database and hope they have it reversed.
Title: Re: Decrypt Person Passord
Post by: DANIEL.DOUSSET on March 04, 2021, 07:20:06 AM
Thank you for your's answers
In this case, i put the username as password and force to change
Title: Re: Decrypt Person Passord
Post by: orel on September 01, 2022, 04:33:37 PM
Hello,

I am trying to find out the way passwords are secured. It seems like the Password column is equal to sha256(cleartextpassword,SALTED_STRING).
But i cannot compute it successfully on an example with known cleartext password.
Would you mind sharing the code snipet ? Maybe the SALTED_STRING is not fully taken into account.

Kind Regards.