code formatting

This commit is contained in:
Athou
2013-08-01 11:17:45 +02:00
parent 8df587aaad
commit 0ff1d58dfb
6 changed files with 11 additions and 13 deletions

View File

@@ -21,14 +21,12 @@ public class PasswordEncryptionService implements Serializable {
private static final Logger log = LoggerFactory.getLogger(UserDAO.class); private static final Logger log = LoggerFactory.getLogger(UserDAO.class);
public boolean authenticate(String attemptedPassword, public boolean authenticate(String attemptedPassword, byte[] encryptedPassword, byte[] salt) {
byte[] encryptedPassword, byte[] salt) {
// Encrypt the clear-text password using the same salt that was used to // Encrypt the clear-text password using the same salt that was used to
// encrypt the original password // encrypt the original password
byte[] encryptedAttemptedPassword = null; byte[] encryptedAttemptedPassword = null;
try { try {
encryptedAttemptedPassword = getEncryptedPassword( encryptedAttemptedPassword = getEncryptedPassword(attemptedPassword, salt);
attemptedPassword, salt);
} catch (Exception e) { } catch (Exception e) {
// should never happen // should never happen
log.error(e.getMessage(), e); log.error(e.getMessage(), e);