Page 1 of 1

OpenVpn Connect daemon with login/password

Posted: Tue Sep 21, 2021 11:05 am
by randomUser124
Hello,

I have a opvn config file working fine when using the OpenVpn Connect app. The authentication is based on login/password, and the app does well remember my password.

Now I would like to configure it as daemon, to automatically start at system boot. How can I achieve this? If I just refer to the opvn config file it won't work, since the login/password is not saved in there...

Thank you

Re: OpenVpn Connect daemon with login/password

Posted: Tue Sep 21, 2021 11:29 am
by openvpn_inc
Hello randomUser124,

There's two ways to go about this. The best way is to use a connection profile that doesn't require username and password. The worst way is putting the username/password in a plain-text file and referencing that with the auth-user-pass directive. Both methods will lead to a solution that doesn't require the user to interactively enter the credentials, so that the connection can be established automatically.

If you're using OpenVPN Cloud or OpenVPN Access Server you can arrange things so that it doesn't require username/password.

Then you can run OpenVPN Connect v3 as windows service daemon:
https://openvpn.net/vpn-server-resource ... emon-mode/

Good luck,
Johan

Re: OpenVpn Connect daemon with login/password

Posted: Tue Sep 21, 2021 11:36 am
by randomUser124
Thank you very much for this fast reply.
The login and password of the VPN is actually managed by Active Directory server, and is the user login/pwd for its windows domain. So storing it in plain text doesn't seem a good option :)

I'll investigate about OpenVPN Access Server

Thank you again

Re: OpenVpn Connect daemon with login/password

Posted: Tue Sep 21, 2021 12:08 pm
by randomUser124
By the way, what happens if I use certificates for authentication? I still need to input the passphrase of the certificates somewhere, right?

Re: OpenVpn Connect daemon with login/password

Posted: Thu Sep 23, 2021 11:21 am
by openvpn_inc
Hello randomUser124,

> By the way, what happens if I use certificates for authentication? I still need to input the passphrase of the certificates somewhere, right?

No, that would entirely defeat the purpose of unattended logins. Then you're just moving the problem of entering credentials from one place to another.

Kind regards,
Johan