I am writing a WCF Web Service which support SOAP and REST. I also enabled the WCF REST Help Page which is very useful for the consumers of the Web Service. Since I enabled SSL in IIS and in the web.config (see below), I can't get the WCF REST Help Page anymore. If I access https://myHost/myWebService/help
, I get a HTTP 404 error. Prior to enabling SSL, I could access that page.
Below is my web.config. Can someone please help me understand how to enable WCF REST Help Page over HTTPS/SSL?
<?xml version="1.0"?>
<configuration>
<system.serviceModel>
<serviceHostingEnvironment aspNetCompatibilityEnabled="true" multipleSiteBindingsEnabled="true" />
<services>
<service name="MyNs.MyServiceWebserviceImpl" behaviorConfiguration="DefaultBehavior">
<endpoint name="MyServiceRestEndpoint" address="" binding="webHttpBinding" behaviorConfiguration="MyServiceRestBehavior" contract="MyNs.IMyServiceWebservice" />
<endpoint name="MyServiceSoapEndpoint" address="soap" binding="basicHttpBinding" bindingConfiguration="MyServiceSoapBinding" behaviorConfiguration="MyServiceSoapBehavior" contract="MyNs.IMyServiceWebservice" />
<endpoint name="MyServiceMexEndpoint" address="mex" binding="mexHttpsBinding" bindingConfiguration="" contract="IMetadataExchange" />
</service>
</services>
<behaviors>
<serviceBehaviors>
<behavior name="DefaultBehavior">
<serviceDebug includeExceptionDetailInFaults="true" />
<serviceMetadata httpGetEnabled="true" httpsGetEnabled="true" />
</behavior>
</serviceBehaviors>
<endpointBehaviors>
<behavior name="MyServiceRestBehavior">
<webHttp helpEnabled="true" defaultOutgoingResponseFormat="Json" automaticFormatSelectionEnabled="true" />
</behavior>
<behavior name="MyServiceSoapBehavior" />
</endpointBehaviors>
</behaviors>
<bindings>
<webHttpBinding>
<binding name="MyServiceRestBinding">
<security mode="Transport" />
</binding>
</webHttpBinding>
<basicHttpBinding>
<binding name="MyServiceSoapBinding">
<security mode="Transport" />
</binding>
</basicHttpBinding>
</bindings>
</system.serviceModel>
</configuration>