Using the Keyboard Filter with Applocker

Christian Reynolds 0 Reputation points
2025-07-21T14:13:59.1733333+00:00

Hi, I am working on an Applocker configuration for a Windows 11 IoT Enterprise device and I'm struggling with using the KeyboardFilter and Applocker together. When I am running the system without Applocker, the KeyboardFilter properly filters out the sequences I've specified, however when I enable Applocker, it doesn't prevent these sequences anymore. In Event Viewer, there is a warning that "The Keyboard Filter Service failed to launch hook process. Reason: This program is blocked by group policy. For more information, contact your system administrator." for the User SYSTEM. That is followed by a "Failed to detach session Catastrophic failure" Error. Any configuration I've tried other than just allowing all executables for all users causes this issue with the KeyboardFilter. Is there a way to see a list of what this requires to function or can someone assist me? It's not very verbose about what's actually causing this issue.

Ideally I would like to use these configurations but the error shows up here as well: https://github.com/nsacyber/AppLocker-Guidance/blob/master/AppLocker%20Starter%20Policy/Windows11_AppLocker%20Starter%20Policy.xml

Windows for business | Windows for IoT
{count} votes

1 answer

Sort by: Most helpful
  1. Smith Pham 2,510 Reputation points Independent Advisor
    2025-07-23T09:42:50.1733333+00:00

    Dear Christian,

    To resolve the issue with the Keyboard Filter not functioning properly when AppLocker is enabled, the root cause is likely that AppLocker is blocking essential executables required by the Keyboard Filter service.

    Here’s how to fix it:


    1. Review AppLocker Logs
    • Use Event Viewer to identify which executable is being blocked (typically the error will reference the Keyboard Filter hook process).

    Check AppLocker logs under Applications and Services Logs > Microsoft > Windows > AppLocker.


    1. Create Explicit AppLocker Rules

    Allow Required Executables: Add rules to allow KeyboardFilterService.exe and any supporting processes or DLLs it needs.

    System Services & Group Policy: Ensure system-related paths (e.g., C:\Windows\System32) aren't blocked by restrictive rules.

    Use Publisher or Path rules to whitelist trusted components.


    1. Verify Group Policy Settings

    Open Group Policy Management Editor.

    Navigate to:

    Computer Configuration > Windows Settings > Security Settings > Application Control Policies > AppLocker

    Make sure no policies are unintentionally preventing system services like Keyboard Filter from launching.


    1. Test with Relaxed Rules

    As a diagnostic step, configure AppLocker to allow all executables temporarily.

    Confirm that the Keyboard Filter functions correctly.

    Then, tighten the policy step-by-step to isolate the exact rule needed without compromising overall security.


    By explicitly allowing the necessary executables and ensuring your policy isn't overly restrictive, you should be able to run Keyboard Filter and AppLocker together without conflict.

    Let me know if you need help identifying the specific blocked executable from your logs.

    Best regards,Dear Christian,

    To resolve the issue with the Keyboard Filter not functioning properly when AppLocker is enabled, the root cause is likely that AppLocker is blocking essential executables required by the Keyboard Filter service.

    Here’s how to fix it:


    1. Review AppLocker Logs

    Use Event Viewer to identify which executable is being blocked (typically the error will reference the Keyboard Filter hook process).

    Check AppLocker logs under Applications and Services Logs > Microsoft > Windows > AppLocker.


    2. Create Explicit AppLocker Rules

    Allow Required Executables: Add rules to allow KeyboardFilterService.exe and any supporting processes or DLLs it needs.

    System Services & Group Policy: Ensure system-related paths (e.g., C:\Windows\System32) aren't blocked by restrictive rules.

    Use Publisher or Path rules to whitelist trusted components.


    3. Verify Group Policy Settings

    Open Group Policy Management Editor.

    Navigate to:

    Computer Configuration > Windows Settings > Security Settings > Application Control Policies > AppLocker

    Make sure no policies are unintentionally preventing system services like Keyboard Filter from launching.


    4. Test with Relaxed Rules

    As a diagnostic step, configure AppLocker to allow all executables temporarily.

    Confirm that the Keyboard Filter functions correctly.

    Then, tighten the policy step-by-step to isolate the exact rule needed without compromising overall security.


    By explicitly allowing the necessary executables and ensuring your policy isn't overly restrictive, you should be able to run Keyboard Filter and AppLocker together without conflict.

    Let me know if you need help identifying the specific blocked executable from your logs.

    Best regards,

    1 person found this answer helpful.

Your answer

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