Commit 336551c9 by Cooper Partin Committed by Jamie Madill

Added compiler flags to enable Control Flow Guard.

Change-Id: I86e24b83e2e9b279c93c518ab9bc7dafd4b3d006 Reviewed-on: https://chromium-review.googlesource.com/272501Reviewed-by: 's avatarGeoff Lang <geofflang@chromium.org> Tested-by: 's avatarJamie Madill <jmadill@chromium.org>
parent fb28d3c5
...@@ -68,7 +68,13 @@ ...@@ -68,7 +68,13 @@
{ {
'VCCLCompilerTool': 'VCCLCompilerTool':
{ {
'AdditionalOptions': ['/MP'], # Control Flow Guard is a security feature in Windows
# 8.1 and higher designed to prevent exploitation of
# indirect calls in executables.
# Control Flow Guard is enabled using the /d2guard4
# compiler setting in combination with the /guard:cf
# linker setting.
'AdditionalOptions': ['/MP', '/d2guard4'],
'BufferSecurityCheck': 'true', 'BufferSecurityCheck': 'true',
'DebugInformationFormat': '3', 'DebugInformationFormat': '3',
'ExceptionHandling': '0', 'ExceptionHandling': '0',
...@@ -79,6 +85,13 @@ ...@@ -79,6 +85,13 @@
}, },
'VCLinkerTool': 'VCLinkerTool':
{ {
# Control Flow Guard is a security feature in Windows
# 8.1 and higher designed to prevent exploitation of
# indirect calls in executables.
# Control Flow Guard is enabled using the /d2guard4
# compiler setting in combination with the /guard:cf
# linker setting.
'AdditionalOptions': ['/guard:cf'],
'FixedBaseAddress': '1', 'FixedBaseAddress': '1',
'ImportLibrary': '$(OutDir)\\lib\\$(TargetName).lib', 'ImportLibrary': '$(OutDir)\\lib\\$(TargetName).lib',
'MapFileName': '$(OutDir)\\$(TargetName).map', 'MapFileName': '$(OutDir)\\$(TargetName).map',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment