Search code examples
wcfwcf-bindingwcf-client

WCF testing : need to use machine name instead of ip address on remote machine


I am using https for a web service and the certificate is a temporary one I created and then imported it to a remote machine. The binding of my WCF service uses the machine name not the ip address. I want to test the service on a remote machine but the only way the service is accessible is to use the ip address by changing the client address for the service. But then the service fails because the certificate expects the machine name and not the ip address. How can I use the machine name and not the ip address to access the remote server?


Solution

  • Create binding for ip address in the hosts file (C:\Windows\System32\drivers\etc) and then use this binding instead of ip.