T1218.015

Electron Applications

Adversaries may abuse components of the Electron framework to execute malicious code. Electron is a cross-platform desktop application development framework using JavaScript, HTML, and CSS that embeds a Chromium browser engine and Node.js runtime. Common Electron apps include Signal, Slack, Microsoft Teams, VS Code, and Discord. Adversaries can abuse these applications by passing malicious JavaScript via command-line flags (--inspect, --inspect-brk, --remote-debugging-port) to enable DevTools remote debugging and execute arbitrary JavaScript with Node.js privileges. Lumma Stealer is a notable malware using this technique. This grants full system access including filesystem operations, child process spawning, and network communication.

Microsoft Sentinel / Defender
kusto
let ElectronApps = dynamic(["slack.exe", "teams.exe", "discord.exe", "code.exe", "signal-desktop.exe", "notion.exe", "obsidian.exe", "figma.exe", "1password.exe"]);
DeviceProcessEvents
| where Timestamp > ago(24h)
| where FileName has_any (ElectronApps) or ProcessCommandLine has_any ("--inspect", "--inspect-brk", "--remote-debugging-port", "--remote-allow-origins", "--js-flags")
| extend DebugPort = ProcessCommandLine has_any ("--inspect", "--inspect-brk", "--remote-debugging-port")
| extend RemoteDebugging = ProcessCommandLine matches regex @"--remote-debugging-port=\d+"
| extend JSFlags = ProcessCommandLine has "--js-flags"
| extend AllowOrigins = ProcessCommandLine has "--remote-allow-origins"
| extend SuspiciousParent = InitiatingProcessFileName has_any ("cmd.exe", "powershell.exe", "wscript.exe", "cscript.exe", "mshta.exe")
| where DebugPort or RemoteDebugging or JSFlags or (AllowOrigins and SuspiciousParent)
| project Timestamp, DeviceName, AccountName, FileName, ProcessCommandLine, InitiatingProcessFileName,
         InitiatingProcessCommandLine, DebugPort, RemoteDebugging, JSFlags, SuspiciousParent
| sort by Timestamp desc
high severity high confidence

Data Sources

Process: Process Creation Command: Command Execution Network: Network Connection Microsoft Defender for Endpoint

Required Tables

DeviceProcessEvents

False Positives

  • Developers using Electron debugging features (--inspect, --remote-debugging-port) during application development and testing
  • IT administrators using Electron debug flags for troubleshooting application issues
  • Automated testing frameworks (Spectron, Playwright for Electron) that use debug ports for headless testing
  • VS Code extension developers using the --inspect flag for extension debugging

Unlock Pro Content

Get the full detection package for T1218.015 including response playbook, investigation guide, and atomic red team tests.

Response PlaybookInvestigation GuideHunting QueriesAtomic Red Team TestsTuning Guidance

Related Detections