Is there any way to deploy an AllUsers VPN connection via group policy

Aspall IT 436 Reputation points
2021-06-11T12:14:00.06+00:00

Hi,

We have previously deployed per user VPN connections to users either manually, or by using a login powershell script to deploy a VPN connection in a users context.

I would like to remove these per user connections, and deploy a global VPN connection using the -AllUsersConnection switch for Add-VpnConnection. This switch requires admin privileges, so amending the existing login script with this switch isn't going to work.

Is there any way I can push this connection via group policy any way, to save me having to do this manually?

Many thanks
James

Windows Server
Windows Server
A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.
12,170 questions
Windows 10 Network
Windows 10 Network
Windows 10: A Microsoft operating system that runs on personal computers and tablets.Network: A group of devices that communicate either wirelessly or via a physical connection.
2,275 questions
{count} votes

Accepted answer
  1. Aspall IT 436 Reputation points
    2021-06-18T09:50:14.04+00:00

    We have decided to go with an approach I came across on Spiceworks, whereby it was suggested to setup the VPN as required, then copy the "rasphone.pbk" to the target machines via Group Policy Preferences.

    This seems to work well, and can be deployed to %ProgramData%\Microsoft\Network\Connections\Pbk to deploy and All Users connection successfully.

    The only downside to this approach (which does not affect us in our use case), is it will overwrite any VPN connections not contained within the new PBK.

    0 comments No comments

1 additional answer

Sort by: Most helpful
  1. Sunny Qi 10,906 Reputation points Microsoft Vendor
    2021-06-14T04:58:24.687+00:00

    Hi,

    Thanks for posting in Q&A platform.

    Kindly check if methods in the following article was helpful:

    DEPLOY WINDOWS VPN USING GP PREFERENCES
    Please Note: Since the website is not hosted by Microsoft, the link may change without notice. Microsoft does not guarantee the accuracy of this information.

    Best Regards,
    Sunny

    ----------

    If the Answer is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    1 person found this answer helpful.