SAM2009
asked on
Check which ports are opened in a Windows server.
Hi,
If I'm in a Window 2008 or 2012 servers and I want to proof that some ports like Tcp 80, 443, 339 for example are opened not blocked by firewall how I can do that? Some time port are opened but there is just nothing listening, I mean there is no application installed which can respond.
Is there cmd or tool that just show what are opened?
Thanks
If I'm in a Window 2008 or 2012 servers and I want to proof that some ports like Tcp 80, 443, 339 for example are opened not blocked by firewall how I can do that? Some time port are opened but there is just nothing listening, I mean there is no application installed which can respond.
Is there cmd or tool that just show what are opened?
Thanks
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Jose, the server side is asked for. Probing a port can be done with telnet as soon as the port has a running process assigned to it, that much is true, but not the answer to this question.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
@dfke:
Sorry, but that is nonsense. nmap cannot scan for ports no-one is listening on. It can test whether a firewall actively rejects connects on ports, but silent discards are just resulting in timeouts as if there is no listening process.
And etc\services just lists names for ports, it does not open anything. The file is used for displaying purposes only.
Sorry, but that is nonsense. nmap cannot scan for ports no-one is listening on. It can test whether a firewall actively rejects connects on ports, but silent discards are just resulting in timeouts as if there is no listening process.
And etc\services just lists names for ports, it does not open anything. The file is used for displaying purposes only.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Sudeep brings up a good point.
If you have access to the machine in question, running this command will be much faster than running nmap...
This will tell you all listeners, from a localhost view.
All the above points still hold though, an open port can only be determined by scanning all ports.
If you have access to the machine in question, typical firewall approach is to...
1) Close all ports + protocols.
2) Create a few exemptions to open only those ports + protocols where server provides listeners.
If you have access to the machine in question, running this command will be much faster than running nmap...
netstat -pluten
This will tell you all listeners, from a localhost view.
All the above points still hold though, an open port can only be determined by scanning all ports.
If you have access to the machine in question, typical firewall approach is to...
1) Close all ports + protocols.
2) Create a few exemptions to open only those ports + protocols where server provides listeners.
I'm reading the original question the same way Qlemo is I think, essentially asking, "what protocol/port combination would a firewall let traffic through (assuming there was some process to receive it)?"
You could parse firewall rules to find this out, but one complication is the fact that many firewalls (including Windows Firewall) allow traffic based on more criteria than just protocol and port, e.g. destination application/service, source subnet, etc. So the thinking needs to be expanded there.
You could parse firewall rules to find this out, but one complication is the fact that many firewalls (including Windows Firewall) allow traffic based on more criteria than just protocol and port, e.g. destination application/service, source subnet, etc. So the thinking needs to be expanded there.
We need a more specific definition of the problem, and the solution that you desire. Would you expand on the problem statement, please?
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Yes David was right, my question is more:
"How do I check which ports have no firewall blocks in a Windows server? Is this required a listener?"
"How do I check which ports have no firewall blocks in a Windows server? Is this required a listener?"
The answer is "you cannot check without a listener".
Well... as I said... you can check + you'll have the same test result if there is no listener or if port is blocked by a firewall rule.
As Shaun + Sudeep stated, the only way to show all listeners or all firewall rules is testing on the local machine. In other words, there is no way to do this type of testing externally (offsite).
As Shaun + Sudeep stated, the only way to show all listeners or all firewall rules is testing on the local machine. In other words, there is no way to do this type of testing externally (offsite).
ASKER
Thanks!
You're welcome!
You can install it from the additional features from windows.
https://www.technipages.com/windows-10-enable-telnet
Then, use it like this
Open in new window
Open in new window