Photo by NeONBRAND on Unsplash

Establishing SSL connection without server’s identity verification is not recommended. According to MySQL 5.5.45+, 5.6.26+ and 5.7.6+ requirements SSL connection must be established by default if explicit option isn’t set.

0Shares

When you are using MySQL in your mule project and you see the below warning, you have two options. Either configure SSL or disable it if it is in your development box:

Establishing SSL connection without server’s identity verification is not recommended. According to MySQL 5.5.45+, 5.6.26+ and 5.7.6+ requirements SSL connection must be established by default if explicit option isn’t set. For compliance with existing applications not using SSL the verifyServerCertificate property is set to ‘false’. You need either to explicitly disable SSL by setting useSSL=false, or set useSSL=true and provide truststore for server certificate verification.

I am using Anypoint Studio 7.3 and will show you how to fix it.

Here is my sample application that selects a query from MySQL database and populates the data.

Figure 1 – Overall Mule flow

So if you have a flow something like above, click on the “Database Select” operation based connector and click on the “Edit” icon in the “Basic Settings”:

Figure 2 – Edit Connector configuration

Go to “Advanced” section and select “Edit inline” for “Connection properties” and add key, value as “useSSL” and “false” and that should disable the check for SSL.

Figure 3 – Set property useSSL = false

Or simply go to “Configuration XML” tab and add the connection properties as below:

<db:config name=”Database_Config” doc:name=”Database Config” doc:id=”61c16a97-0f57-4418-9b7b-5ae434be33e2″ >
<db:my-sql-connection host=”localhost” port=”3306″ user=”user” password=”password” database=”db” >
<db:connection-properties >
<db:connection-property key=”useSSL” value=”false” />
</db:connection-properties>
</db:my-sql-connection>
</db:config>
0Shares