Export and import wireless profiles through powershell

I needed to be able to push out wireless connections through sccm and this is what I came up with.



1. We need to export the wireless profile from a connected computer

2. Open the .xml file that was created in the previous step

3. Change the value protected from true to false

4. Enter your password for the wireless connection under keyMaterial, right now you will find a long string so just delete that and enter your password

5. Save and close

Now you have exported a profile and configured it with the password, the password is now in clear-text so this file should be kept in a secure place



1. Import the profile on the new computer, default is for current/all users


Done, now you have imported the wireless profile and you can now connect without entering a password.

But we dont want to import the profile manually, so now its time to automate this through powershell

1. We need to get the current directory where the script is running from

2. Import the wireless profile

3. Save your .pst file in the same directory as “Your Wireless Profile Name.xml” and just run your script from any source like usb, network share or whatever.

Leave a Reply