T1564.007sub-technique of T1564 Hide Artifacts
VBA Stomping
Linux · macOS · Windowsnothing on this site yetT1564.007 on attack.mitre.org
Adversaries may hide malicious Visual Basic for Applications (VBA) payloads embedded within MS Office documents by replacing the VBA source code with benign data. MS Office documents with embedded VBA content store source code inside of module streams. Each module stream has a `PerformanceCache` that stores a separate compiled version of the VBA source code known as p-code.
how MITRE says to see it
Detection Strategy for VBA Stomping
- Discrepancies between VBA source code and p-code inside Office documents. Defender perspective: anomalies in file metadata streams, execution of Office processes loading macros without source code consistency, and script execution with no corresponding source metadata.
- Execution of Wine or LibreOffice macros with inconsistent VBA metadata. Defender perspective: file analysis showing p-code embedded without matching source streams.
- Opening of Office files where VBA source code appears benign or missing, but p-code remains active. Defender perspective: process execution of Office apps with macro execution lacking visible source components.
what reduces it
- M1042 Disable or Remove Feature or Program. Turn off or restrict access to unneeded VB components.
the rest of T1564
- T1564.001 Hidden Files and Directories
- T1564.002 Hidden Users
- T1564.003 Hidden Window
- T1564.004 NTFS File Attributes
- T1564.005 Hidden File System
- T1564.006 Run Virtual Instance
- T1564.008 Email Hiding Rules
- T1564.009 Resource Forking
- T1564.010 Process Argument Spoofing
- T1564.011 Ignore Process Interrupts
- T1564.012 File/Path Exclusions
- T1564.013 Bind Mounts
- T1564.014 Extended Attributes