Detect AppInit DLLs in IBM QRadar
Adversaries may establish persistence and/or elevate privileges by executing malicious content triggered by AppInit DLLs loaded into processes. Dynamic-link libraries (DLLs) that are specified in the AppInit_DLLs value in the Registry keys HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\Windows or HKEY_LOCAL_MACHINE\Software\Wow6432Node\Microsoft\Windows NT\CurrentVersion\Windows are loaded by user32.dll into every process that loads user32.dll. In practice, this is nearly every desktop process (GUI applications). This Registry-based injection mechanism has been used by multiple APT groups and crimeware families including Flame, FinFisher, and others.
MITRE ATT&CK
- Tactic
- Privilege Escalation Persistence
- Technique
- T1546 Event Triggered Execution
- Sub-technique
- T1546.010 AppInit DLLs
- Canonical reference
- https://attack.mitre.org/techniques/T1546/010/
QRadar Detection Query
SELECT
DATEFORMAT(devicetime, 'YYYY-MM-dd HH:mm:ss') AS event_time,
logsourcename(logsourceid) AS log_source,
username AS user_name,
"hostname" AS host,
QIDNAME(qid) AS event_name,
"YARA-L TargetObject" AS registry_path,
"YARA-L Details" AS registry_value,
CASE
WHEN "eventpayload" ILIKE '%AppInit_DLLs%'
AND "eventpayload" NOT ILIKE '%system32%'
AND "eventpayload" NOT ILIKE '%SysWOW64%'
AND "eventpayload" NOT ILIKE 'Details><%'
THEN 'APPINIT_SUSPICIOUS_DLL_PATH'
WHEN "eventpayload" ILIKE '%LoadAppInit_DLLs%'
AND "eventpayload" ILIKE '%Details>1<%'
THEN 'APPINIT_LOADING_ENABLED'
WHEN "eventpayload" ILIKE '%RequireSignedAppInit_DLLs%'
AND "eventpayload" ILIKE '%Details>0<%'
THEN 'APPINIT_SIGNATURE_DISABLED'
ELSE 'APPINIT_KEY_MODIFIED'
END AS detection_type,
"eventpayload" AS raw_payload
FROM events
WHERE
LOGSOURCETYPEID(logsourceid) IN (12, 347, 380)
AND (
("eventpayload" ILIKE '%Microsoft\\Windows NT\\CurrentVersion\\Windows%'
OR "eventpayload" ILIKE '%Wow6432Node\\Microsoft\\Windows NT\\CurrentVersion\\Windows%')
AND (
"eventpayload" ILIKE '%AppInit_DLLs%'
OR "eventpayload" ILIKE '%LoadAppInit_DLLs%'
OR "eventpayload" ILIKE '%RequireSignedAppInit_DLLs%'
)
)
AND devicetime > NOW() - 86400000
ORDER BY event_time DESC
LIMIT 500 Detects AppInit DLL registry modifications (T1546.010) by querying Windows Security and Sysmon log sources in QRadar. Identifies suspicious DLL paths, enabling of AppInit loading (LoadAppInit_DLLs=1), and disabling of code-signing requirement (RequireSignedAppInit_DLLs=0). LOGSOURCETYPEID 12 = Windows Event Log, 347 = Sysmon, 380 may vary by environment — adjust to match local DSM mappings.
Data Sources
Required Tables
False Positives & Tuning
- Security software vendors (endpoint agents, AV products) that register signed helper DLLs in AppInit_DLLs as part of user-mode monitoring
- Legacy enterprise applications deployed before AppInit_DLLs was deprecated that still rely on this mechanism for cross-process functionality
- Software deployment pipelines or SCCM/Intune scripts that configure registry values during mass workstation provisioning
Other platforms for T1546.010
Testing Methodology
Validate this detection against 3 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.
- Test 1Register DLL in AppInit_DLLs and Enable Loading
Expected signal: Three Sysmon Event ID 13 records: (1) AppInit_DLLs set to C:\Users\Public\argus_appinit.dll, (2) LoadAppInit_DLLs set to 1, (3) RequireSignedAppInit_DLLs set to 0. The combination of all three changes in a short time window is a high-confidence indicator.
- Test 2Enable AppInit Loading Without DLL Path
Expected signal: Sysmon Event ID 13: TargetObject contains Windows NT\CurrentVersion\Windows\LoadAppInit_DLLs, Details=1. This single-value change is an intermediate persistence indicator.
- Test 3Audit Current AppInit_DLLs State
Expected signal: Process creation for reg.exe (multiple times) querying AppInit keys. Read-only — no modifications. Use this as a scheduled hunt query to detect pre-existing AppInit DLL registrations.
References (5)
- https://attack.mitre.org/techniques/T1546/010/
- https://github.com/redcanaryco/atomic-red-team/blob/master/atomics/T1546.010/T1546.010.md
- https://support.microsoft.com/en-us/topic/description-of-the-appinit-dlls-feature-in-windows-7-and-windows-server-2008-r2-aabbf40f-3e10-eadd-6260-79df3d753b5f
- https://www.mandiant.com/resources/blog/likely-iranian-threat-actor-conducts-politically-motivated-disruptive-activity-against-israel
- https://pentestlab.blog/2019/12/12/persistence-appinit-dlls/
Unlock Pro Content
Get the full detection package for T1546.010 including response playbook, investigation guide, and atomic red team tests.