Disabling Data Execution Prevention
To disable Data Execution Prevention on Windows Server 2008 R2, 2012, 2012 R2, 2016 or 2019.
- In Windows, open the command prompt window.
- After the command prompt, type bcdedit.exe /set {current} nx AlwaysOff and press Enter.
- Restart the computer.
Verifying the status of Data Execution Prevention
To verify the status of Data Execution Prevention on Windows Server 2008 R2, 2012, 2012 R2, 2016 or 2019.
- In Windows, open the command prompt window.
- After the command prompt, type wmic OS Get DataExecutionPrevention_SupportPolicy and press Enter.
The command prompt will return a number that maps to the status of Data Execution Prevention, as defined by the following table.
0 | AlwaysOff | DEP is disabled for all processes. |
1 | AlwaysOn | DEP is enabled for all processes. |
2 | OptIn | DEP is enabled only for Windows system components and services that have DEP applied. |
3 | OptOut | DEP is enabled for all processes. Administrators can manually create a list of specific applications that do not have DEP applied. |
↑