The Set-CMWindowsFirewallPolicy cmdlet changes settings of one or more Windows Firewall policies for System Center 2016 Endpoint Protection in Configuration Manager.
Note
Run Configuration Manager cmdlets from the Configuration Manager site drive, for example PS XYZ:\>. For more information, see getting started.
Examples
Example 1: Decrease the priority of a Windows Firewall policy by using a name
The first command gets the CMWindowsFirewallPolicy object that has the ID 16777568 and stores it in the $WFPobj variable.
The second command increases the priority of the Windows Firewall policy stored in the $WFPobj variable.
Parameters
-Confirm
Prompts you for confirmation before running the cmdlet.
Parameter properties
Type:
SwitchParameter
Default value:
False
Supports wildcards:
False
DontShow:
False
Aliases:
cf
Parameter sets
(All)
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-Description
Specifies a description for the Windows Firewall policy.
Parameter properties
Type:
String
Default value:
None
Supports wildcards:
False
DontShow:
False
Aliases:
LocalizedDescription
Parameter sets
SetByValue
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetById
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetByName
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-Digest
The Set-CMWindowsFirewallPolicy cmdlet changes settings of one or more Windows Firewall policies for System Center 2016 Endpoint Protection in Configuration Manager.
Note
Run Configuration Manager cmdlets from the Configuration Manager site drive, for example PS XYZ:\>. For more information, see getting started.
Parameter properties
Type:
ConfigurationItem
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
SetByValue
Position:
Named
Mandatory:
False
Value from pipeline:
True
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetById
Position:
Named
Mandatory:
False
Value from pipeline:
True
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetByName
Position:
Named
Mandatory:
False
Value from pipeline:
True
Value from pipeline by property name:
False
Value from remaining arguments:
False
-DigestPath
The Set-CMWindowsFirewallPolicy cmdlet changes settings of one or more Windows Firewall policies for System Center 2016 Endpoint Protection in Configuration Manager.
Note
Run Configuration Manager cmdlets from the Configuration Manager site drive, for example PS XYZ:\>. For more information, see getting started.
Parameter properties
Type:
String
Default value:
None
Supports wildcards:
False
DontShow:
False
Aliases:
DesiredConfigurationDigestPath
Parameter sets
SetByValue
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetById
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetByName
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-DigestXml
The Set-CMWindowsFirewallPolicy cmdlet changes settings of one or more Windows Firewall policies for System Center 2016 Endpoint Protection in Configuration Manager.
Note
Run Configuration Manager cmdlets from the Configuration Manager site drive, for example PS XYZ:\>. For more information, see getting started.
Parameter properties
Type:
String
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
SetByValue
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetById
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetByName
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-DisableWildcardHandling
This parameter treats wildcard characters as literal character values. You can't combine it with ForceWildcardHandling.
Parameter properties
Type:
SwitchParameter
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
(All)
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-DomainBlockAllInboundTraffic
Specifies whether the firewall blocks all incoming traffic for a ___domain type network ___location.
Valid values are:
No
Not Configured
Yes
Parameter properties
Type:
SettingType
Default value:
None
Accepted values:
Yes, No, NotConfigured
Supports wildcards:
False
DontShow:
False
Parameter sets
SetByValue
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetById
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetByName
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-DomainNotification
The Set-CMWindowsFirewallPolicy cmdlet changes settings of one or more Windows Firewall policies for System Center 2016 Endpoint Protection in Configuration Manager.
Note
Run Configuration Manager cmdlets from the Configuration Manager site drive, for example PS XYZ:\>. For more information, see getting started.
Parameter properties
Type:
SettingType
Default value:
None
Accepted values:
Yes, No, NotConfigured
Supports wildcards:
False
DontShow:
False
Aliases:
DomainNotifications
Parameter sets
SetByValue
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetById
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetByName
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-DomainTurnOnFirewall
Specifies whether to enable Windows Firewall for ___domain network ___location.
Valid values are:
No
Not Configured
Yes
Parameter properties
Type:
SettingType
Default value:
None
Accepted values:
Yes, No, NotConfigured
Supports wildcards:
False
DontShow:
False
Parameter sets
SetByValue
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetById
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetByName
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-ForceWildcardHandling
This parameter processes wildcard characters and may lead to unexpected behavior (not recommended). You can't combine it with DisableWildcardHandling.
Parameter properties
Type:
SwitchParameter
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
(All)
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-Id
Specifies an array of IDs of firewall policies.
Parameter properties
Type:
Int32
Default value:
None
Supports wildcards:
False
DontShow:
False
Aliases:
CIId, CI_ID
Parameter sets
SetById
Position:
0
Mandatory:
True
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetOrderById
Position:
0
Mandatory:
True
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-InputObject
Specifies a CMWindowsFirewallPolicy object.
To obtain a CMWindowsFirewallPolicy object, use the Get-CMWindowsFirewallPolicy cmdlet.
Parameter properties
Type:
IResultObject
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
SetByValue
Position:
0
Mandatory:
True
Value from pipeline:
True
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetOrderByValue
Position:
0
Mandatory:
True
Value from pipeline:
True
Value from pipeline by property name:
False
Value from remaining arguments:
False
-Name
Specifies an array of firewall policy names.
Parameter properties
Type:
String
Default value:
None
Supports wildcards:
False
DontShow:
False
Aliases:
LocalizedDisplayName
Parameter sets
SetByName
Position:
0
Mandatory:
True
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetOrderByName
Position:
0
Mandatory:
True
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-NewName
Specifies a new name for the firewall policy.
Parameter properties
Type:
String
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
SetByValue
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetById
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetByName
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-Order
{{ Fill Order Description }}
Parameter properties
Type:
PriorityChangeType
Default value:
None
Accepted values:
Increase, Decrease
Supports wildcards:
False
DontShow:
False
Aliases:
Priority
Parameter sets
SetOrderById
Position:
Named
Mandatory:
True
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetOrderByValue
Position:
Named
Mandatory:
True
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetOrderByName
Position:
Named
Mandatory:
True
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-PassThru
Add this parameter to return an object that represents the item with which you're working. By default, this cmdlet may not generate any output.
Parameter properties
Type:
SwitchParameter
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
(All)
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-PrivateBlockAllInboundTraffic
Specifies whether the firewall blocks all incoming traffic for a private network ___location.
Valid values are:
No
Not Configured
Yes
Parameter properties
Type:
SettingType
Default value:
None
Accepted values:
Yes, No, NotConfigured
Supports wildcards:
False
DontShow:
False
Parameter sets
SetByValue
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetById
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetByName
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-PrivateNotification
The Set-CMWindowsFirewallPolicy cmdlet changes settings of one or more Windows Firewall policies for System Center 2016 Endpoint Protection in Configuration Manager.
Note
Run Configuration Manager cmdlets from the Configuration Manager site drive, for example PS XYZ:\>. For more information, see getting started.
Parameter properties
Type:
SettingType
Default value:
None
Accepted values:
Yes, No, NotConfigured
Supports wildcards:
False
DontShow:
False
Aliases:
PrivateNotifications
Parameter sets
SetByValue
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetById
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetByName
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-PrivateTurnOnFirewall
Specifies whether to enable Windows Firewall for a private network ___location.
Valid values are:
No
Not Configured
Yes
Parameter properties
Type:
SettingType
Default value:
None
Accepted values:
Yes, No, NotConfigured
Supports wildcards:
False
DontShow:
False
Parameter sets
SetByValue
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetById
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetByName
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-PublicBlockAllInboundTraffic
Specifies whether the firewall blocks all incoming traffic for a public network ___location.
Valid values are:
No
Not Configured
Yes
Parameter properties
Type:
SettingType
Default value:
None
Accepted values:
Yes, No, NotConfigured
Supports wildcards:
False
DontShow:
False
Parameter sets
SetByValue
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetById
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetByName
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-PublicNotification
The Set-CMWindowsFirewallPolicy cmdlet changes settings of one or more Windows Firewall policies for System Center 2016 Endpoint Protection in Configuration Manager.
Note
Run Configuration Manager cmdlets from the Configuration Manager site drive, for example PS XYZ:\>. For more information, see getting started.
Parameter properties
Type:
SettingType
Default value:
None
Accepted values:
Yes, No, NotConfigured
Supports wildcards:
False
DontShow:
False
Aliases:
PublicNotifications
Parameter sets
SetByValue
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetById
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetByName
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-PublicTurnOnFirewall
Specifies whether to enable Windows Firewall for a public network ___location.
Valid values are:
No
Not Configured
Yes
Parameter properties
Type:
SettingType
Default value:
None
Accepted values:
Yes, No, NotConfigured
Supports wildcards:
False
DontShow:
False
Parameter sets
SetByValue
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetById
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
SetByName
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
-WhatIf
Shows what would happen if the cmdlet runs. The cmdlet doesn't run.
Parameter properties
Type:
SwitchParameter
Default value:
False
Supports wildcards:
False
DontShow:
False
Aliases:
wi
Parameter sets
(All)
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
False
Value from remaining arguments:
False
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable,
-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable,
-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see
about_CommonParameters.