Connection fails unless WorkBench connected

from the Artful MySQL Tips List

Since MySQL 8.0, default authentication caching_sha2_password, which on the first authentication since startip requires a secure connection; subsequent non-SSL authentications are allowed.

So when you find you need to connect via WB before you connect via your app (eg using Connector/J), that's probably what's going on. If MySQL is using caching_sha2_password, bulletproof app connection logic needs to be secure.

Last updated 23 Nov 2021

Return to the Artful MySQL Tips page