I am trying to find a way to use powershell to query a sql server and provide back the instance names with the port numbers used, then ideally get the port numbers and add them to specific rules I create for the Windows firewall.
Currently I use the netsh commands for the firewall config and go to the gui to locate the ports.
Prior to Win8, there are no cmdlets for querying the firewall or modifying it. And prior to SQL2012 I'm not aware of any that could be used to gather that SQL information. I'm not a SQL PowerShell expert, though.