开发者

Accessing WCF service with Integrated Windows Authentication from Windows Service using local SYSTEM account

We have WCF service using Integrated windows authentication deployed on a dedicated server. There will be Windows Service开发者_运维百科 on Client machines[windows service uses Local System Account].We get an error when the WCFServiceClient in Windows service accesses the WCF service.[If windows service is on server machine it works fine]

System.ServiceModel.Security.MessageSecurityException: The HTTP request is unauthorized with client authentication scheme 'Negotiate'. The authentication header received from the server was 'Negotiate,NTLM'. ---> System.Net.WebException: The remote server returned an error: (401) Unauthorized.
   at System.Net.HttpWebRequest.GetResponse()
   at System.ServiceModel.Channels.HttpChannelFactory.HttpRequestChannel.HttpChannelRequest.WaitForReply(TimeSpan timeout)

We cannot allow anonymous access or can not remove windows authentication from WCF service. Is there a way to get around this problem.

The config on client side is

<basicHttpBinding>
        <binding name="BasicServiceHttpBinding">
          <security mode="TransportCredentialOnly">
            <transport clientCredentialType="Windows" proxyCredentialType="None"
              realm="" />
            <message clientCredentialType="UserName" algorithmSuite="Default" />
          </security>
        </binding>
</basicHttpBinding>

The server config is

 <basicHttpBinding>
        <binding>
          <security mode="TransportCredentialOnly">
            <transport clientCredentialType="Windows" />
          </security>
        /binding>
  </basicHttpBinding>
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜