How to send Decrypted Password from ServiceNow

Hemasundar_B
Tera Contributor

Hello Community,

We have a requirement to send the generated password to users after they click "Set Password" on the contact record. However, the password is stored in an encrypted format in the user_password field. Currently, we are sending the encrypted password, which prevents users from logging in.
Here’s the script we are using: Before update BR
gs.eventQueue("new.contact.password.set", current, current.user_password, current.email);
Since ServiceNow encrypts passwords and does not allow decryption, what would be the best approach to send a usable password to users?

3 REPLIES 3

Vishal Jaswal
Giga Sage

Hemasundar_B
Tera Contributor

Is there an alternative way to send the actual password to the user?

Hello @Hemasundar_B 

Capture the username and password in a pdf and attach it to the e-mail. 


Hope that helps!