com.verisign.epp.transport.server
Class EPPSSLServer

java.lang.Object
  extended by com.verisign.epp.transport.server.EPPSSLServer
All Implemented Interfaces:
EPPServerCon
Direct Known Subclasses:
EPPSSLServerSingle

public class EPPSSLServer
extends java.lang.Object
implements EPPServerCon

SSL Server class. This class implements the EPPServerCon interface and handles SSL communication with a SSL client.


Constructor Summary
EPPSSLServer()
          Creates an EPPSSLServer that initializes the SSL configuration and gets the port number to listen on.
 
Method Summary
 void close()
          Closing the server socket
protected  java.lang.String getSSLPropertyListString(java.lang.String[] aList)
          Gets an SSL property list as a string for logging purposes.
 boolean isListening()
          Is the server actively listening for connections?
 void loop()
          Run the accept loop, where the server will continue listening while the listening flag is true as defined by the getListening and the setListening(boolean) methods.
 void RunServer(ServerEventHandler aHandler)
          Starts the server by creating the SSL server socket and going into connection accept loop.
 void setListening(boolean aListening)
          Sets the server listing property that can be used to stop the server from listening for new connections.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EPPSSLServer

public EPPSSLServer()
             throws EPPConException
Creates an EPPSSLServer that initializes the SSL configuration and gets the port number to listen on. The server will listen on all interfaces.

Throws:
EPPConException - Error initializing SSL server
Method Detail

getSSLPropertyListString

protected java.lang.String getSSLPropertyListString(java.lang.String[] aList)
Gets an SSL property list as a string for logging purposes. Examples of SSL property lists include supported protocols, enabled protocols, supported cipher suites, and enabled cipher suites.

Parameters:
aList - Array of String's.
Returns:
Space delimited String representing the property list if aList is not null; null otherwise

RunServer

public void RunServer(ServerEventHandler aHandler)
               throws EPPConException
Starts the server by creating the SSL server socket and going into connection accept loop.

Specified by:
RunServer in interface EPPServerCon
Parameters:
aHandler - Connection handler
Throws:
EPPConException - Error creating server socket

loop

public void loop()
          throws EPPConException
Run the accept loop, where the server will continue listening while the listening flag is true as defined by the getListening and the setListening(boolean) methods. Inside the loop, the server will accept a client connection and spawn a new thread to handle the connection.

Throws:
EPPConException - Any error with accepting or handling a client connection

close

public void close()
           throws EPPConException
Closing the server socket

Throws:
EPPConException - Error closing the server socket

isListening

public boolean isListening()
Is the server actively listening for connections?

Returns:
Listening boolean property

setListening

public void setListening(boolean aListening)
Sets the server listing property that can be used to stop the server from listening for new connections.

Parameters:
aListening - false to stop the server from listening to new connections.


Copyright © VeriSign Inc. All Rights Reserved.