Skip to content

feat(openclaw): add curl and python3 to exec allowed commands#1

Open
nt1412 wants to merge 1 commit intomainfrom
feat/openclaw-n8n-exec
Open

feat(openclaw): add curl and python3 to exec allowed commands#1
nt1412 wants to merge 1 commit intomainfrom
feat/openclaw-n8n-exec

Conversation

@nt1412
Copy link
Copy Markdown
Owner

@nt1412 nt1412 commented Mar 20, 2026

Summary

Add curl and python3 to OpenClaw's allowed exec commands, enabling agents to make HTTP API calls and run scripts from within the container.

Use case: Create n8n workflows from Open WebUI chat

With this change, a user can chat with the openclaw model in Open WebUI and ask it to create n8n workflows via the REST API:

  1. User: "Create a webhook workflow that responds with Hello"
  2. OpenClaw writes the workflow JSON to a file
  3. OpenClaw runs curl -X POST http://n8n:5678/api/v1/workflows -d @/tmp/wf.json
  4. Workflow appears in n8n

Depends on: Light-Heart-Labs#438 (OpenClaw + Open WebUI integration)

Changes

  • openclaw-strix-halo.json: add curl, python3 to tools.exec.allowedCommands

Security note

curl is restricted to commands the agent can run — it cannot escape the container. The OpenClaw container has no-new-privileges:true and resource limits. python3 enables script execution for data processing tasks.

Test plan

  • Ask OpenClaw via Open WebUI to run curl http://n8n:5678/api/v1/workflows — verify it executes
  • Ask OpenClaw to write JSON and POST it to n8n — verify workflow is created
  • Verify python3 works: ask OpenClaw to write and run a Python script

🤖 Generated with Claude Code

Enables OpenClaw agents to make HTTP API calls (curl) and run Python
scripts (python3) from within the container. This allows use cases
like creating n8n workflows via the REST API directly from an Open
WebUI chat session.

Tested: OpenClaw successfully wrote workflow JSON and POSTed it to
n8n's /api/v1/workflows endpoint, creating a working webhook workflow.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@nt1412
Copy link
Copy Markdown
Owner Author

nt1412 commented Mar 20, 2026

Screenshot 2026-03-20 at 10 16 54 AM

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 2759d68cd7

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

"exec": {
"enabled": true,
"allowedCommands": ["ls", "cat", "grep", "find", "head", "tail", "wc"]
"allowedCommands": ["ls", "cat", "grep", "find", "head", "tail", "wc", "curl", "python3"]
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Remove python3 from exec allowlist

Allowlisting python3 defeats the purpose of the constrained allowedCommands model, because an agent can run arbitrary Python (for example via -c) and then invoke unrestricted subprocesses, network calls, and file operations that were previously blocked by command-level gating. In deployments where OpenClaw has mounted data/config volumes, this effectively expands execution from a small read-only toolset to near-arbitrary code execution inside the container, which is a significant security and containment regression.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant