How To Display Firewall Rule Ports With Powershell

[Solved] How To Display Firewall Rule Ports With Powershell | Powershell - Code Explorer | yomemimo.com
Question : How to display firewall rule ports with powershell

Answered by : sylvain-jlio

Get-NetFirewallRule -DisplayGroup 'Remote Desktop' |
Format-Table -Property Name,
DisplayName,
DisplayGroup,
@{Name='Protocol';Expression={($PSItem | Get-NetFirewallPortFilter).Protocol}},
@{Name='LocalPort';Expression={($PSItem | Get-NetFirewallPortFilter).LocalPort}},
@{Name='RemotePort';Expression={($PSItem | Get-NetFirewallPortFilter).RemotePort}},
@{Name='RemoteAddress';Expression={($PSItem | Get-NetFirewallAddressFilter).RemoteAddress}},
Enabled,
Profile,
Direction,
Action

Source : https://itluke.online/2018/11/27/how-to-display-firewall-rule-ports-with-powershell/ | Last Update : Mon, 20 Jun 22

Answers related to How to display firewall rule ports with powershell

Code Explorer Popular Question For Powershell