Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions cmd/gateway_setup.go
Original file line number Diff line number Diff line change
Expand Up @@ -221,6 +221,14 @@ func setupToolRegistry(
filepath.Join(dataDir, "skills-store")+"/",
filepath.Join(dataDir, "tenants")+"/",
)
// Allow the goclaw-managed Python venv interpreter to be invoked with its
// absolute path. venv/bin/python3 is a symlink to the real interpreter
// (e.g. linuxbrew cellar), and matchesAnyPathExemption resolves symlinks
// before comparing — so we must exempt the *resolved* target dir.
// Resolved at startup; falls back silently if venv not present.
if real, err := filepath.EvalSymlinks(filepath.Join(filepath.Dir(dataDir), "venv", "bin", "python3")); err == nil {
et.AllowPathExemptions(filepath.Dir(real) + "/")
}
// Harden: block access to internal workspace files via shell commands.
// Prevents `cat ../config.json`, `cat memory.db` etc. from user workspaces.
et.DenyPaths(
Expand Down
Loading