Interface OutgoingServerSession
-
- All Superinterfaces:
ChannelHandler<org.xmpp.packet.Packet>
,RoutableChannelHandler
,ServerSession
,Session
- All Known Implementing Classes:
LocalOutgoingServerSession
,RemoteOutgoingServerSession
public interface OutgoingServerSession extends ServerSession
Server-to-server communication is done using two TCP connections between the servers. One connection is used for sending packets while the other connection is used for receiving packets. TheOutgoingServerSession
represents the connection to a remote server that will only be used for sending packets.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.
- Author:
- Gaston Dombiak
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.jivesoftware.openfire.session.ServerSession
ServerSession.AuthenticationMethod
-
Nested classes/interfaces inherited from interface org.jivesoftware.openfire.session.Session
Session.Status
-
-
Field Summary
-
Fields inherited from interface org.jivesoftware.openfire.session.Session
Log, MAJOR_VERSION, MINOR_VERSION
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
addOutgoingDomainPair(DomainPair domainPair)
Marks a domain pair as being authenticated.boolean
authenticateSubdomain(DomainPair domainPair)
Authenticates a subdomain of this server with the specified remote server over an existing outgoing connection.boolean
checkOutgoingDomainPair(DomainPair domainPair)
Checks to see if a pair of domains has previously been authenticated.Collection<DomainPair>
getOutgoingDomainPairs()
Obtains all authenticated domain pairs.-
Methods inherited from interface org.jivesoftware.openfire.session.ServerSession
getAuthenticationMethod, isUsingSaslExternal, isUsingServerDialback
-
Methods inherited from interface org.jivesoftware.openfire.session.Session
close, deliverRawText, getAddress, getCipherSuiteName, getCreationDate, getHostAddress, getHostName, getLanguage, getLastActiveDate, getNumClientPackets, getNumServerPackets, getPeerCertificates, getServerName, getSoftwareVersion, getStatus, getStreamID, getTLSProtocolName, isAuthenticated, isClosed, isEncrypted, process, validate
-
-
-
-
Method Detail
-
authenticateSubdomain
boolean authenticateSubdomain(@Nonnull DomainPair domainPair)
Authenticates a subdomain of this server with the specified remote server over an existing outgoing connection. If the existing session was using server dialback then a new db:result is going to be sent to the remote server. But if the existing session was TLS+SASL based then just assume that the subdomain was authenticated by the remote server.- Parameters:
domainPair
- the local (sub) and remote domain for which authentication is to be established.- Returns:
- True if the domain was authenticated by the remote server.
-
checkOutgoingDomainPair
boolean checkOutgoingDomainPair(@Nonnull DomainPair domainPair)
Checks to see if a pair of domains has previously been authenticated. Since domains are authenticated as pairs, authenticating A->B does not imply anything about A-->C or D->B.- Parameters:
domainPair
- the local and remote domain for which the check is executed.- Returns:
- True if the pair of domains has been authenticated.
-
addOutgoingDomainPair
void addOutgoingDomainPair(@Nonnull DomainPair domainPair)
Marks a domain pair as being authenticated.- Parameters:
domainPair
- the local and remote domain for which authentication has been established.
-
getOutgoingDomainPairs
Collection<DomainPair> getOutgoingDomainPairs()
Obtains all authenticated domain pairs. Most callers should avoid accessing this and use a simple check as above.- Returns:
- collection of authenticated DomainPairs
-
-