以索赔模式托管在Sharepoint中的WCF服务
我在声明模式下为Https配置了sharepoint服务器。我在sharepoint服务器中托管了WCF服务。此WCF服务器使用客户端证书进行身份验证 WCF服务使用BasicHttpBinding 在客户端,以下是绑定:以索赔模式托管在Sharepoint中的WCF服务,wcf,sharepoint,claims,Wcf,Sharepoint,Claims,我在声明模式下为Https配置了sharepoint服务器。我在sharepoint服务器中托管了WCF服务。此WCF服务器使用客户端证书进行身份验证 WCF服务使用BasicHttpBinding 在客户端,以下是绑定: BasicHttpBinding binding = new BasicHttpBinding(); binding.TransferMode = TransferMode.StreamedResponse; binding.Security.Mode = BasicHttp
BasicHttpBinding binding = new BasicHttpBinding();
binding.TransferMode = TransferMode.StreamedResponse;
binding.Security.Mode = BasicHttpSecurityMode.Transport;
binding.Security.Transport.ClientCredentialType = HttpClientCredentialType.Certificate;
binding.Security.Transport.ProxyCredentialType = HttpProxyCredentialType.Ntlm;
我还使用以下调用设置了客户端证书:
base.ClientCredentials.ClientCertificate.SetCertificate(
"CN=tempClientcert", StoreLocation.LocalMachine, StoreName.My
);
客户端证书已在客户端和服务器中正确设置
当我尝试调用服务时,出现以下错误:
System.Security.MessageSecurityException : The HTTP request is unauthorized
with client authentication scheme 'Anonymous'. The authentication header
received from the server was 'NTLM'
虽然我已将客户端凭据设置为证书,但不清楚为什么它会说http客户端身份验证方案是匿名的。看起来此配置可能有一定的相关性?注意模式-仅传输WCF服务支持许多传输选项,但它们未完全集成到SharePoint中