Process to Port Computer Property

(imported topic written by dav200191)

Hello,

I am trying to find a way to enumerate certain service processes (name and PID) on a computer and the port on which they are listening.

I have not found anything in the WMI that can pull this information.

Any help is appreciated.

Thanks!

(imported comment written by BenKus)

Hi dav2001,

I am not sure if you can get this information in WMI, do you know of any commandline option or tool that displays this info?

Ben

(imported comment written by dav200191)

I think something like “netstat -na | find “LISTENING”” would pull the listening TCP processes and return the PID, but I am not sure how to incorperate that into a property.