Security

Trusted folders

Control which projects can use Bob Shell's full capabilities with trusted folder security.

Trusted folders

Trusted folders give you control over which projects can be used with Bob Shell. You must approve a folder before Bob Shell loads any project-specific configurations, protecting you from potentially malicious code.

Note:

The trusted folders feature is disabled by default. To enable it, open the /settings menu and set Folder Trust to true. A restart is required for the change to take effect.

How trusted folders work

When you run Bob Shell from a folder for the first time, a trust dialog appears automatically, prompting you to make a choice:

  • Trust folder: Grant full trust to the current folder (for example, my-project)
  • Trust parent folder: Grant trust to the parent directory (for example, safe-projects), which automatically trusts all of its subdirectories. Use this option if you keep all your safe projects in one location
  • Don't trust: Mark the folder as untrusted. Bob Shell operates in a restricted safe mode

Your choice is saved in ~/.bob/trustedFolders.json, so you are only asked once per folder.

Impact of untrusted folders

When a folder is untrusted, Bob Shell runs in restricted safe mode. The following features are disabled or ignored:

FeatureBehaviour in safe mode
Project settings.bob/settings.json is not loaded. Custom tools and potentially dangerous configurations are blocked.
Tool auto-approvalYou are always prompted before any tool runs, even if auto-approval is enabled globally.
MCP serversBob Shell will not attempt to connect to any MCP servers.
Custom modesModes defined in the project folder are unavailable. Only built-in modes and your globally defined modes can be used.
SkillsProject-bundled skills are not loaded. Only globally available skills and built-in capabilities are active.
SubagentsCustom subagents from the project folder are unavailable. The agent cannot delegate work to project-provided helpers.
Project instructionsGuidance files such as AGENTS.md and custom project rules are not read. The agent operates without the project's custom instructions.

Granting trust to a folder unlocks the full functionality of Bob Shell for that workspace.

Managing trust settings

How trust is resolved
Bob Shell checks ~/.bob/trustedFolders.json for an existing decision for the current folder.
Change the current folder's trust
Run the /permissions slash command from within Bob Shell. The interactive dialog appears, allowing you to change the trust level for the current folder.
View all trust rules
Inspect ~/.bob/trustedFolders.json in your home directory for a complete list of all your trusted and untrusted folder rules.

Non-interactive sessions

Unlike interactive mode, non-interactive sessions never display the trust dialog. Bob Shell operates silently based on pre-existing trust decisions.

When the feature is enabled and no trust decision exists for the folder, or the folder is marked as untrusted, Bob Shell throws an error and does not run:

<folder> is not a trusted folder. Pass --trust to run in this folder,
or run Bob Shell interactively and choose a trust level.

Flag behaviour by mode

The --trust and --auto-approve flags behave differently depending on how Bob Shell is launched. Select your mode to session the relevant behaviour:

--trust
The folder is persisted as trusted. Bob Shell writes a trusted entry for the current directory to ~/.bob/trustedFolders.json and skips the first-access trust dialog. This is equivalent to opening the folder and manually selecting "Trust folder."
--auto-approve
Auto-approval is silently suppressed in an untrusted folder. You are still prompted before every tool runs.
--trust
The folder is treated as trusted for that run only. The trust decision is not persisted and nothing is written to the trust store.

Pre-configuration for automation

For secure automation and CI/CD pipelines, establish trust decisions before running non-interactive commands:

  1. Run an interactive session first to set trust preferences via the dialog.
  2. Manually configure ~/.bob/trustedFolders.json.

Pre-configuring trust is essential for security-sensitive environments, as Bob Shell will not fall back to a trusted state when no decision exists.

Best practices

  • Trust only folders containing code you have reviewed or created yourself
  • Use the "Trust parent folder" option for directories containing multiple safe projects
  • Regularly review your trusted folders list in ~/.bob/trustedFolders.json
  • When working with unfamiliar code, start in untrusted mode to understand the project before granting trust
How is this topic?