mirror of
https://git.openldap.org/openldap/openldap.git
synced 2026-01-19 13:23:44 -05:00
ITS#2570 - don't permanently give up on TLS due to transient failures
This commit is contained in:
parent
5083977fee
commit
d31a3fb981
1 changed files with 3 additions and 2 deletions
|
|
@ -763,6 +763,7 @@ do_bind(
|
|||
)
|
||||
{
|
||||
int ldrc;
|
||||
int do_tls = ri->ri_tls;
|
||||
|
||||
*lderr = 0;
|
||||
|
||||
|
|
@ -885,7 +886,7 @@ retry:
|
|||
}
|
||||
ldap_set_option(ri->ri_ldp, LDAP_OPT_RESTART, LDAP_OPT_ON);
|
||||
|
||||
if( ri->ri_tls ) {
|
||||
if( do_tls ) {
|
||||
int err = ldap_start_tls_s(ri->ri_ldp, NULL, NULL);
|
||||
|
||||
if( err != LDAP_SUCCESS ) {
|
||||
|
|
@ -907,7 +908,7 @@ retry:
|
|||
ri->ri_ldp = NULL;
|
||||
return BIND_ERR_TLS_FAILED;
|
||||
}
|
||||
ri->ri_tls = TLS_OFF;
|
||||
do_tls = TLS_OFF;
|
||||
goto retry;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue