Emmanuel Lecharny wrote:
Hi,
when the client issue a first BindRequest, the messageId will be '1'. It
will start a new LdapSession on the server, with all the subsequent
operations having an incremented messageId. The clinet is responsible
for the ID generation.
Now, if the client issue a new BindRequest, should the messageId be
incremented, or reset to 1 ? My understanding is that we are stil in the
same LdapSession, with a request for new credentials, and we then need
to use an incremented ID.
Agreed, that's what we do. RFC4511 section 4.1.1.1 says the messageID must not
be reused within an LDAP session.
For instance, in this scenario, where the ID is in parentheses after the
request :
Bind(1)
Search(2)
Search(3)
Bind(XXX)
the XXX should be 4.
Now, that raise another question : whet should we do with the responses
to (3), assuming we haven't received all of it ? Should we discard them
? My understanding is that they are still valid.
This is spelled out in RFC4511 section 4.2.1.
--
-- Howard Chu
CTO, Symas Corp. http://www.symas.com
Director, Highland Sun http://highlandsun.com/hyc/
Chief Architect, OpenLDAP http://www.openldap.org/project/