T1553.006 IBM QRadar · QRadar

Detect Code Signing Policy Modification in IBM QRadar

Adversaries may modify code signing policies to enable execution of unsigned or self-signed code. On Windows, this includes enabling TESTSIGNING boot mode via bcdedit.exe, disabling Driver Signature Enforcement (DSE) by modifying the g_CiOptions kernel variable (typically via a BYOVD exploit), or changing registry keys that control signed DLL enforcement such as RequireSignedAppInit_DLLs. On macOS, adversaries disable System Integrity Protection (SIP) using csrutil disable from Recovery Mode. Threat actors including APT39, BlackEnergy, Hikit, Pandora, and Turla have used these techniques to load unsigned rootkit drivers and persist with kernel-level access.

MITRE ATT&CK

Tactic
Defense Evasion
Technique
T1553 Subvert Trust Controls
Sub-technique
T1553.006 Code Signing Policy Modification
Canonical reference
https://attack.mitre.org/techniques/T1553/006/

QRadar Detection Query

IBM QRadar (QRadar)
sql
SELECT
  DATEFORMAT(starttime, 'yyyy-MM-dd HH:mm:ss') AS event_time,
  sourceip,
  username,
  "hostname",
  QIDNAME(qid) AS event_name,
  CATEGORYNAME(category) AS category_name,
  "Process Name" AS process_name,
  "Command" AS command_line,
  "Target Object" AS registry_target,
  "Details" AS registry_value,
  CASE
    WHEN LOWER("Command") LIKE '%nointegritychecks%' AND LOWER("Command") LIKE '%on%' THEN 'critical'
    WHEN LOWER("Command") LIKE '%testsigning%' AND LOWER("Command") LIKE '%on%' THEN 'high'
    WHEN LOWER("Target Object") LIKE '%HypervisorEnforcedCodeIntegrity%' THEN 'critical'
    WHEN LOWER("Target Object") LIKE '%RequireSignedAppInit_DLLs%' THEN 'high'
    WHEN LOWER("Target Object") LIKE '%EnableVirtualizationBasedSecurity%' THEN 'high'
    ELSE 'medium'
  END AS severity,
  CASE
    WHEN "Process Name" LIKE '%bcdedit%' THEN 'BCD_Policy_Modification'
    WHEN "Target Object" LIKE '%DeviceGuard%' OR "Target Object" LIKE '%CI%' THEN 'Registry_CI_Modification'
    ELSE 'Code_Signing_Policy_Change'
  END AS detection_type
FROM events
WHERE
  starttime > NOW() - 1 DAYS
  AND (
    (
      LOGSOURCETYPEID = 119  -- Microsoft Windows Security Event Log
      AND qid IN (
        SELECT qid FROM qidmap WHERE eventid IN (4688, 4657)
      )
      AND (
        ("Process Name" ILIKE '%bcdedit%'
          AND (LOWER("Command") LIKE '%testsigning%'
               OR LOWER("Command") LIKE '%nointegritychecks%'
               OR LOWER("Command") LIKE '%bootdebug%'))
        OR
        ("Object Name" ILIKE '%RequireSignedAppInit%'
          OR "Object Name" ILIKE '%DeviceGuard%'
          OR "Object Name" ILIKE '%\\Control\\CI%'
          OR "Object Name" ILIKE '%CodeIntegrity%')
      )
    )
    OR
    (
      LOGSOURCETYPEID = 215  -- Sysmon
      AND (
        (qid IN (SELECT qid FROM qidmap WHERE eventid = 1)
          AND LOWER("Image") LIKE '%bcdedit%'
          AND (LOWER("CommandLine") LIKE '%testsigning%'
               OR LOWER("CommandLine") LIKE '%nointegritychecks%'
               OR LOWER("CommandLine") LIKE '%bootdebug%'))
        OR
        (qid IN (SELECT qid FROM qidmap WHERE eventid = 13)
          AND (
            "TargetObject" ILIKE '%RequireSignedAppInit_DLLs%'
            OR "TargetObject" ILIKE '%LoadAppInit_DLLs%'
            OR "TargetObject" ILIKE '%HypervisorEnforcedCodeIntegrity%'
            OR "TargetObject" ILIKE '%EnableVirtualizationBasedSecurity%'
            OR "TargetObject" ILIKE '%RequirePlatformSecurityFeatures%'
            OR "TargetObject" ILIKE '%\\Control\\CI\\%'
            OR "TargetObject" ILIKE '%\\Control\\CodeIntegrity%'
          )
        )
      )
    )
  )
ORDER BY starttime DESC
critical severity medium confidence

QRadar AQL detection for T1553.006 querying both Windows Security Event Log (EventIDs 4688 process creation, 4657 registry audit) and Sysmon (EventID 1 process, EventID 13 registry set value). Identifies bcdedit.exe invocations enabling test signing or disabling integrity checks, and registry writes disabling DeviceGuard/HVCI/RequireSignedAppInit_DLLs controls. Severity is computed inline using CASE logic based on the specific policy being modified.

Data Sources

Microsoft Windows Security Event Log (DSM)Microsoft Sysmon (DSM)IBM QRadar SIEM

Required Tables

events

False Positives & Tuning

  • IT operations teams running bcdedit as part of Windows OS upgrade or repair procedures such as rebuilding BCD stores after corruption
  • Software developers on approved developer workstations enabling TESTSIGNING to load in-development kernel drivers that have not yet been submitted for WHQL signing
  • Vulnerability management or penetration testing teams running authorized BYOVD simulation tests on isolated lab hosts as part of red team exercises
Download portable Sigma rule (.yml)

Other platforms for T1553.006


Testing Methodology

Validate this detection against 5 adversary techniques from Atomic Red Team. Each test below lists the behaviour to exercise and the telemetry you should expect to see. Executable commands and cleanup steps are available with Pro.

  1. Test 1Enable TESTSIGNING Boot Mode via bcdedit

    Expected signal: Sysmon Event ID 1: Process Create with Image=C:\Windows\System32\bcdedit.exe, CommandLine='bcdedit /set testsigning on'. Security Event ID 4688 (with process command line auditing enabled) with same details. Note: no additional event is generated when TESTSIGNING takes effect at next reboot — the bcdedit process event is the only log entry.

  2. Test 2Disable Driver Signature Enforcement via nointegritychecks

    Expected signal: Sysmon Event ID 1: Process Create with Image=bcdedit.exe and CommandLine containing 'nointegritychecks on'. Security Event ID 4688 if process command line auditing is enabled. Microsoft-Windows-Kernel-Boot/Operational Event ID 16 will show the changed boot configuration at next boot cycle.

  3. Test 3Disable RequireSignedAppInit_DLLs via Registry

    Expected signal: Sysmon Event ID 13: Registry Value Set with TargetObject='HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Windows\RequireSignedAppInit_DLLs', Details='DWORD (0x00000000)'. Sysmon Event ID 1: Process Create for reg.exe with full command line. Security Event ID 4657 if object access auditing is configured for registry keys.

  4. Test 4Disable Hypervisor-Protected Code Integrity (HVCI) via Registry

    Expected signal: Sysmon Event ID 13: Registry Value Set with TargetObject containing 'DeviceGuard\HypervisorEnforcedCodeIntegrity', Details='DWORD (0x00000000)'. Sysmon Event ID 1 for reg.exe process. Security Event ID 4657 (if object access auditing enabled). At next reboot: Windows Event Log Microsoft-Windows-DeviceGuard/Operational will show HVCI enforcement status change.

  5. Test 5macOS System Integrity Protection Status Check and Disable Simulation

    Expected signal: macOS Unified Log (ULS): process execution of csrutil with 'disable' argument. EDR telemetry (if macOS endpoint agent deployed): process creation event for /usr/bin/csrutil with arguments 'disable'. The command will fail with 'csrutil: failed to modify system integrity configuration. This tool needs to be executed from Recovery OS.' which itself is a detectable signal.

Unlock Pro Content

Get the full detection package for T1553.006 including response playbook, investigation guide, and atomic red team tests.

Response PlaybookInvestigation GuideHunting QueriesAtomic Red Team TestsTuning Guidance

Related Detections