Package org.apache.activeio.xnet.hba
Class ServiceAccessController
java.lang.Object
org.apache.activeio.xnet.hba.ServiceAccessController
- All Implemented Interfaces:
ServerService
,SocketService
-
Constructor Summary
ConstructorsConstructorDescriptionServiceAccessController
(String name, ServerService next, IPAddressPermission[] ipAddressMasks) -
Method Summary
Modifier and TypeMethodDescriptionvoid
checkHostsAuthorization
(InetAddress clientAddress, InetAddress serverAddress) getIP()
Gets the ip number that the daemon is listening on.getName()
Gets the name of the service.int
getPort()
Gets the port number that the daemon is listening on.void
init
(Properties props) void
void
setAllowHosts
(IPAddressPermission[] ipAddressMasks) void
start()
void
stop()
-
Constructor Details
-
ServiceAccessController
-
ServiceAccessController
public ServiceAccessController(String name, ServerService next, IPAddressPermission[] ipAddressMasks)
-
-
Method Details
-
service
- Specified by:
service
in interfaceSocketService
- Throws:
ServiceException
IOException
-
getAllowHosts
-
setAllowHosts
-
checkHostsAuthorization
public void checkHostsAuthorization(InetAddress clientAddress, InetAddress serverAddress) throws SecurityException - Throws:
SecurityException
-
init
- Specified by:
init
in interfaceServerService
- Throws:
Exception
-
start
- Specified by:
start
in interfaceServerService
- Throws:
ServiceException
-
stop
- Specified by:
stop
in interfaceServerService
- Throws:
ServiceException
-
getName
Description copied from interface:SocketService
Gets the name of the service. Used for display purposes only- Specified by:
getName
in interfaceSocketService
-
getIP
Description copied from interface:ServerService
Gets the ip number that the daemon is listening on.- Specified by:
getIP
in interfaceServerService
-
getPort
public int getPort()Description copied from interface:ServerService
Gets the port number that the daemon is listening on.- Specified by:
getPort
in interfaceServerService
-