With trial and error, I was able to fix this problem without disabling peer-to-peer testing, partly thanks to the MySQL documentation:
Important
Whatever method you use to create the certificate and key files, the common name used for the server / client certificate / key must be different from the common name used for the CA certificate. Otherwise, the certificate and key files will not work on servers compiled using OpenSSL. Typical error in this case:
ERROR 2026 (HY000): SSL connection error: error:00000001:lib(0):func(0):reason(1)
MySQL documentation
However, this only gave me part of the way. PHP defaults to VERIFY_IDENTITY , which requires a hostname match for a common name.
This satisfies everything:
CA: Assign a unique name. It could be anything. I just add root. in my fully qualified domain name.
client and server: assign the fully qualified domain name of the MySQL server. These two values ββmust match.
If the FQDN does not match between the client and server, VERIFY_IDENTITY will fail.
If the FQDN matches between ca, the client, and the server, then OpenSSL in PHP will fail, as promised in the MySQL documentation.
source share