APIdia Launch Partner
Top Description Fields Constructors Methods
com.sun.jndi.ldap

public final Class LdapClient

extends Object
implements PooledConnection
Class Inheritance
All Implemented Interfaces
com.sun.jndi.ldap.pool.PooledConnection
Imports
java.io.*, java.util.ArrayList, .Locale, .Set, .Vector, .Hashtable, java.util.concurrent.locks.ReentrantLock, javax.naming.*, javax.naming.directory.*, javax.naming.ldap.*, com.sun.jndi.ldap.pool.PooledConnection, .PoolCallback, com.sun.jndi.ldap.sasl.LdapSasl, .SaslInputStream

LDAP (RFC-1777) and LDAPv3 (RFC-2251) compliant client This class represents a connection to an LDAP client. Callers interact with this class at an LDAP operation level. That is, the caller invokes a method to do a SEARCH or MODRDN operation and gets back the result. The caller uses the constructor to create a connection to the server. It then needs to use authenticate() to perform an LDAP BIND. Note that for v3, BIND is optional so authenticate() might not actually send a BIND. authenticate() can be used later on to issue a BIND, for example, for a v3 client that wants to change the connection's credentials.

Multiple LdapCtx might share the same LdapClient. For example, contexts derived from the same initial context would share the same LdapClient until changes to a context's properties necessitates its own LdapClient. LdapClient methods that access shared data are thread-safe (i.e., caller does not have to sync).

Fields: isLdapv3 - no sync; initialized and updated within sync authenticate(); always updated when connection is "quiet" and not shared; read access from outside LdapClient not sync referenceCount - sync within LdapClient; exception is forceClose() which is used by Connection thread to close connection upon receiving an Unsolicited Notification. access from outside LdapClient must sync; conn - no sync; Connection takes care of its own sync unsolicited - sync Vector; multiple operations sync'ed

Authors
Vincent Ryan, Jagane Sundar, Rosanna Lee

Field Summary

Modifier and TypeField and Description
pack-priv static final int
private boolean
pack-priv static final boolean
pack-priv final Connection
private static final int
private static final Set<String>
pack-priv static final int
private static final String
pack-priv boolean
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final int
pack-priv static final int
pack-priv static final String[]
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final String
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final String
pack-priv final ReentrantLock
private final PoolCallback
private final boolean
pack-priv int
pack-priv static final int
pack-priv static final int
pack-priv static final int
pack-priv static final int
private final Vector<LdapCtx>
private final ReentrantLock

Constructor Summary

AccessConstructor and Description
pack-priv
LdapClient(String host, int port, String socketFactory, int connectTimeout, int readTimeout, OutputStream trace, PoolCallback pcb)

Method Summary

Modifier and TypeMethod and Description
pack-priv LdapResult
add(LdapEntry entry, Control[] reqCtls)

pack-priv void
pack-priv LdapResult
authenticate(boolean initial, String name, Object pw, int version, String authMechanism, Control[] ctls, Hashtable<?, ?> env)

pack-priv boolean
pack-priv void
pack-priv void
close(Control[] reqCtls, boolean hardClose)

public void
closeConnection()

Implements com.sun.jndi.ldap.pool.PooledConnection.closeConnection.

Closes the physical connection.

pack-priv LdapResult
compare(String DN, String type, String value, Control[] reqCtls)

pack-priv LdapResult
delete(String DN, Control[] reqCtls)

private void
pack-priv static void
private static byte[]
encodePassword(Object pw, boolean v3)

Returns the encoded password.

private void
pack-priv LdapResult
extendedOp(String id, byte[] request, Control[] reqCtls, boolean pauseAfterReceipt)

protected void
finalize()

Overrides java.lang.Object.finalize.

Called by the garbage collector on an object when garbage collection determines that there are no more references to the object.

private void
forceClose(boolean cleanPool)

pack-priv static String
getErrorMessage(int errorCode, String errorMessage)

pack-priv static LdapClient
getInstance(boolean usePool, String hostname, int port, String factory, int connectTimeout, int readTimeout, OutputStream trace, int version, String authMechanism, Control[] ctls, String protocol, String user, Object passwd, Hashtable<?, ?> env)

pack-priv LdapResult
getSearchReply(int batchSize, LdapResult res, Hashtable<String, Boolean> binaryAttrs)

private LdapResult
getSearchReply(LdapRequest req, int batchSize, LdapResult res, Hashtable<String, Boolean> binaryAttrs)

private static boolean
pack-priv void
private boolean
isBinaryValued(String attrid, Hashtable<String, Boolean> binaryAttrs)

pack-priv boolean
public LdapResult
ldapBind(String
The possibly null DN to use in the BIND request. null if anonymous.
dn
,
byte[]
The possibly null array of bytes to send to the server.
toServer
,
Control[] bindCtls, String
The authentication mechanism
auth
,
boolean pauseAfterReceipt)

Sends an LDAP Bind request.

pack-priv LdapResult
moddn(String DN, String newrdn, boolean deleteOldRdn, String newSuperior, Control[] reqCtls)

pack-priv LdapResult
modify(String dn, int[] operations, Attribute[] attrs, Control[] reqCtls)

private void
private Attribute
private int
parseAttributeValue(BerDecoder ber, Attribute la, boolean hasBinaryValues)

pack-priv static Vector<Control>
private void
pack-priv static void
parseResult(BerDecoder replyBer, LdapResult res, boolean isLdapv3)

pack-priv void
processConnectionClosure()

Called by Connection.cleanup().

private LdapResult
processReply(LdapRequest req, LdapResult res, int responseType)

Reads the next reply corresponding to msgId, outstanding on requestBer.

pack-priv void
pack-priv void
pack-priv LdapResult
search(String dn, int scope, int deref, int sizeLimit, int timeLimit, boolean attrsOnly, String[] attrs, String filter, int batchSize, Control[] reqCtls, Hashtable<String, Boolean> binaryAttrs, boolean waitFirstReply, int replyQueueCapacity)

pack-priv boolean
usingSaslStreams()

Determines whether SASL encryption/integrity is in progress.

Inherited from java.lang.Object:
cloneequalsgetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

ADDback to summary
pack-priv static final int ADD
authenticateCalledback to summary
private boolean authenticateCalled
caseIgnoreback to summary
pack-priv static final boolean caseIgnore
connback to summary
pack-priv final Connection conn
debugback to summary
private static final int debug
defaultBinaryAttrsback to summary
private static final Set<String> defaultBinaryAttrs
DELETEback to summary
pack-priv static final int DELETE
DISCONNECT_OIDback to summary
private static final String DISCONNECT_OID
isLdapv3back to summary
pack-priv boolean isLdapv3
LBER_BITSTRINGback to summary
pack-priv static final int LBER_BITSTRING
LBER_BOOLEANback to summary
pack-priv static final int LBER_BOOLEAN
LBER_ENUMERATEDback to summary
pack-priv static final int LBER_ENUMERATED
LBER_INTEGERback to summary
pack-priv static final int LBER_INTEGER
LBER_NULLback to summary
pack-priv static final int LBER_NULL
LBER_OCTETSTRINGback to summary
pack-priv static final int LBER_OCTETSTRING
LBER_SEQUENCEback to summary
pack-priv static final int LBER_SEQUENCE
LBER_SETback to summary
pack-priv static final int LBER_SET
LDAP_ADMIN_LIMIT_EXCEEDEDback to summary
pack-priv static final int LDAP_ADMIN_LIMIT_EXCEEDED
LDAP_AFFECTS_MULTIPLE_DSASback to summary
pack-priv static final int LDAP_AFFECTS_MULTIPLE_DSAS
LDAP_ALIAS_DEREFERENCING_PROBLEMback to summary
pack-priv static final int LDAP_ALIAS_DEREFERENCING_PROBLEM
LDAP_ALIAS_PROBLEMback to summary
pack-priv static final int LDAP_ALIAS_PROBLEM
LDAP_ATTRIBUTE_OR_VALUE_EXISTSback to summary
pack-priv static final int LDAP_ATTRIBUTE_OR_VALUE_EXISTS
LDAP_AUTH_METHOD_NOT_SUPPORTEDback to summary
pack-priv static final int LDAP_AUTH_METHOD_NOT_SUPPORTED
LDAP_BUSYback to summary
pack-priv static final int LDAP_BUSY
LDAP_COMPARE_FALSEback to summary
pack-priv static final int LDAP_COMPARE_FALSE
LDAP_COMPARE_TRUEback to summary
pack-priv static final int LDAP_COMPARE_TRUE
LDAP_CONFIDENTIALITY_REQUIREDback to summary
pack-priv static final int LDAP_CONFIDENTIALITY_REQUIRED
LDAP_CONSTRAINT_VIOLATIONback to summary
pack-priv static final int LDAP_CONSTRAINT_VIOLATION
LDAP_CONTROL_MANAGE_DSA_ITback to summary
pack-priv static final String LDAP_CONTROL_MANAGE_DSA_IT
LDAP_CONTROL_PAGED_RESULTSback to summary
pack-priv static final String LDAP_CONTROL_PAGED_RESULTS
LDAP_CONTROL_PREFERRED_LANGback to summary
pack-priv static final String LDAP_CONTROL_PREFERRED_LANG
LDAP_CONTROL_SERVER_SORT_REQback to summary
pack-priv static final String LDAP_CONTROL_SERVER_SORT_REQ
LDAP_CONTROL_SERVER_SORT_RESback to summary
pack-priv static final String LDAP_CONTROL_SERVER_SORT_RES
LDAP_CONTROLSback to summary
pack-priv static final int LDAP_CONTROLS
LDAP_ENTRY_ALREADY_EXISTSback to summary
pack-priv static final int LDAP_ENTRY_ALREADY_EXISTS
ldap_error_messageback to summary
pack-priv static final String[] ldap_error_message
LDAP_INAPPROPRIATE_AUTHENTICATIONback to summary
pack-priv static final int LDAP_INAPPROPRIATE_AUTHENTICATION
LDAP_INAPPROPRIATE_MATCHINGback to summary
pack-priv static final int LDAP_INAPPROPRIATE_MATCHING
LDAP_INSUFFICIENT_ACCESS_RIGHTSback to summary
pack-priv static final int LDAP_INSUFFICIENT_ACCESS_RIGHTS
LDAP_INVALID_ATTRIBUTE_SYNTAXback to summary
pack-priv static final int LDAP_INVALID_ATTRIBUTE_SYNTAX
LDAP_INVALID_CREDENTIALSback to summary
pack-priv static final int LDAP_INVALID_CREDENTIALS
LDAP_INVALID_DN_SYNTAXback to summary
pack-priv static final int LDAP_INVALID_DN_SYNTAX
LDAP_IS_LEAFback to summary
pack-priv static final int LDAP_IS_LEAF
LDAP_LOOP_DETECTback to summary
pack-priv static final int LDAP_LOOP_DETECT
LDAP_NAMING_VIOLATIONback to summary
pack-priv static final int LDAP_NAMING_VIOLATION
LDAP_NO_SUCH_ATTRIBUTEback to summary
pack-priv static final int LDAP_NO_SUCH_ATTRIBUTE
LDAP_NO_SUCH_OBJECTback to summary
pack-priv static final int LDAP_NO_SUCH_OBJECT
LDAP_NOT_ALLOWED_ON_NON_LEAFback to summary
pack-priv static final int LDAP_NOT_ALLOWED_ON_NON_LEAF
LDAP_NOT_ALLOWED_ON_RDNback to summary
pack-priv static final int LDAP_NOT_ALLOWED_ON_RDN
LDAP_OBJECT_CLASS_MODS_PROHIBITEDback to summary
pack-priv static final int LDAP_OBJECT_CLASS_MODS_PROHIBITED
LDAP_OBJECT_CLASS_VIOLATIONback to summary
pack-priv static final int LDAP_OBJECT_CLASS_VIOLATION
LDAP_OPERATIONS_ERRORback to summary
pack-priv static final int LDAP_OPERATIONS_ERROR
LDAP_OTHERback to summary
pack-priv static final int LDAP_OTHER
LDAP_PARTIAL_RESULTSback to summary
pack-priv static final int LDAP_PARTIAL_RESULTS
LDAP_PROTOCOL_ERRORback to summary
pack-priv static final int LDAP_PROTOCOL_ERROR
LDAP_REF_FOLLOWback to summary
pack-priv static final int LDAP_REF_FOLLOW
LDAP_REF_FOLLOW_SCHEMEback to summary
pack-priv static final int LDAP_REF_FOLLOW_SCHEME
LDAP_REF_IGNOREback to summary
pack-priv static final int LDAP_REF_IGNORE
LDAP_REF_THROWback to summary
pack-priv static final int LDAP_REF_THROW
LDAP_REFERRALback to summary
pack-priv static final int LDAP_REFERRAL
LDAP_REP_ADDback to summary
pack-priv static final int LDAP_REP_ADD
LDAP_REP_BINDback to summary
pack-priv static final int LDAP_REP_BIND
LDAP_REP_COMPAREback to summary
pack-priv static final int LDAP_REP_COMPARE
LDAP_REP_DELETEback to summary
pack-priv static final int LDAP_REP_DELETE
LDAP_REP_EXT_OIDback to summary
pack-priv static final int LDAP_REP_EXT_OID
LDAP_REP_EXT_VALback to summary
pack-priv static final int LDAP_REP_EXT_VAL
LDAP_REP_EXTENSIONback to summary
pack-priv static final int LDAP_REP_EXTENSION
LDAP_REP_MODIFYback to summary
pack-priv static final int LDAP_REP_MODIFY
LDAP_REP_MODRDNback to summary
pack-priv static final int LDAP_REP_MODRDN
LDAP_REP_REFERRALback to summary
pack-priv static final int LDAP_REP_REFERRAL
LDAP_REP_RESULTback to summary
pack-priv static final int LDAP_REP_RESULT
LDAP_REP_SEARCH_REFback to summary
pack-priv static final int LDAP_REP_SEARCH_REF
LDAP_REQ_ABANDONback to summary
pack-priv static final int LDAP_REQ_ABANDON
LDAP_REQ_ADDback to summary
pack-priv static final int LDAP_REQ_ADD
LDAP_REQ_BINDback to summary
pack-priv static final int LDAP_REQ_BIND
LDAP_REQ_COMPAREback to summary
pack-priv static final int LDAP_REQ_COMPARE
LDAP_REQ_DELETEback to summary
pack-priv static final int LDAP_REQ_DELETE
LDAP_REQ_EXTENSIONback to summary
pack-priv static final int LDAP_REQ_EXTENSION
LDAP_REQ_MODIFYback to summary
pack-priv static final int LDAP_REQ_MODIFY
LDAP_REQ_MODRDNback to summary
pack-priv static final int LDAP_REQ_MODRDN
LDAP_REQ_UNBINDback to summary
pack-priv static final int LDAP_REQ_UNBIND
LDAP_SASL_BIND_IN_PROGRESSback to summary
pack-priv static final int LDAP_SASL_BIND_IN_PROGRESS
LDAP_SIZE_LIMIT_EXCEEDEDback to summary
pack-priv static final int LDAP_SIZE_LIMIT_EXCEEDED
LDAP_STRONG_AUTH_REQUIREDback to summary
pack-priv static final int LDAP_STRONG_AUTH_REQUIRED
LDAP_SUCCESSback to summary
pack-priv static final int LDAP_SUCCESS
LDAP_SUPERIOR_DNback to summary
pack-priv static final int LDAP_SUPERIOR_DN
LDAP_TIME_LIMIT_EXCEEDEDback to summary
pack-priv static final int LDAP_TIME_LIMIT_EXCEEDED
LDAP_UNAVAILABLEback to summary
pack-priv static final int LDAP_UNAVAILABLE
LDAP_UNAVAILABLE_CRITICAL_EXTENSIONback to summary
pack-priv static final int LDAP_UNAVAILABLE_CRITICAL_EXTENSION
LDAP_UNDEFINED_ATTRIBUTE_TYPEback to summary
pack-priv static final int LDAP_UNDEFINED_ATTRIBUTE_TYPE
LDAP_UNWILLING_TO_PERFORMback to summary
pack-priv static final int LDAP_UNWILLING_TO_PERFORM
LDAP_URLback to summary
pack-priv static final String LDAP_URL
LDAP_VERSIONback to summary
pack-priv static final int LDAP_VERSION
LDAP_VERSION2back to summary
pack-priv static final int LDAP_VERSION2
LDAP_VERSION3back to summary
pack-priv static final int LDAP_VERSION3
LDAP_VERSION3_VERSION2back to summary
pack-priv static final int LDAP_VERSION3_VERSION2
LDAPS_URLback to summary
pack-priv static final String LDAPS_URL
lockback to summary
pack-priv final ReentrantLock lock
pcbback to summary
private final PoolCallback pcb
pooledback to summary
private final boolean pooled
referenceCountback to summary
pack-priv int referenceCount
REPLACEback to summary
pack-priv static final int REPLACE
SCOPE_BASE_OBJECTback to summary
pack-priv static final int SCOPE_BASE_OBJECT
SCOPE_ONE_LEVELback to summary
pack-priv static final int SCOPE_ONE_LEVEL
SCOPE_SUBTREEback to summary
pack-priv static final int SCOPE_SUBTREE
unsolicitedback to summary
private final Vector<LdapCtx> unsolicited
unsolicitedLockback to summary
private final ReentrantLock unsolicitedLock

Constructor Detail

LdapClientback to summary
pack-priv LdapClient(String host, int port, String socketFactory, int connectTimeout, int readTimeout, OutputStream trace, PoolCallback pcb) throws NamingException

Method Detail

addback to summary
pack-priv LdapResult add(LdapEntry entry, Control[] reqCtls) throws IOException, NamingException
addUnsolicitedback to summary
pack-priv void addUnsolicited(LdapCtx ctx)
authenticateback to summary
pack-priv LdapResult authenticate(boolean initial, String name, Object pw, int version, String authMechanism, Control[] ctls, Hashtable<?, ?> env) throws NamingException
authenticateCalledback to summary
pack-priv boolean authenticateCalled()
clearSearchReplyback to summary
pack-priv void clearSearchReply(LdapResult res, Control[] ctls)
closeback to summary
pack-priv void close(Control[] reqCtls, boolean hardClose)
closeConnectionback to summary
public void closeConnection()

Implements com.sun.jndi.ldap.pool.PooledConnection.closeConnection.

Doc from com.sun.jndi.ldap.pool.PooledConnection.closeConnection.

Closes the physical connection.

compareback to summary
pack-priv LdapResult compare(String DN, String type, String value, Control[] reqCtls) throws IOException, NamingException
deleteback to summary
pack-priv LdapResult delete(String DN, Control[] reqCtls) throws IOException, NamingException
encodeAttributeback to summary
private void encodeAttribute(BerEncoder ber, Attribute attr) throws IOException, NamingException
encodeControlsback to summary
pack-priv static void encodeControls(BerEncoder ber, Control[] reqCtls) throws IOException
encodePasswordback to summary
private static byte[] encodePassword(Object pw, boolean v3) throws IOException

Returns the encoded password.

ensureOpenback to summary
private void ensureOpen() throws IOException
extendedOpback to summary
pack-priv LdapResult extendedOp(String id, byte[] request, Control[] reqCtls, boolean pauseAfterReceipt) throws IOException, NamingException
finalizeback to summary
protected void finalize()

Overrides java.lang.Object.finalize.

Doc from java.lang.Object.finalize.

Called by the garbage collector on an object when garbage collection determines that there are no more references to the object. A subclass overrides the finalize method to dispose of system resources or to perform other cleanup.

When running in a Java virtual machine in which finalization has been disabled or removed, the garbage collector will never call finalize(). In a Java virtual machine in which finalization is enabled, the garbage collector might call finalize only after an indefinite delay.

The general contract of finalize is that it is invoked if and when the Java virtual machine has determined that there is no longer any means by which this object can be accessed by any thread that has not yet died, except as a result of an action taken by the finalization of some other object or class which is ready to be finalized. The finalize method may take any action, including making this object available again to other threads; the usual purpose of finalize, however, is to perform cleanup actions before the object is irrevocably discarded. For example, the finalize method for an object that represents an input/output connection might perform explicit I/O transactions to break the connection before the object is permanently discarded.

The finalize method of class Object performs no special action; it simply returns normally. Subclasses of Object may override this definition.

The Java programming language does not guarantee which thread will invoke the finalize method for any given object. It is guaranteed, however, that the thread that invokes finalize will not be holding any user-visible synchronization locks when finalize is invoked. If an uncaught exception is thrown by the finalize method, the exception is ignored and finalization of that object terminates.

After the finalize method has been invoked for an object, no further action is taken until the Java virtual machine has again determined that there is no longer any means by which this object can be accessed by any thread that has not yet died, including possible actions by other objects or classes which are ready to be finalized, at which point the object may be discarded.

The finalize method is never invoked more than once by a Java virtual machine for any given object.

Any exception thrown by the finalize method causes the finalization of this object to be halted, but is otherwise ignored.

Annotations
@SuppressWarnings:removal
forceCloseback to summary
private void forceClose(boolean cleanPool)
getErrorMessageback to summary
pack-priv static String getErrorMessage(int errorCode, String errorMessage)
getInstanceback to summary
pack-priv static LdapClient getInstance(boolean usePool, String hostname, int port, String factory, int connectTimeout, int readTimeout, OutputStream trace, int version, String authMechanism, Control[] ctls, String protocol, String user, Object passwd, Hashtable<?, ?> env) throws NamingException
getSearchReplyback to summary
pack-priv LdapResult getSearchReply(int batchSize, LdapResult res, Hashtable<String, Boolean> binaryAttrs) throws IOException, NamingException
getSearchReplyback to summary
private LdapResult getSearchReply(LdapRequest req, int batchSize, LdapResult res, Hashtable<String, Boolean> binaryAttrs) throws IOException, NamingException
hasNoValueback to summary
private static boolean hasNoValue(Attribute attr) throws NamingException
incRefCountback to summary
pack-priv void incRefCount()
isBinaryValuedback to summary
private boolean isBinaryValued(String attrid, Hashtable<String, Boolean> binaryAttrs)
isUpgradedToStartTlsback to summary
pack-priv boolean isUpgradedToStartTls()
ldapBindback to summary
public LdapResult ldapBind(String dn, byte[] toServer, Control[] bindCtls, String auth, boolean pauseAfterReceipt) throws IOException, NamingException

Sends an LDAP Bind request. Cannot be private; called by LdapSasl

Parameters
dn:String

The possibly null DN to use in the BIND request. null if anonymous.

toServer:byte[]

The possibly null array of bytes to send to the server.

auth:String

The authentication mechanism

moddnback to summary
pack-priv LdapResult moddn(String DN, String newrdn, boolean deleteOldRdn, String newSuperior, Control[] reqCtls) throws IOException, NamingException
modifyback to summary
pack-priv LdapResult modify(String dn, int[] operations, Attribute[] attrs, Control[] reqCtls) throws IOException, NamingException
notifyUnsolicitedback to summary
private void notifyUnsolicited(Object e)
parseAttributeback to summary
private Attribute parseAttribute(BerDecoder ber, Hashtable<String, Boolean> binaryAttrs) throws IOException
parseAttributeValueback to summary
private int parseAttributeValue(BerDecoder ber, Attribute la, boolean hasBinaryValues) throws IOException
parseControlsback to summary
pack-priv static Vector<Control> parseControls(BerDecoder replyBer) throws IOException
parseExtResponseback to summary
private void parseExtResponse(BerDecoder replyBer, LdapResult res) throws IOException
parseResultback to summary
pack-priv static void parseResult(BerDecoder replyBer, LdapResult res, boolean isLdapv3) throws IOException
processConnectionClosureback to summary
pack-priv void processConnectionClosure()

Called by Connection.cleanup(). LdapClient should notify any unsolicited listeners and removing itself from any pool. This is almost like forceClose(), except it doesn't call Connection.cleanup() (because this is called from cleanup()).

processReplyback to summary
private LdapResult processReply(LdapRequest req, LdapResult res, int responseType) throws IOException, NamingException

Reads the next reply corresponding to msgId, outstanding on requestBer. Processes the result and any controls.

processUnsolicitedback to summary
pack-priv void processUnsolicited(BerDecoder ber)
removeUnsolicitedback to summary
pack-priv void removeUnsolicited(LdapCtx ctx)
searchback to summary
pack-priv LdapResult search(String dn, int scope, int deref, int sizeLimit, int timeLimit, boolean attrsOnly, String[] attrs, String filter, int batchSize, Control[] reqCtls, Hashtable<String, Boolean> binaryAttrs, boolean waitFirstReply, int replyQueueCapacity) throws IOException, NamingException
usingSaslStreamsback to summary
pack-priv boolean usingSaslStreams()

Determines whether SASL encryption/integrity is in progress. This check is made prior to reauthentication. You cannot reauthenticate over an encrypted/integrity-protected SASL channel. You must close the channel and open a new one.