I have a project with multiple WCF services compiled, and accessible by another project on the same machine. Now I'm trying to connect to one of these services from another machine. I put the service refence URL, but it asks me for authentication. What should I do to be able to call the service? I have all methods available but at the time of running the program gives me the authentication error. I have the web.config service like this:
<!--Companies Service-->
<service name="BusinessServicesImplementation.CompaniesService"
behaviorConfiguration="BusinessServicesImplementation.GeneralServiceBehavior">
<endpoint address=""
binding="wsHttpBinding"
bindingConfiguration="wsHttpTransactionalBinding"
contract="BusinessServicesImplementation.ICompanyService">
<identity>
<dns value="localhost"/>
</identity>
</endpoint>
<endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange"/>
</service>
On the client side I have:
<binding name="WSHttpBinding_ICompanyService" transactionFlow="true" />
...
<endpoint address="http://URLEXTERIORÀMÁQUINA/Services/CompaniesService.svc"
binding="wsHttpBinding" bindingConfiguration="WSHttpBinding_ICompanyService"
contract="CompaniesService.ICompanyService" name="WSHttpBinding_ICompanyService">
<identity>
<dns value="localhost" />
</identity>
</endpoint>
In the design of the same service machine I have the address in the endpoint as localhost
, the rest is all the same and it works many years ago (it was done a long time ago, before I joined the company). How can I solve? Thanks