Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Joe Martin
OpenLDAP
Commits
ad84b995
Commit
ad84b995
authored
Apr 23, 2011
by
Howard Chu
Committed by
Quanah Gibson-Mount
Jun 08, 2011
Browse files
ITS#6909 blind fix. re-init creds for retry.
Move retry so that cred validity is also re-checked.
parent
886c6b10
Changes
1
Hide whitespace changes
Inline
Side-by-side
servers/slapd/back-meta/search.c
View file @
ad84b995
...
...
@@ -235,6 +235,10 @@ meta_search_dobind_init(
assert
(
msc
->
msc_ld
!=
NULL
);
/* connect must be async only the first time... */
ldap_set_option
(
msc
->
msc_ld
,
LDAP_OPT_CONNECT_ASYNC
,
LDAP_OPT_ON
);
retry:
;
if
(
!
BER_BVISEMPTY
(
&
binddn
)
&&
BER_BVISEMPTY
(
&
cred
)
)
{
/* bind anonymously? */
Debug
(
LDAP_DEBUG_ANY
,
"%s meta_search_dobind_init[%d] mc=%p: "
...
...
@@ -250,10 +254,6 @@ meta_search_dobind_init(
goto
other
;
}
/* connect must be async only the first time... */
ldap_set_option
(
msc
->
msc_ld
,
LDAP_OPT_CONNECT_ASYNC
,
LDAP_OPT_ON
);
retry:
;
rc
=
ldap_sasl_bind
(
msc
->
msc_ld
,
binddn
.
bv_val
,
LDAP_SASL_SIMPLE
,
&
cred
,
NULL
,
NULL
,
&
candidates
[
candidate
].
sr_msgid
);
...
...
@@ -327,6 +327,8 @@ down:;
if
(
rc
==
LDAP_SUCCESS
)
{
candidates
[
candidate
].
sr_msgid
=
META_MSGID_IGNORE
;
binddn
=
msc
->
msc_bound_ndn
;
cred
=
msc
->
msc_cred
;
goto
retry
;
}
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment