This is applicable for both Windows 7 and Windows Vista. Windows Firewall program allows you to add Programs and Port numbers which you trust to be added to the Firewall settings so they can pass through it.
Open Windows Firewall program under control panel. Once it’s open just look around for Allows Program through Firewall link and This is what you will see
This screen shot is taken from Windows 7 and here you will need to click on Change Settings tab which gets disabled once clicked. This is basically locking Default Settings. Everything is same in Windows Vista also except this default settings.
Moreover if you are wondering about Home/ Work and Public list of check boxes I will be talking about it in next post. Basically Windows 7 allows you to create network profile i.e. You can have different network settings for Home , Office or at friends place. So here you can select this setting will be availble in which network profile.
Clicking on add program will let you add any program which you can browse and select.
Clicking on Add Port button will let you add two types of port UDP and TCP.
While adding Port or Programs here, you would see Network Location Types Button in Windows 7 and Change Scope in Windows Vista. They both do almost same thing i.e. basically specifying which network profile it should be not blocked by the windows firewall.
As a summary : You can add programs and port number which passes through the firewall. However make sure you need to make sure which network profile you choose. If you have any doubt on this feel free to ask.