public class LocalOutgoingServerSession extends LocalServerSession implements OutgoingServerSession
Currently only the Server Dialback method is being used for authenticating with the remote
server. Use authenticateDomain(String, String)
to create a new connection to a remote
server that will be used for sending packets to the remote server from the specified domain.
Only the authenticated domains with the remote server will be able to effectively send packets
to the remote server. The remote server will reject and close the connection if a
non-authenticated domain tries to send a packet through this connection.
Once the connection has been established with the remote server and at least a domain has been authenticated then a new route will be added to the routing table for this connection. For optimization reasons the same outgoing connection will be used even if the remote server has several hostnames. However, different routes will be created in the routing table for each hostname of the remote server.
inboundAllowed, outboundAllowed, usingServerDialback
CHARSET, conn, sessionManager, status, streamManager
MAJOR_VERSION, MINOR_VERSION, STATUS_AUTHENTICATED, STATUS_CLOSED, STATUS_CONNECTED
Constructor and Description |
---|
LocalOutgoingServerSession(String localDomain,
Connection connection,
OutgoingServerSocketReader socketReader,
StreamID streamID) |
Modifier and Type | Method and Description |
---|---|
void |
addOutgoingDomainPair(String localDomain,
String remoteDomain)
Marks a domain pair as being authenticated.
|
static boolean |
authenticateDomain(String localDomain,
String remoteDomain)
Authenticates the local domain to the remote domain.
|
boolean |
authenticateSubdomain(String localDomain,
String remoteDomain)
Authenticates a subdomain of this server with the specified remote server over an exsiting
outgoing connection.
|
boolean |
checkOutgoingDomainPair(String localDomain,
String remoteDomain)
Checks to see if a pair of domains has previously been authenticated.
|
String |
getAvailableStreamFeatures()
Returns a text with the available stream features.
|
Collection<DomainPair> |
getOutgoingDomainPairs()
Obtains all authenticated domain pairs.
|
isUsingServerDialback
close, decodeVersion, deliverRawText, getAddress, getCipherSuiteName, getConnection, getCreationDate, getHostAddress, getHostName, getLanguage, getLastActiveDate, getNumClientPackets, getNumServerPackets, getPeerCertificates, getServerName, getSessionData, getStatus, getStreamID, getStreamManager, incrementClientPacketCount, incrementServerPacketCount, isClosed, isDetached, isSecure, isUsingSelfSignedCertificate, process, reattach, removeSessionData, setAddress, setDetached, setSessionData, setStatus, toString, validate
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
isUsingServerDialback
close, deliverRawText, getAddress, getCipherSuiteName, getCreationDate, getHostAddress, getHostName, getLanguage, getLastActiveDate, getNumClientPackets, getNumServerPackets, getPeerCertificates, getServerName, getStatus, getStreamID, isClosed, isSecure, process, validate
public LocalOutgoingServerSession(String localDomain, Connection connection, OutgoingServerSocketReader socketReader, StreamID streamID)
public static boolean authenticateDomain(String localDomain, String remoteDomain)
localDomain
- the local domain to authenticate with the remote server.remoteDomain
- the remote server, to which the local domain intends to send data.public boolean authenticateSubdomain(String localDomain, String remoteDomain)
OutgoingServerSession
authenticateSubdomain
in interface OutgoingServerSession
localDomain
- the locally domain to authenticate with the remote server.remoteDomain
- the domain of the remote server.public String getAvailableStreamFeatures()
LocalSession
getAvailableStreamFeatures
in class LocalServerSession
public void addOutgoingDomainPair(String localDomain, String remoteDomain)
OutgoingServerSession
addOutgoingDomainPair
in interface OutgoingServerSession
localDomain
- the locally hosted domain.remoteDomain
- the remote domain.public boolean checkOutgoingDomainPair(String localDomain, String remoteDomain)
OutgoingServerSession
checkOutgoingDomainPair
in interface OutgoingServerSession
localDomain
- the local domain (previously: authenticated domain)remoteDomain
- the remote domain (previous: hostname)public Collection<DomainPair> getOutgoingDomainPairs()
OutgoingServerSession
getOutgoingDomainPairs
in interface OutgoingServerSession
Copyright © 2003-2008 Jive Software.