Configuring the host firewall
A host firewall is a VMware vSphere feature to protect the host against attacks. The host firewall allows or blocks traffic to and from specific host services. You can use PowerCLI to configure the host firewall.
To get a list of all of the PowerCLI cmdlets that you can use to configure a host firewall, type:
PowerCLI C:\> Get-Command -Noun VMHostFirewall* CommandType Name ----------- ---- Cmdlet Get-VMHostFirewallDefaultPolicy Cmdlet Get-VMHostFirewallException Cmdlet Set-VMHostFirewallDefaultPolicy Cmdlet Set-VMHostFirewallException
Getting the host firewall default policy
To get the host firewall default policy of a host, you have to use the Get-VMHostFirewallDefaultPolicy
cmdlet.
The syntax of the Get-VMHostFirewallDefaultPolicy
cmdlet is:
Get-VMHostFirewallDefaultPolicy [-VMHost] <VMHost[]> [[-Server] <VIServer[]>] [<CommonParameters>]
Let's first get the host firewall default policy for a host...