Permissions, approvals, and sandboxing
Codant evaluates session permissions, command approval, filesystem sandboxing, and tool network policy separately. The daemon checks the relevant boundaries when it executes an operation.
Choose a session mode
The default mode is confirm. Select a startup mode with codant --mode <mode> or switch in the terminal UI with /mode <mode>.
| Mode | Behavior |
|---|---|
plan | Investigate using read-only workspace tools. File writes, shell commands, web tools, and external MCP tools are denied. |
confirm | Read the workspace directly. File writes, shell commands, web tools, and external MCP tools enter the relevant approval flow. |
auto | Edit files within the permitted workspace automatically. Shell commands recognized as safe and read-only can run directly, while other commands require approval. |
full | The session mode allows routine operations without per-action confirmation. Workspace, command, sandbox, and network constraints still apply. |
Use plan to investigate the code and tests. When you want to approve specific edits, submit a task with defined scope and acceptance criteria in confirm mode. Permission matrix in checkPermission · Terminal mode arguments
Review an approval request
The approval panel shows the pending operation. Use the offered choices to review that original operation, including the command, path, and target workspace. After an interruption or denial, check task details and the workspace diff for actions that have already run. Non-interactive codant exec denies operations requiring user approval. Use --mode plan for read-only automation.
In sessions with permission ceiling support, an accepted task is bound by the execution permission ceiling recorded for it. Raising the session mode applies to new submissions. An accepted task uses the stricter of its original ceiling and the current session mode. Execution ceilings in SessionPermissionModes · Non-interactive approval behavior
Inspect and revoke command rules
Persistent command rules come from the original approval flow. A rule can apply across sessions and matches the exact command, logical and physical workspace, and execution directory.
/rules list
/rules revoke <rule UUID>From the shell, use codant rules list and codant rules revoke <rule UUID>. Revocation applies to future dispatches. Manage an already running command through the corresponding task's interruption controls. The list is paginated. Read it again from the first page after changes. Command rule help and receipts
Inspect the local sandbox
Run codant sandbox status --offline from the actual project directory to read local installation and isolation diagnostics without starting a daemon. Online codant sandbox status and codant sandbox resources query a running daemon. Use --workspace <absolute path> to select a project. If a resource page has a nextCursor, continue with that cursor and keep the original workspace and page limit.
On Windows, you can explicitly initialize the sandbox with codant sandbox setup. Windows may show a UAC prompt. Offline output describes known local installation state. Check runtime isolation against the actual platform and workspace. Sandbox command arguments and offline behavior · Platform diagnostics in SandboxDiagnostics
Inspect tool network policy
Run codant network status to view the running daemon's tool network policy. Set tool networking in the user configuration under [sandbox.network]. Available modes include off, proxy, and full. Restart the daemon to load changes. Command approval and filesystem sandboxing still apply when the network policy permits a connection. Model provider and MCP connections use their own channels.
Local session and task records default to ~/.codant. Model providers and authorized external tools may receive project context within the permitted scope. Choose the scope of tasks with the data handling requirements of the configured services in mind. Tool network command · Network configuration schema · Model configuration and requests
Manage screen and clipboard grants
These host capabilities use separate interactive authorization. Run /computer help in the terminal interface for the available actions, or codant computer help at the shell for authorization, status, and stop commands. A grant requires confirmation in a local interactive terminal and remains tied to the original connection.
Inspect or revoke a session's access with codant computer status --session <session ID> or codant computer revoke --session <session ID>. Host capability commands and grant scope
Terminal workflows · Sandbox and daemon troubleshooting · Guide overview
