T1027.001
Binary Padding
Adversaries may use binary padding to add junk data and change the on-disk representation of malware. This can be done without affecting the functionality or behavior of a binary, but can increase the size of the binary beyond what some security tools are capable of handling due to file size limitations. Binary padding effectively changes the checksum of the file and can also be used to avoid hash-based blocklists and static anti-virus signatures. Known threat actors including APT29, Kimsuky, Emotet, QakBot, Black Basta, and Akira have employed this technique to inflate file sizes and change file hashes.
Microsoft Sentinel / Defender
kusto
let LargePEThresholdMB = 50;
DeviceFileEvents
| where Timestamp > ago(24h)
| where ActionType == "FileCreated"
| where FileName endswith ".exe" or FileName endswith ".dll" or FileName endswith ".sys"
| where FileSize > (LargePEThresholdMB * 1024 * 1024)
| join kind=leftouter (
DeviceProcessEvents
| where Timestamp > ago(24h)
| project DeviceName, InitiatingProcessFileName, InitiatingProcessCommandLine, ProcessCommandLine, SHA256
) on DeviceName
| where FolderPath !startswith "C:\\Windows\\"
and FolderPath !startswith "C:\\Program Files\\"
and FolderPath !startswith "C:\\Program Files (x86)\\"
| project Timestamp, DeviceName, FolderPath, FileName, FileSize,
InitiatingProcessFileName, InitiatingProcessCommandLine, SHA256
| extend FileSizeMB = round(toreal(FileSize) / (1024*1024), 1)
| sort by FileSizeMB desc medium severity
medium confidence
Data Sources
File: File Creation Microsoft Defender for Endpoint
Required Tables
DeviceFileEvents DeviceProcessEvents
False Positives
- Large legitimate software installers (e.g., game installers, IDE packages, database engines) dropped in temp or user directories during installation
- Backup or archive tools writing large consolidated files that happen to use .exe or .dll extensions
- Software development workflows where compiled binaries with debug symbols legitimately exceed size thresholds
- Container or VM image export utilities writing large binary blobs with executable extensions
Last updated: 2026-04-13 Research depth: deep
References (6)
- https://attack.mitre.org/techniques/T1027/001/
- https://www.welivesecurity.com/2018/03/13/oceanlotus-ships-new-backdoor/
- https://securelist.com/old-malware-tricks-to-bypass-detection-in-the-age-of-big-data/78010/
- https://www.virustotal.com/en/faq/
- https://github.com/redcanaryco/atomic-red-team/blob/master/atomics/T1027.001/T1027.001.md
- https://www.mandiant.com/resources/blog/golang-internals-symbol-recovery
Unlock Pro Content
Get the full detection package for T1027.001 including response playbook, investigation guide, and atomic red team tests.
Response PlaybookInvestigation GuideHunting QueriesAtomic Red Team TestsTuning Guidance
Related Detections
Parent Technique
T1027Obfuscated Files or InformationRelated Sub-techniques
T1027.002Software PackingT1027.003SteganographyT1027.004Compile After DeliveryT1027.005Indicator Removal from ToolsT1027.006HTML SmugglingT1027.007Dynamic API ResolutionT1027.008Stripped PayloadsT1027.009Embedded PayloadsT1027.010Command ObfuscationT1027.011Fileless StorageT1027.012LNK Icon SmugglingT1027.013Encrypted/Encoded FileT1027.014Polymorphic CodeT1027.015CompressionT1027.016Junk Code InsertionT1027.017SVG Smuggling