Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'm not sure whether this is a Windows problem or a .NET problem (i.e. whether it belongs here on on SO), but I've written a small HTTP server program in C# (using the .NET HttpListner class) which works fine for the most part, but Windows Firewall seems to be refusing to let connections through to it from anything other than localhost. I've added exceptions for TCP and UDP in the "Inbound Rules" section of the firewall settings, essentially duplicating existing rules for other HTTP-based services which work fine (e.g. foo_httpcontrol). Specifically, I've added separate rules for TCP and UDP connections covering all ports, specific to the executable I'm running.

There's no problem when Windows Firewall is disabled, but if I enable it, the connection simply times out.

share|improve this question

2 Answers 2

If this is a server I think you also need to allow outbound connections for it. You said you allowed inbound connections to the server (you can connect to it) but you did not create a rule for outbound connections (it can't respond) and the connection times out.

You can also try Windows Firewall Control to debug this:

http://binisoft.org/wfc.php

It has a window where are displayed the last blocked connections from Windows Firewall. If you check this log you will be able to see what was blocked recently and needs to be allowed. I hope this helps.

share|improve this answer

HttpListener uses Http.sys. See this msdn article.

share|improve this answer
    
What does it have to do with @Will's question? –  noloader Jun 21 at 17:45

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.