Password Encryption and Decryption Using jBCrypt
In this article, we will take a look into how to generate random passwords that have alphanumeric and special characters and encrypt it using the one-way hash algorithm, jBCrypt.
Generating a Random Password
I’ll use the Passay library to generate random passwords having alphanumeric and special characters. The following code block is a sample code to generate a random password using the Passay library. It also allows you to configure the character length of the resultant password.
via DZone.com Feed https://dzone.com
May 20, 2017 at 07:09AM