Technical clarification: GetProcessMitigationPolicy and ProcessChildProcessPolicy

ふみや 竹崎 0 Reputation points
2026-11-15T03:33:40.6466667+00:00

Hello Microsoft Windows API Support Team,

I am seeking clarification about the documented support for querying child-process creation mitigation policies on Windows.

The Microsoft Learn documentation defines ProcessChildProcessPolicy in the PROCESS_MITIGATION_POLICY enumeration. It also documents PROCESS_MITIGATION_CHILD_PROCESS_POLICY and the process-creation attribute PROC_THREAD_ATTRIBUTE_CHILD_PROCESS_POLICY.

However, I could not establish the complete relationship between these definitions and the documented return-buffer contract of GetProcessMitigationPolicy.

Could you please clarify the following?

1. Query API support

Does GetProcessMitigationPolicy officially support ProcessChildProcessPolicy as its MitigationPolicy argument?

If yes, which Windows versions support this operation?

2. Return structure and buffer length

Which user-mode Windows SDK structure must be supplied through lpBuffer?

Which header defines that structure, and what is the required dwLength?

Does the documented ntddk.h structure have an officially supported user-mode equivalent?

3. Querying a suspended process

Can a separate launcher query the child-process creation policy of a newly created process while its initial thread remains suspended, before any user-mode code in that process has executed?

What conditions or limitations apply?

4. Relationship to process creation attributes

When the policy is specified using PROC_THREAD_ATTRIBUTE_CHILD_PROCESS_POLICY, can the queried mitigation state reliably reflect that setting before the target process is resumed?

Are audit-only settings distinguishable from enforced restrictions in the returned value?

5. Supported verification method

If this specific policy cannot be queried through GetProcessMitigationPolicy, is there a documented and supported alternative for independently verifying the applied child-process creation restriction before the target process executes?

Please provide official documentation references or relevant SDK definitions where possible.

This is a documentation and API-contract clarification request only. I am not requesting assistance with executing a process, bypassing security restrictions, or enabling network access.

Thank you for your assistance.

Windows development | Windows API - Win32
0 comments No comments

2 answers

Sort by: Most helpful
  1. Nguyen Dam (WICLOUD CORPORATION) 1,580 Reputation points Microsoft External Staff Moderator
    2026-11-16T04:36:18.56+00:00

    Hello @ふみや 竹崎 and thank you for your detailed questions. 

    As Microsoft Q&A is a community support forum, I may not be able to provide authoritative confirmation of undocumented API behavior. However, I can help clarify what is established by the available Windows API documentation. 

    1. Query API support 

    I cannot confirm whether GetProcessMitigationPolicy officially supports ProcessChildProcessPolicy, as it is not listed among the function's documented supported policies. 

    For version compatibility, the related PROCESS_MITIGATION_CHILD_PROCESS_POLICY structure is documented for Windows 10 version 1709 and Windows Server 2016. However, I cannot confirm whether these versions also support querying the policy through GetProcessMitigationPolicy. 

    2. Return structure and buffer length 

    The Windows Driver Kit documents PROCESS_MITIGATION_CHILD_PROCESS_POLICY in ntddk.h. This structure contains a 32-bit flags field with the following members: 

    • NoChildProcessCreation 
    • AuditNoChildProcessCreation 
    • AllowSecureProcessCreation 

    Its size is 4 bytes. However, the documentation does not establish this structure as the return buffer for GetProcessMitigationPolicy when using ProcessChildProcessPolicy. 

    Therefore, I cannot confirm an officially supported user-mode equivalent or the required dwLength for this particular query. 

    3. Querying a suspended process 

    A launcher can query documented process mitigation policies while the target process is suspended. 

    When a process is created with CREATE_SUSPENDED, its primary thread remains suspended until resumed. The launcher can use the process handle returned by CreateProcess with GetProcessMitigationPolicy, provided it has PROCESS_QUERY_INFORMATION access. 

    However, since ProcessChildProcessPolicy is not among the function's documented supported policies, I cannot confirm whether this particular query works before the process resumes. 

    4. Relationship to process creation attributes 

    PROC_THREAD_ATTRIBUTE_CHILD_PROCESS_POLICY is a documented process creation attribute that can be configured through UpdateProcThreadAttribute. 

    The documented values include: 

    • PROCESS_CREATION_CHILD_PROCESS_RESTRICTED: Restricts the process from creating child processes. 
    • PROCESS_CREATION_CHILD_PROCESS_OVERRIDE: Allows the process to override the restriction under the documented conditions. 

    The related PROCESS_MITIGATION_CHILD_PROCESS_POLICY structure also defines separate flags for enforced restrictions (NoChildProcessCreation) and audit-only behavior (AuditNoChildProcessCreation). 

    However, the documentation does not establish that GetProcessMitigationPolicy can reliably read back the policy configured through the creation attribute before the process resumes. 

    Although the structure distinguishes enforced restrictions from audit-only behavior, I cannot confirm a supported user-mode query that exposes this distinction. 

    5. Supported verification method 

    I could not identify a documented user-mode API that independently verifies the applied child-process creation restriction before the target process begins executing. 

    For an implementation using PROC_THREAD_ATTRIBUTE_CHILD_PROCESS_POLICY, you can check whether UpdateProcThreadAttribute and CreateProcess succeed and retain the configured attribute value on the launcher side. 

    This allows you to verify that the requested configuration was supplied through the documented process creation mechanism, although it does not independently confirm the resulting mitigation state. 

    I hope this helps clarify the documented behavior and the limitations of the available API information. 

    If you found my response helpful or informative, I would greatly appreciate it if you could follow this guide for your confirmation. Thank you. 

    Was this answer helpful?

    0 comments No comments

  2. AI answer

    2026-11-15T03:34:54.8466667+00:00

    ProcessChildProcessPolicy is not currently included in the documented set of values accepted by GetProcessMitigationPolicy; therefore, its buffer ABI, supported query versions, and use for pre-resume verification are not part of the published Win32 contract.

    1. Query API support

    The public PROCESS_MITIGATION_POLICY enumeration in winnt.h includes ProcessChildProcessPolicy ^1^. However, that alone does not establish that every enumeration member is accepted by every API taking the enumeration.

    The GetProcessMitigationPolicy documentation says that MitigationPolicy can be one of its listed values and specifies the corresponding output type for each. That list does not include ProcessChildProcessPolicy, even though it includes some later policies such as side-channel isolation and user shadow stacks ^2^.

    Consequently:

    • There is no documented guarantee that passing ProcessChildProcessPolicy is supported.
    • No supported Windows-version range can be assigned to that operation.
    • A successful result observed on a particular Windows build would be implementation behavior, not a documented compatibility contract.
    • The general Windows 8/Windows Server 2012 minimum shown for GetProcessMitigationPolicy does not establish support for this particular policy.

    The separate ntddk.h enumeration also includes ProcessChildProcessPolicy, but that is DDI documentation and does not expand the documented Win32 function contract ^3^.

    2. Return structure and length

    Microsoft documents this DDI structure in ntddk.h:

    typedef struct _PROCESS_MITIGATION_CHILD_PROCESS_POLICY {
        union {
            ULONG Flags;
            struct {
                ULONG NoChildProcessCreation : 1;
                ULONG AuditNoChildProcessCreation : 1;
                ULONG AllowSecureProcessCreation : 1;
                ULONG ReservedFlags : 29;
            };
        };
    } PROCESS_MITIGATION_CHILD_PROCESS_POLICY;
    

    It is a four-byte ULONG flags layout, and its documented minimum platforms are Windows 10 version 1709 and Windows Server 2016 ^4^.

    Nevertheless, the public material supplied here does not document this ntddk.h type—or a winnt.h user-mode counterpart—as the lpBuffer type for GetProcessMitigationPolicy. It therefore does not establish an officially supported dwLength for that policy. sizeof(PROCESS_MITIGATION_CHILD_PROCESS_POLICY) may match an observed implementation, but it is not a documented Win32 query contract.

    User-mode applications should not include ntddk.h merely to infer an undocumented Kernel32 ABI.

    3. Querying a suspended process

    CREATE_SUSPENDED guarantees that the new process’s primary thread does not run until ResumeThread is called ^5^. The process handle returned by process creation can therefore be used for documented process-handle operations before user-mode execution begins.

    GetProcessMitigationPolicy requires a process handle with PROCESS_QUERY_INFORMATION ^2^. This supports querying the policies that the function explicitly documents while the target is suspended. It does not make the omitted child-process policy query supported.

    4. Relationship to the creation attribute

    PROC_THREAD_ATTRIBUTE_CHILD_PROCESS_POLICY is a documented process-creation attribute whose value is a DWORD. It supports:

    • PROCESS_CREATION_CHILD_PROCESS_RESTRICTED (0x01)
    • PROCESS_CREATION_CHILD_PROCESS_OVERRIDE (0x02)

    The restriction becomes a property of the token under which the process runs. Microsoft also warns that it is effective only in sandboxed applications that prevent access to sufficiently privileged process handles; otherwise, access such as PROCESS_CREATE_PROCESS or PROCESS_VM_WRITE may permit bypassing the restriction ^6^.

    A typical creation value is:

    DWORD childPolicy = PROCESS_CREATION_CHILD_PROCESS_RESTRICTED;
    
    UpdateProcThreadAttribute(
        attributes,
        0,
        PROC_THREAD_ATTRIBUTE_CHILD_PROCESS_POLICY,
        &childPolicy,
        sizeof(childPolicy),
        nullptr,
        nullptr);
    

    The attribute value must remain valid until the attribute list is deleted ^6^.

    There is no documented guarantee that this value can subsequently be read through GetProcessMitigationPolicy before or after resume.

    The DDI structure defines separate NoChildProcessCreation and AuditNoChildProcessCreation bits, with enforcement taking precedence when both are set ^4^. However, the documented PROC_THREAD_ATTRIBUTE_CHILD_PROCESS_POLICY values shown above do not provide an audit-only creation value. The DDI bit definitions therefore cannot be used to infer a supported user-mode query or audit mapping for that attribute.

    5. Supported verification before execution

    The available public documentation does not specify a supported API that independently reads back this particular creation attribute from another process before its initial thread runs.

    Get-ProcessMitigation -Id can report current mitigation settings for a running process, but its documentation does not establish it as a pre-resume readback contract for PROC_THREAD_ATTRIBUTE_CHILD_PROCESS_POLICY ^7^.

    NtQueryInformationProcess is not a suitable supported substitute: Microsoft states that its information classes and returned structures are internal and may change, and recommends public alternatives ^8^.

    For a supported design, treat successful process creation with the requested attribute as the configuration result, retain the exact attribute value in launcher-side state or logs, and enforce the documented sandbox and handle-access conditions. There is no documented independent readback that provides the stronger pre-execution attestation requested.


    References

    1. PROCESS_MITIGATION_POLICY enumeration (winnt.h)
    2. GetProcessMitigationPolicy function (processthreadsapi.h)
    3. PROCESS_MITIGATION_POLICY enumeration (ntddk.h)
    4. PROCESS_MITIGATION_CHILD_PROCESS_POLICY structure (ntddk.h)
    5. Process Creation Flags
    6. UpdateProcThreadAttribute function (processthreadsapi.h)
    7. Gets all process mitigation policies for all processes set in the registry using the Get-ProcessMitigation PowerShell cmdlet.
    8. NtQueryInformationProcess function (winternl.h)
    AI-generated content may be incorrect. Read our transparency notes for more information.

    Was this answer helpful?

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.