Interface PasswordEncryptor

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      boolean checkPassword​(String plainPassword, String encryptedPassword)
      Checks an unencrypted (plain) password against an encrypted one (a digest) to see if they match.
      String encryptPassword​(String password)
      Encrypts (digests) a password.
    • Method Detail

      • encryptPassword

        String encryptPassword​(String password)
        Encrypts (digests) a password.
        Parameters:
        password - the password to be encrypted.
        Returns:
        the resulting digest.
      • checkPassword

        boolean checkPassword​(String plainPassword,
                              String encryptedPassword)
        Checks an unencrypted (plain) password against an encrypted one (a digest) to see if they match.
        Parameters:
        plainPassword - the plain password to check.
        encryptedPassword - the digest against which to check the password.
        Returns:
        true if passwords match, false if not.