Class PasswordCredential

java.lang.Object
com.atlassian.crowd.embedded.api.PasswordCredential
All Implemented Interfaces:
Serializable

public class PasswordCredential extends Object implements Serializable
Password based authentication information.
See Also:
  • Field Details

    • NONE

      public static final PasswordCredential NONE
    • SANITISED_PASSWORD

      public static final String SANITISED_PASSWORD
      String that substitutes the real password in contexts where it cannot be displayed.
      See Also:
    • credential

      protected String credential
  • Constructor Details

    • PasswordCredential

      @Deprecated public PasswordCredential()
      Deprecated.
      since 1.3.2, please use any other PasswordCredential constructor, this constructor should only be used by hibernate. If this constructor is used, please be aware that you must set setEncryptedCredential(boolean)
      Default constructor used by hibernate
    • PasswordCredential

      public PasswordCredential(PasswordCredential passwordCredential)
    • PasswordCredential

      public PasswordCredential(String unencryptedCredential)
      Constructor that takes an unencrypted credential. ie encryptedCredential is false.
      Parameters:
      unencryptedCredential - the unencrypted password credential
    • PasswordCredential

      public PasswordCredential(String credential, boolean encryptedCredential)
  • Method Details

    • encrypted

      public static PasswordCredential encrypted(String encryptedCredential)
    • unencrypted

      public static PasswordCredential unencrypted(String unencryptedCredential)
    • getCredential

      public String getCredential()
      Gets the password credential.
      Returns:
      The credential.
    • setCredential

      public void setCredential(String credential)
      Deprecated.
      create a new instance rather than mutating.
      Sets the password credential.
      Parameters:
      credential - The credential.
    • isEncryptedCredential

      public boolean isEncryptedCredential()
    • setEncryptedCredential

      @Deprecated public void setEncryptedCredential(boolean encryptedCredential)
      Deprecated.
      create a new instance rather than mutating.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object