org.netbeans.lib.collab
Interface SecurityListener

All Superinterfaces:
CollaborationSessionListener, SecureSessionListener

public interface SecurityListener
extends SecureSessionListener

This specifies the callback which will be used to determine the runtime behaviour of the api w.r.t TLS. If this is not implemented by the listener passed in during session creation , then TLS will not be initiated - if the server specifies TLF support as mandatory , this will result in session termination.

Author:
Jacques Belissent , Mridul Muralidharan

Method Summary
 boolean continueInClear()
          When api determines that the communication with server will be in cleartext it invokes this method.
 void securityHandshakeComplete()
          called by API after the security nego is complete.
 boolean useTLS()
          Called by the API implementation after it detects that TLS is available and optional.
 
Methods inherited from interface org.netbeans.lib.collab.SecureSessionListener
onX509Certificate
 
Methods inherited from interface org.netbeans.lib.collab.CollaborationSessionListener
onError
 

Method Detail

continueInClear

public boolean continueInClear()
When api determines that the communication with server will be in cleartext it invokes this method.

Returns:
true to continue, false to abort the connection.

securityHandshakeComplete

public void securityHandshakeComplete()
called by API after the security nego is complete. this is only a notification. If tls handshake fails, CollaborationSessionListener.onError is called.


useTLS

public boolean useTLS()
Called by the API implementation after it detects that TLS is available and optional. Unless there is a specific reason not to use TLS, it is highly recommended to return true. This method is not called if TLS is required by the server

Returns:
whether to use TLS.