Connection to MySQL with SSL (.pem + .key)


I’m trying to connect to an KNIME with a MySQL Database with SSL certificate (.pem) and a private key.

Unfortunately I can’t find a way to include both files (.pem + .key) in a node or in the properties.

Can anyone help me or has experience with such a connection?

Thank you.

Hello ArtBra,
first you need to import the certificate and the private key into the Java keystore so that they can be used by the Java SSL library. For more details on this see the Setting up Client Authentication section of the MySQL documentation.

Once this is done you need to tell KNIME to use the truststore. You can do this either by appending the following two lines to the end of your knime.ini file which is located in the KNIME installation folder: path_to_keystore_file mypassword

or you can specify them as JDBC Parameters in the connector node. In KNIME 4.0 you open the node dialog of the MySQL Connector node and go to the JDBC Parameters tab. In the tab add the following two parameters with the appropriate file path:

clientCertificateKeyStorePassword= mypassword


Instead of writing the password in plain text into the node dialog you can also use the Credentials Configuration node and connect it to the MySQL Connector node.


Once they are connected you can select the Credentials - password Type in the Type column of the table and then selecting the name of the credential in the Value column.




This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.