public class ActiveMQSslConnectionFactory extends ActiveMQConnectionFactory
setTrustStore, setTrustStorePassword,
setKeyStore, and setKeyStorePassword.
Call setKeyAndTrustManagers.| Modifier and Type | Field and Description |
|---|---|
protected KeyManager[] |
keyManager |
protected String |
keyStore |
protected String |
keyStoreKeyPassword |
protected String |
keyStorePassword |
protected SecureRandom |
secureRandom |
protected TrustManager[] |
trustManager |
protected String |
trustStore |
protected String |
trustStorePassword |
alwaysSessionAsync, brokerURL, clientID, DEFAULT_BROKER_BIND_URL, DEFAULT_BROKER_URL, DEFAULT_PASSWORD, DEFAULT_PRODUCER_WINDOW_SIZE, DEFAULT_USER, dispatchAsync, password, userName, xaAckMode| Constructor and Description |
|---|
ActiveMQSslConnectionFactory() |
ActiveMQSslConnectionFactory(String brokerURL) |
ActiveMQSslConnectionFactory(URI brokerURL) |
| Modifier and Type | Method and Description |
|---|---|
protected KeyManager[] |
createKeyManager() |
protected Transport |
createTransport()
Overriding to make special considerations for SSL connections.
|
protected TrustManager[] |
createTrustManager() |
protected InputStream |
getInputStream(String urlOrResource) |
String |
getKeyStore() |
String |
getKeyStoreKeyPassword() |
String |
getKeyStorePassword() |
String |
getTrustStore() |
String |
getTrustStorePassword() |
protected byte[] |
loadClientCredential(String fileName) |
void |
setKeyAndTrustManagers(KeyManager[] km,
TrustManager[] tm,
SecureRandom random)
Sets the key and trust managers used when creating SSL connections.
|
void |
setKeyStore(String keyStore)
The location of a keystore file (in
jks format) containing a
certificate and its private key. |
void |
setKeyStoreKeyPassword(String keyStoreKeyPassword)
The password to match the key from the keyStore.
|
void |
setKeyStorePassword(String keyStorePassword)
The password to match the key store specified by
setKeyStore. |
void |
setTrustStore(String trustStore)
The location of a keystore file (in
jks format) containing
one or more trusted certificates. |
void |
setTrustStorePassword(String trustStorePassword)
The password to match the trust store specified by
setTrustStore. |
buildFromMap, buildFromProperties, configureConnection, copy, createActiveMQConnection, createActiveMQConnection, createActiveMQConnection, createConnection, createConnection, createQueueConnection, createQueueConnection, createTopicConnection, createTopicConnection, getAuditDepth, getAuditMaximumProducerNumber, getBlobTransferPolicy, getBrokerURL, getClientID, getClientIdGenerator, getClientIDPrefix, getClientInternalExceptionListener, getCloseTimeout, getConnectionIdGenerator, getConnectResponseTimeout, getConsumerFailoverRedeliveryWaitPeriod, getExceptionListener, getMaxThreadPoolSize, getOptimizeAcknowledgeTimeOut, getOptimizedAckScheduledAckInterval, getPassword, getPrefetchPolicy, getProducerWindowSize, getRedeliveryPolicy, getRedeliveryPolicyMap, getRejectedTaskHandler, getSendTimeout, getSessionTaskRunner, getStats, getTransformer, getTransportListener, getTrustedPackages, getUserName, getWarnAboutUnstartedConnectionTimeout, isAlwaysSessionAsync, isAlwaysSyncSend, isCheckForDuplicates, isConsumerExpiryCheckEnabled, isCopyMessageOnSend, isDisableTimeStampsByDefault, isDispatchAsync, isExclusiveConsumer, isMessagePrioritySupported, isNestedMapAndListEnabled, isNonBlockingRedelivery, isObjectMessageSerializationDefered, isOptimizeAcknowledge, isOptimizedMessageDispatch, isRmIdFromConnectionId, isSendAcksAsync, isStatsEnabled, isTransactedIndividualAck, isTrustAllPackages, isUseAsyncSend, isUseCompression, isUseDedicatedTaskRunner, isUseRetroactiveConsumer, isWatchTopicAdvisories, populateProperties, setAlwaysSessionAsync, setAlwaysSyncSend, setAuditDepth, setAuditMaximumProducerNumber, setBlobTransferPolicy, setBrokerURL, setCheckForDuplicates, setClientID, setClientIdGenerator, setClientIDPrefix, setClientInternalExceptionListener, setCloseTimeout, setConnectionIdGenerator, setConnectionIDPrefix, setConnectResponseTimeout, setConsumerExpiryCheckEnabled, setConsumerFailoverRedeliveryWaitPeriod, setCopyMessageOnSend, setDisableTimeStampsByDefault, setDispatchAsync, setExceptionListener, setExclusiveConsumer, setMaxThreadPoolSize, setMessagePrioritySupported, setNestedMapAndListEnabled, setNonBlockingRedelivery, setObjectMessageSerializationDefered, setOptimizeAcknowledge, setOptimizeAcknowledgeTimeOut, setOptimizedAckScheduledAckInterval, setOptimizedMessageDispatch, setPassword, setPrefetchPolicy, setProducerWindowSize, setRedeliveryPolicy, setRedeliveryPolicyMap, setRejectedTaskHandler, setRmIdFromConnectionId, setSendAcksAsync, setSendTimeout, setSessionTaskRunner, setStatsEnabled, setTransactedIndividualAck, setTransformer, setTransportListener, setTrustAllPackages, setTrustedPackages, setUseAsyncSend, setUseCompression, setUseDedicatedTaskRunner, setUseRetroactiveConsumer, setUserName, setWarnAboutUnstartedConnectionTimeout, setWatchTopicAdvisoriesgetProperties, getReference, readExternal, setProperties, writeExternalprotected KeyManager[] keyManager
protected TrustManager[] trustManager
protected SecureRandom secureRandom
protected String trustStore
protected String trustStorePassword
protected String keyStorePassword
protected String keyStoreKeyPassword
public ActiveMQSslConnectionFactory()
public ActiveMQSslConnectionFactory(String brokerURL)
public ActiveMQSslConnectionFactory(URI brokerURL)
public void setKeyAndTrustManagers(KeyManager[] km, TrustManager[] tm, SecureRandom random)
km - The KeyManagers used.tm - The TrustManagers used.random - The SecureRandom number used.protected Transport createTransport() throws JMSException
createTransport in class ActiveMQConnectionFactoryJMSException - If unable to create trasnport.protected TrustManager[] createTrustManager() throws Exception
Exceptionprotected KeyManager[] createKeyManager() throws Exception
Exceptionprotected byte[] loadClientCredential(String fileName) throws IOException
IOExceptionprotected InputStream getInputStream(String urlOrResource) throws IOException
IOExceptionpublic String getTrustStore()
public void setTrustStore(String trustStore) throws Exception
jks format) containing
one or more trusted certificates.trustStore - If specified with a scheme, treat as a URL, otherwise treat as
a classpath resource.Exceptionpublic String getTrustStorePassword()
public void setTrustStorePassword(String trustStorePassword)
setTrustStore.trustStorePassword - The password used to unlock the keystore file.public String getKeyStore()
public void setKeyStore(String keyStore) throws Exception
jks format) containing a
certificate and its private key.keyStore - If specified with a scheme, treat as a URL, otherwise treat as
a classpath resource.Exceptionpublic String getKeyStorePassword()
public void setKeyStorePassword(String keyStorePassword)
setKeyStore.keyStorePassword - The password, which is used both to unlock the keystore file
and as the pass phrase for the private key stored in the
keystore.public String getKeyStoreKeyPassword()
public void setKeyStoreKeyPassword(String keyStoreKeyPassword)
keyStoreKeyPassword - The password for the private key stored in the
keyStore if different from keyStorePassword.Copyright © 2005–2016 FuseSource, Corp.. All rights reserved.