Hi
Can someone please help?
I’ve created a solution to communication with the MESH API. The development was done using the SANDBOX solution and everything worked well.
Now that I’ve moved to the Integration environment, I am getting the below error. I have altered the Password, MailboxId and Sharekey as instructed\provided, but I’m still getting this error. Does anyone know what I have done wrong or missed?
“Authentication failed because the remote party sent a TLS alert: ‘HandshakeFailure’.” with the inner exception of {“The message received was unexpected or badly formatted.”}.
Thanks
P.S.
The solution is build in C# and is sending\attaching the cert using the below code
private HttpClient GetHttpClientCertificate()
{
if (string.IsNullOrEmpty(_meshClientCertPassword) || string.IsNullOrEmpty(_meshClientCertPassword))
return new HttpClient();
var handler = new HttpClientHandler()
{
SslProtocols = System.Security.Authentication.SslProtocols.Tls12 | System.Security.Authentication.SslProtocols.Tls13 | System.Security.Authentication.SslProtocols.Tls11,
UseDefaultCredentials = true
};
handler.ClientCertificates.Add(new X509Certificate2(_meshClientCertPath, _meshClientCertPassword));
return new HttpClient(handler);
}