mirror of https://github.com/OpenVPN/openvpn-gui
fixup! Password-reveal: Respect group policy setting, if any
- Minor edit in registry.cpull/622/head
parent
fa1191b799
commit
14c7a69c79
|
@ -213,7 +213,7 @@ GetRegistryKeys ()
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Read group policy setting for password reveal */
|
/* Read group policy setting for password reveal */
|
||||||
status = RegOpenKeyEx(HKEY_CURRENT_USER, L"Software\\Policies\\Microsoft\\Windows\\CredUI", 0, KEY_READ, ®key);
|
status = RegOpenKeyExW(HKEY_CURRENT_USER, L"Software\\Policies\\Microsoft\\Windows\\CredUI", 0, KEY_READ, ®key);
|
||||||
if (status != ERROR_SUCCESS
|
if (status != ERROR_SUCCESS
|
||||||
|| !GetRegistryValueNumeric(regkey, L"DisablePasswordReveal", &o.disable_password_reveal))
|
|| !GetRegistryValueNumeric(regkey, L"DisablePasswordReveal", &o.disable_password_reveal))
|
||||||
{
|
{
|
||||||
|
@ -225,7 +225,9 @@ GetRegistryKeys ()
|
||||||
PrintDebug(L"from policy: %ls = %lu", L"DisablePasswordReveal", o.disable_password_reveal);
|
PrintDebug(L"from policy: %ls = %lu", L"DisablePasswordReveal", o.disable_password_reveal);
|
||||||
}
|
}
|
||||||
if (status == ERROR_SUCCESS)
|
if (status == ERROR_SUCCESS)
|
||||||
|
{
|
||||||
RegCloseKey(regkey);
|
RegCloseKey(regkey);
|
||||||
|
}
|
||||||
|
|
||||||
ExpandOptions ();
|
ExpandOptions ();
|
||||||
return true;
|
return true;
|
||||||
|
|
Loading…
Reference in New Issue