X.509 certificates on WCF is not working for netTcpBinding
X.509 certificates on WCF is not working for netTcpBinding
My client application can easily access service
hear is my App.config for Tcp/ip service
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<system.web>
<compilation debug="true" />
</system.web>
<!-- When deploying the service library project, the content of the config file must be added to the host's
app.config file. System.Configuration does not support config files for libraries. -->
<system.serviceModel>
<bindings>
<netTcpBinding>
<binding name="NewBinding0">
<security>
<message clientCredentialType="Certificate" />
</security>
</binding >
</netTcpBinding>
</bindings>
<services>
<service behaviorConfiguration="ServiceSqlToAccess.Service1Behavior"
name="ServiceSqlToAccess.clsInsertData">
<endpoint address="" binding="netTcpBinding" bindingConfiguration=""
contract="ServiceSqlToAccess.InterFace1">
<identity>
<dns value="localhost" />
<certificateReference storeName="Root" storeLocation="CurrentUser" findValue="WCFServer" x509FindType="FindBySubjectName" />
</identity>
</endpoint>
<endpoint address="mex" binding="mexTcpBinding" bindingConfiguration=""
contract="IMetadataExchange" />
<host>
<baseAddresses>
<add baseAddress="net.tcp://localhost:8731/TransferToAccess/" />
</baseAddresses>
</host>
</service>
</services>
<behaviors>
<serviceBehaviors>
<behavior name="ServiceSqlToAccess.Service1Behavior">
<serviceCredentials>
<clientCertificate>
<authentication certificateValidationMode="PeerTrust" />
</clientCertificate>
<serviceCertificate findValue="WCFServer" storeLocation="CurrentUser" storeName="My" x509FindType="FindBySubjectName" />
</serviceCredentials>
<serviceMetadata httpGetEnabled="false" />
<serviceDebug includeExceptionDetailInFaults="false" />
</behavior>
</serviceBehaviors>
</behaviors>
</system.serviceModel>
</configuration>