BugMeNot114514 - 2024-05-15

Subsystem version >= 6.3 requires IMAGE_LOAD_CONFIG_DIRECTORY::SecurityCookie != 0.

This can also be reproduced in MSVC.

cl /MD main.c /link ucrt.lib msvcrt.lib /subsystem:console,6.3 /entry:main

prevent happen

cl /MD main.c /link ucrt.lib msvcrt.lib /subsystem:console,6.3 /entry:main /include:__load_config_used

It's not strange for Windows to look at the image's subsystem version and enable mitigation, as it has in the past with heap termination and SEHOP.

 

Last edit: BugMeNot114514 2024-05-15