com.atlassian.crowd.integration.authentication
Class PasswordHelper

java.lang.Object
  extended by com.atlassian.crowd.integration.authentication.PasswordHelper

public class PasswordHelper
extends java.lang.Object

Various password helper methods.

Version:
1.0
Author:
Justen Stepka

Constructor Summary
PasswordHelper()
           
 
Method Summary
 boolean isUniquePassword(PasswordCredential newCredential, RemotePrincipal principal)
          Checks if the new credential has already been used by the the principal.
 void setI18nHelper(I18nHelper i18nHelper)
           
 void validateRegex(java.lang.String regex, PasswordCredential credential)
          Validates the password meets the expected regex restriction.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PasswordHelper

public PasswordHelper()
Method Detail

validateRegex

public void validateRegex(java.lang.String regex,
                          PasswordCredential credential)
                   throws InvalidCredentialException
Validates the password meets the expected regex restriction.

Parameters:
regex - The regex pattern.
credential - The password to check.
Throws:
InvalidCredentialException - The password failed the regex check.

isUniquePassword

public boolean isUniquePassword(PasswordCredential newCredential,
                                RemotePrincipal principal)
Checks if the new credential has already been used by the the principal.

Parameters:
newCredential - The new credential.
principal - The principal.
Returns:
boolean 'true' if the password is unique, false otherwise.

setI18nHelper

public void setI18nHelper(I18nHelper i18nHelper)


Copyright © 2009 Atlassian Pty Ltd. All Rights Reserved.