fix(qqbot): require auth for bot-approve

This commit is contained in:
Vincent Koc
2026-04-23 10:43:22 -07:00
parent 604ce85ce0
commit 9694a4501f
3 changed files with 10 additions and 0 deletions

View File

@@ -8,6 +8,7 @@ Docs: https://docs.openclaw.ai
### Fixes
- QQBot/security: require framework auth for `/bot-approve` so unauthorized QQ senders cannot change exec approval settings through the unauthenticated pre-dispatch slash-command path. (#70706) Thanks @vincentkoc.
- MCP/tools: stop the ACPX OpenClaw tools bridge from listing or invoking owner-only tools such as `cron`, closing a privilege-escalation path for non-owner MCP callers. (#70698) Thanks @vincentkoc.
- Feishu/onboarding: load Feishu setup surfaces through a setup-only barrel so first-run setup no longer imports Feishu's Lark SDK before bundled runtime deps are staged. (#70339) Thanks @andrejtr.
- WhatsApp/security: keep contact/vCard/location structured-object free text out of the inline message body and render it through fenced untrusted metadata JSON, limiting hidden prompt-injection payloads in names, phone fields, and location labels/comments.

View File

@@ -0,0 +1,8 @@
import { describe, expect, it } from "vitest";
import { getFrameworkCommands } from "./slash-commands-impl.js";
describe("QQBot framework slash commands", () => {
it("routes bot-approve through the auth-gated framework registry", () => {
expect(getFrameworkCommands().map((command) => command.name)).toContain("bot-approve");
});
});

View File

@@ -746,6 +746,7 @@ export function registerApproveRuntimeGetter(
registerCommand({
name: "bot-approve",
description: "管理命令执行审批配置",
requireAuth: true,
usage: [
`/bot-approve 查看操作指引`,
`/bot-approve on 开启审批(白名单模式,推荐)`,