Package com.sun.mail.auth
Class OAuth2SaslClientFactory
java.lang.Object
com.sun.mail.auth.OAuth2SaslClientFactory
- All Implemented Interfaces:
SaslClientFactory
Jakarta Mail SASL client factory for OAUTH2.
- Author:
- Bill Shannon
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreateSaslClient
(String[] mechanisms, String authorizationId, String protocol, String serverName, Map<String, ?> props, CallbackHandler cbh) String[]
getMechanismNames
(Map<String, ?> props) static void
init()
Initialize this OAUTH2 provider, but only if there isn't one already.
-
Constructor Details
-
OAuth2SaslClientFactory
public OAuth2SaslClientFactory()
-
-
Method Details
-
createSaslClient
public SaslClient createSaslClient(String[] mechanisms, String authorizationId, String protocol, String serverName, Map<String, ?> props, CallbackHandler cbh) throws SaslException- Specified by:
createSaslClient
in interfaceSaslClientFactory
- Throws:
SaslException
-
getMechanismNames
- Specified by:
getMechanismNames
in interfaceSaslClientFactory
-
init
public static void init()Initialize this OAUTH2 provider, but only if there isn't one already. If we're not allowed to add this provider, just give up silently.
-