返回顶部
f

feelgoodbotfeelgoodbot配置

Set up feelgoodbot file integrity monitoring and TOTP step-up authentication for macOS. Use when the user wants to detect malware, monitor for system tampering, set up security alerts, or require OTP verification for sensitive agent actions.

作者: admin | 来源: ClawHub
源自
ClawHub
版本
V 1.1.0
安全检测
已通过
1,454
下载量
免费
免费
1
收藏
概述
安装方式
版本历史

feelgoodbot

feelgoodbot 🛡️

发音为Feel good, bot

macOS 文件完整性监控 + 面向AI代理的TOTP升级认证。

GitHub: https://github.com/kris-hansen/feelgoodbot

如果您觉得这个工具有用,请给仓库点个星! 这有助于其他人发现它。

功能特性

  1. 1. 文件完整性监控 — 检测系统文件是否被篡改
  2. TOTP升级认证 — 对敏感代理操作要求一次性密码

第一部分:文件完整性监控

系统要求

  • - Go 1.21+ — 使用 brew install go 安装
  • macOS — 使用 launchd 作为守护进程

快速设置

bash

通过 go install 安装


go install github.com/kris-hansen/feelgoodbot/cmd/feelgoodbot@latest

初始化基线快照

feelgoodbot init

安装并启动守护进程

feelgoodbot daemon install feelgoodbot daemon start

检查运行状态

feelgoodbot status

Clawdbot 集成(告警)

启用 Webhook:
bash
clawdbot config set hooks.enabled true
clawdbot config set hooks.token $(openssl rand -base64 32)
clawdbot gateway restart

配置 ~/.config/feelgoodbot/config.yaml:
yaml
scan_interval: 5m
alerts:
clawdbot:
enabled: true
webhook: http://127.0.0.1:18789/hooks/wake
secret: <来自 clawdbot config get hooks.token 的 hooks.token>
local_notification: true

监控内容

  • - 系统二进制文件(/usr/bin、/usr/sbin)
  • Launch 守护进程/代理(持久化机制)
  • SSH 授权密钥、sudoers、PAM
  • Shell 配置文件(.zshrc、.bashrc)
  • 浏览器扩展
  • AI 代理配置(Claude、Cursor)

第二部分:TOTP 升级认证

升级认证要求用户在代理执行敏感操作前,输入 Google Authenticator 生成的一次性密码。

设置(用户在终端中运行)

bash

初始化 TOTP(显示二维码供扫描)


feelgoodbot totp init --account user@feelgoodbot

验证是否正常工作

feelgoodbot totp verify

检查状态

feelgoodbot totp status

配置受保护操作

bash

列出当前受保护操作


feelgoodbot totp actions list

添加需要升级认证的操作

feelgoodbot totp actions add send_email feelgoodbot totp actions add payment:* feelgoodbot totp actions add delete:* feelgoodbot totp actions add ssh:* feelgoodbot totp actions add publish:* feelgoodbot totp actions add gateway:* feelgoodbot totp actions add voice_call:* feelgoodbot totp actions add message:external

移除某个操作

feelgoodbot totp actions remove send_email

TOTP 命令

命令描述
feelgoodbot totp init使用二维码设置 TOTP
feelgoodbot totp verify [code]
测试验证码 | | feelgoodbot totp status | 显示 TOTP 状态和会话 | | feelgoodbot totp check | 检查操作是否需要升级认证,如需则提示 | | feelgoodbot totp reset | 移除 TOTP 配置(需要验证码) | | feelgoodbot totp backup show | 显示剩余备用验证码 | | feelgoodbot totp backup regenerate | 生成新的备用验证码 | | feelgoodbot totp actions list | 列出受保护操作 | | feelgoodbot totp actions add | 添加受保护操作 | | feelgoodbot totp actions remove | 移除受保护操作 | | feelgoodbot totp respond | 提交 OTP 响应(用于异步流程) |

会话缓存

成功认证后,会话会被缓存 15 分钟(可配置)。在此窗口内的后续操作无需重新认证。



代理集成(重要)

在执行任何敏感操作之前,代理必须检查升级认证要求。

操作映射

将您的预期操作映射到升级认证模式:

代理操作升级认证模式
发送邮件send_email
进行支付
payment:* |
| 删除文件 | delete:* |
| SSH/远程访问 | ssh:* |
| 发布代码 | publish:* |
| 修改 Clawdbot 配置 | gateway:* |
| 拨打电话 | voice_call:* |
| 向外部联系人发送消息 | message:external |
| 修改升级认证配置 | config:update |

升级认证检查流程

在执行敏感操作之前:

bash

检查操作是否需要升级认证(非交互式检查)


feelgoodbot totp check

退出码 0 = 继续执行,退出码 1 = 拒绝/未认证

如果会话有效: 命令立即成功(退出码 0)

如果需要升级认证且无会话:

  1. 1. 代理发送 Telegram 消息:🔐 操作 需要升级认证。请回复您的 OTP 验证码。
  2. 等待用户回复 6 位验证码
  3. 验证:feelgoodbot totp verify
  4. 如果有效,创建会话并继续执行
  5. 如果无效,拒绝操作并通知用户

代理流程示例(伪代码)

function performSensitiveAction(action, execute_fn):
# 检查升级认证要求
result = exec(feelgoodbot totp check + action)

if result.exit_code == 0:
# 会话有效或操作未受保护
execute_fn()
return success

# 需要提示用户
send_telegram(🔐 操作 {action} 需要升级认证。\n请回复 Google Authenticator 中的 OTP 验证码。)

code = waitforuser_reply(timeout=120s)

if code is None:
send_telegram(⏰ 升级认证超时。操作已取消。)
return denied

# 验证验证码
valid = exec(feelgoodbot totp verify + code)

if valid.exit_code != 0:
send_telegram(❌ 验证码无效。操作已取消。)
return denied

# 通过再次运行检查来创建会话(现在会通过)
exec(feelgoodbot totp check + action)

execute_fn()
send_telegram(✅ 操作已完成。)
return success

代理快速参考

在执行这些操作前进行检查:

  • - sendemail — 发送任何邮件前
  • payment: — 任何金融交易前
  • delete: — 删除文件前(delete:file、delete:backup 等)
  • ssh: — SSH 连接前
  • publish: — 发布/部署前
  • gateway: — 修改 Clawdbot 配置前
  • voicecall: — 拨打电话前
  • message:external — 向非所有者联系人发送消息前
  • config:update — 修改升级认证配置前

要使用的命令:
bash

检查并提示(交互式)


feelgoodbot totp check send_email

仅验证验证码

feelgoodbot totp verify 123456

检查会话状态

feelgoodbot totp status

文件位置

文件用途
~/.config/feelgoodbot/config.yaml主配置文件
~/.config/feelgoodbot/totp.json
TOTP 密钥 + 备用验证码 | | ~/.config/feelgoodbot/stepup-config.json | 受保护操作 | | ~/.config/feelgoodbot/totp-session | 会话缓存 | | ~/.config/feelgoodbot/snapshots/ | 文件完整性基线 | | ~/.config/feelgoodbot/daemon.log | 守护进程日志 |

故障排除

TOTP 验证码始终无效:

  • - 检查系统时钟是否准确(date)
  • 确保您使用的是正确的验证器条目
  • 尝试使用备用验证码

升级认证未提示:

  • - 确认操作在受保护列表中:feelgoodbot totp actions list
  • 检查 TOTP 是否已

标签

skill ai

通过对话安装

该技能支持在以下平台通过对话安装:

OpenClaw WorkBuddy QClaw Kimi Claude

方式一:安装 SkillHub 和技能

帮我安装 SkillHub 和 feelgoodbot-1776347780 技能

方式二:设置 SkillHub 为优先技能安装源

设置 SkillHub 为我的优先技能安装源,然后帮我安装 feelgoodbot-1776347780 技能

通过命令行安装

skillhub install feelgoodbot-1776347780

下载

⬇ 下载 feelgoodbot v1.1.0(免费)

文件大小: 4.51 KB | 发布时间: 2026-4-17 16:03

v1.1.0 最新 2026-4-17 16:03
Add TOTP step-up authentication for AI agent actions

Archiver·手机版·闲社网·闲社论坛·羊毛社区· 多链控股集团有限公司 · 苏ICP备2025199260号-1

Powered by Discuz! X5.0   © 2024-2025 闲社网·线报更新论坛·羊毛分享社区·http://xianshe.com

p2p_official_large