Package org.opends.server.core
Class BindOperationWrapper
- java.lang.Object
-
- org.opends.server.core.OperationWrapper<BindOperation>
-
- org.opends.server.core.BindOperationWrapper
-
- All Implemented Interfaces:
Runnable,BindOperation,Operation
- Direct Known Subclasses:
LocalBackendBindOperation
public abstract class BindOperationWrapper extends OperationWrapper<BindOperation> implements BindOperation
This abstract class wraps/decorates a given bind operation. This class will be extended by sub-classes to enhance the functionality of the BindOperationBasis.
-
-
Field Summary
-
Fields inherited from interface org.opends.server.types.Operation
LOCALBACKENDOPERATIONS
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedBindOperationWrapper(BindOperation bind)Creates a new bind operation based on the provided bind operation.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AuthenticationInfogetAuthenticationInfo()Retrieves the authentication info that resulted from processing this bind operation.AuthenticationTypegetAuthenticationType()Retrieves the authentication type for this bind operation.org.forgerock.i18n.LocalizableMessagegetAuthFailureReason()Retrieves a human-readable message providing the reason that the authentication failed, if available.DNgetBindDN()Retrieves the bind DN for this bind operation.StringgetProtocolVersion()Retrieves a string representation of the protocol version associated with this bind request.ByteStringgetRawBindDN()Retrieves the raw, unprocessed bind DN for this bind operation as contained in the client request.EntrygetSASLAuthUserEntry()Retrieves the user entry associated with the SASL authentication attempt.ByteStringgetSASLCredentials()Retrieves the SASL credentials for this bind operation.StringgetSASLMechanism()Retrieves the SASL mechanism for this bind operation.ByteStringgetServerSASLCredentials()Retrieves the set of server SASL credentials to include in the bind response.ByteStringgetSimplePassword()Retrieves the simple authentication password for this bind operation.DNgetUserEntryDN()Retrieves the user entry DN for this bind operation.voidsetAuthenticationInfo(AuthenticationInfo authInfo)Specifies the authentication info that resulted from processing this bind operation.voidsetAuthFailureReason(org.forgerock.i18n.LocalizableMessage reason)Specifies the reason that the authentication failed.voidsetProtocolVersion(String protocolVersion)Specifies the string representation of the protocol version associated with this bind request.voidsetRawBindDN(ByteString rawBindDN)Specifies the raw, unprocessed bind DN for this bind operation.voidsetSASLAuthUserEntry(Entry saslAuthUserEntry)Specifies the user entry associated with the SASL authentication attempt.voidsetSASLCredentials(String saslMechanism, ByteString saslCredentials)Specifies the SASL credentials for this bind operation.voidsetServerSASLCredentials(ByteString serverSASLCredentials)Specifies the set of server SASL credentials to include in the bind response.voidsetSimplePassword(ByteString simplePassword)Specifies the simple authentication password for this bind operation.voidsetUserEntryDN(DN userEntryDN)Set the user entry DN for this bind operation.StringtoString()Retrieves a string representation of this operation.-
Methods inherited from class org.opends.server.core.OperationWrapper
abort, addAdditionalLogItem, addRequestControl, addResponseControl, appendErrorMessage, appendMaskedErrorMessage, cancel, checkIfCanceled, disconnectClient, dontSynchronize, equals, getAdditionalLogItems, getAttachment, getAttachments, getAuthorizationDN, getAuthorizationEntry, getCancelRequest, getCancelResult, getClientConnection, getConnectionID, getErrorMessage, getMaskedErrorMessage, getMaskedResultCode, getMatchedDN, getMessageID, getOperation, getOperationID, getOperationType, getProcessingNanoTime, getProcessingStartTime, getProcessingStopTime, getProcessingTime, getProxiedAuthorizationDN, getReferralURLs, getRequestControl, getRequestControls, getResponseControls, getResultCode, hashCode, isInnerOperation, isInternalOperation, isSynchronizationOperation, operationCompleted, registerPostResponseCallback, removeAttachment, removeResponseControl, run, setAttachment, setAttachments, setAuthorizationEntry, setDontSynchronize, setErrorMessage, setInnerOperation, setInternalOperation, setMaskedErrorMessage, setMaskedResultCode, setMatchedDN, setProxiedAuthorizationDN, setReferralURLs, setResponseData, setResultCode, setSynchronizationOperation, toString
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.opends.server.types.Operation
abort, addAdditionalLogItem, addRequestControl, addResponseControl, appendErrorMessage, appendMaskedErrorMessage, cancel, checkIfCanceled, disconnectClient, dontSynchronize, getAdditionalLogItems, getAttachment, getAttachments, getAuthorizationDN, getAuthorizationEntry, getCancelRequest, getCancelResult, getClientConnection, getConnectionID, getErrorMessage, getMaskedErrorMessage, getMaskedResultCode, getMatchedDN, getMessageID, getOperationID, getOperationType, getProcessingNanoTime, getProcessingStartTime, getProcessingStopTime, getProcessingTime, getProxiedAuthorizationDN, getReferralURLs, getRequestControl, getRequestControls, getResponseControls, getResultCode, isInnerOperation, isInternalOperation, isSynchronizationOperation, operationCompleted, registerPostResponseCallback, removeAttachment, removeResponseControl, run, setAttachment, setAttachments, setAuthorizationEntry, setDontSynchronize, setErrorMessage, setInnerOperation, setInternalOperation, setMaskedErrorMessage, setMaskedResultCode, setMatchedDN, setProxiedAuthorizationDN, setReferralURLs, setResponseData, setResultCode, setSynchronizationOperation, toString
-
-
-
-
Constructor Detail
-
BindOperationWrapper
protected BindOperationWrapper(BindOperation bind)
Creates a new bind operation based on the provided bind operation.- Parameters:
bind- The bind operation to wrap
-
-
Method Detail
-
getAuthenticationInfo
public AuthenticationInfo getAuthenticationInfo()
Description copied from interface:BindOperationRetrieves the authentication info that resulted from processing this bind operation. It will only be valid if the bind processing was successful.- Specified by:
getAuthenticationInfoin interfaceBindOperation- Returns:
- The authentication info that resulted from processing this bind operation.
-
getAuthenticationType
public AuthenticationType getAuthenticationType()
Description copied from interface:BindOperationRetrieves the authentication type for this bind operation.- Specified by:
getAuthenticationTypein interfaceBindOperation- Returns:
- The authentication type for this bind operation.
-
getAuthFailureReason
public org.forgerock.i18n.LocalizableMessage getAuthFailureReason()
Description copied from interface:BindOperationRetrieves a human-readable message providing the reason that the authentication failed, if available.- Specified by:
getAuthFailureReasonin interfaceBindOperation- Returns:
- A human-readable message providing the reason that the
authentication failed, or
nullif none is available.
-
getBindDN
public DN getBindDN()
Description copied from interface:BindOperationRetrieves the bind DN for this bind operation. This method should not be called by pre-parse plugins, as the raw value will not have been processed by that time. Instead, pre-parse plugins should call thegetRawBindDNmethod.- Specified by:
getBindDNin interfaceBindOperation- Returns:
- The bind DN for this bind operation, or
nullif the raw DN has not yet been processed.
-
getRawBindDN
public ByteString getRawBindDN()
Description copied from interface:BindOperationRetrieves the raw, unprocessed bind DN for this bind operation as contained in the client request. The value may not actually contain a valid DN, as no validation will have been performed.- Specified by:
getRawBindDNin interfaceBindOperation- Returns:
- The raw, unprocessed bind DN for this bind operation as contained in the client request.
-
getSASLAuthUserEntry
public Entry getSASLAuthUserEntry()
Description copied from interface:BindOperationRetrieves the user entry associated with the SASL authentication attempt. This should be set by any SASL mechanism in which the processing was able to get far enough to make this determination, regardless of whether the authentication was ultimately successful.- Specified by:
getSASLAuthUserEntryin interfaceBindOperation- Returns:
- The user entry associated with the SASL authentication attempt, or
nullif it was not a SASL authentication or the SASL processing was not able to map the request to a user.
-
getSASLCredentials
public ByteString getSASLCredentials()
Description copied from interface:BindOperationRetrieves the SASL credentials for this bind operation.- Specified by:
getSASLCredentialsin interfaceBindOperation- Returns:
- The SASL credentials for this bind operation, or
nullif there are none or if the bind does not use SASL authentication.
-
getSASLMechanism
public String getSASLMechanism()
Description copied from interface:BindOperationRetrieves the SASL mechanism for this bind operation.- Specified by:
getSASLMechanismin interfaceBindOperation- Returns:
- The SASL mechanism for this bind operation, or
nullif the bind does not use SASL authentication.
-
getServerSASLCredentials
public ByteString getServerSASLCredentials()
Description copied from interface:BindOperationRetrieves the set of server SASL credentials to include in the bind response.- Specified by:
getServerSASLCredentialsin interfaceBindOperation- Returns:
- The set of server SASL credentials to include in the bind
response, or
nullif there are none.
-
getSimplePassword
public ByteString getSimplePassword()
Description copied from interface:BindOperationRetrieves the simple authentication password for this bind operation.- Specified by:
getSimplePasswordin interfaceBindOperation- Returns:
- The simple authentication password for this bind operation.
-
getUserEntryDN
public DN getUserEntryDN()
Description copied from interface:BindOperationRetrieves the user entry DN for this bind operation. It will only be available if the bind processing has proceeded far enough to identify the user attempting to authenticate.- Specified by:
getUserEntryDNin interfaceBindOperation- Returns:
- The user entry DN for this bind operation, or
nullif the bind processing has not progressed far enough to identify the user or if the user DN could not be determined.
-
setAuthenticationInfo
public void setAuthenticationInfo(AuthenticationInfo authInfo)
Description copied from interface:BindOperationSpecifies the authentication info that resulted from processing this bind operation. This method must only be called by SASL mechanism handlers during the course of processing theprocessSASLBindmethod.- Specified by:
setAuthenticationInfoin interfaceBindOperation- Parameters:
authInfo- The authentication info that resulted from processing this bind operation.
-
setAuthFailureReason
public void setAuthFailureReason(org.forgerock.i18n.LocalizableMessage reason)
Description copied from interface:BindOperationSpecifies the reason that the authentication failed.- Specified by:
setAuthFailureReasonin interfaceBindOperation- Parameters:
reason- providing the reason that the authentication failed.
-
setRawBindDN
public void setRawBindDN(ByteString rawBindDN)
Description copied from interface:BindOperationSpecifies the raw, unprocessed bind DN for this bind operation. This should only be called by pre-parse plugins.- Specified by:
setRawBindDNin interfaceBindOperation- Parameters:
rawBindDN- The raw, unprocessed bind DN for this bind operation.
-
setSASLAuthUserEntry
public void setSASLAuthUserEntry(Entry saslAuthUserEntry)
Description copied from interface:BindOperationSpecifies the user entry associated with the SASL authentication attempt. This should be set by any SASL mechanism in which the processing was able to get far enough to make this determination, regardless of whether the authentication was ultimately successful.- Specified by:
setSASLAuthUserEntryin interfaceBindOperation- Parameters:
saslAuthUserEntry- The user entry associated with the SASL authentication attempt.
-
setSASLCredentials
public void setSASLCredentials(String saslMechanism, ByteString saslCredentials)
Description copied from interface:BindOperationSpecifies the SASL credentials for this bind operation.- Specified by:
setSASLCredentialsin interfaceBindOperation- Parameters:
saslMechanism- The SASL mechanism for this bind operation.saslCredentials- The SASL credentials for this bind operation, ornullif there are none.
-
setServerSASLCredentials
public void setServerSASLCredentials(ByteString serverSASLCredentials)
Description copied from interface:BindOperationSpecifies the set of server SASL credentials to include in the bind response.- Specified by:
setServerSASLCredentialsin interfaceBindOperation- Parameters:
serverSASLCredentials- The set of server SASL credentials to include in the bind response.
-
setSimplePassword
public void setSimplePassword(ByteString simplePassword)
Description copied from interface:BindOperationSpecifies the simple authentication password for this bind operation.- Specified by:
setSimplePasswordin interfaceBindOperation- Parameters:
simplePassword- The simple authentication password for this bind operation.
-
setUserEntryDN
public void setUserEntryDN(DN userEntryDN)
Description copied from interface:BindOperationSet the user entry DN for this bind operation.- Specified by:
setUserEntryDNin interfaceBindOperation- Parameters:
userEntryDN- The user entry DN for this bind operation, ornullif the bind processing has not progressed far enough to identify the user or if the user DN could not be determined.
-
toString
public String toString()
Description copied from interface:OperationRetrieves a string representation of this operation.- Specified by:
toStringin interfaceOperation- Overrides:
toStringin classOperationWrapper<BindOperation>- Returns:
- A string representation of this operation.
-
setProtocolVersion
public void setProtocolVersion(String protocolVersion)
Description copied from interface:BindOperationSpecifies the string representation of the protocol version associated with this bind request.- Specified by:
setProtocolVersionin interfaceBindOperation- Parameters:
protocolVersion- The string representation of the protocol version associated with this bind request.
-
getProtocolVersion
public String getProtocolVersion()
Description copied from interface:BindOperationRetrieves a string representation of the protocol version associated with this bind request.- Specified by:
getProtocolVersionin interfaceBindOperation- Returns:
- A string representation of the protocol version associated with this bind request.
-
-