Commit Graph

1 Commits

Author SHA1 Message Date
Moltbot System
f3d695fe8b feat(security): add 'moltbot security wrap' CLI for external content protection
Adds a new CLI subcommand that wraps external content with security boundaries,
mirroring the existing wrapExternalContent() function but making it accessible
for skills and manual API calls.

Features:
- Wrap content from stdin or URL
- Detect suspicious patterns (prompt injection attempts)
- Output wrapped content with security warnings
- JSON output option with metadata

Usage:
  echo '{"data": "test"}' | moltbot security wrap --stdin --source api
  moltbot security wrap --url https://api.example.com/data
  curl -s https://api.example.com | moltbot security wrap --stdin

This addresses the gap where the existing external content protection only
applies to inbound hooks, not to content agents fetch manually.

Closes #4329
2026-01-30 03:11:15 +00:00