VB.NET – Expose WCF Service Unable to retrieve objects via Windows firewall

I built a WCF service that exposes itself for a web application, it accepts an object and prints the data on the client machine. It works fine on my development machine, and the The service is up and running on any machine where I installed it. I can enter the IP address in the client web browser to see if it is running. The problem is that when I send the object to the client computer, it returns an error , It sounds like it might be because of the client-side Windows firewall. Where do I start to deal with this problem?

There is no endpoint that can accept the message at http://192.168.1.168:2202/PrintLabel. This is usually caused by a wrong address or SOAP operation. For more details, please See InnerException (if it exists).

And InnerException: Unable to connect to remote server

Through further research and discussion with community members, I started to understand as mentioned at the bottom of this article.
“WCF’s self-hosted HTTP addressing is not integrated into Windows Firewall. An exception must be added in the firewall configuration To allow inbound connections using specific URLs.

But this SO question led me to a page where I explained how to control the Windows firewall through code to enable my WCF self-hosted service Accept an object.
This link is as follows.

http://www.shafqatahmed.com/2008/01/controlling-win.html

This link is towards what I need But according to user comments, it seems to have some errors. A colleague found this link, I believe this technique will be the best solution for this situation.

I built a WCF service that exposes itself for a web application, it accepts an object and prints the data on the client machine. It works fine on my development machine, and the service is on any machine where I install it I can enter the IP address in the client’s web browser to see if it is running. The problem is that when I send the object to the client computer, it returns an error, it sounds like it might be because of the client Windows Firewall. Where do I start to deal with this issue?

There is no endpoint at http://192.168.1.168:2202/PrintLabel that can accept the message. This is usually caused by the wrong address or Caused by SOAP operation. For more details, please refer to InnerException (if it exists).

And InnerException: Unable to connect to remote server

< p>Through further research and discussion with community members, I began to understand as mentioned at the bottom of this article.
“WCF’s self-hosted HTTP addressing is not set Into the Windows firewall. Exceptions must be added to the firewall configuration to allow inbound connections using specific URLs.

But this SO question led me to a page that explains how to pass The code controls the Windows firewall so that my WCF self-hosted service can accept an object.
This link is as follows.

http://www.shafqatahmed.com/2008/01/controlling-win.html

This link is going in the direction I need, but based on user comments, it seems to have some errors. A colleague found this link and I believe this technique will be the best solution for this situation .

Leave a Comment

Your email address will not be published.