Interface KeyringBackend

All Superinterfaces:
AutoCloseable
All Known Implementing Classes:
FreedesktopKeyringBackend, KWalletBackend, ModernOsxKeychainBackend, OsxKeychainBackend, WinCredentialStoreBackend

public interface KeyringBackend extends AutoCloseable

java-keyring backend interface.

  • Method Details

    • getPassword

      String getPassword(String service, String account) throws PasswordAccessException
      Gets password from key store.
      Parameters:
      service - Service name
      account - Account name
      Returns:
      Password related to specified service and account
      Throws:
      PasswordAccessException - Thrown when an error happened while getting password
    • setPassword

      void setPassword(String service, String account, String password) throws PasswordAccessException
      Sets password to key store.
      Parameters:
      service - Service name
      account - Account name
      password - Password
      Throws:
      PasswordAccessException - Thrown when an error happened while saving the password
    • deletePassword

      void deletePassword(String service, String account) throws PasswordAccessException
      Deletes password from keystore.
      Parameters:
      service - Service name
      account - Account name
      Throws:
      PasswordAccessException - Thrown when an error happened while deleting the password (including if it is not found).