GHSA-647h-p824-99w7: @grackle ai/mcp @grackle-ai/mcp Has A Workspace Authorization Vulnerability
HIGHGHSA-647h-p824-99w7 is a HIGH @grackle-ai/mcp has a workspace authorization vulnerability (CWE-284: Improper Access Control) affecting @grackle ai/mcp libraries in the npm ecosystem. The issue involves @grackle-ai/mcp has a workspace authorization bypass in its knowledge_search mcp tool. Remediation is available by upgrading affected packages to version 0.70.2.
GHSA-647h-p824-99w7 at a Glance
How to Fix GHSA-647h-p824-99w7
To remediate this vulnerability, upgrade all affected @grackle ai/mcp dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
npm install @grackle-ai/mcp@0.70.2
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
npm ls @grackle-ai/mcp
How to Check if You Are Affected
To determine whether your Node.js application is affected by GHSA-647h-p824-99w7, inspect your project dependencies using npm:
npm ls @grackle-ai/mcp
Analyze the terminal output to locate any version of @grackle ai/mcp in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.70.2), your application is affected.
Note: The npm ls @grackle-ai/mcp command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-284: Improper Access Control, where the product does not restrict or incorrectly restricts access to a resource from an unauthorized actor. In @grackle ai/mcp, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
GHSA-647h-p824-99w7 Affected @grackle ai/mcp Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
@grackle-ai/mcp
|
npm |
< 0.70.2
|
0.70.2
|
References
Frequently Asked Questions
What is GHSA-647h-p824-99w7?
Which @grackle ai/mcp versions are affected?
What version fixes GHSA-647h-p824-99w7?
Is @grackle-ai/mcp affected?
What CWE is associated with GHSA-647h-p824-99w7?
How can I check npm dependencies for GHSA-647h-p824-99w7?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-647h-p824-99w7",
"modified" : "2026-03-25T17:23:11Z",
"published" : "2026-03-25T17:23:11Z",
"aliases" : [ ],
"summary" : "@grackle-ai/mcp has a workspace authorization bypass in its knowledge_search MCP tool",
"details" : "### Impact\n\nThe `knowledge_search` and `knowledge_get_node` MCP tools are included in `SCOPED_TOOLS` (visible to scoped agents) but their handlers do not receive `authContext` and do not enforce workspace scoping. A scoped agent in Workspace A can supply an arbitrary `workspaceId` parameter to search or retrieve knowledge graph nodes from Workspace B, bypassing workspace isolation boundaries.\n\nThis is a **cross-workspace data leakage** vulnerability affecting any deployment where multiple workspaces contain sensitive knowledge graph data and scoped agents are used.\n\n**Affected code:**\n- `packages/mcp/src/tools/knowledge.ts:146-169` (knowledge_search handler)\n- `packages/mcp/src/tools/knowledge.ts:244-283` (knowledge_get_node handler)\n- `packages/mcp/src/tool-scoping.ts:11` (both tools listed in SCOPED_TOOLS)\n\n**Contrast with correct implementation:** `knowledge_create_node` (same file, lines 334-357) properly receives `authContext` and overrides the user-supplied `workspaceId` for scoped callers.\n\n### Design Note\n\nCross-workspace knowledge sharing is a legitimate future feature — agents working across different repos may need to collaborate and share knowledge. However, this access should be **opt-in with explicit grants**, not an implicit bypass. The immediate fix locks scoped agents to their own workspace. A future design could introduce:\n- Workspace-level \"share knowledge with\" settings\n- A `cross_workspace` scope on scoped tokens\n- Explicit `workspaceIds` (plural) in the auth context\n\n### Patches\n\n**Fix:** Add `authContext` parameter to `knowledge_search` and `knowledge_get_node` handlers and enforce workspace scoping, matching the pattern in `knowledge_create_node`:\n```typescript\nconst resolvedWorkspaceId =\n authContext?.type === \"scoped\"\n ? authContext.workspaceId ?? \"\"\n : workspaceId ?? \"\";\n```\n\nWhen cross-workspace collaboration is designed, this check can be relaxed intentionally with proper access controls.\n\n### Workarounds\n\nDo not use scoped agent tokens in multi-workspace deployments until patched. Alternatively, remove `knowledge_search` and `knowledge_get_node` from the `SCOPED_TOOLS` set in `tool-scoping.ts`.\n\n### References\n\n- CWE-284: Improper Access Control\n- File: `packages/mcp/src/tools/knowledge.ts`\n- File: `packages/mcp/src/tool-scoping.ts`",
"severity" : [ {
"type" : "CVSS_V4",
"score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:N/SC:L/SI:L/SA:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "npm",
"name" : "@grackle-ai/mcp"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "0.70.2"
} ]
} ],
"database_specific" : {
"last_known_affected_version_range" : "<= 0.70.1"
}
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/nick-pape/grackle/security/advisories/GHSA-647h-p824-99w7"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/nick-pape/grackle"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-284" ],
"severity" : "HIGH",
"github_reviewed" : true,
"github_reviewed_at" : "2026-03-25T17:23:11Z",
"nvd_published_at" : null
}
}