diff --git a/CHANGELOG.md b/CHANGELOG.md index 597259e11c..dc052cf433 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -24,6 +24,7 @@ Docs: https://docs.openclaw.ai ### Fixes - Auto-reply: avoid referencing workspace files in /new greeting prompt. (#5706) Thanks @bravostation. +- Tools: treat `"*"` tool allowlist entries as valid to avoid spurious unknown-entry warnings. - Process: resolve Windows `spawn()` failures for npm-family CLIs by appending `.cmd` when needed. (#5815) Thanks @thejhinvirtuoso. - Discord: resolve PluralKit proxied senders for allowlists and labels. (#5838) Thanks @thewilloftheshadow. - Agents: ensure OpenRouter attribution headers apply in the embedded runner. diff --git a/src/agents/tool-policy.plugin-only-allowlist.test.ts b/src/agents/tool-policy.plugin-only-allowlist.test.ts index d0d19b7d4d..2ade184bb3 100644 --- a/src/agents/tool-policy.plugin-only-allowlist.test.ts +++ b/src/agents/tool-policy.plugin-only-allowlist.test.ts @@ -20,6 +20,12 @@ describe("stripPluginOnlyAllowlist", () => { expect(policy.unknownAllowlist).toEqual([]); }); + it('keeps allowlist when it uses "*"', () => { + const policy = stripPluginOnlyAllowlist({ allow: ["*"] }, pluginGroups, coreTools); + expect(policy.policy?.allow).toEqual(["*"]); + expect(policy.unknownAllowlist).toEqual([]); + }); + it("keeps allowlist when it mixes plugin and core entries", () => { const policy = stripPluginOnlyAllowlist( { allow: ["lobster", "read"] }, diff --git a/src/agents/tool-policy.ts b/src/agents/tool-policy.ts index 293e6d5e9d..a14cb73ac0 100644 --- a/src/agents/tool-policy.ts +++ b/src/agents/tool-policy.ts @@ -215,6 +215,10 @@ export function stripPluginOnlyAllowlist( const unknownAllowlist: string[] = []; let hasCoreEntry = false; for (const entry of normalized) { + if (entry === "*") { + hasCoreEntry = true; + continue; + } const isPluginEntry = entry === "group:plugins" || pluginIds.has(entry) || pluginTools.has(entry); const expanded = expandToolGroups([entry]);