相关疑难解决方法(0)

如何在IIS中仅使用WCF进行basichttpbinding,SSL和基本身份验证?

是否可以仅使用BasicHttpBinding绑定在IIS中使用SSL和基本身份验证设置WCF服务?(我不能使用wsHttpBinding绑定)

该站点托管在IIS 7上,并设置了以下身份验证:

   - Anonymous access: off
   - Basic authentication: on
   - Integrated Windows authentication: off !!
Run Code Online (Sandbox Code Playgroud)

服务配置:

<services>
  <service name="NameSpace.SomeService">
    <host>
      <baseAddresses>
        <add baseAddress="https://hostname/SomeService/" />
      </baseAddresses>

    </host>
    <!-- Service Endpoints -->
    <endpoint address="" binding="basicHttpBinding"
              bindingNamespace="http://hostname/SomeMethodName/1"
              contract="NameSpace.ISomeInterfaceService"
              name="Default"
                      />
    <endpoint address="mex" binding="mexHttpsBinding" contract="IMetadataExchange"/>
  </service>
</services>
<behaviors>
  <serviceBehaviors>
    <behavior>
      <!-- To avoid disclosing metadata information, set the value below to false and remove the metadata endpoint above before deployment -->
      <serviceMetadata httpsGetEnabled="true"/>
      <!-- To receive exception details in faults for debugging …
Run Code Online (Sandbox Code Playgroud)

ssl wcf basichttpbinding wcf-binding wcf-security

19
推荐指数
1
解决办法
5万
查看次数

标签 统计

basichttpbinding ×1

ssl ×1

wcf ×1

wcf-binding ×1

wcf-security ×1