I have a simple Web Socket Server Application (SuperWebSocket) which I use to communicate with JavaScript. The idea here is to allow a local application to communicate with a browser. I'm developing this application for Windows 7 & 8 platforms.
The problem which I am having is that during the initial run, the Windows firewall shows the Security Alert for blocking communication to public domains. My application does not communicate with any resource outside the PC and therefore regardless whether we select unblock or block, the application will work.
My question is, can we avoid this security warning programatically? If the PC does not allow firewall access, is it possible to allow it to block it silently without popping any warnings?
I'm using WiX Installer to create a MSI package which will distribute the application. Is there any way we can set firewall permissions during install time?
The basic idea is to allow the program to run with minimal user interactions.
Thanks in Advance.
Update:
It seems that the issue was in the SuperWebSocket which binds the socket to all available interfaces. Something similar to this,
TcpListener _listener = new TcpListener(IPAddress.Any, 21000);
However, If I use something like this,
TcpListener _listener = new TcpListener(IPAddress.Loopback, 21000);
The warning does not appear anymore. I tested this on a Windows 8 PC.