Windows Firewall
Jump to navigation
Jump to search
(Get-NetFirewallProfile -Name Domain | Get-NetFirewallRule | select DisplayName | findstr "Skype" | Measure-Object).Count ((Get-NetFirewallProfile -Name Domain | Get-NetFirewallRule | select DisplayName | findstr "Skype" | Measure-Object) | select Count).Count Get-NetFirewallProfile -Name Private | Get-NetFirewallRule | select -first 3 -property action,direction
function get_vpn_netcat() { $netcat=(Get-NetConnectionProfile -InterfaceAlias (Get-NetAdapter -Name "*" | Where-Object {$_.InterfaceDescription -Match "^Cisco.*"} | select Name,InterfaceDescription,ifIndex,Status,MacAddress,LinkSpeed).Name).NetworkCategory if ($netcat -eq "DomainAuthenticated"){ write-host 1 }elseif($netcat -eq "Private"){ write-host 2 }elseif($netcat -eq "Public"){ write-host 3 }else{ write-host 4 } }