Forum Discussion
Install/Configure VPN For All Users
CacheCredentials=1
in the pbk file
"%AppData%\Microsoft\Network\Connections\Pbk\rasphone.pbk"
https://github.com/paulstancer/VPNCredentialsHelper/issues/1
Perhaps this is the case for you? You can't add the VPN connection as the user itself?
- LordNikon187Feb 24, 2022Copper Contributor
Harm_Veenstra That might work, but if I can't change that value via the script then it defeats the purpose of automating everything. And no, the script doesn't pass the credentials through if you run it on the non admin profile. Even if it did though, I don't want my techs to have to switch back and forth between the admin profile and the non-admin profile. I want them to simply run everything from the admin profile and be done with it.
- Feb 24, 2022
LordNikon187 When you start rasphone.exe as admin and choose Connect, the radio-button is Me Only after using the script. Not sure how to change that in the rasphone.pbk settings by using PowerShell, the setting I mentioned was already there by default.
- LordNikon187Feb 25, 2022Copper Contributor
Harm_Veenstra Yep, and like I said in my update to the post, after running the script, on the non admin profile, if I run a batch that calls on rasphone and also supplies the username and password, I receive an error saying the connection isn't listed in the global address book, which doesn't make any sense, because in the network settings, the connection is there and configured properly minus having to input the credentials on the first connection attempt. Even after doing so, the global address book still isn't updated with the connection so rasphone is essential broken after running my script as well.
Likely what will need to happen unless someone else chimes in, is to figure out how to incorporate a line or two into my script that appends the entries in the global address book and adds the connection details for all users after it's created.