PMCORE-2597 Importing a configuration when the TLS certificate is not set- does not appears a message about it

This commit is contained in:
Roly Rudy Gutierrez Pinto
2021-01-04 10:25:32 -04:00
parent 5ee01f86de
commit a6e3cff4d7
5 changed files with 23 additions and 3 deletions

View File

@@ -504,7 +504,7 @@ class LdapAdvanced
* @param Array $aAuthSource the authsource data
* @return Object A object with the resulting ldap bind
*/
public function ldapConnection($aAuthSource)
public function ldapConnection($aAuthSource, &$resultLDAPStartTLS = false)
{
$pass = explode("_", $aAuthSource["AUTH_SOURCE_PASSWORD"]);
@@ -522,7 +522,7 @@ class LdapAdvanced
ldap_set_option($ldapcnn, LDAP_OPT_REFERRALS, 0);
if (isset($aAuthSource["AUTH_SOURCE_ENABLED_TLS"]) && $aAuthSource["AUTH_SOURCE_ENABLED_TLS"]) {
@ldap_start_tls($ldapcnn);
$resultLDAPStartTLS = @ldap_start_tls($ldapcnn);
$ldapServer = "TLS " . $ldapServer;
//$this->log($ldapcnn, "start tls");
}