I want to open up and control a specific port for my application. How to?

Hi there;

I want to open up and control a specific port for my application. How to?

When I go for Windows Firewall, I see a list of program but what I want is that I want to open up a specific port totally for incoming requests.

How to do that?

Kind regards.
LVL 12
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

You can do that from "Windows Firewall with Advanced Security".
You can get this if you go to firewall and click on "Advanced Settings" on the left pane.

Hope this helps.
jazzIIIloveAuthor Commented:
I know this, but then what?

computer 1
program 1 uses port 12345

computer 2
another program uses port 12345

So, what should be the firewall settings of both computers?

Kind regards.
these are two links from microsoft that explain how to allow a program to comunicate through windows firewall:http://windows.microsoft.com/en-US/windows7/Allow-a-program-to-communicate-through-Windows-Firewall
And how to open ports in the windows firewall: http://windows.microsoft.com/en-US/windows7/Open-a-port-in-Windows-Firewall
I understand both computers are in the same intranet, aren't they?
Webinar: Cyber Crime Becomes Big Business

The rising threat of malware-as-a-service is not one to be overlooked. Malware-as-a-service is growing and easily purchased from a full-service cyber-criminal store in a “Virus Depot” fashion. Join us in our upcoming webinar as we discuss how to best defend against these attacks!

you will need to create Inbound and Out bound Rules for Both PC on port 12345 specifying those ports
1. Depending on the direction of the traffic that you need to allow, you will right click on "Inbound Rules" and/or "Outbound Rules" then choose "New Rule".
2. Choose "Custom", click "Next"
3. Choose the "Program Path", click "Next"
4. Choose what port settings you need, click "Next"
5. Choose what IP address(es) you need, click "Next"
6. Choose to "Allow Connection"
7. Choose the relevant Network Profile, click "Next"
8. Choose a "Name" and click "Finish"

jazzIIIloveAuthor Commented:
Hi there;

So, if a firewall is disabled, no need to do such rule as inbound or outbound, am i right?

Kind regards.
True but ill advised due to the fact that it opens you up to potential security risks
It would be useful to start by testing with disabling the firewall to check if the application is working at all.
After you clear this stage then you will be sure that any coming issue is due to some firewall are misconfiguration.

Such test should not be made unless you have a secured private environment, not something internet facing for example...
jazzIIIloveAuthor Commented:
ok the entities are as follows:

computer 1
server.exe uses port 12345, he listens and accepts clients

computer 2
client.exe uses port 12345, he connects to server to send some info

so, given this, please give me the inbound and outbounds rules roughly.

Kind regards.
Sometimes Port settings are better controlled by accessing your DSL Modem's internal settings.  You can usually access these settings pages by entering the Modem's IP address in your web browser like this:
That is a fairly commonly used modem IP address.  Yours could easily be different, so you would have to consult your user manual.  Be advised also that your manual should tell you what the Default UserName and Password are for the modem.  Quite often it is "admin" for both.  It is better to change the password to your own one.

There should be a Firewall page in your modem's internal settings pages where you can allow or disallow inbound and/or outbound traffic for Ports commonly used by a list of applications.  You should also be able to create a custom application profile with the specified inbound and outbound port(s) and then enable it.

Where more than one computer is connected to the Internet through the modem you will see each listed by the ComputerName, and each can have its own modem firewall settings.

If you prefer to control things using only the built-in Windows Firewall but your new settings don't work, then you should familiarise yourself with your modem's settings pages just in case that is where traffic is being blocked.
jazzIIIloveAuthor Commented:
Ah, I really want to stick Windows Firewall at first. So I love to have a screenshot for rules as an example.

But here you go for my Thomson Gateway (what is a gateway; is it a router, modem or both or what);

How can I do it?

I tried to this port forwarding thing, but not sure what to do? My application uses the TCP port 11111.

Günaydin! jazzIIIlove

A Gateway is just a device that controls what goes in and out of a network.  I suppose you could call your Thomson device a "Residential Gateway" or "Home Gateway", which is a mix of Router, DSL/Cable Modem, and Wireless Access Point all in one small unit.  So it is just a modem that you can configure to block or allow certain packets of data to enter or leave when connected to the Internet or other computers on your home network.

Here is the Thomson page for your TG784 device:
It will redirect to the correct product at:

Don't worry about the name.  Thomson have used many names including Alcatel, SpeedTouch, etc.

There have been two models: 8.2.x and 8.4.x
The 8.2 tab has a lot more documents that probably still relate to the 8.4 model.  Unfortunately I don't see one in Turkish.  The "Setup and User Guide" documents do not give a lot of detail about configuring the Firewall.  Down at the bottom of the 8.2 documents there is one named "Stateful Inspection Firewall Configuration Guide" that is very informative and tells you a lot more about the device's Firewall.

First off, the officially registered TCP or UDP Port 11111 is referred to by the name "Viral Computing Environment (VCE)", which makes me rather concerned that it is not the best port for your software to be using:

I cannot find a good description of what this port is commonly used for or how safe it is, but I see suggestions that this port "is known to have vulnerabilities caused by trojans and remote code execution."  Whether or not this is an accurate description I do not know.  I am not an expert in that particular area.

You would generally expect an application to use a port that falls inside a range of port numbers used by similar applications.  That port could be one near to a "Well Known" port number within the range 0 to 1023.  The "Registered" ports are in the range 1024-49151:

As far as the Windows Firewall is concerned, here are some instructions:

Good Video for Windows 7 - very strong South of England accent:

Good Video for Windows XP Firewall, generic Gateway/Router and Wi-Fi info (French accent but understandable):


Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Thank you jazzIIIlove
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.