Hi all,
Was curious if anyone can share a link to the properties list that are applicable to the TigerGraph RestPP Driver:
https://github.com/tigergraph/ecosys/tree/master/etl/tg-jdbc-driver
I don’t see any SSL example or anything in the README.
I’m particularly looking to do mutual SSL so I just need to know which props are required.
I assume there should be maybe 5? truststore, truststorePass, keystore, keystorePass, and ssl?
Having trouble finding anything useful.
The properties list in the java.sql.Driver javadocs is nonexistent: Driver (Java SE 11 & JDK 11 )
What’s the point of docs if they’re not even useful? :0
Any help or link would be appreciated.
Hi Brett Renshaw,
Are your trying to use the JDBC driver with ssl? If so, you can simply change ‘http’ to ‘https’ when creating a JDBC connection, like this:
Connection con = driver.connect("jdbc:tg:https://127.0.0.1:14240", properties)
Any issue please let me know.
Thanks,
Yong
I know what the connection string is supposed to look like, I am just wondering what
are the property key names that I should use to specify the keystore, truststore, etc
in the properties variable. Unless you’re saying that I don’t need to specify certs to use SSL?
Hi Brett,
Please refer to this link to set up SSL:
https://docs.tigergraph.com/admin/admin-guide/data-encryption/encrypting-connections#step-2-configure-ssl-with-gadmin
You need to pass your nginx public certificate to the keystore.
Thanks,
Kevin
Thanks for the responses.
Maybe I was being unclear before, though. I am trying to figure out the Java app side properties, not the NGINX server properties.
There is already documentation for the NGINX settings thankfully.
So, back to the Java app side, when you call the connect method on the com.tigergraph.jdbc Driver, you are supposed to provide properties.
For reference:
https://github.com/tigergraph/ecosys/tree/master/etl/tg-jdbc-driver#minimum-viable-snippet
I don’t see anything in the README about setting ssl properties in the Properties variable.
So what I was wondering, is what are the Property key names that I should use to set the ssl variables?
I am looking for something like properties.setProperty(“someSSLProperty”, "someSSLPropertyValue).
I had found this, scroll down to the JSSE Related Properties section:
https://docs.oracle.com/cd/B19306_01/java.102/b14355/sslthin.htm#BABCBGDB
But I am not sure if it is applicable.
Hi Brett,
You may enable ssl simply by changing “http” to “https” when creating a JDBC connection, like this:
Connection con = driver.connect("jdbc:tg:https://127.0.0.1:14240", properties))
``
Please also provide username/password via properties if auth is enabled.
Thanks,
Yong
Hi Brett,
Sorry, I’ve just seen your previous email. There’s no need to provide keystore/truststore, just provide username/password if auth is enabled.
Thanks,
Yong
Hi Brett,
Sorry again. After checking the source code, currently the JDBC driver does not support some SSL options. I’ll add its support and keep you updated.
Thanks,
Yong
Thank you! That makes sense.
Please shoot a link to the docs when it’s ready.