12 KiB
12 KiB
Common Malware Indicators Reference
Suspicious Import Functions
Process Injection/Manipulation
CreateRemoteThread- Inject code into another processWriteProcessMemory- Write to another process's memoryVirtualAllocEx- Allocate memory in another processOpenProcess- Access another processNtUnmapViewOfSection- Process hollowing techniqueSetThreadContext- Modify thread executionResumeThread- Resume suspended thread (often after injection)QueueUserAPC- APC injection technique
Keylogging
SetWindowsHookEx- Install keyboard hooksGetAsyncKeyState- Poll keyboard stateGetForegroundWindow- Get active window titleGetKeyState- Check key status
Network Activity
InternetOpen/InternetOpenUrl- WinINet HTTP requestsHttpSendRequest- Send HTTP requestsend/recv- Raw socket communicationWSAStartup- Initialize Winsockconnect/socket- Network connectionsURLDownloadToFile- Download files from URLs
Persistence Mechanisms
RegSetValueEx/RegCreateKeyEx- Registry manipulationCreateService- Install Windows serviceStartService- Start serviceITaskService/ITaskFolder::RegisterTaskDefinition- COM interfaces for scheduled task creation;schtasks.exe /createis the command-line equivalent
Stealth/Anti-Analysis
IsDebuggerPresent- Debugger detectionCheckRemoteDebuggerPresent- Remote debugger checkNtQueryInformationProcess- Process information (anti-debug)GetTickCount- Timing checks (anti-sandbox)Sleep- Delay execution (sandbox evasion)FindWindow- Look for analysis tools
EDR/Telemetry Evasion
EtwEventWrite/NtTraceEvent- ETW patching target; writing 0xC3 (ret) to prologue blinds EDR telemetryAmsiScanBuffer/AmsiScanString/AmsiInitialize- AMSI bypass targets; patched to return S_OK (0) with AMSI_RESULT_CLEAN (0), or to return E_INVALIDARG so the caller treats the result as no threatUpdateProcThreadAttribute- PPID spoofing when called with PROC_THREAD_ATTRIBUTE_PARENT_PROCESS attributeVirtualProtect- Required before patching; look for calls targeting ntdll.dll or amsi.dll memory rangesGetProcAddress+LoadLibrary- Runtime API resolution to avoid static import evidence (common in syscall stubs)
Callback-based Shellcode Execution
EnumChildWindows/EnumDesktopWindows- Callback used as execution primitive instead of CreateThreadCreateTimerQueueTimer- Timer callback used to invoke shellcodeTpAllocWork/TpPostWork/TpReleaseWork- Threadpool callbacks for shellcode dispatchSetTimer/EnumSystemLocales/EnumTimeFormatsEx- Less common callback execution primitives
File Manipulation
CreateFile/WriteFile/ReadFile- File I/ODeleteFile- Delete filesMoveFile/CopyFile- File operationsFindFirstFile/FindNextFile- Directory enumeration
Encryption/Encoding
CryptEncrypt/CryptDecrypt- Data encryptionCryptAcquireContext- Crypto provider setupCryptGenKey- Generate encryption keys
Suspicious String Patterns
Network Indicators
- Hardcoded IP addresses (especially RFC1918 or suspicious IPs)
- Domain names (especially newly registered or suspicious TLDs)
- URL patterns:
http://,https://,ftp:// - Port numbers in strings (especially non-standard ports)
- User-Agent strings (especially custom/unusual ones)
- Email addresses (especially for data exfiltration)
File Paths
%APPDATA%,%TEMP%,%LOCALAPPDATA%- Common malware locations\Microsoft\Windows\Start Menu\Programs\Startup\- PersistenceC:\ProgramData\- Hidden location- Hidden folders:
$Recycle.Bin,System Volume Information
Registry Keys
Persistence (Run Keys):
Software\Microsoft\Windows\CurrentVersion\RunSoftware\Microsoft\Windows\CurrentVersion\RunOnceSOFTWARE\Microsoft\Windows\CurrentVersion\RunServices
System Modification:
SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon(especially Userinit, Shell)SYSTEM\CurrentControlSet\Services- Service installationSOFTWARE\Microsoft\Windows\CurrentVersion\policies- Policy changes
Commands and Scripts
-
PowerShell indicators:
-EncodedCommand- Base64 encoded commands-ExecutionPolicy Bypass- Bypass script restrictions-WindowStyle Hidden- Hide executionDownloadString,DownloadFile- Download payloadsIEX(Invoke-Expression) - Execute code
-
CMD indicators:
cmd.exe /c- Execute commandschtasks- Task schedulingreg add- Registry manipulationnetsh- Network/firewall changeswmic- WMI commandsrundll32- Execute DLL functions
Encoding/Obfuscation
- Base64 encoded strings (check for padding:
==) - Hex encoded data
- XOR key patterns
- Reversed strings
- Unicode/wide character strings
Cryptocurrency
- Bitcoin addresses (start with 1, 3, or bc1)
- Ethereum addresses (0x followed by 40 hex chars)
- Monero addresses
- Wallet-related terms: "wallet.dat", "cryptocurrency"
Ransomware Indicators
- File extension strings:
.encrypted,.locked,.crypto, etc. - Ransom note filenames:
README.txt,HOW_TO_DECRYPT.txt - Payment terms: "bitcoin", "decrypt", "ransom", "payment"
- Encryption terms: "AES", "RSA", "encrypted"
Suspicious File Characteristics
PE Header Anomalies
- Compilation timestamp in the future
- Compilation timestamp too old for file features
- Mismatched architecture in headers
- Unusual section names (normal:
.text,.data,.rdata,.rsrc) - High entropy sections (>7.0 suggests encryption/packing)
- Overlapping sections
- Large overlay data
- Missing or invalid digital signatures
Entropy Analysis
- Low entropy (0-3): Likely unencrypted, readable data
- Medium entropy (3-5): Typical compiled code
- High entropy (7-8): Packed, encrypted, or compressed
- Check individual PE sections for high entropy
Packer Signatures
Common packers:
- UPX (common, legitimate and malicious)
- ASPack
- PECompact
- Themida/WinLicense (strong protection)
- Armadillo
- VMProtect
- Enigma Protector
- Custom/unknown packers (more suspicious)
File Size Oddities
- Very small for claimed functionality (<10KB for complex malware)
- Unusually large resources section
- Significant overlay data
- File size doesn't match claimed type
Behavioral Indicators
Anti-Analysis Behaviors
- Checks for VM artifacts (VMware, VirtualBox, QEMU)
- Looks for debugger presence
- Timing checks (execution delays)
- Checks for analysis tools (Process Monitor, Wireshark, IDA)
- Sandbox detection (limited resources, username checks)
- Parent process verification
- Mouse movement monitoring
- Checks for user interaction
Modern EDR/AV Evasion Techniques
ETW Patching:
- Overwrites the prologue of
EtwEventWriteorNtTraceEventwith aretinstruction (0xC3) to suppress Event Tracing for Windows telemetry - Look for:
VirtualProtect→WriteProcessMemory/memcpytargeting ntdll address space, followed by restoration of original page protections - Effect: EDR and ETW-based logging goes blind for the process lifetime
AMSI Bypass:
- Patches
AmsiScanBufferorAmsiScanStringin amsi.dll to return S_OK (0) withAMSI_RESULT_CLEAN(0), or to return E_INVALIDARG so the caller treats the result as no threat; disables script content scanning - Look for:
LoadLibrary("amsi.dll")+GetProcAddress+VirtualProtect+ small write (1-8 bytes); orAmsiInitializenever called while PowerShell/script engine is used - Effect: Malicious PowerShell, VBScript, or JScript passes AMSI unchecked
Direct Syscalls / SysWhispers:
- Bypasses EDR hooks placed on ntdll.dll exports by issuing raw syscall/sysenter instructions with the correct System Service Number (SSN)
- Look for:
syscallorsysenterinstructions in non-system modules (useobjdump/dumpbin); runtime SSN resolution via ntdll stub scanning (Hell's Gate, Halo's Gate, Tartarus Gate patterns); absence of ntdll imports for expected operations (noNtAllocateVirtualMemoryimport but memory is allocated) - Common SSNs targeted: NtAllocateVirtualMemory, NtWriteVirtualMemory, NtCreateThreadEx, NtProtectVirtualMemory
PPID Spoofing:
- Creates a child process with a forged parent PID by passing a handle to the target parent via
UpdateProcThreadAttribute(PROC_THREAD_ATTRIBUTE_PARENT_PROCESS)before callingCreateProcess - Look for:
OpenProcesson an unrelated high-privilege process (e.g., explorer.exe, svchost.exe) immediately beforeCreateProcess; process tree in logs showing implausible parent-child relationships - Effect: Evades detections that trigger on suspicious parent-child pairs (e.g., Word spawning cmd.exe)
Module Stomping / DLL Hollowing:
- Loads a legitimate, signed DLL into memory then overwrites its
.textsection with malicious shellcode, so execution appears to originate from a trusted module - Look for:
LoadLibraryon an unexpected DLL followed byVirtualProtect(PAGE_EXECUTE_READWRITE)andWriteProcessMemory/memcpyinto that DLL's base address; signed DLL mapped but exports resolve to unexpected code - Distinguish from process hollowing: the host process is not suspended — the stomped DLL simply runs attacker code under a legitimate module name
Persistence Techniques
- Registry Run key modification
- Scheduled task creation
- Service installation
- WMI event subscriptions
- DLL hijacking/search order hijacking
- AppInit_DLLs registry key
- Startup folder files
- Browser extension installation
Network Patterns
- Beaconing (regular C2 communication)
- HTTP with suspicious User-Agents
- Raw socket connections
- IRC protocols
- DNS tunneling (unusual DNS queries)
- TOR usage
- Fast flux domains
Data Exfiltration
- Unusual outbound data volumes
- Screenshots being taken
- Credential harvesting
- Browser data collection
- Keylogger output transmission
- File upload to external servers
Red Flags by File Type
Executable Files (.exe, .dll, .scr)
- No digital signature or invalid signature
- Packed/protected
- Very few imports (possibly resolved at runtime)
- Unusual compilation timestamp
- Suspicious filename mimicking system files
Script Files (.ps1, .vbs, .js, .bat)
- Heavy obfuscation
- Base64 encoded sections
- Download and execute patterns
- WMI usage for execution
- Registry manipulation
Office Documents (.doc, .xls, .docx, .xlsx)
- Macros enabled
- Auto-execute macro names (AutoOpen, Auto_Open, Workbook_Open)
- External template references
- Embedded objects
- Suspicious OLE streams
Archive Files (.zip, .rar, .7z)
- Executable files with misleading extensions
- Multi-layer nested archives
- Password-protected archives (especially with generic passwords)
- Suspicious filenames inside
Quick Classification Patterns
Ransomware
- File encryption APIs
- Many file I/O operations
- File extension changes
- Ransom note creation
- Cryptocurrency addresses
- File deletion after encryption
Trojan/RAT
- Network communication APIs
- Remote control capabilities
- Screen capture
- File transfer
- Command execution
- Persistence mechanisms
Infostealer
- Browser data access
- Credential harvesting
- Clipboard monitoring
- Form grabbing
- Cookie stealing
- Cryptocurrency wallet targeting
Dropper/Loader
- Embedded resources
- Creates and executes files
- Downloads additional payloads
- Process injection
- Minimal visible functionality
Cryptominer
- High CPU usage
- Mining pool connections
- Cryptocurrency-related strings
- GPU access APIs
- Persistence with hidden processes
Tool Detection Strings
Malware often checks for these analysis tools:
Debuggers:
- OllyDbg, x64dbg, IDA Pro, WinDbg
- Immunity Debugger
Monitors:
- Process Monitor (procmon), Process Explorer
- Wireshark, Fiddler
- TCPView, RegShot
Sandboxes:
- Cuckoo, Joe Sandbox
- Any.Run, Hybrid Analysis
- VMRay, FireEye
VM Artifacts:
- "VMware", "VirtualBox", "QEMU", "Hyper-V"
- "vmmouse", "vmhgfs", "vboxguest"
- Registry keys related to VMs
Analysis Artifacts:
- Username: "sandbox", "malware", "virus", "sample"
- Hostname: "VIRUS-PC", "MALWARE-ANALYSIS"
- Limited resources (low RAM, CPU count)