CVE-2026-121864 / CVE-2026-121865: nanobot let a chosen shell run outside the exec sandbox, and WebSocket clients open conversations in directories outside the configured workspace (fixed 0.4.1)
nanobot (HKUDS/nanobot, PyPI nanobot-ai) is an open-source personal AI agent. Tenable Research reported two bugs fixed in 0.4.1. With sandboxed exec turned on, the shell used to run commands could be chosen by the caller and was started before the sandbox, so an agent tricked into creating an executable in its workspace and selecting it as the shell ran that file outside the sandbox (for example Linux bubblewrap). Separately, a WebSocket client with a valid client token could start a new conversation rooted in a directory outside the operator's configured workspace and have the agent read files there.
What it is
CVE-2026-121864 (GHSA-5v87-m222-qr94, CWE-73, CVSS 3.1 8.5): when sandboxed exec is enabled, the shell executable is caller-selectable and launched before the sandbox is applied. An attacker who can induce the agent to create an executable in the workspace and select it as the shell gets it run outside the sandbox with the nanobot process's OS permissions (not root). Affected: nanobot-ai 0.2.1 up to (not including) 0.4.1.
CVE-2026-121865 (GHSA-hg87-wf6q-3m38, CWE-863, CVSS 3.1 7.6): a standard WebSocket gateway client holding a valid client token could pick an existing directory outside the configured workspace as the root of a new conversation; the agent could then expose files there readable by the nanobot service account. Confirmed affected: 0.3.5 and 0.4.0 (NVD: 0.3.5 before 0.4.1); the maintainers say earlier releases are still being assessed.
The maintainer advisories note exploitation through chat depends on the agent carrying out the required tool actions, and the second bug needs gateway access plus a valid client token.
Fix in 0.4.1: the sandbox is launched before the selected shell, and ordinary clients are restricted to their configured workspace authority. GitHub advisories published 8 November 2026; NVD published both CVEs on 17 November 2026 (Tenable TRA-2026-68 and TRA-2026-69).
How to check
- Run pip show nanobot-ai (or check your container tag): versions below 0.4.1 are affected.
- If you gave WebSocket client tokens to other people or apps, review gateway logs for conversations whose root directory is outside your configured workspace.
How to fix
- Upgrade nanobot-ai to 0.4.1 or later with your usual install method and restart the gateway.
- Run nanobot as a dedicated low-privilege user so a sandbox escape or out-of-workspace read only reaches files that user can see.
pip show nanobot-ai | grep -i '^version'
pip install -U 'nanobot-ai>=0.4.1'