T09 · Insecure Skill Coding Practices
- Location
SKILL.md:42- Finding
Overbroad Forced Termination of Node.js Processes
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 42-43
Vulnerability Type: Overbroad destructive process management
Risk Level: Mediumtext ACT: taskkill /F /IM node.exe EVALUATE: gekillt → neu startenTechnical Analysis
The gateway-diagnostic example instructs the agent to execute
taskkill /F /IM node.exe. Selecting processes by image name causes the command to target every accessiblenode.exeprocess rather than only the process associated with the gateway on port 18789. The/Foption also forces termination, preventing graceful shutdown and cleanup.This violates least-scope process-management practices. Although the command appears in an example rather than executable code, an agent applying the documented workflow may execute it directly during gateway diagnosis.
Attack Path
- A user or automated workflow requests diagnosis of a gateway issue.
- The agent follows the documented autonomous cascade example.
- The agent executes
taskkill /F /IM node.exe. - Windows selects all accessible processes whose image name is
node.exe. - The processes are forcibly terminated without verifying their relationship to port 18789 or the gateway.
- Unrelated Node.js services, development servers, or active jobs are disrupted.
No privilege-escalation mechanism is present: the command can terminate only those processes permitted by the agent's existing execution context.
Impact Assessment
Successful execution can cause denial of service for unrelated Node.js applications within the account's process-control scope. Forced termination may interrupt requests, background jobs, and development sessions, and may cause loss of unsaved or in-memory state. If the agent already runs with elevated privileges, the disruption could extend to Node.js services owned by other users or the system; the Skill itself does not obtain those elevated privileges.
- Remediation
View remediation
Remediation Suggestions
Replace image-wide forced termination with a narrowly scoped and verified procedure:
- Identify the PID listening on port 18789 using
Get-NetTCPConnection,netstat -ano, or an equivalent trusted mechanism. - Verify that the PID belongs to the intended gateway by checking its executable path, command line, owner, and expected working directory.
- If no verified gateway process owns the port, stop and report the discrepancy rather than terminating unrelated processes.
- Request user confirmation before destructive process termination unless prior authorization explicitly covers that action.
- Attempt graceful shutdown of only the verified PID or use the gateway's supported stop command.
- Use forced termination solely as an explicitly approved fallback after graceful shutdown fails.
- Confirm that port 18789 has been released before restarting the gateway, and verify the health endpoint afterward.
- Identify the PID listening on port 18789 using
