SSL的WCF服务问题

SSL的WCF服务问题,wcf,Wcf,我在控制台应用程序中通过SSL调用WCf服务时遇到问题。WCF服务位于Windows Server 2003上。这是简单的数学服务。WCF服务和客户端位于同一台计算机上。这是测试,我在本地主机上调用服务 web.confing <?xml version="1.0"?> <configuration> <system.serviceModel> <services> <service name=

我在控制台应用程序中通过SSL调用WCf服务时遇到问题。WCF服务位于Windows Server 2003上。这是简单的数学服务。WCF服务和客户端位于同一台计算机上。这是测试,我在本地主机上调用服务

web.confing

<?xml version="1.0"?>
<configuration>
    <system.serviceModel>
        <services>
            <service name="Service.CalculatorService" behaviorConfiguration="CalculatorServiceBehavior">
                <endpoint address="https://machineName/https/calculatorservice.svc" name="myEndpoint" binding="basicHttpBinding" 
                  bindingConfiguration="Binding1" contract="Service.ICalculator"/>
            </service>
        </services>
        <bindings>
            <basicHttpBinding>
                <binding name="Binding1">
                    <security mode="Transport">
                        <transport clientCredentialType="None"/>
                    </security>
                </binding>
            </basicHttpBinding>
        </bindings>
        <behaviors>
   <serviceBehaviors>
    <behavior name="CalculatorServiceBehavior">
      <serviceMetadata httpsGetEnabled="true"
        httpsGetUrl="https://machineName/https/calculatorservice.svc" />
     <serviceDebug includeExceptionDetailInFaults="false" />
    </behavior>
   </serviceBehaviors>
  </behaviors>
    </system.serviceModel>
    <system.web>
        <compilation debug="true"/></system.web></configuration>

如果我从Visual Studio examaple调用服务: 我得到一个错误: 不支持协议“https”。我认为可以

但如果我从浏览器调用服务,则会出现错误:

URI“”的注册已存在。


什么是坏的?有人能帮我吗,谢谢。

从端点元素中删除“地址”属性-当您在IIS中托管时,它会自动提供此属性。

从端点元素中删除“地址”属性-当您在IIS中托管时,它会自动提供此属性。

Visual Studio Development Server不支持https。您需要在IIS中托管服务
Visual Studio Development Server不支持https。您需要在IIS中托管服务