Google Researcher Shows How a Single Bit Change in .NET Files Bypassed Windows Code Integrity
A Google researcher demonstrated a method to bypass Windows code integrity protections using a single bit change in .NET files.

A quirk in the .NET Framework's file loading process allowed a local attacker to bypass Windows' security measures designed to prevent untrusted code execution, according to a write-up by Google Project Zero researcher James Forshaw. This finding is significant because it exposes vulnerabilities in both Windows code integrity and Oracle VirtualBox's process hardening mechanisms.
Forshaw's analysis revealed that a minor modification—a single bit change in a .NET file's header—enabled the execution of untrusted code, circumventing Windows' code integrity checks. Specifically, the change involved the IMAGE_FILE_EXECUTABLE_IMAGE flag, which, when cleared, allowed the .NET Framework to load and execute the file despite the integrity restrictions in place. This method also affected Oracle VirtualBox, allowing the bypass of its process hardening protections.
The mechanism exploits the way the .NET Framework loads program files. Normally, a .NET program is loaded as an executable image, but if this fails, the framework can run a plain copy from memory. Forshaw identified that for .NET files compiled as AnyCPU, a specific error during loading would trigger this fallback, allowing the code to bypass the checks that would typically prevent it from running.
In general, the .NET Framework is a software development platform created by Microsoft that allows developers to build and run applications on Windows. It includes a large library and supports various programming languages. One of its key features is the ability to load and execute code dynamically, which can be useful but also poses security risks if not properly managed. Attackers can exploit these features to run malicious code if they find a way to bypass the built-in security checks.
The vulnerabilities affect systems running Windows and Oracle VirtualBox, particularly those that utilize the .NET Framework version 4. Forshaw's findings indicate that the bypass could allow untrusted code to run in protected environments, potentially leading to unauthorized access or control over sensitive processes.
Both Microsoft and Oracle have addressed these vulnerabilities. Oracle released a fix for the VirtualBox flaw in September, while Microsoft issued a patch for the Windows code integrity issue on October 13. These updates were made available before Forshaw's write-up was published, indicating an awareness of the vulnerabilities by these companies.
Forshaw first presented the bypass technique at the 44Con conference in September, believing it fell outside Microsoft's typical criteria for fixes. After discussions with .NET developers, he reported the issue in late September, leading to a rapid response from Microsoft, which included a fix in the following month's Patch Tuesday.
Currently, it remains unclear if these vulnerabilities have been exploited in the wild. Microsoft has classified the Windows code integrity bypass as a local, low-privilege security feature bypass but has noted that it is publicly disclosed without evidence of active exploitation.
What security teams should do
- Organizations should update VirtualBox to the latest version that includes the September fixes.
- Security teams need to apply the October 13 update for the .NET Framework that corresponds to their specific Windows version.
What it meansA researcher showed how a minor change in .NET files allowed untrusted code to bypass Windows security checks. This highlights potential vulnerabilities in widely used systems.
Ask your IT team this weekWhich versions of the .NET Framework are currently in use across our systems?Have we applied the latest updates for both Windows and VirtualBox?
DecisionThe IT team will ensure all relevant updates for Windows and VirtualBox are applied, and security will verify compliance.