mirror of
https://github.com/veracrypt/VeraCrypt.git
synced 2025-11-11 19:08:26 -06:00
Windows: Add setting in main UI and setup wizard to disable memory protection
This can be useful for users who need Accessibility software that may not work when memory protection is active in VeraCrypt
This commit is contained in:
@@ -74,6 +74,7 @@ BOOL UnloadDriver = TRUE;
|
||||
BOOL bSystemRestore = TRUE;
|
||||
BOOL bDisableSwapFiles = FALSE;
|
||||
BOOL bForAllUsers = TRUE;
|
||||
BOOL bDisableMemoryProtection = FALSE;
|
||||
BOOL bRegisterFileExt = TRUE;
|
||||
BOOL bAddToStartMenu = TRUE;
|
||||
BOOL bDesktopIcon = TRUE;
|
||||
@@ -2335,6 +2336,11 @@ void DoInstall (void *arg)
|
||||
if (bSystemRestore)
|
||||
SetSystemRestorePoint (hwndDlg, TRUE);
|
||||
|
||||
if (bOK && bDisableMemoryProtection)
|
||||
{
|
||||
WriteMemoryProtectionConfig(FALSE);
|
||||
}
|
||||
|
||||
if (bOK)
|
||||
{
|
||||
UpdateProgressBarProc(100);
|
||||
|
||||
@@ -120,6 +120,7 @@ extern BOOL bReinstallMode;
|
||||
extern BOOL bSystemRestore;
|
||||
extern BOOL bDisableSwapFiles;
|
||||
extern BOOL bForAllUsers;
|
||||
extern BOOL bDisableMemoryProtection;
|
||||
extern BOOL bRegisterFileExt;
|
||||
extern BOOL bAddToStartMenu;
|
||||
extern BOOL bDesktopIcon;
|
||||
|
||||
@@ -146,12 +146,14 @@ FONT 8, "MS Shell Dlg", 0, 0, 0x0
|
||||
BEGIN
|
||||
EDITTEXT IDC_DESTINATION,11,41,260,13,ES_AUTOHSCROLL
|
||||
PUSHBUTTON "Bro&wse...",IDC_BROWSE,278,40,59,14
|
||||
CONTROL "Install &for all users",IDC_ALL_USERS,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,77,168,11
|
||||
CONTROL "Install &for all users",IDC_ALL_USERS,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,68,168,11
|
||||
CONTROL "Add VeraCrypt to &Start menu",IDC_PROG_GROUP,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,80,168,11
|
||||
CONTROL "Add VeraCrypt icon to &desktop",IDC_DESKTOP_ICON,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,92,168,11
|
||||
CONTROL "Associate the .hc file &extension with VeraCrypt",IDC_FILE_TYPE,
|
||||
"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,113,232,11
|
||||
CONTROL "Add VeraCrypt to &Start menu",IDC_PROG_GROUP,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,89,168,11
|
||||
"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,104,232,11
|
||||
CONTROL "Disable memory protection in VeraCrypt",IDC_DISABLE_MEMORY_PROTECTION,
|
||||
"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,115,218,10
|
||||
CONTROL "Create System &Restore point",IDC_SYSTEM_RESTORE,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,125,194,11
|
||||
CONTROL "Add VeraCrypt icon to &desktop",IDC_DESKTOP_ICON,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,101,168,11
|
||||
LTEXT "Please select or type the location where you want to install the VeraCrypt program files. If the specified folder does not exist, it will be automatically created.",IDT_INSTALL_DESTINATION,11,14,319,25
|
||||
END
|
||||
|
||||
|
||||
@@ -685,6 +685,10 @@ BOOL CALLBACK PageDialogProc (HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lPa
|
||||
bForAllUsers = IsButtonChecked (GetDlgItem (hCurPage, IDC_ALL_USERS));
|
||||
return 1;
|
||||
|
||||
case IDC_DISABLE_MEMORY_PROTECTION:
|
||||
bDisableMemoryProtection = IsButtonChecked (GetDlgItem (hCurPage, IDC_DISABLE_MEMORY_PROTECTION));
|
||||
return 1;
|
||||
|
||||
case IDC_FILE_TYPE:
|
||||
bRegisterFileExt = IsButtonChecked (GetDlgItem (hCurPage, IDC_FILE_TYPE));
|
||||
return 1;
|
||||
|
||||
Reference in New Issue
Block a user