SmartFrog 3.10.000
Class SFServerSocket

  extended by
      extended by

public class SFServerSocket

Extends ServerSocket so that it contains the security context, and configures properly the socket returned in the accept(), getting hold of the session...

Constructor Summary
SFServerSocket(int port, SFSecurityEnvironment secEnv)
          Class Constructor.
Method Summary accept()
          Listens for a connection to be made to this socket and accepts it.
Methods inherited from class
bind, bind, close, getChannel, getInetAddress, getLocalPort, getLocalSocketAddress, getReceiveBufferSize, getReuseAddress, getSoTimeout, implAccept, isBound, isClosed, setPerformancePreferences, setReceiveBufferSize, setReuseAddress, setSocketFactory, setSoTimeout, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

Constructor Detail


public SFServerSocket(int port,
                      SFSecurityEnvironment secEnv)
Class Constructor.

port - The port number
secEnv - A security environment that handles the configuration of sockets.
Throws: - In case error while creating server socket
Method Detail


public accept()
Listens for a connection to be made to this socket and accepts it. The method blocks until a connection is made.

A new Socket s is created and, if there is a security manager, the security manager's checkAccept method is called with s.getInetAddress().getHostAddress() and s.getPort() as its arguments to ensure the operation is allowed. This could result in a SecurityException. We attach our custom socket to the SocketImpl returned by the accept and wrap around it the ssl socket.

accept in class
the new Socket
Throws: - if an I/O error occurs when waiting for a connection.
See Also:
SecurityManager.checkAccept(java.lang.String, int)

SmartFrog CORE 3.10.000

(C) Copyright 1998-2006 Hewlett-Packard Development Company, LP