public String encryptPassWord(String password){ BasicPasswordEncryptor bpe = new BasicPasswordEncryptor(); return bpe.encryptPassword([password]) }
public boolean checkPassWord(String newPass, oldPass){ BasicPasswordEncryptor bpe = new BasicPasswordEncryptor(); bpe.checkPassword(newPass, oldPass); }
Real easy to implement.
Returns a hashed string for storage. An additional method compares the already hashed string with a new string.