Response playbooks, investigation guides, and Atomic Red Team tests are Pro-only. Upgrade to unlock the full detection package for T1027.012.

Upgrade to Pro
T1027.012 Elastic Security · Elastic

Detect LNK Icon Smuggling in Elastic Security

This detection identifies adversary abuse of Windows shortcut (.LNK) file metadata — specifically the IconEnvironmentDataBlock (icon location field) and target path field — to smuggle commands or URLs that download malicious payloads. Threat actors including Kimsuky, Gamaredon Group, and Mustang Panda have leveraged crafted LNK files delivered via phishing or USB to execute scripts and binaries while displaying benign icons (e.g., PDF, Word document). Detection focuses on LNK files spawning unusual child processes, network connections originating from LNK-invoked interpreters, suspicious icon paths pointing to remote UNC or HTTP locations, and command-line interpreters launched with padded or obfuscated arguments consistent with LNK target field abuse.

MITRE ATT&CK

Tactic
Defense Evasion
Technique
T1027 Obfuscated Files or Information
Sub-technique
T1027.012 LNK Icon Smuggling
Canonical reference
https://attack.mitre.org/techniques/T1027/012/

Elastic Detection Query

Elastic Security (Elastic)
eql
sequence by host.name, user.name with maxspan=3m
  [file where event.action == "creation" and
   file.extension == "lnk" and
   not file.path : ("C:\\Users\\*\\AppData\\Roaming\\Microsoft\\Windows\\Recent\\*",
                    "C:\\ProgramData\\Microsoft\\Windows\\Start Menu\\*")]
  [process where event.type == "start" and
   process.parent.name : ("explorer.exe", "cmd.exe") and
   process.name : ("powershell.exe", "cmd.exe", "wscript.exe", "cscript.exe", "mshta.exe", "rundll32.exe", "certutil.exe", "bitsadmin.exe") and
   process.args : ("*http://*", "*https://*", "*ftp://*", "*downloadstring*", "*downloadfile*", "*iex*", "*invoke-expression*")]
  [network where event.type == "connection" and
   network.direction == "egress" and
   not destination.ip : ("10.0.0.0/8", "172.16.0.0/12", "192.168.0.0/16", "127.0.0.0/8")]
high severity medium confidence

Three-stage EQL sequence correlating: (1) suspicious LNK file creation outside standard Recent/Start Menu paths, (2) a scripting interpreter launch with download-related arguments within 3 minutes, and (3) an outbound network connection to a public IP from the same host and user.

Data Sources

Elastic AgentWinlogbeatFilebeat

Required Tables

fileprocessnetwork

False Positives & Tuning

  • Automated software provisioning that creates LNK launchers and immediately downloads components from CDNs
  • Browser-initiated downloads that create LNK files in non-standard locations with associated network activity
  • IT asset management agents that stage LNK shortcuts and fetch configuration from internal (but routable) servers

Other platforms for T1027.012


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.

  1. Test 1LNK Icon Path URL Trigger via PowerShell Download

    Expected signal: DeviceProcessEvents: powershell.exe spawned by explorer.exe with -WindowStyle Hidden and DownloadString URL; DeviceNetworkEvents: outbound connection from powershell.exe to 127.0.0.1:8080; Sysmon Event ID 11: LNK file creation in %TEMP%; Sysmon Event ID 3: network connection from powershell.exe

  2. Test 2LNK Target Field Padding to Bypass Visual Inspection

    Expected signal: Sysmon Event ID 1 or Security Event ID 4688: cmd.exe spawned by explorer.exe; CommandLine field showing /c echo command with 300+ trailing spaces; Sysmon Event ID 11: lnk_test_output.txt created in %TEMP%

  3. Test 3LNK File Executing mshta for Remote HTA Payload

    Expected signal: DeviceProcessEvents: mshta.exe spawned by explorer.exe with HTTP URL argument; DeviceNetworkEvents: outbound HTTP GET from mshta.exe to 127.0.0.1:8080; Sysmon Event ID 1: mshta.exe with command line containing http://; Sysmon Event ID 3: network connection from mshta.exe process

Unlock playbooks & atomic tests with Pro

Get the full detection package for T1027.012 — response playbook and atomic red team tests, plus investigation guidance and hunting queries.

df00tech Pro — £29/user/month

Response PlaybookInvestigation GuideHunting QueriesAtomic Red Team TestsTuning Guidance

Related Detections