Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2026-79403 Overview
CVE-2026-79403 is a local arbitrary code execution vulnerability in Kilo Code before version v7.4.1. The flaw resides in the permission/allow-everything endpoint exposed by the Kilo Code TUI daemon. A local attacker with access to the loopback interface can reach this endpoint without authentication and coerce the running instance to execute arbitrary code with the privileges of the user running Kilo Code.
Critical Impact
Any local process, including unprivileged applications and browser-hosted scripts able to reach localhost, can trigger arbitrary code execution through an unauthenticated TUI-owned HTTP route.
Affected Products
- Kilo Code versions prior to v7.4.1
- Kilo Code TUI daemon (opencode package, packages/opencode/src/cli/cmd/tui/thread.ts)
- Deployments exposing the local permission/allow-everything endpoint
Discovery Timeline
- 2026-09-29 - CVE-2026-79403 published to NVD
- 2026-09-29 - Last updated in NVD database
Technical Details for CVE-2026-79403
Vulnerability Analysis
Kilo Code ships a Terminal User Interface (TUI) daemon that exposes HTTP routes on the local machine for orchestrating agent sessions. One of these routes, permission/allow-everything, is designed to grant the running session unrestricted permission to invoke tools and execute commands. Prior to v7.4.1, that route accepted requests from any local caller without validating a shared secret or bearer token.
Because Kilo Code executes shell commands and file operations on behalf of the agent, an attacker who invokes permission/allow-everything can escalate a benign session into one that runs arbitrary code. The result is local code execution in the user's context, including the ability to read, modify, or exfiltrate any file the user can access.
Root Cause
The TUI-owned HTTP routes were reachable on the loopback interface with no per-worker authentication. The daemon spawned worker processes without provisioning a shared credential, so the server had no mechanism to distinguish the legitimate TUI from any other local process making the same request.
Attack Vector
Exploitation requires local access to the loopback interface where the Kilo Code daemon is listening. Any local user session, a co-resident process, or a web page bound to localhost in the same origin scope can issue an HTTP request to the permission/allow-everything endpoint and then submit a follow-up prompt that runs attacker-supplied commands.
// Security patch: packages/opencode/src/kilocode/cli/cmd/tui/thread.ts
import { randomUUID } from "node:crypto"
import { UI } from "@/cli/ui"
import type { NetworkOptions } from "@/cli/network"
import { ServerAuth } from "@/server/auth"
import { Flag } from "@opencode-ai/core/flag/flag"
import { errorMessage } from "@/util/error"
import { TuiConfig } from "@/cli/cmd/tui/config/tui"
import { validateSession } from "@/cli/cmd/tui/validate-session"
// Security patch: packages/opencode/src/cli/cmd/tui/thread.ts
// kilocode_change start - default TUI sessions attach to the daemon unless explicitly disabled
if (await KiloTuiThreadDaemon.attach({ args, cwd, input: () => input(args.prompt), start })) return
// kilocode_change end
const auth = KiloTuiThreadDaemon.workerAuth() // kilocode_change - protect TUI-owned HTTP routes from unauthenticated local callers
const env = sanitizedProcessEnv({
[KILO_PROCESS_ROLE]: "worker",
[KILO_RUN_ID]: ensureRunID(),
...auth.env, // kilocode_change
KILO_BACKGROUND_PROCESS_PORTS: "true", // kilocode_change - TUI surfaces inferred background process ports
})
Source: GitHub Commit 51e45d7fb7. The fix introduces ServerAuth, generates a per-worker credential with randomUUID, and propagates it via sanitized environment variables so only the legitimate TUI worker can call the protected routes.
Stop Remote Code Execution Before It Runs
Singularity™ Endpoint detects and blocks exploit attempts at machine speed, including zero-days and novel attack techniques.
Stop Exploit AttemptsDetection Methods for CVE-2026-79403
Indicators of Compromise
- Unexpected HTTP requests to the local Kilo Code daemon targeting permission/allow-everything from processes other than the TUI worker.
- Child processes of the Kilo Code daemon executing shell commands, package managers, or network utilities outside normal developer workflows.
- New or modified files under user home directories immediately after a Kilo Code session started an unattended prompt.
Detection Strategies
- Inspect process trees for node/opencode worker processes spawning shells, curl, wget, or credential-access binaries.
- Enable HTTP access logging on the local daemon and alert on requests to permission-related routes that lack the expected worker authentication header or environment token.
- Correlate loopback socket connections to the Kilo Code listening port with the PIDs of the processes initiating them; anything other than the parent TUI is suspect.
Monitoring Recommendations
- Track installed Kilo Code versions across developer endpoints and flag any host running a build older than v7.4.1.
- Monitor developer workstations for outbound connections originating from Kilo Code child processes to non-corporate destinations.
- Retain endpoint telemetry for command-line arguments and parent-child process relationships to support post-incident review of agent-driven executions.
How to Mitigate CVE-2026-79403
Immediate Actions Required
- Upgrade Kilo Code to v7.4.1 or later on every workstation where it is installed.
- Terminate any running Kilo Code daemon or TUI worker on unpatched hosts until the upgrade is complete.
- Audit shell history, agent transcripts, and file modification timestamps on hosts that ran vulnerable versions to confirm no unauthorized actions were executed.
Patch Information
The fix is delivered in commit 51e45d7fb7, merged through Pull Request #11887. The patch introduces KiloTuiThreadDaemon.workerAuth() and the ServerAuth module so TUI-owned HTTP routes require a per-worker credential, blocking unauthenticated local callers from reaching permission/allow-everything. A proof-of-concept demonstrating the pre-patch behavior is documented in the GitHub Gist PoC.
Workarounds
- If patching is not immediately possible, stop the Kilo Code daemon and avoid launching the TUI on shared or multi-user hosts.
- Restrict access to the loopback port used by Kilo Code with a local firewall rule or namespace isolation until the upgrade is applied.
- Do not run Kilo Code on systems where untrusted browser sessions or other local users can reach the daemon's listening port.
# Verify installed Kilo Code version and upgrade to the fixed release
kilo --version
npm install -g kilocode@7.4.1
# Confirm no unauthenticated listener remains on the TUI port
lsof -iTCP -sTCP:LISTEN -P | grep -i kilo
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

