C# REST wcf service with https cannot be reached on localhost -


i struggling https rest server running on localhost testing purposes ms visual studio 2015. regular http rest wcf server runs fine, when trying access localhost through https, seems down (site can't reached). have read instructions on the hanselman website try working, feel missing crucial step. possible missing (few) settings?

i assuming creation of certificate handled when enabling ssl in wcfservice project properties, correct?

here follows web.config file:

<?xml version="1.0"?> <configuration>   <appsettings>     <add key="aspnet:usetaskfriendlysynchronizationcontext" value="true"/>   </appsettings>   <system.web>     <compilation debug="true" targetframework="4.5.2"/>     <httpruntime targetframework="4.5.2"/>     <httpmodules>       <add name="applicationinsightswebtracking" type="microsoft.applicationinsights.web.applicationinsightshttpmodule, microsoft.ai.web"/>     </httpmodules>   </system.web>   <system.servicemodel>     <services>       <service name="wcfservice.service1" behaviorconfiguration="wcfservice.service1behavior" >          <host>           <baseaddresses>             <add baseaddress="https://localhost/" />           </baseaddresses>         </host>         <endpoint address=""                    binding="webhttpbinding"  bindingconfiguration="webhttptransportsecurity"                   behaviorconfiguration="wcfservice.service1endpointbehavior"                   contract="wcfservice.iservice1" />         <endpoint address="mex"                   binding="mexhttpbinding"                   contract="imetadataexchange" />       </service>     </services>     <bindings>       <webhttpbinding>         <binding name="webhttptransportsecurity">           <security mode="transport" />         </binding>       </webhttpbinding>       <wshttpbinding>         <binding name="transportsecurity">           <security mode="transport">             <transport clientcredentialtype="none"/>           </security>         </binding>       </wshttpbinding>     </bindings>     <behaviors>       <servicebehaviors>         <behavior name="wcfservice.service1behavior">           <!-- avoid disclosing metadata information, set values below false before deployment -->           <servicemetadata httpgetenabled="false" httpsgetenabled="true" />           <!-- receive exception details in faults debugging purposes, set value below true.  set false before deployment avoid disclosing exception information -->           <servicedebug includeexceptiondetailinfaults="true"/>         </behavior>       </servicebehaviors>       <endpointbehaviors>         <behavior name="wcfservice.service1endpointbehavior">           <webhttp/>         </behavior>       </endpointbehaviors>      </behaviors>     <protocolmapping>         <add binding="basichttpsbinding" scheme="https"/>     </protocolmapping>         <servicehostingenvironment aspnetcompatibilityenabled="true" multiplesitebindingsenabled="true"/>   </system.servicemodel>   <system.webserver>     <modules runallmanagedmodulesforallrequests="true">       <remove name="applicationinsightswebtracking"/>       <add name="applicationinsightswebtracking" type="microsoft.applicationinsights.web.applicationinsightshttpmodule, microsoft.ai.web"         precondition="managedhandler"/>     </modules>     <!--         browse web app root directory during debugging, set value below true.         set false before deployment avoid disclosing web app folder information.       -->     <directorybrowse enabled="true"/>     <validation validateintegratedmodeconfiguration="false"/>   </system.webserver> </configuration> 

the iis specific server deployment looks this:

...    <site name="wcfservice" id="2" serverautostart="true">      <application path="/" applicationpool="clr4integratedapppool">      <virtualdirectory path="/" physicalpath="c:\users\test\documents\visual studio 2015\projects\myproject\wcfservice" />      </application>      <bindings>         <binding protocol="http" bindinginformation="*:2444:localhost" />         <binding protocol="https" bindinginformation="*:44378:localhost" />      </bindings>    </site>  ...

all appreciated!


Comments

Popular posts from this blog

Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12:test (default-test) on project.Error occurred in starting fork -

windows - Debug iNetMgr.exe unhandle exception System.Management.Automation.CmdletInvocationException -

configurationsection - activeMq-5.13.3 setup configurations for wildfly 10.0.0 -