use WCF service method returns The caller was not authenticated by the service

0

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

    
asked by anonymous 03.08.2017 / 15:43

1 answer

0

It may be the machine firewall that is preventing incoming requests. It checks which port the service is using and it frees it in the Windows firewall.

    
07.08.2017 / 04:55