This issue occurs when there are issues with certificate trust either in the server certificate or in the client certificate.
The first error (General SSLEngine problem) alludes to issues with the server certificate and if the client can trust it.
The second error (bad_certificate) is related to issues with the client certificate, this could be missing authentication extension or some other issue.