diff options
Diffstat (limited to 'phosphor-ldap-config/ldap_configuration.hpp')
-rw-r--r-- | phosphor-ldap-config/ldap_configuration.hpp | 31 |
1 files changed, 10 insertions, 21 deletions
diff --git a/phosphor-ldap-config/ldap_configuration.hpp b/phosphor-ldap-config/ldap_configuration.hpp index 6601bd2..034aab8 100644 --- a/phosphor-ldap-config/ldap_configuration.hpp +++ b/phosphor-ldap-config/ldap_configuration.hpp @@ -53,7 +53,7 @@ class Config : public ConfigIface * @param[in] lDAPServerURI - LDAP URI of the server. * @param[in] lDAPBindDN - distinguished name with which to bind. * @param[in] lDAPBaseDN - distinguished name to use as search base. - * @param[in] lDAPBindDNpassword - credentials with which to bind. + * @param[in] lDAPBindDNPassword - credentials with which to bind. * @param[in] lDAPSearchScope - the search scope. * @param[in] lDAPType - Specifies the LDAP server type which can be AD or openLDAP. @@ -62,25 +62,17 @@ class Config : public ConfigIface Config(sdbusplus::bus::bus& bus, const char* path, const char* filePath, bool secureLDAP, std::string lDAPServerURI, std::string lDAPBindDN, - std::string lDAPBaseDN, std::string lDAPBindDNpassword, + std::string lDAPBaseDN, std::string&& lDAPBindDNPassword, ldap_base::Config::SearchScope lDAPSearchScope, ldap_base::Config::Type lDAPType, ConfigMgr& parent); using ConfigIface::lDAPBaseDN; using ConfigIface::lDAPBindDN; - using ConfigIface::lDAPBINDDNpassword; using ConfigIface::lDAPSearchScope; using ConfigIface::lDAPServerURI; using ConfigIface::lDAPType; - using ConfigIface::secureLDAP; using ConfigIface::setPropertyByName; - /** @brief Update the secure LDAP property. - * @param[in] value - secureLDAP value to be updated. - * @returns value of changed secureLDAP. - */ - bool secureLDAP(bool value) override; - /** @brief Update the Server URI property. * @param[in] value - lDAPServerURI value to be updated. * @returns value of changed lDAPServerURI. @@ -99,12 +91,6 @@ class Config : public ConfigIface */ std::string lDAPBaseDN(std::string value) override; - /** @brief Update the BindDN password property. - * @param[in] value - lDAPBINDDNpassword value to be updated. - * @returns value of changed lDAPBINDDNpassword. - */ - std::string lDAPBINDDNpassword(std::string value) override; - /** @brief Update the Search scope property. * @param[in] value - lDAPSearchScope value to be updated. * @returns value of changed lDAPSearchScope. @@ -122,8 +108,11 @@ class Config : public ConfigIface */ void delete_() override; + bool secureLDAP; + private: std::string configFilePath{}; + std::string lDAPBindDNPassword{}; /** @brief Persistent sdbusplus D-Bus bus connection. */ sdbusplus::bus::bus& bus; @@ -174,20 +163,19 @@ class ConfigMgr : public CreateIface /** @brief concrete implementation of the pure virtual funtion xyz.openbmc_project.User.Ldap.Create.createConfig. - * @param[in] secureLDAP - Specifies whether to use SSL or not. * @param[in] lDAPServerURI - LDAP URI of the server. * @param[in] lDAPBindDN - distinguished name with which bind to bind to the directory server for lookups. * @param[in] lDAPBaseDN - distinguished name to use as search base. - * @param[in] lDAPBindDNpassword - credentials with which to bind. + * @param[in] lDAPBindDNPassword - credentials with which to bind. * @param[in] lDAPSearchScope - the search scope. * @param[in] lDAPType - Specifies the LDAP server type which can be AD or openLDAP. * @returns the object path of the D-Bus object created. */ - std::string createConfig(bool secureLDAP, std::string lDAPServerURI, - std::string lDAPBindDN, std::string lDAPBaseDN, - std::string lDAPBindDNpassword, + std::string createConfig(std::string lDAPServerURI, std::string lDAPBindDN, + std::string lDAPBaseDN, + std::string lDAPBindDNPassword, ldap_base::Create::SearchScope lDAPSearchScope, ldap_base::Create::Type lDAPType) override; @@ -206,6 +194,7 @@ class ConfigMgr : public CreateIface void deleteObject(); private: + std::string configFilePath{}; /** @brief Persistent sdbusplus D-Bus bus connection. */ sdbusplus::bus::bus& bus; |