Suspicious Network Module LoadLibrary


Description

Detects attempts to load a Microsoft networking related module from a potentially altered call stack in order to conceal the true source of the call.

Query · eql

library where dll.name : ("ws2_32.dll", "winhttp.dll", "wininet.dll") and
 _arraysearch(process.thread.Ext.call_stack, $entry, $entry.symbol_info like "C:\\Windows\\System32\\KernelBase.dll!LoadLibrary*") and
 process.thread.Ext.call_stack_summary like "ntdll.dll|kernelbase.dll|*" and
 not process.thread.Ext.call_stack_summary like "ntdll.dll|kernelbase.dll|*|kernelbase.dll*" and
 _arraysearch(process.thread.Ext.call_stack, $entry, $entry.symbol_info regex~ """C:\\Windows\\System32\\KernelBase.dll!([A-K]|[M-Z]).+""") and
 _arraysearch(process.thread.Ext.call_stack, $entry, $entry.symbol_info: "C:\\Windows\\System32\\ntdll.dll!LdrLoadDll*") and
 _arraysearch(process.thread.Ext.call_stack, $entry, $entry.symbol_info: "C:\\Windows\\System32\\kernel32.dll!BaseThreadInitThunk*") and
 not process.thread.Ext.call_stack_summary in ("ntdll.dll|kernelbase.dll|doclient.dll|rpcrt4.dll|combase.dll|rpcrt4.dll|ntdll.dll|kernel32.dll|ntdll.dll",
                                               "ntdll.dll|kernelbase.dll|doclient.dll|dosvc.dll|svchost.exe|sechost.dll|kernel32.dll|ntdll.dll")
Raw source Suspicious Network Module LoadLibrary · Elastic TOML
Esc
Published by elastic/protections-artifacts ↗, licensed under Elastic License 2.0 ↗. Reproduced here unmodified.
[rule]
description = """
Detects attempts to load a Microsoft networking related module from a potentially altered call stack in order to conceal
the true source of the call.
"""
id = "7bfc7234-49c6-4f52-93d6-f9d8ba13903b"
license = "Elastic License v2"
name = "Suspicious Network Module LoadLibrary"
os_list = ["windows"]
reference = ["https://www.elastic.co/security-labs/doubling-down-etw-callstacks"]
version = "1.0.3"

query = '''
library where dll.name : ("ws2_32.dll", "winhttp.dll", "wininet.dll") and
 _arraysearch(process.thread.Ext.call_stack, $entry, $entry.symbol_info like "C:\\Windows\\System32\\KernelBase.dll!LoadLibrary*") and
 process.thread.Ext.call_stack_summary like "ntdll.dll|kernelbase.dll|*" and
 not process.thread.Ext.call_stack_summary like "ntdll.dll|kernelbase.dll|*|kernelbase.dll*" and
 _arraysearch(process.thread.Ext.call_stack, $entry, $entry.symbol_info regex~ """C:\\Windows\\System32\\KernelBase.dll!([A-K]|[M-Z]).+""") and
 _arraysearch(process.thread.Ext.call_stack, $entry, $entry.symbol_info: "C:\\Windows\\System32\\ntdll.dll!LdrLoadDll*") and
 _arraysearch(process.thread.Ext.call_stack, $entry, $entry.symbol_info: "C:\\Windows\\System32\\kernel32.dll!BaseThreadInitThunk*") and
 not process.thread.Ext.call_stack_summary in ("ntdll.dll|kernelbase.dll|doclient.dll|rpcrt4.dll|combase.dll|rpcrt4.dll|ntdll.dll|kernel32.dll|ntdll.dll",
                                               "ntdll.dll|kernelbase.dll|doclient.dll|dosvc.dll|svchost.exe|sechost.dll|kernel32.dll|ntdll.dll")
'''

min_endpoint_version = "8.10.0"
optional_actions = []
[[actions]]
action = "kill_process"
field = "process.entity_id"
state = 0

[[threat]]
framework = "MITRE ATT&CK"
[[threat.technique]]
id = "T1036"
name = "Masquerading"
reference = "https://attack.mitre.org/techniques/T1036/"


[threat.tactic]
id = "TA0005"
name = "Defense Evasion"
reference = "https://attack.mitre.org/tactics/TA0005/"

[internal]
min_endpoint_version = "8.10.0"

Detection rules belong to the projects that publish them and remain under their own licenses. This site indexes and links to them; it claims no rights in them.