Hi,i would like to know if there is a way to know the ports a program is trying to use,or is already using,in order to know which ports should i open.

Thanks