Hi , On Wed, Feb 14, 2018 at 5:47 PM, fragmentux <[email protected]> wrote: > Hi, > > > On 13/02/18 21:04, David Sommerseth wrote: >> >> On 13/02/18 17:21, Илья Шипицин wrote: >>> >>> personally, I would like something like "preconnect script" which will >>> check >>> something and decide "we are in a place, where vpn is not needed" >> >> >> This feature has been requested numerous times. And it is not needed. >> Really. You have the management interface which can be done to resolve >> exactly that problem. >> >> - OpenVPN is configured with --management and --management-hold >> >> - Start the management client script >> - polls for the OpenVPN management port to become available if it is >> not >> getting a connection instantly >> - once connected, it can do whatever queries/preparations needed >> - sends the 'hold release' command on the management inteface >> >> - OpenVPN starts connecting to the remote server >> >> And if OpenVPN looses its connection, the management interface can capture >> that and do whatever it needs to do. And if OpenVPN stops running/dies, >> this >> management client script can even detect that and do whatever is needed in >> this scenario as well - like restarting OpenVPN. > > > If starting openvpn with the Windows GUI would a separate background > process be required to be polling the management port *all* the time > and take appropriate action upon connection ? > > If so, a --pre-connect script could be useful in that whatever tests > are required are only run prior to sending any data or other action. > Returning 0 to continue or anything else to abort .. > with an appropriate verbage openvpn.log error message. > > Another 'blade' for the "swiss army knife" of openvpn ..
The Windows GUI already supports a preconnect script. It waits on the script for a user defined timeout seconds and abort the connection if the script fails. Selva ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot _______________________________________________ Openvpn-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/openvpn-users
