Connect to VPN before login to computer
-
Hello there,
Is there a way to have OpenVPN connected before the user logs in to the computer?
Since everyone working from home I can not push AD GPOs per machine. -
It's certainly possible in Linux. Not sure about Windows.
-
You would have to run the client as a service, so it starts with the OS before login:
https://openvpn.net/cloud-docs/user-guide-openvpn-as-a-system-service-on-windows/
https://openvpn.net/community-resources/running-openvpn-as-a-windows-service/
-
@marvosa
I am aware of running OpenVPN as a service, but how can I provide user's credentials? -
@piotres
One option, add the following to the client's config:auth-user-pass pass.txt
then add a 2 line text file called "pass.txt" in the same folder as the client's config using the following format:
username
passwordAnother option, create a separate instance for auto-connect users that auth's from certificate only.
Another option, create a service account for auto-connect users, so solutions similar to the above can be deployed without input from the end-user. We did this at my last gig with Cisco AnyConnect.
Another possible option, it looks like the "auth-user-pass" directive can be invoked via the command line, so it may be possible to add something like the following to the parameters section of the service instead of modifying the client config:
--config C:\Program Files\OpenVPN\config\myvpnconfig.ovpn --auth-user-pass "C:\Program Files\OpenVPN\config\pass.txt"
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register LoginPrivacy Policy · Cookie Policy