digesting flow (from original password to digest):
digesting flow (from original password to digest):
random salt byte array of length 8 ->
byte array of (salt + sha1(salt, password)) -> base64Encode
Verifies user input password with stored digest:
Verifies user input password with stored digest:
base64Decode -> extract salt -> do sha1(salt, password) -> generate digest: salt + sha1 -> compare the generated digest with the stored digest.
Util to verify whether user input password is valid or not. It use sha1 to do the digesting.