Hi all,
I can connect to Oracle DB with an SSL certificate via JDBC (see code
snippet below). However, I have problems to connect with OpenJPA. Any hints
and tips are appreciated.
Regards,
Martin
try {
Connection conn = null;
FileInputStream pin = new FileInputStream(
"/home/iopapp/java/dbconnection_properties");
Properties cnxProp = new Properties();
cnxProp.load(pin);
String url = cnxProp.getProperty("url");
cnxProp.remove("url");
OracleDataSource ods = new OracleDataSource();
ods.setURL(url);
ods.setConnectionProperties(cnxProp);
conn = ods.getConnection();
} catch (Exception exception) {
exception.printStackTrace();
}
file /home/iopapp/java/dbconnection_properties:
url=url=jdbc:oracle:thin:@DZHLOD2003-scan.ch.hedani.net:1523:DZHIOP10
javax.net.ssl.keyStore=/opt/pki/etc/spid_S107973_T.keystore.properties
javax.net.ssl.trustStore=/opt/pki/etc/tca/trusted_ca_cs.properties
javax.net.ssl.trustStoreType=CS_PKI
javax.net.ssl.keyStoreType=CS_PKI
javax.net.ssl.trustStorePassword=not_used
javax.net.ssl.keyStorePassword=not_used
oracle.net.authentication_services=(TCPS)
oracle.net.ssl_client_authentication=TRUE
oracle.net.ssl_cipher_suites=(TLS_RSA_WITH_AES_256_CBC_SHA)
ssl.keyManagerFactory.algorithm=SunX509
--
View this message in context:
http://openjpa.208410.n2.nabble.com/Oracle-DB-authentication-with-SSL-certificate-tp7538367.html
Sent from the OpenJPA Users mailing list archive at Nabble.com.