Skip to content
Branch: master
Find file Copy path
Find file Copy path
1 contributor

Users who have contributed to this file

45 lines (31 sloc) 1.27 KB
Extract EAP configuration from existing Windows 10 VPN connection.
.PARAMETER Connection
The name of the VPN connection to extract the EAP configuration from.
.PARAMETER xmlFilePath
The full path and name of the file to export EAP configuration to.
Get-EapConfiguration.ps1 -Connection "Test VPN Connection" -xmlFilePath "C:\Users\rdeckard\desktop\eapconfig.xml"
Use this script to extract the EAP configuration from an existing VPN connection. The output XML can be copied and pasted in to ProfileXML for configuring Windows 10 Always On VPN connections.
Version: 1.0
Creation Date: 5/27/2019
Last Updated: 5/27/2019
Author: Richard Hicks
Organization: Richard M. Hicks Consulting, Inc.
Web Site:
Param (
If (Test-Path $xmlFilePath) {Remove-Item $xmlFilePath}
$VPN = Get-VpnConnection -Name $Connection
$xml = $VPN.EapConfigXmlStream.InnerXml
$xml -join "`r" | % { $_ -replace '>\s*<','><'} | Out-File $xmlFilePath -Encoding ASCII
You can’t perform that action at this time.