PowerShell Logo Small

Remove-NetIPsecRule



This is the built-in help made by Microsoft for the command 'Remove-NetIPsecRule', in PowerShell version 5 - as retrieved from Windows version 'Microsoft Windows Server 2012 R2 Standard' PowerShell help files on 2016-06-23.

For PowerShell version 3 and up, where you have Update-Help, this command was run just before creating the web pages from the help files.

SYNOPSIS

Defines security requirements for network connections that match the specified criteria.

SYNTAX


Remove-NetIPsecRule [-All] [-AsJob] [-CimSession <CimSession[]>] [-GPOSession <String>] [-PassThru] [-PolicyStore <String>] [-ThrottleLimit <Int32>] [-TracePolicyStore]
[-Confirm] [-WhatIf] [<CommonParameters>]
Remove-NetIPsecRule [-AllowSetKey <Boolean[]>] [-AllowWatchKey <Boolean[]>] [-AsJob] [-CimSession <CimSession[]>] [-Description <String[]>] [-DisplayGroup <String[]>]
[-Enabled <Enabled[]>] [-EncryptedTunnelBypass <Boolean[]>] [-ForwardPathLifetime <UInt32[]>] [-GPOSession <String>] [-Group <String[]>] [-InboundSecurity
<SecurityPolicy[]>] [-KeyModule <KeyModule[]>] [-Machine <String[]>] [-Mode <IPsecMode[]>] [-OutboundSecurity <SecurityPolicy[]>] [-PassThru] [-Phase1AuthSet <String[]>]
[-Phase2AuthSet <String[]>] [-PolicyStore <String>] [-PolicyStoreSource <String[]>] [-PolicyStoreSourceType <PolicyStoreType[]>] [-PrimaryStatus <PrimaryStatus[]>]
[-QuickModeCryptoSet <String[]>] [-RemoteTunnelHostname <String[]>] [-RequireAuthorization <Boolean[]>] [-Status <String[]>] [-ThrottleLimit <Int32>] [-TracePolicyStore]
[-User <String[]>] [-Confirm] [-WhatIf] [<CommonParameters>]
Remove-NetIPsecRule [-AsJob] [-CimSession <CimSession[]>] [-GPOSession <String>] [-PassThru] [-PolicyStore <String>] [-ThrottleLimit <Int32>] [-TracePolicyStore]
-DisplayName <String[]> [-Confirm] [-WhatIf] [<CommonParameters>]
Remove-NetIPsecRule [-IPsecRuleName] <String[]> [-AsJob] [-CimSession <CimSession[]>] [-GPOSession <String>] [-PassThru] [-PolicyStore <String>] [-ThrottleLimit <Int32>]
[-TracePolicyStore] [-Confirm] [-WhatIf] [<CommonParameters>]
Remove-NetIPsecRule [-AsJob] [-CimSession <CimSession[]>] [-GPOSession <String>] [-PassThru] [-PolicyStore <String>] [-ThrottleLimit <Int32>] [-TracePolicyStore]
-AssociatedNetIPsecPhase2AuthSet <CimInstance> [-Confirm] [-WhatIf] [<CommonParameters>]
Remove-NetIPsecRule [-AsJob] [-CimSession <CimSession[]>] [-GPOSession <String>] [-PassThru] [-PolicyStore <String>] [-ThrottleLimit <Int32>] [-TracePolicyStore]
-AssociatedNetFirewallAddressFilter <CimInstance> [-Confirm] [-WhatIf] [<CommonParameters>]
Remove-NetIPsecRule [-AsJob] [-CimSession <CimSession[]>] [-GPOSession <String>] [-PassThru] [-PolicyStore <String>] [-ThrottleLimit <Int32>] [-TracePolicyStore]
-AssociatedNetIPsecQuickModeCryptoSet <CimInstance> [-Confirm] [-WhatIf] [<CommonParameters>]
Remove-NetIPsecRule [-AsJob] [-CimSession <CimSession[]>] [-GPOSession <String>] [-PassThru] [-PolicyStore <String>] [-ThrottleLimit <Int32>] [-TracePolicyStore]
-AssociatedNetIPsecPhase1AuthSet <CimInstance> [-Confirm] [-WhatIf] [<CommonParameters>]
Remove-NetIPsecRule [-AsJob] [-CimSession <CimSession[]>] [-PassThru] [-ThrottleLimit <Int32>] -InputObject <CimInstance[]> [-Confirm] [-WhatIf] [<CommonParameters>]
Remove-NetIPsecRule [-AsJob] [-CimSession <CimSession[]>] [-GPOSession <String>] [-PassThru] [-PolicyStore <String>] [-ThrottleLimit <Int32>] [-TracePolicyStore]
-AssociatedNetFirewallProfile <CimInstance> [-Confirm] [-WhatIf] [<CommonParameters>]
Remove-NetIPsecRule [-AsJob] [-CimSession <CimSession[]>] [-GPOSession <String>] [-PassThru] [-PolicyStore <String>] [-ThrottleLimit <Int32>] [-TracePolicyStore]
-AssociatedNetFirewallPortFilter <CimInstance> [-Confirm] [-WhatIf] [<CommonParameters>]
Remove-NetIPsecRule [-AsJob] [-CimSession <CimSession[]>] [-GPOSession <String>] [-PassThru] [-PolicyStore <String>] [-ThrottleLimit <Int32>] [-TracePolicyStore]
-AssociatedNetFirewallInterfaceTypeFilter <CimInstance> [-Confirm] [-WhatIf] [<CommonParameters>]
Remove-NetIPsecRule [-AsJob] [-CimSession <CimSession[]>] [-GPOSession <String>] [-PassThru] [-PolicyStore <String>] [-ThrottleLimit <Int32>] [-TracePolicyStore]
-AssociatedNetFirewallInterfaceFilter <CimInstance> [-Confirm] [-WhatIf] [<CommonParameters>]



Search powershellhelp.space

DESCRIPTION


The Remove-NetIPsecRule cmdlet permanently deletes one or more IPsec rules from the specified policy store.


This cmdlet gets one or more IPsec rules to be deleted with the IPsecRuleName parameter (default), the DisplayName parameter, rule properties, or by associated filters or
objects. The resulting queried rule is removed from the computer.


This cmdlet permanently removes a previously enabled IPsec rule to be inactive within the computer or a group policy organizational unit. This cmdlet differs from the
Disable-NetIPsecRule cmdlet that disables a previously enabled IPsec rule to be inactive within the computer or a group policy organizational unit. A disabled main mode rule
will not actively modify computer behavior, but it still exists on the computer or in a Group Policy Object (GPO) so it can be re-enabled.



<

RELATED LINKS

Online Version: http://go.microsoft.com/fwlink/?LinkId=288201
Copy-NetIPsecRule
Disable-NetIPsecRule
Get-NetFirewallAddressFilter
Get-NetFirewallInterfaceFilter
Get-NetFirewallInterfaceTypeFilter
Get-NetFirewallPortFilter
Get-NetFirewallProfile
Get-NetIPsecPhase1AuthSet
Get-NetIPsecPhase2AuthSet
Get-NetIPsecQuickModeCryptoSet
New-NetIPsecRule
Open-NetGPO
Save-NetGPO
Set-NetIPsecRule
New-GPO

REMARKS

<

Examples


EXAMPLE 1

PS C:\>Remove-NetIPsecRule



This example removes all of the static local policies.




EXAMPLE 2

PS C:\>Remove-NetIPsecRule -DisplayName " Transport Mode - CorpNet IPv4 – AuthIP"



This example deletes an IPsec rule based on the localized name.




EXAMPLE 3

PS C:\>Remove-NetIPsecRule -Enabled False –PolicyStore contoso.com\gpo_name



This example removes all of the IPsec rules that are currently disabled on a GPO.




EXAMPLE 4

PS C:\>$nfProfile = Get-NetFirewallProfile –Profile Public



PS C:\>Remove-NetIPsecRule –InputObject $nfProfile



This example removes all of the IPsec rules associated with the public profile.