Detection rules › Elastic

Ingress Tool Transfer via INET Cache

Time window
1m
Sequence by
process.entity_id
Source
github.com/elastic/protections-artifacts

Identifies the use of a signed utility that takes a remote URL as a process argument or no arguments at all followed by the creation of an executable file in the INetCache Folder. Adversaries may use trusted utilities to download extra payloads to avoid ingress tool transfer restrictions.

MITRE ATT&CK coverage

TacticTechniques
Command & Control

Rule body

[rule]
description = """
Identifies the use of a signed utility that takes a remote URL as a process argument or no arguments at all followed by
the creation of an executable file in the INetCache Folder. Adversaries may use trusted utilities to download extra
payloads to avoid ingress tool transfer restrictions.
"""
id = "bd4d88c1-466e-4591-9c81-f2d257dbc9db"
license = "Elastic License v2"
name = "Ingress Tool Transfer via INET Cache"
os_list = ["windows"]
reference = [
    "https://attack.mitre.org/techniques/T1105/",
    "https://www.elastic.co/security-labs/unmasking-financial-services-intrusion-ref0657",
]
version = "1.0.7"

query = '''
sequence by process.entity_id with maxspan=1m
 [process where event.action == "start" and not user.id : ("S-1-5-18", "S-1-5-19", "S-1-5-20") and 
  process.code_signature.trusted == true and process.code_signature.subject_name : "Microsoft*" and 
  (process.command_line : "*http*" or (process.executable : "?:\\Windows\\*" and process.args_count <= 1)) and 
  not process.executable : ("?:\\Program Files\\*.exe", "?:\\Program Files (x86)\\*.exe") and
  not (process.name : "rundll32.exe" and process.args : "C:\\Windows\\System32\\rundll32.exe  C:\\Windows\\System32\\LogiLDA.dll,LogiFetch")]
 [file where event.action!= "deletion" and file.path : "?:\\Users\\*\\AppData\\Local\\Microsoft\\Windows\\INetCache\\*" and 
  (file.Ext.header_bytes : "4d5a*" or 
   file.extension : ("exe", "pif", "scr", "dll", "cpl", "bat", "cmd", "hta"))]
'''

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

[[optional_actions]]
action = "rollback"
field = "process.entity_id"
state = 0

[[threat]]
framework = "MITRE ATT&CK"
[[threat.technique]]
id = "T1105"
name = "Ingress Tool Transfer"
reference = "https://attack.mitre.org/techniques/T1105/"


[threat.tactic]
id = "TA0011"
name = "Command and Control"
reference = "https://attack.mitre.org/tactics/TA0011/"

[internal]
min_endpoint_version = "8.0.0"

Stages and Predicates

Ordered sequence: each step below must occur in order within 1m, correlated by process.entity_id.

Stage 1: process

[process where event.action == "start" and not user.id : ("S-1-5-18", "S-1-5-19", "S-1-5-20") and 
  process.code_signature.trusted == true and process.code_signature.subject_name : "Microsoft*" and 
  (process.command_line : "*http*" or (process.executable : "?:\\Windows\\*" and process.args_count <= 1)) and 
  not process.executable : ("?:\\Program Files\\*.exe", "?:\\Program Files (x86)\\*.exe") and
  not (process.name : "rundll32.exe" and process.args : "C:\\Windows\\System32\\rundll32.exe  C:\\Windows\\System32\\LogiLDA.dll,LogiFetch")]

Stage 2: file

[file where event.action!= "deletion" and file.path : "?:\\Users\\*\\AppData\\Local\\Microsoft\\Windows\\INetCache\\*" and 
  (file.Ext.header_bytes : "4d5a*" or 
   file.extension : ("exe", "pif", "scr", "dll", "cpl", "bat", "cmd", "hta"))]

Exclusions

The rule actively suppresses these predicates.

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
event.actioneq
  • start corpus 391 (elastic 391)
field:"EventType" kind:eq value:"start"
event.actionne
  • deletion corpus 86 (elastic 86)
field:"EventType" kind:ne value:"deletion"
file.Ext.header_byteswildcard
  • 4d5a* corpus 46 (elastic 46)
field:"file.Ext.header_bytes" kind:wildcard value:"4d5a*"
file.extensionwildcard
  • bat corpus 13 (elastic 13)
  • cmd corpus 15 (elastic 15)
  • cpl corpus 19 (elastic 19)
  • dll corpus 33 (elastic 33)
  • exe corpus 32 (elastic 32)
  • hta corpus 20 (elastic 20)
  • pif corpus 18 (elastic 18)
  • scr corpus 17 (elastic 17)
field:"file.extension" kind:wildcard
file.pathwildcard
  • ?:\Users\*\AppData\Local\Microsoft\Windows\INetCache\*
field:"TargetFilename" kind:wildcard value:"?:\Users\*\AppData\Local\Microsoft\Windows\INetCache\*"
process.args_countle
  • 1 transforms: number corpus 5 (elastic 5)
field:"process.args_count" kind:le value:"1"
process.code_signature.subject_namewildcard
  • Microsoft* corpus 22 (elastic 22)
field:"Signature" kind:wildcard value:"Microsoft*"
process.code_signature.trustedeq
  • true transforms: boolean corpus 14 (elastic 14)
field:"process.code_signature.trusted" kind:eq value:"true"
process.command_linewildcard
  • *http* corpus 52 (sigma 34, elastic 15, chronicle 2, splunk 1)
field:"CommandLine" kind:wildcard value:"*http*"
process.executablewildcard
  • ?:\Windows\* corpus 5 (elastic 5)
field:"Image" kind:wildcard value:"?:\Windows\*"