使用摘要客户端身份验证方法(ASP.NET)访问ASMX Web服务

问题描述 投票:2回答:0

访问使用摘要式身份验证的AMSX Web服务,我已将网站的web.config文件配置如下:

<system.serviceModel>
    <bindings>
      <basicHttpBinding>
        <binding name="SEWebServiceSoap" >
          <security mode="TransportCredentialOnly" >
            <transport clientCredentialType="Digest" />
          </security>
        </binding>
      </basicHttpBinding>
    </bindings>
    <client>
      <endpoint address="http://localhost:00000/SEWebService.asmx" binding="basicHttpBinding" bindingConfiguration="SEWebServiceSoap" contract="SEWS.SEWebServiceSoap" name="SEWebServiceSoap" />
    </client>
    <behaviors>
      <endpointBehaviors>
        <behavior name="impersonationBehavior">
          <clientCredentials>
            <!--<windows allowedImpersonationLevel="Impersonation" allowNtlm="false" />-->
            <httpDigest impersonationLevel="Impersonation" />
          </clientCredentials>
        </behavior>
      </endpointBehaviors>
    </behaviors>
  </system.serviceModel>

但我不断收到此错误消息:

指定了模拟级别“ Identification”,但HTTP Digest身份验证仅在与显式凭据一起使用时才支持“ Impersonation”级别。

我已经搜索了很多,但是没有找到信息。 有什么线索吗?

c# asp.net asmx impersonation digest-authentication
© www.soinside.com 2019 - 2024. All rights reserved.