Hi I am getting following error when i run wcf services
An error occurred while making the HTTP request to
https://localhost:8732/Design_Time_Addresses/DemoService/HeaderService/. 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.
Please help with this
Result from httpcfg query ssl:
c:\Program Files\Microsoft Visual Studio 9.0\VC>httpcfg query ssl
IP : 0.0.0.0:8732
Hash : cd2e7afb5804332cf87e80ea60c645d3db81d53
Guid : {00000000-0000-0000-0000-000000000000}
CertStoreName : (null)
CertCheckMode : 0
RevocationFreshnessTime : 0
UrlRetrievalTimeout : 0
SslCtlIdentifier : (null)
SslCtlStoreName : (null)
Flags : 0
------------------------------------------------------------------------------
Service config:
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<system.serviceModel>
<services>
<service name="DemoService.HeaderService" behaviorConfiguration="DemoService.HeaderServiceBehavior">
<host>
<baseAddresses>
<add baseAddress="
https://localhost:8732/Design_Time_Addresses/DemoService/HeaderService/" />
<add baseAddress="
http://localhost:8181/Design_Time_Addresses/DemoService/HeaderService/" />
</baseAddresses>
</host>
<endpoint address="" binding="wsHttpBinding" contract="DemoService.IGetHeaders" bindingConfiguration="SecurityDemo"></endpoint>
<endpoint address="mex" binding="mexHttpsBinding" contract="IMetadataExchange" />
</service>
</services>
<bindings>
<wsHttpBinding>
<binding name="SecurityDemo">
<security mode="Transport" >
<transport clientCredentialType="None"/>
</security>
</binding>
</wsHttpBinding>
</bindings>
<behaviors>
<serviceBehaviors>
<behavior name="DemoService.HeaderServiceBehavior">
<serviceMetadata httpGetEnabled="True" httpsGetEnabled="True"/>
<serviceDebug includeExceptionDetailInFaults="True" />
<serviceCredentials>
<windowsAuthentication allowAnonymousLogons="True"/>
<serviceCertificate findValue="OlbDevelopment" storeLocation="LocalMachine" storeName="My" x509FindType="FindBySubjectName"/>
</serviceCredentials>
</behavior>
</serviceBehaviors>
</behaviors>
</system.serviceModel>
</configuration>
Client Config:
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<system.web>
<httpRuntime maxRequestLength="99999"/>
</system.web>
<system.serviceModel>
<bindings>
<wsHttpBinding>
<binding name="SecurityDemo">
<security mode="Transport">
<transport clientCredentialType="Certificate"/>
<message clientCredentialType="Windows"/>
</security>
</binding>
</wsHttpBinding>
</bindings>
<client>
<endpoint address="
https://localhost:8732/Design_Time_Addresses/DemoService/HeaderService/"
binding="wsHttpBinding" bindingConfiguration="SecurityDemo" behaviorConfiguration="CertificateDemo"
contract="DemoService.IGetHeaders"
name="IGetHeaders">
<headers>
<MyHeader name="Sample" xmlns="
http://tempuri.org">This is my header data</MyHeader>
</headers>
</endpoint>
</client>
<behaviors>
<endpointBehaviors>
<behavior name="CertificateDemo">
<clientCredentials>
<clientCertificate findValue="OlbDevelopment" storeLocation="LocalMachine"
storeName="My" x509FindType="FindBySubjectName" />
</clientCredentials>
</behavior>
</endpointBehaviors>
</behaviors>
</system.serviceModel>
</configuration>