← 返回
安全合规 中文

Clawback

Gmail security proxy with policy enforcement, approval workflows, and audit logging. Use when the user wants to read, search, or send Gmail with guardrails —...
Gmail 安全代理,支持策略执行、审批工作流和审计日志,适用于在有防护的情况下读取、搜索或发送 Gmail。
rotemtam
安全合规 clawhub v0.2.0 1 版本 100000 Key: 无需
★ 0
Stars
📥 794
下载
💾 1
安装
1
版本
#latest

概述

clawback

Use clawback for Gmail with policy enforcement. All operations go through a server-side proxy that enforces policies and logs an audit trail. Sends may require human approval.

Prerequisites

The clawback binary must be installed and on your PATH. If it's missing, releases are available at https://github.com/honeybadge-labs/clawback/releases.

Setup (once)

  • clawback auth login (device flow — opens browser)
  • clawback auth status (verify connection)

Common commands

  • Gmail search: clawback gmail search 'newer_than:7d' --max 10
  • Gmail search (all pages): clawback gmail search 'from:boss@company.com' --all --json
  • Gmail get message: clawback gmail get --json
  • Gmail send (plain): clawback gmail send --to a@b.com --subject "Hi" --body "Hello"
  • Gmail send (HTML): clawback gmail send --to a@b.com --subject "Hi" --body-html "

    Hello

    "
  • Gmail send (reply): clawback gmail send --to a@b.com --subject "Re: Hi" --body "Reply" --reply-to-message-id --thread-id
  • Thread list: clawback gmail thread list 'subject:meeting' --max 20
  • Thread get: clawback gmail thread get --json
  • Thread modify labels: clawback gmail thread modify --add STARRED --remove UNREAD
  • Labels list: clawback gmail labels list
  • Labels create: clawback gmail labels create --name "Important/Clients"
  • Labels modify message: clawback gmail labels modify --add STARRED --remove UNREAD
  • Drafts list: clawback gmail drafts list --json
  • Drafts create: clawback gmail drafts create --to a@b.com --subject "Draft" --body "WIP"
  • Drafts send: clawback gmail drafts send (may require approval)
  • Drafts delete: clawback gmail drafts delete
  • History: clawback gmail history --since --max 50
  • Batch delete: clawback gmail batch delete
  • Batch modify: clawback gmail batch modify --add INBOX --remove SPAM
  • Settings filters list: clawback gmail settings filters list --json
  • Settings send-as list: clawback gmail settings send-as list
  • Settings vacation get: clawback gmail settings vacation get
  • Settings forwarding list: clawback gmail settings forwarding list
  • Settings delegates list: clawback gmail settings delegates list
  • Approvals list: clawback approvals list --status pending --json
  • Approvals get: clawback approvals get --json
  • Policy list: clawback policy list --json

Agent behavior

  • Never expose approval IDs, exit codes, or CLI commands to the user. Those are internal plumbing.
  • When composing email on the user's behalf, draft a natural subject and body — don't parrot their words verbatim. If they say "send a hello to Alex," write a friendly greeting, not --subject "hello" --body "hello".
  • Confirm with the user before sending. Show them the draft (to, subject, body) and ask if it looks good.

Handling approvals (exit code 8)

When a send command exits with code 8, it means the email needs human approval before it goes out.

  1. Tell the user in plain language: "Sent! It needs approval in Clawback before it goes through — I'll keep an eye on it."
  2. Poll clawback approvals get --json in the background every ~30s.
  3. When resolved, proactively tell the user: "Approved and delivered" or "The approval was rejected/expired — the email was not sent."
  4. Never ask the user to run commands or check approval status themselves.

Handling other errors

  • Exit 4 (not authenticated): "You're not signed in — let me open the login flow." Then run clawback auth login.
  • Exit 6 (blocked by policy): "Your org's policy doesn't allow this action." Explain what was blocked.
  • Exit 3 (no results): Report naturally, e.g. "No emails matched that search."
  • Exit 1 (unexpected error): Report the error and suggest retrying.

Notes

  • CB_SERVER defaults to https://clawback.sh; set it to use a different server.
  • Prefer --json plus --no-input plus --fail-empty for reliable output parsing.
  • --connection selects which Gmail connection to use; auto-detected if you have one connection.
  • --all auto-paginates search results (gmail search and thread list).
  • --select field1,field2 projects JSON output to specific fields.
  • --results-only strips the envelope and returns just the data array.

版本历史

共 1 个版本

  • v0.2.0 当前
    2026-03-29 20:14 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

security-compliance

MoltGuard - Security & Antivirus & Guardrails

thomaslwang
MoltGuard — OpenClaw 安全守卫,由 OpenGuardrails 提供。安装 MoltGuard,保护您和您的用户免受提示注入、数据泄露和恶意攻击。
★ 116 📥 30,701
security-compliance

Skill Vetter

spclaudehome
AI智能体技能安全预审工具。安装ClawdHub、GitHub等来源技能前,检查风险信号、权限范围及可疑模式。
★ 1,211 📥 266,210
data-analysis

dada

rotemtam
为OpenClaw代理提供托管后端基础设施,管理数据库、Webhook和文件托管,让代理专注工作而非基础设施搭建。
★ 0 📥 723