Forum Discussion

Vanierf's avatar
Vanierf
Copper Contributor
Aug 04, 2021
Solved

Meraki VPN L2TP with Preshared key in Intune

Is there any way to configure L2TP VPN with pre-shared key in Intune?

  • Hi Vanier,

    There is a possibility to configure your Meraki L2TP VPN that would be through a PowerShell script. Unfortunately, it’s yet not possible to use a configuration profile for this.

    There is a non-Microsoft website build that will help you create the PowerShell script: https://www.ifm.net.nz/cookbooks/meraki-client-vpn.html

    Just enter your VPN info (I would use fake info - and change the PS script afterward). After you have specified your info, it will spit out a PowerShell script that you can push through Intune. The best approach would be wrapping this PowerShell script into a Win32 app, and configure a detection rule so you're in control who has the app installed and who didn’t.

    Good luck!

    Regards, Bilal

6 Replies

  • BilalelHadd's avatar
    BilalelHadd
    Iron Contributor

    Hi Vanier,

    There is a possibility to configure your Meraki L2TP VPN that would be through a PowerShell script. Unfortunately, it’s yet not possible to use a configuration profile for this.

    There is a non-Microsoft website build that will help you create the PowerShell script: https://www.ifm.net.nz/cookbooks/meraki-client-vpn.html

    Just enter your VPN info (I would use fake info - and change the PS script afterward). After you have specified your info, it will spit out a PowerShell script that you can push through Intune. The best approach would be wrapping this PowerShell script into a Win32 app, and configure a detection rule so you're in control who has the app installed and who didn’t.

    Good luck!

    Regards, Bilal

    • PDC916's avatar
      PDC916
      Copper Contributor

      Not to disregard this tool....but not sure I want to give a random site my VPN Server IP and PreShared Key just so they can generate a script.  All thats left would be user credentials and they're in if they're a bad actor...  #JustSaying

    • LiamPrince1330's avatar
      LiamPrince1330
      Copper Contributor

      BilalelHadd 

      Does this prevent Hybrid AD login? The infrastructure I work with uses the Meraki L2TP client VPN and has a requirement to Hybrid domain join at intune. Is there any way of getting this working if we cannot set up configuration profile VPN connections in this manner?

    • Tanjiro's avatar
      Tanjiro
      Copper Contributor

      BilalelHadd I'm running into a problem trying to push this through the Scripts function in Intune. Can anybody share their Intune settings or how to deploy this with Azure AD? When I run the .ps1 script as an elevated admin locally, the VPN is added. When I push it through Intune, no VPN shows up when I log in with an Azure AD user account but Intune says the script was performed successfully. Thanks!

  • CJHarms's avatar
    CJHarms
    Copper Contributor
    Looking also for a Solution. Currently pushing the VPN Config via a Powershell Script but I would prefer to do it via a VPN Configuration Policy
    • JonasRy's avatar
      JonasRy
      Copper Contributor
      Same issue here.
      If someone could share a powershell-script until that's fixed by Microsoft I would appreciate.

Resources