如果客户端使用证书进行身份验证,如何在wcf中使用客户端证书身份验证?
答案 0 :(得分:2)
您必须设置
<transport clientCredentialType="Certificate" />
在您的服务配置中,告诉WCF客户端证书提供了crendential。
并设置messageEncoding =“Mtom”
<wsHttpBinding>
<binding name="wshttpconfig" messageEncoding="Mtom">
<readerQuotas maxArrayLength="64000" />
<security mode="Transport">
<transport clientCredentialType="Certificate" />
</security>
</binding>
</wsHttpBinding>
查看此链接
An easy way to use certificates for WCF security
Configuring WCF for client certificate authentication
Using Certificate-based Authentication and Protection with Windows Communication Foundation (WCF)
再见。