Package org.wildfly.security.sasl.util
Class SSLSaslClientFactory
- java.lang.Object
-
- org.wildfly.security.sasl.util.AbstractDelegatingSaslClientFactory
-
- org.wildfly.security.sasl.util.SSLSaslClientFactory
-
- All Implemented Interfaces:
SaslClientFactory
public final class SSLSaslClientFactory extends AbstractDelegatingSaslClientFactory implements SaslClientFactory
A SASL client factory which provides information about the security layer of the connection to the callback handler.- Author:
- David M. Lloyd
-
-
Field Summary
Fields Modifier and Type Field Description private Supplier<SSLConnection>
sslConnectionSupplier
-
Fields inherited from class org.wildfly.security.sasl.util.AbstractDelegatingSaslClientFactory
delegate
-
-
Constructor Summary
Constructors Constructor Description SSLSaslClientFactory(Supplier<SSLConnection> sslConnectionSupplier, SaslClientFactory delegate)
Construct a new instance.SSLSaslClientFactory(SaslClientFactory delegate, Supplier<SSLSession> sslSession)
Deprecated.UseSSLSaslClientFactory(Supplier, SaslClientFactory)
to avoid problems where a TLS client is acting as a SASL server.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected int
calculateHashCode()
Perform the calculation of the hash code of this factory.SaslClient
createSaslClient(String[] mechanisms, String authorizationId, String protocol, String serverName, Map<String,?> props, CallbackHandler cbh)
boolean
equals(Object other)
boolean
equals(AbstractDelegatingSaslClientFactory other)
boolean
equals(SSLSaslClientFactory other)
-
Methods inherited from class org.wildfly.security.sasl.util.AbstractDelegatingSaslClientFactory
delegatesThrough, delegatesThroughNN, getMechanismNames, hashCode, toString
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface javax.security.sasl.SaslClientFactory
getMechanismNames
-
-
-
-
Field Detail
-
sslConnectionSupplier
private final Supplier<SSLConnection> sslConnectionSupplier
-
-
Constructor Detail
-
SSLSaslClientFactory
public SSLSaslClientFactory(Supplier<SSLConnection> sslConnectionSupplier, SaslClientFactory delegate)
Construct a new instance.- Parameters:
sslConnectionSupplier
- supplier of the current SSL connectiondelegate
- the delegate SASL client factory
-
SSLSaslClientFactory
public SSLSaslClientFactory(SaslClientFactory delegate, Supplier<SSLSession> sslSession)
Deprecated.UseSSLSaslClientFactory(Supplier, SaslClientFactory)
to avoid problems where a TLS client is acting as a SASL server.Construct a new instance.- Parameters:
delegate
- the delegate SASL client factorysslSession
- supplier of the current SSLSession
-
-
Method Detail
-
createSaslClient
public SaslClient createSaslClient(String[] mechanisms, String authorizationId, String protocol, String serverName, Map<String,?> props, CallbackHandler cbh) throws SaslException
- Specified by:
createSaslClient
in interfaceSaslClientFactory
- Overrides:
createSaslClient
in classAbstractDelegatingSaslClientFactory
- Throws:
SaslException
-
equals
public boolean equals(Object other)
- Overrides:
equals
in classAbstractDelegatingSaslClientFactory
-
equals
public boolean equals(AbstractDelegatingSaslClientFactory other)
- Overrides:
equals
in classAbstractDelegatingSaslClientFactory
-
equals
public boolean equals(SSLSaslClientFactory other)
-
calculateHashCode
protected int calculateHashCode()
Description copied from class:AbstractDelegatingSaslClientFactory
Perform the calculation of the hash code of this factory.- Overrides:
calculateHashCode
in classAbstractDelegatingSaslClientFactory
- Returns:
- the calculated hash code
-
-