I encountered this issue while learning how to setup a Chef Server remotely. After installing Chef Server on a remote server, setting up Knife on my local workstation, I ran into the issue of having the wrong SSL certificate. The error on my computer looks like this:
$knife ssl check
Connecting to host remote.yjx.me:443
ERROR: The SSL cert is signed by a trusted authority but is not valid for the given hostname
ERROR: You are attempting to connect to: 'remote.yjx.me'
ERROR: The server's certificate belongs to 'remote.c.personal-172203.internal'