Skip to content
User application hardening
Essential EightE8-AH-ML2.4

Essential Eight AH-ML2.4 Block Microsoft Office from injecting code into other processes

What it says

Microsoft Office is blocked from injecting code into other processes.

Quoted as published. Everything else on this page is written by Control Stack.

In plain English

Microsoft Office must be blocked from injecting code into other running processes, so malicious code from a document cannot hide inside another program.

Microsoft Office must be blocked from injecting code into other processes. Code injection means placing code inside another running program so it runs as part of that program, with its identity and access. The block must cover every Office application on every device that runs Office. Blocked means the attempt fails, not that it is only logged or that the user can override it. This is a Maturity Level Two requirement.

Why it matters

Code that a malicious document runs inside Office can inject itself into another running program, where it passes as that program's normal activity and keeps running after Office closes. Blocking injection denies it that hiding place.

How to implement

  1. Run the code injection rule in audit mode on a pilot group.

    On Windows, use the endpoint protection rule that blocks Office applications from injecting code into other processes. Review each audit event; an add-in that needs injection must be changed or replaced, because an exclusion leaves Office able to inject.

  2. Set the rule to block on every device running Office.

    Apply it through Group Policy or device management to all workstations and servers with Office, including remote desktop hosts. Use block, not audit or warn. If another product replaces the built-in Windows antivirus, use its equivalent rule.

  3. Test that injection is blocked.

    On a test device, set the block on macros making Win32 API calls (E8-RM-ML2.1) to audit, or it stops the macro first. Signed in as a user allowed to run macros, open a purpose-built test document that attempts code injection. Confirm the block event names the code injection rule, then restore the Win32 API block.

Keep it running

Investigate every block event, since legitimate tools rarely need Office to inject code, and change the tool rather than add an exclusion. Recheck when endpoint protection changes or new devices are built, since a rule can be missed or left in audit.

Evidence and audit

  1. Check 1 of 3What an auditor asks for

    Ask for

    Office licence activation records or a software inventory, compared with the devices reporting the code injection rule.

    Look at

    Devices running Office, including servers and remote desktop hosts, that are missing from the report or not set to block.

    Good evidence

    Every device running Office reports the rule set to block, with none missing.

  2. Check 2 of 3What an auditor asks for

    Ask for

    The exclusions configured for the code injection rule.

    Look at

    Whether any exclusion lets Office inject code into another process.

    Good evidence

    No exclusion applies to the rule; one recorded as an approved exception still counts as a gap.

  3. Check 3 of 3What an auditor asks for

    Ask for

    A demonstration with a purpose-built test document that attempts to inject code into a program already running (the block on Office creating child processes, E8-AH-ML2.2, stops the document starting one), run by a user allowed to run macros, on a device in everyday use that the assessor picks, with only the block on macros making Win32 API calls (E8-RM-ML2.1) switched to audit for the test, so it cannot stop the macro first.

    Look at

    Whether the injection succeeds, and which rule the block event names.

    Good evidence

    The injection fails in each Office application tested, and each attempt is recorded as blocked by the code injection rule itself.

Mappings

Closest match in ASD Information Security Manual: ISM-1669, Prevent Microsoft Office from injecting code, which asks for the same thing.

ASD ISM

ASD Information Security Manual: 6 mappings

ASD Essentials

ASD Essentials for enterprise IT: 1 mapping

Mappings show how controls relate across frameworks. They do not imply full equivalence or certification.