PowerShell Logo Small

Get-VpnConnection



This is the built-in help made by Microsoft for the command 'Get-VpnConnection', in PowerShell version 3 - as retrieved from Windows version 'Microsoft Windows Server 2012 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

Retrieves the specified VPN connection profile information.

SYNTAX


Get-VpnConnection [[-Name] <String[]>] [-AllUserConnection [<SwitchParameter>]] [-AsJob [<SwitchParameter>]] [-CimSession <CimSession[]>]
[-ThrottleLimit <Int32>] [<CommonParameters>]



Search powershellhelp.space

DESCRIPTION


The Get-VpnConnection cmdlet retrieves the specified VPN connection profile and its properties. If you do not specify a profile name, the
cmdlet returns a list of all VPN connections in the phone book.



<

RELATED LINKS

Add-VpnConnection
Set-VpnConnection
Remove-VpnConnection
New-EapConfiguration

REMARKS

<

Examples


Example 1: Get all available VPN connections

PS C:\> Get-VpnConnection
Name : Test1

ServerAddress : 10.1.1.1

AllUserConnection : False

Guid : {4B308E9B-C225-42CB-8158-307193429591}

TunnelType : Automatic

AuthenticationMethod : {MsChapv2}

EncryptionLevel : Required

L2tpIPsecAuth : Certificate

UseWinlogonCredential : False

EapConfigXmlStream :

ConnectionStatus : Disconnected

NapState : NotConnected

RememberCredential : False

SplitTunneling : False



This command returns a list of all available VPN connections in the user's local phone book.




Example 2: Get all available VPN connections from the global phonebook

PS C:\> Get-VpnConnection -AllUserConnection

Name : Test3

ServerAddress : 10.1.1.1

AllUserConnection : True

Guid : {76746D4E-D72A-467D-A11F-3D4D9075F50D}

TunnelType : Pptp

AuthenticationMethod : {MsChapv2}

EncryptionLevel : Required

L2tpIPsecAuth :

UseWinlogonCredential : True

EapConfigXmlStream :

ConnectionStatus : Disconnected

NapState : NotConnected

RememberCredential : True

SplitTunneling : True

Name : Test4

ServerAddress : 10.1.1.2

AllUserConnection : True

Guid : {1D423FF3-E3D4-404A-B052-DB9130656D29}

TunnelType : L2tp

AuthenticationMethod : {Eap}

EncryptionLevel : Required

L2tpIPsecAuth : Psk

UseWinlogonCredential : False

EapConfigXmlStream : #document

ConnectionStatus : Disconnected

NapState : NotConnected

RememberCredential : True

SplitTunneling : True

Name : Test5

ServerAddress : 10.1.1.3

AllUserConnection : True

Guid : {CF9F624F-D7DF-48BA-BD4B-D4E34AE05148}

TunnelType : L2tp

AuthenticationMethod : {Eap}

EncryptionLevel : Required

L2tpIPsecAuth : Certificate

UseWinlogonCredential : False

EapConfigXmlStream : #document

ConnectionStatus : Disconnected

NapState : NotConnected

RememberCredential : True

SplitTunneling : True



This command retrieves all the available VPN connections from the global phone book.




Example 3: Get a specific VPN connection from the global phone book

PS C:\> Get-VpnConnection -Name "Test3" –AllUserConnection

Name : Test3

ServerAddress : 10.1.1.1

AllUserConnection : True

Guid : {76746D4E-D72A-467D-A11F-3D4D9075F50D}

TunnelType : Pptp

AuthenticationMethod : {MsChapv2}

EncryptionLevel : Required

L2tpIPsecAuth :

UseWinlogonCredential : True

EapConfigXmlStream :

ConnectionStatus : Disconnected

NapState : NotConnected

RememberCredential : True

SplitTunneling : True



This command retrieves the VPN connection named Test3 from the global phone book.




Example 4: Get multiple VPN connections

PS C:\> Get-VpnConnection -Name "Test3", "Test4", "test5" –AllUserConnection

Name : Test3

ServerAddress : 10.1.1.1

AllUserConnection : True

Guid : {76746D4E-D72A-467D-A11F-3D4D9075F50D}

TunnelType : Pptp

AuthenticationMethod : {MsChapv2}

EncryptionLevel : Required

L2tpIPsecAuth :

UseWinlogonCredential : True

EapConfigXmlStream :

ConnectionStatus : Disconnected

NapState : NotConnected

RememberCredential : True

SplitTunneling : True

Name : Test4

ServerAddress : 10.1.1.2

AllUserConnection : True

Guid : {1D423FF3-E3D4-404A-B052-DB9130656D29}

TunnelType : L2tp

AuthenticationMethod : {Eap}

EncryptionLevel : Required

L2tpIPsecAuth : Psk

UseWinlogonCredential : False

EapConfigXmlStream : #document

ConnectionStatus : Disconnected

NapState : NotConnected

RememberCredential : True

SplitTunneling : True

Name : test5

ServerAddress : 10.1.1.3

AllUserConnection : True

Guid : {CF9F624F-D7DF-48BA-BD4B-D4E34AE05148}

TunnelType : L2tp

AuthenticationMethod : {Eap}

EncryptionLevel : Required

L2tpIPsecAuth : Certificate

UseWinlogonCredential : False

EapConfigXmlStream : #document

ConnectionStatus : Disconnected

NapState : NotConnected

RememberCredential : True

SplitTunneling : True



This command retrieves multiple specified VPN connections from the global phone book.