One of the top OWASP issues is security mis-configuration. So as the case with MySQL and other Database servers are mis-configured to allow sensitive data leak

Database servers should be configured properly, which should be using TLS certificates , than a self -signed one