How to enable SSL? Http.sys problem
"An error occurred while making the HTTP request to https://dev01:8087/TestService/ep1. This could be due to the fact that the server certificate is not configured properly with HTTP.SYS in the HTTPS case. This could also be caused by a mismatch of the security binding between the client and the server."
Server binding is created programatically in selfhosting app:
BasicHttpBinding binding = new BasicHttpBinding();
binding.Security.Mode = BasicHttpSecurityMode.Transport;
binding.Security.Transport.ClientCredentialType = HttpClientCredentialType.None;
ServiceHost serviceHost = new ServiceHost(typeof(TestService),
new Uri("https://0.0.0.0:8087/TestService"));
serviceHost.AddServiceEndpoint(
typeof(ITestService),
binding,
"ep1");
serviceHost.Credentials.ServiceCertificate.SetCertificate(
StoreLocation.CurrentUser,
StoreName.My,
X509FindType.FindByThumbprint,
"24f01491216b94fb6b2c20b9e3724dcbb2c42391"
);
Client binding is through configuration file:
<bindings>
<basicHttpBinding>
<binding name="clientBinding">
<security mode="Transport"/>
</binding>
</basicHttpBinding>
</bindings>
I have already tried using httpcfg.exe to assign certificate to end point but it doesn't help.
Can anyone shed some light on the issue? What could be the cause of this problem?

