On Fri, Nov 25, 2016 at 10:27 AM, Gert Doering <g...@greenie.muc.de> wrote:
> On Fri, Nov 25, 2016 at 09:38:31AM -0500, Selva Nair wrote: > > Even if the GUI cjecks HKLM and HKCU, toggling the option will not work > as > > the GUI cannot reset HKLM values. We do not want to be requiring admin > > rights to run the GUI and that option becomes "readonly" for the user if > > startup is set in HKLM. > > How do other packagages handle "this is the system default, but users > can change their own setting"? (So the admin could say "I want this > started > by default, for all users" and individual users can uncheck this "leave > me alone!") > > Just thinking aloud, no idea how much effort this is, and whether it's > a useful consideration in the first place. The installer could enumerate all users and adds the setting to their HKCU's. But its not perfect as new users will not get the setting. A more sophisticated approach is to use the "active-setup" feature. I have never used it but its supposed to work like this: Installer adds a reg key "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Active Setup\Installed Components\OpenVPNUserSetup" with two values: Version = "2.4.1" <-- update this every install StubPath = "some_cmd" <-- see below When the user logs system will check the value of Version and if new, will execute "some_cmd". So we can set som_cmd to just add teh required reg-key in HKCU like this: reg add HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Run /v "OPENVPN-GUI" /d "path_to_openvpn_gui" /t REG_SZ /f" I haven't tested it. For more details see: https://helgeklein.com/ blog/2010/04/active-setup-explained/ or google active setup. Selva
------------------------------------------------------------------------------
_______________________________________________ Openvpn-devel mailing list Openvpn-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openvpn-devel