Set-VMHostFirewallException

This cmdlet activates or deactivates host firewall exceptions.

Syntax

[-Exception]  <VMHostFirewallException[]>
-Enabled  <Boolean>
[CommonParameters]

Parameters

Required Parameter Name Type Position Features Description
required
Exception
VMHostFirewallException[] 1
  • pipeline
  • Specifies the firewall exceptions you want to activate or deactivate.
    required
    Enabled
    Boolean named If the value is $true, the specified firewall exceptions are activated. If the value is $false, the firewall exceptions are deactivated.

    Output

    VMware.VimAutomation.ViCore.Types.V1.Host.VMHostFirewallException

    Examples


    Example 1

    $ftpFirewallExceptions = Get-VMHostFirewallException -VMHost $vmhost | where {$_.Name.StartsWith('FTP')}
    $ftpFirewallExceptions | Set-VMHostFirewallException -Enabled $true

    Enables the firewall exceptions for the FTP services on the specified host.

    Related Commands

    Feedback

    Was this page helpful?