netsh wlan add profile not importing encrypted passphrase
Just use the key=clear
parameter when exporting the profiles.
netsh wlan export profile key=clear
Now the passphrase/key will be stored in the XML file(s) in the clear. When you import the profile (as above), you will not be prompted for a passphrase.
The problem is that the encrypted password was encrypted with a machine-specific key on the machine you exported the config from. You could import that xml file back into the same machine and it would work just fine. But it won't work on a different machine because the 2nd machine doesn't have the same machine-specific key and can't decrypt the password.
I'm not exactly sure what netsh uses as the machine-specific key or whether its possible to clone it from one system to another.
Ryan is right in that the key has a machine-specific encryption. Here's a solution:
Open your XML file and locate the following line:
<protected>true</protected>
Change it to:
<protected>false</protected>
Under you will see encrypted line:
<keyMaterial>01000000D08C9DDF0115D1118</keyMaterial>
Change it to your key in plain text:
<keyMaterial>Yourkey</keyMaterial>
Note: It means that your wireless key will be in clear text and everyone who has access to the file will be able to read your wireless key. But it works!