ibmmq-jms-spring version(s):
3.0.3 and 3.0.5
Java version (including vendor and platform):
JDK 17 Zuul with Spring Boot 3
A small code sample that demonstrates the issue.
I get an error trying to connect to my MQ-server using the following properties specified in application.yml:
Possible cause:com.ibm.mq.spring.boot.MQConnectionFactoryFactory#configureTLSStores seems to map MQConfigurationPropertiesJks to system properties with prefix jakarta.net.ssl.* and com.ibm.ssl.* instead of javax.net.ssl.* i.e.:
private static void configureTLSStores(MQConfigurationProperties props) {
String[] prefixes = new String[]{"jakarta.net.ssl.", "com.ibm.ssl."};
logger.trace("configuring TLS Store system properties");
MQConfigurationPropertiesJks jksProperties = props.getJks();
String[] var3 = prefixes;
int var4 = prefixes.length;
for(int var5 = 0; var5 < var4; ++var5) {
String prefix = var3[var5];
if (!isNullOrEmpty(jksProperties.getKeyStore())) {
System.setProperty(prefix + "keyStore", jksProperties.getKeyStore());
}
if (!isNullOrEmpty(jksProperties.getKeyStorePassword())) {
System.setProperty(prefix + "keyStorePassword", jksProperties.getKeyStorePassword());
}
if (!isNullOrEmpty(jksProperties.getTrustStore())) {
System.setProperty(prefix + "trustStore", jksProperties.getTrustStore());
}
if (!isNullOrEmpty(jksProperties.getTrustStorePassword())) {
System.setProperty(prefix + "trustStorePassword", jksProperties.getTrustStorePassword());
}
}
}
Thanks for finding that. The script that automatically creates the jakarta variant from the base source code was a little too aggressive in its conversions. I'll fix it for the next update.
ibmmq-jms-spring version(s):
3.0.3 and 3.0.5 Java version (including vendor and platform): JDK 17 Zuul with Spring Boot 3
A small code sample that demonstrates the issue. I get an error trying to connect to my MQ-server using the following properties specified in application.yml:
However, if I replace this configuration with the following command-line params, everything works:
Possible cause:
com.ibm.mq.spring.boot.MQConnectionFactoryFactory#configureTLSStores
seems to mapMQConfigurationPropertiesJks
to system properties with prefixjakarta.net.ssl.*
andcom.ibm.ssl.*
instead ofjavax.net.ssl.*
i.e.: