Detect LNK Icon Smuggling in Google Chronicle
Adversaries abuse Windows shortcut (.LNK) files to smuggle malicious payloads past content filters. LNK files contain metadata fields including an icon location field (IconEnvironmentDataBlock) designed to specify an icon file path. Adversaries exploit this field to reference external URLs that trigger payload downloads when the LNK is invoked. They also abuse the LNK target path field to embed interpreter commands with obfuscated arguments, often padding target fields with extra spaces to hide the malicious portion from casual inspection. Threat actors including Kimsuky, Gamaredon Group, Mustang Panda, and TONESHELL malware have weaponized LNK files with spoofed PDF icons to trick users into executing malicious binaries.
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/
YARA-L Detection Query
rule lnk_icon_smuggling_t1027_012 {
meta:
author = "Argus Detection Engineering"
description = "Detects T1027.012 LNK Icon Smuggling via scripting engine LNK creation, padded commandlines, and suspicious binary execution from temp paths"
mitre_attack_tactic = "Defense Evasion"
mitre_attack_technique = "T1027.012"
severity = "HIGH"
priority = "HIGH"
events:
(
/* Pattern 1: LNK creation by scripting engine */
(
$e1.metadata.event_type = "FILE_CREATION"
and re.regex($e1.target.file.full_path, `(?i)\.lnk$`)
and re.regex($e1.principal.process.file.full_path,
`(?i)(powershell|cmd|wscript|cscript|mshta|rundll32|regsvr32|certutil)\.exe$`)
)
or
/* Pattern 2: Padded commandline execution via explorer.exe (Kimsuky) */
(
$e1.metadata.event_type = "PROCESS_LAUNCH"
and re.regex($e1.principal.process.file.full_path, `(?i)\\explorer\.exe$`)
and re.regex($e1.target.process.file.full_path,
`(?i)(powershell|cmd|wscript|cscript|mshta|regsvr32|rundll32)\.exe$`)
and re.regex($e1.target.process.command_line, `\s{15,}`)
)
or
/* Pattern 3: Suspicious binary from Temp/AppData via explorer.exe (Mustang Panda/TONESHELL) */
(
$e1.metadata.event_type = "PROCESS_LAUNCH"
and re.regex($e1.principal.process.file.full_path, `(?i)\\explorer\.exe$`)
and (
re.regex($e1.target.process.file.full_path, `(?i)\\office\.exe$`)
or re.regex($e1.target.process.file.full_path,
`(?i)(\\Temp\\|\\AppData\\Local\\Temp\\|\\AppData\\Roaming\\).*\.exe$`)
)
)
or
/* Pattern 4: DNS query from explorer.exe for suspicious domains (icon field fetch) */
(
$e1.metadata.event_type = "NETWORK_DNS"
and re.regex($e1.principal.process.file.full_path, `(?i)\\explorer\.exe$`)
and (
re.regex($e1.network.dns.questions.name, `(?i)\.(ps1|exe|dll|bat|vbs)$`)
and not re.regex($e1.network.dns.questions.name,
`(?i)(microsoft\.com|windows\.com|windowsupdate\.com|office\.com)$`)
)
)
)
condition:
$e1
} Chronicle YARA-L 2.0 rule detecting T1027.012 LNK Icon Smuggling across four behavioral patterns using UDM events: file creation of LNK files by scripting engines, process launch with padded commandlines via explorer.exe (Kimsuky TTP), suspicious binary execution from temp/AppData paths via explorer.exe (Mustang Panda/TONESHELL TTP), and DNS queries from explorer.exe for non-standard hostnames indicating icon field URL fetch.
Data Sources
Required Tables
False Positives & Tuning
- Automated build or CI/CD systems that generate LNK shortcuts via PowerShell scripts during artifact packaging
- Enterprise application launchers (e.g., Citrix, VMware Horizon) that use explorer.exe to open shortcuts with long path arguments
- Security tools performing DNS resolution through explorer.exe process context for threat intelligence lookups
Other platforms for T1027.012
Testing Methodology
Validate this detection against 4 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 1Create LNK with External Icon URL
Expected signal: Sysmon EventCode 11 (FileCreate) for the .lnk file creation. EventCode 1 (ProcessCreate) showing powershell.exe creating the file via WScript.Shell COM object.
- Test 2LNK with Padded Target Path (Kimsuky Evasion)
Expected signal: Sysmon EventCode 11 for LNK creation by powershell.exe. If executed: EventCode 1 showing cmd.exe spawned from explorer.exe with 260 spaces in CommandLine, then child powershell.exe process.
- Test 3LNK with PDF Icon Spoofing (Mustang Panda/TONESHELL Pattern)
Expected signal: Sysmon EventCode 11 for LNK creation. EventCode 1 for calc.exe (renamed as office.exe) execution from %TEMP% if the LNK is invoked. EventCode 11 for office.exe copy operation.
- Test 4LNK Executed via Script (Automated Execution Pattern)
Expected signal: Sysmon EventCode 11 for LNK creation by powershell.exe. EventCode 1 for cmd.exe spawned from powershell.exe. If icon URL were external: EventCode 22 DNS query and EventCode 3 network connection.
References (7)
- https://attack.mitre.org/techniques/T1027/012
- https://unprotect.it/technique/shortcut-hiding/
- https://www.uperesia.com/booby-trapped-shortcut
- https://www.securonix.com/blog/detecting-kimsuky-lnk-attack-chain/
- https://symantec-enterprise-blogs.security.com/threat-intelligence/shuckworm-ukraine-usb
- https://blog.talosintelligence.com/mustang-panda-plugx-pubload/
- https://www.sophos.com/en-us/threat-center/threat-analyses/mustang-panda-plugx
Unlock Pro Content
Get the full detection package for T1027.012 including response playbook, investigation guide, and atomic red team tests.