Implement encrypt_password