Package org.forgerock.opendj.ldap
Interface ConnectionSecurityLayer
public interface ConnectionSecurityLayer
An interface for providing additional connection security to a connection.
-
Method Summary
Modifier and TypeMethodDescriptionvoiddispose()Disposes of any system resources or security-sensitive information that this connection security layer might be using.byte[]unwrap(byte[] incoming, int offset, int len) Unwraps a byte array received from the peer.byte[]wrap(byte[] outgoing, int offset, int len) Wraps a byte array to be sent to the peer.
-
Method Details
-
dispose
void dispose()Disposes of any system resources or security-sensitive information that this connection security layer might be using. Invoking this method invalidates this instance. -
unwrap
Unwraps a byte array received from the peer.- Parameters:
incoming- A non-nullbyte array containing the encoded bytes from the peer.offset- The starting position inincomingof the bytes to be unwrapped.len- The number of bytes fromincomingto be unwrapped.- Returns:
- A non-
nullbyte array containing the unwrapped bytes. - Throws:
LdapException- Ifincomingcannot be successfully unwrapped.
-
wrap
Wraps a byte array to be sent to the peer.- Parameters:
outgoing- A non-nullbyte array containing the unencoded bytes to be sent to the peer.offset- The starting position inoutgoingof the bytes to be wrapped.len- The number of bytes fromoutgoingto be wrapped.- Returns:
- A non-
nullbyte array containing the wrapped bytes. - Throws:
LdapException- Ifoutgoingcannot be successfully wrapped.
-