public abstract class ConnectionConfiguration
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
ConnectionConfiguration.Builder<B extends ConnectionConfiguration.Builder<B,C>,C extends ConnectionConfiguration>
A builder for XMPP connection configurations.
|
static class |
ConnectionConfiguration.DnssecMode
Determines the requested DNSSEC security mode.
|
static class |
ConnectionConfiguration.SecurityMode
An enumeration for TLS security modes that are available when making a connection
to the XMPP server.
|
Modifier and Type | Field and Description |
---|---|
protected boolean |
allowNullOrEmptyUsername |
protected org.minidns.dnsname.DnsName |
host |
protected java.net.InetAddress |
hostAddress |
protected int |
port |
protected ProxyInfo |
proxy |
protected org.jxmpp.jid.DomainBareJid |
xmppServiceDomain
The XMPP domain of the XMPP Service.
|
Modifier | Constructor and Description |
---|---|
protected |
ConnectionConfiguration(ConnectionConfiguration.Builder<?,?> builder) |
Modifier and Type | Method and Description |
---|---|
org.jxmpp.jid.EntityBareJid |
getAuthzid()
Returns the optional XMPP address to be requested as the SASL authorization identity.
|
javax.security.auth.callback.CallbackHandler |
getCallbackHandler()
Returns a CallbackHandler to obtain information, such as the password or
principal information during the SASL authentication.
|
javax.net.ssl.SSLContext |
getCustomSSLContext()
Gets the custom SSLContext previously set with
ConnectionConfiguration.Builder.setCustomSSLContext(SSLContext) for
SSL sockets. |
javax.net.ssl.X509TrustManager |
getCustomX509TrustManager() |
SmackDebuggerFactory |
getDebuggerFactory()
Returns the Smack debugger factory.
|
ConnectionConfiguration.DnssecMode |
getDnssecMode() |
java.util.Set<java.lang.String> |
getEnabledSaslMechanisms()
Return the explicitly enabled SASL mechanisms.
|
java.lang.String[] |
getEnabledSSLCiphers()
Return the enabled SSL/TLS ciphers.
|
java.lang.String[] |
getEnabledSSLProtocols()
Return the enabled SSL/TLS protocols.
|
javax.net.ssl.HostnameVerifier |
getHostnameVerifier()
Returns the configured HostnameVerifier of this ConnectionConfiguration or the Smack default
HostnameVerifier configured with
SmackConfiguration.setDefaultHostnameVerifier(HostnameVerifier) . |
java.lang.String |
getKeystorePath()
Retuns the path to the keystore file.
|
java.lang.String |
getKeystoreType()
Returns the keystore type, or null if it's not set.
|
java.lang.String |
getPassword()
Returns the password to use when trying to reconnect to the server.
|
java.lang.String |
getPKCS11Library()
Returns the PKCS11 library file location, needed when the
Keystore type is PKCS11.
|
ProxyInfo |
getProxyInfo()
Get the configured proxy information (if any).
|
org.jxmpp.jid.parts.Resourcepart |
getResource()
Returns the resource to use when trying to reconnect to the server.
|
ConnectionConfiguration.SecurityMode |
getSecurityMode()
Returns the TLS security mode used when making the connection.
|
org.jxmpp.jid.DomainBareJid |
getServiceName()
Deprecated.
use
getXMPPServiceDomain() instead. |
javax.net.SocketFactory |
getSocketFactory()
Returns the socket factory used to create new xmppConnection sockets.
|
java.lang.CharSequence |
getUsername()
Returns the username to use when trying to reconnect to the server.
|
org.jxmpp.jid.DomainBareJid |
getXMPPServiceDomain()
Returns the XMPP domain used by this configuration.
|
boolean |
isCompressionEnabled()
Returns true if the connection is going to use stream compression.
|
boolean |
isEnabledSaslMechanism(java.lang.String saslMechanism)
Check if the given SASL mechansism is enabled in this connection configuration.
|
boolean |
isSendPresence()
Returns true if an available presence should be sent when logging in while reconnecting.
|
protected final org.jxmpp.jid.DomainBareJid xmppServiceDomain
protected final java.net.InetAddress hostAddress
protected final org.minidns.dnsname.DnsName host
protected final int port
protected final ProxyInfo proxy
protected final boolean allowNullOrEmptyUsername
protected ConnectionConfiguration(ConnectionConfiguration.Builder<?,?> builder)
@Deprecated public org.jxmpp.jid.DomainBareJid getServiceName()
getXMPPServiceDomain()
instead.public org.jxmpp.jid.DomainBareJid getXMPPServiceDomain()
public ConnectionConfiguration.SecurityMode getSecurityMode()
ConnectionConfiguration.SecurityMode.ifpossible
.public ConnectionConfiguration.DnssecMode getDnssecMode()
public javax.net.ssl.X509TrustManager getCustomX509TrustManager()
public java.lang.String getKeystorePath()
public java.lang.String getKeystoreType()
public java.lang.String getPKCS11Library()
public javax.net.ssl.SSLContext getCustomSSLContext()
ConnectionConfiguration.Builder.setCustomSSLContext(SSLContext)
for
SSL sockets. This is null by default.public java.lang.String[] getEnabledSSLProtocols()
public java.lang.String[] getEnabledSSLCiphers()
public javax.net.ssl.HostnameVerifier getHostnameVerifier()
SmackConfiguration.setDefaultHostnameVerifier(HostnameVerifier)
.null
public SmackDebuggerFactory getDebuggerFactory()
null
public javax.security.auth.callback.CallbackHandler getCallbackHandler()
public javax.net.SocketFactory getSocketFactory()
public ProxyInfo getProxyInfo()
null
.public java.lang.CharSequence getUsername()
public java.lang.String getPassword()
public org.jxmpp.jid.parts.Resourcepart getResource()
public org.jxmpp.jid.EntityBareJid getAuthzid()
public boolean isSendPresence()
public boolean isCompressionEnabled()
public boolean isEnabledSaslMechanism(java.lang.String saslMechanism)
saslMechanism
- public java.util.Set<java.lang.String> getEnabledSaslMechanisms()
null
if no SASL mechanisms where
explicitly enabled, i.e. all SALS mechanisms supported and announced by the service will be considered.null
.