Warning about SSL connection when connecting to MySQL database
Your connection URL should look like the below,
jdbc:mysql://localhost:3306/Peoples?autoReconnect=true&useSSL=false
This will disable SSL and also suppress the SSL errors.
How about using SSL but turning off server verification (such as when in development mode on your own computer):
jdbc:mysql://localhost:3306/Peoples?verifyServerCertificate=false&useSSL=true
Mention the url
like:
jdbc:mysql://hostname:3306/hibernatedb?autoReconnect=true&useSSL=false
But in xml configuration when you mention &
sign, the IDE shows below error:
The reference to entity "useSSL" must end with the ';' delimiter.
And then you have to explicitly use the &
instead of &
to be determined as &
by xml
thereafter in xml
you have to give the url in xml configuration like this:
<property name="connection.url">jdbc:mysql://hostname:3306/hibernatedb?autoReconnect=true&useSSL=false</property>