Set-VpnConnectionIPsecConfiguration

Set-VpnConnectionIPsecConfiguration

Sets the IPsec parameters of a VPN connection.

構文

Parameter Set: Default
Set-VpnConnectionIPsecConfiguration [-ConnectionName] <String> [-RevertToDefault] [-AllUserConnection] [-AsJob] [-CimSession <CimSession[]> ] [-Force] [-ThrottleLimit <Int32> ] [-Confirm] [-WhatIf] [ <CommonParameters>]

Parameter Set: CustomPolicy
Set-VpnConnectionIPsecConfiguration [-ConnectionName] <String> [-AuthenticationTransformConstants] <AuthenticationTransformConstants> [-CipherTransformConstants] <CipherTransformConstants> [-DHGroup] <DHGroup> [-EncryptionMethod] <EncryptionMethod> [-IntegrityCheckMethod] <IntegrityCheckMethod> [-PfsGroup] <PfsGroup> [-AllUserConnection] [-AsJob] [-CimSession <CimSession[]> ] [-Force] [-PassThru] [-ThrottleLimit <Int32> ] [-Confirm] [-WhatIf] [ <CommonParameters>]

詳細説明

The Set-VpnConnectionIpsecConfiguration cmdlet sets the IPsec parameters of a VPN connection. The settings apply only to IKEv2 and L2TP VPN connections.

パラメーター

-AllUserConnection

Indicates that the VPN connection being modified is in the global phone book.

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-AsJob

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-AuthenticationTransformConstants<AuthenticationTransformConstants>

Specifies authentication header (AH) transform in the IPsec policy. For more information, see Set-VpnServerIPsecConfiguration. Acceptable values for this parameter are:

-- MD596
-- SHA196
-- SHA256128
-- GCMAES128
-- GCMAES192
-- GCMAES256
-- None

エイリアス

なし

必須?

true

位置は?

3

既定値

なし

パイプライン入力を許可する

True (ByPropertyName)

ワイルドカード文字を許可する

false

-CimSession<CimSession[]>

リモート セッションまたはリモート コンピューターでコマンドレットを実行します。New-CimSession コマンドレットや Get-CimSession コマンドレットの出力など、コンピューター名またはセッション オブジェクトを入力します。既定値は、ローカル コンピューターで実行中の現在のセッションです。

エイリアス

Session

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-CipherTransformConstants<CipherTransformConstants>

Specifies Encapsulating Security Payload (ESP) cipher transform in the IPsec policy. Acceptable values for this parameter are:

-- DES
-- DES3
-- AES128
-- AES192
-- AES256
-- GCMAES128
-- GCMAES192
-- GCMAES256
-- None

エイリアス

なし

必須?

true

位置は?

4

既定値

なし

パイプライン入力を許可する

True (ByPropertyName)

ワイルドカード文字を許可する

false

-ConnectionName<String>

Specifies the name of a VPN connection profile to modify. To view existing VPN connection profiles, use the Get-VpnConnection cmdlet.

エイリアス

Name

必須?

true

位置は?

2

既定値

なし

パイプライン入力を許可する

True (ByPropertyName)

ワイルドカード文字を許可する

false

-DHGroup<DHGroup>

Specifies the Diffie-Hellman (DH) Group to use during IKE key exchanges. Acceptable values for this parameter are:

-- None
-- Group1
-- Group2
-- Group14
-- ECP256
-- ECP384
-- Group24

エイリアス

なし

必須?

true

位置は?

5

既定値

なし

パイプライン入力を許可する

True (ByPropertyName)

ワイルドカード文字を許可する

false

-EncryptionMethod<EncryptionMethod>

Specifies the encryption method. Acceptable values for this parameter are:

-- DES
-- DES3
-- AES128
-- AES192
-- AES256

エイリアス

なし

必須?

true

位置は?

6

既定値

なし

パイプライン入力を許可する

True (ByPropertyName)

ワイルドカード文字を許可する

false

-Force

Performs the action without a confirmation message.

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-IntegrityCheckMethod<IntegrityCheckMethod>

Specifies the integrity check method used to protect data from tampering. Acceptable values for this parameter are:

-- MD5
-- SHA196
-- SHA256
-- SHA384

エイリアス

なし

必須?

true

位置は?

7

既定値

なし

パイプライン入力を許可する

True (ByPropertyName)

ワイルドカード文字を許可する

false

-PassThru

作業中の項目を表すオブジェクトを返します。既定では、このコマンドレットによる出力はありません。 If you specify this parameter, the cmdlet returns the VpnConnection object that contains the VpnConnection configuration settings.

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-PfsGroup<PfsGroup>

Specifies the Perfect Forwarding Secrecy (PFS) Group in the IPsec policy. Acceptable values for this parameter are:

-- None
-- PFS1
-- PFS2
-- PFS2048
-- ECP256
-- ECP384
-- PFSMM
-- PFS24

エイリアス

なし

必須?

true

位置は?

8

既定値

なし

パイプライン入力を許可する

True (ByPropertyName)

ワイルドカード文字を許可する

false

-RevertToDefault

Indicates that the cmdlet sets the IPsec parameters to the default values.

エイリアス

なし

必須?

true

位置は?

3

既定値

なし

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-ThrottleLimit<Int32>

このコマンドレットを実行するために確立できる最大同時操作数を指定します。このパラメーターを省略するか、値として 0 を入力した場合、Windows PowerShell® では、コンピューターで実行している CIM コマンドレットの数に基づいて、コマンドレットに対する最適なスロットル制限を計算します。スロットル制限は現在のコマンドレットのみに適用され、セッションまたはコンピューターには適用されません。

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-Confirm

コマンドレットを実行する前に、ユーザーに確認を求めます。

必須?

false

位置は?

named

既定値

false

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-WhatIf

コマンドレットを実行するとどのような結果になるかを表示します。コマンドレットは実行されません。

必須?

false

位置は?

named

既定値

false

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

<CommonParameters>

このコマンドレットは次の共通パラメーターをサポートします。-Verbose、-Debug、-ErrorAction、-ErrorVariable、-OutBuffer、-OutVariable.詳細については、以下を参照してください。 about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216)。

入力

入力型は、コマンドレットにパイプできるオブジェクトの型です。

出力

出力型は、コマンドレットによって生成されるオブジェクトの型です。

  • Microsoft.Management.Infrastructure.CimInstance#VpnConnectionIPsecConfiguration

Example 1: Set the IPsec configuration for an IKEv2 tunnel

This example sets the IPsec configuration for a VPN connection using IKEv2.

The first command uses the Add-VpnConnection cmdlet to add a VPN connection on the server with the address 176.16.1.2. The cmdlet specifies an IKEv2 tunnel.

The second command uses the Set-VpnConnectionIPsecConfiguration cmdlet to set the configuration by using the ConnectionName parameter. The command also specifies values for the CipherTransformConstants, EncryptionMethod, IntegrityCheckMethod, and DHGroup parameters.

PS C:\> Add-VpnConnection -Name "Contoso" -ServerAddress 176.16.1.2 -TunnelType Ikev2
PS C:\> Set-VpnConnectionIPsecConfiguration -ConnectionName "Contoso" -AuthenticationTransformConstants None -CipherTransformConstants AES256 -EncryptionMethod AES256 -IntegrityCheckMethod SHA384 -PfsGroup None -DHGroup ECP384 -PassThru -Force

Example 2: Set the IPsec configuration for an L2TP tunnel

This example sets the IPsec configuration for an L2TP tunnel.

The first command uses the Add-VpnConnection cmdlet to add a VPN connection on the server with the address 176.16.1.2. The command also specifies an L2TP tunnel.

The second command uses the Set-VpnConnectionIPsecConfiguration cmdlet to set the configuration. The command also specifies values for the CipherTransformConstants, EncryptionMethod, IntegrityCheckMethod, and DHGroup parameters.

PS C:\> Add-VpnConnection -Name "Contoso" -ServerAddress 176.16.1.2 -TunnelType L2tp
PS C:\> Set-VpnConnectionIPsecConfiguration -ConnectionName "Contoso" -AuthenticationTransformConstants None -CipherTransformConstants AES128 -EncryptionMethod AES128 -IntegrityCheckMethod SHA256 -PfsGroup None -DHGroup ECP256 -PassThru -Force

Example 3: Set the IPsec configuration for an IKEv2 tunnel with 128-bit data blocks

This example sets the IPsec configuration for an IKEv2 tunnel with authentication transform constants.

The first command uses the Add-VpnConnection cmdlet to add a VPN connection on the server with the address 176.16.1.2. The cmdlet specifies an IKEv2 tunnel.

The second command uses the Set-VpnConnectionIPsecConfiguration cmdlet to set the configuration. The command also specifies values for the CipherTransformConstants, EncryptionMethod, IntegrityCheckMethod, and DHGroup parameters, as well as specifying a value for the AuthenticationTransformConstants parameter.

PS C:\> Add-VpnConnection -Name "Contoso" -ServerAddress 176.16.1.2 -TunnelType Ikev2
PS C:\> Set-VpnConnectionIPsecConfiguration -ConnectionName "Contoso" -AuthenticationTransformConstants GCMAES128 -CipherTransformConstants None -EncryptionMethod AES128 -IntegrityCheckMethod SHA256 -PfsGroup None -DHGroup ECP256 -PassThru -Force

Example 4: Set the IPsec configuration for an IKEv2 tunnel with 256-bit data blocks

This example sets the IPsec configuration for an IKEv2 tunnel, and specifies authentication transform constants.

The first command uses the Add-VpnConnection cmdlet to add a VPN connection on the server with the address 176.16.1.2. The cmdlet specifies an IKEv2 tunnel.

The second command uses the Set-VpnConnectionIPsecConfiguration cmdlet to set the configuration. The command also specifies values for the CipherTransformConstants, EncryptionMethod, IntegrityCheckMethod, and DHGroup parameters, as well as specifying a value for the AuthenticationTransformConstants parameter.

PS C:\> Add-VpnConnection -Name "Contoso" -ServerAddress 176.16.1.2 -TunnelType Ikev2
PS C:\> Set-VpnConnectionIPsecConfiguration -ConnectionName "Contoso" -AuthenticationTransformConstants GCMAES256 -CipherTransformConstants None -EncryptionMethod AES256 -IntegrityCheckMethod SHA384 -PfsGroup None -DHGroup ECP384 -PassThru -Force

関連トピック

Set-VpnServerIPsecConfiguration