Class PasswordFile

java.lang.Object
net.officefloor.web.security.store.PasswordFile

public class PasswordFile extends Object
Contents of the password file.
Author:
Daniel Sagenschneider
  • Constructor Details

    • PasswordFile

      public PasswordFile(String algorithm)
      Initiate.
      Parameters:
      algorithm - Algorithm encrypting the password entry credentials.
  • Method Details

    • getAlgorithm

      public String getAlgorithm()
      Obtains the algorithm encrypting the credentials.
      Returns:
      Algorithm encrypting the credentials.
    • getEntry

      public PasswordEntry getEntry(String userId)
      Obtains the PasswordEntry for the user Id.
      Parameters:
      userId - User Id.
      Returns:
      PasswordEntry for the user Id or null if user Id not exist within this PasswordFile.
    • addEntry

      public void addEntry(String userId, byte[] credentials, Set<String> roles)
      Adds a PasswordEntry to this PasswordFile.
      Parameters:
      userId - User Id.
      credentials - Credentials of user.
      roles - Roles.