Class DefaultPropertiesPasswordManager

java.lang.Object
org.kawanfw.sql.api.server.auth.crypto.DefaultPropertiesPasswordManager
All Implemented Interfaces:
PropertiesPasswordManager

public class DefaultPropertiesPasswordManager
extends Object
implements PropertiesPasswordManager
This default implementation will extract the password from the "password" property of the file properties_password_manager.properties which must be located in the same directory as the aceql-server.properties file.

This default implementation is provided as is: password is not secured if an attacker gets access to the server.
Note that the getPassword() will return null if the file does not exists.

Author:
Nicolas de Pomereu
  • Constructor Details

    • DefaultPropertiesPasswordManager

      public DefaultPropertiesPasswordManager()
  • Method Details

    • getPassword

      public char[] getPassword() throws IOException, SQLException
      Returns the value of the "password" property contained in the file properties_password_manager.properties which must be located in the same directory as the aceql-server.properties file.
      Returns null if the file does not exist.
      Specified by:
      getPassword in interface PropertiesPasswordManager
      Returns:
      the password to use to decrypt the Properties of the aceql-server.properties file.
      Throws:
      IOException - if an IOException occurs
      SQLException - if a SQLException occurs