Startup Persistence via Unusual Process
Description
Identifies files written to or modified in the startup folder by an unusual Microsoft process. Adversaries may use this technique to maintain persistence.
Query · eql
file where event.action != "deletion" and
file.path : ("?:\\Users\\*\\AppData\\Roaming\\Microsoft\\Windows\\Start Menu\\Programs\\Startup\\*",
"?:\\ProgramData\\Microsoft\\Windows\\Start Menu\\Programs\\StartUp\\*") and
process.executable : "?:\\Windows\\*" and
/* Issue #297 */
not file.name : "desktop.ini" and
not process.executable : "?:\\Windows\\Application Compatibility Scripts\\acregl.exe" and
not process.executable : "?:\\Windows\\Temp\\*.exe" and
not user.id : "S-1-5-18" and
not process.name :
("wscript.exe",
"cscript.exe",
"powershell.exe",
"explorer.exe",
"dllhost.exe",
"notepad.exe",
"cmd.exe",
"Robocopy.exe",
"xcopy.exe",
"wuauclt.exe",
"msiexec.exe",
"CompPkgSrv.exe",
"rundll32.exe",
"svchost.exe",
"sc.exe",
"backgroundTaskHost.exe",
"AppVClient.exe") and
not file.extension : ("TMP", "INF", "INI", "DDF", "CAB", "RPT", "RDP", "ppk")