Skip to content

Prove that identity named in a tool's input never becomes ctx.caller - #58

Merged
shuv1337 merged 1 commit into
v2from
shuv/caller-forgery-e2e-20261023
Oct 23, 2026
Merged

shuv1337 merged 1 commit into
v2from
shuv/caller-forgery-e2e-20261023

Conversation

@shuv1337

Copy link
Copy Markdown
Owner

Acceptance evidence for #15 (identity). This only adds assertions; no product code changes.

#15 requires that "substituting member, organization, or profile identifiers cannot impersonate another principal". The host sets ctx.caller and never reads it from input, but no scenario showed that.

Change

caller-identity.spec.ts (scenario callerIdentity): the test app gains a claim query whose input carries a caller and an approvedBy. Alice (a member) calls it with Bob's verified caller, a foreign organizationId, the owner's email, and a forged human approver. The app still sees exactly Alice's verified caller and no approver.

The rest of #15, already covered by existing scenarios (run on the merged tree today)

#15 item Scenario Result
Two principals invoke the same tool with correct, distinct identity caller-identity.spec.ts: "apps see each MCP user, the dashboard person and workflow work as distinct verified callers" passed
Substituted identifiers can't impersonate same scenario, with the new claim assertions passed
Removed membership fails closed member-api-keys.spec.ts: "Organization membership removal permanently revokes pinned API keys"; warm-request-auth.spec.ts: "Dashboard requests refuse signed-out sessions and removed members immediately" passed
Hidden or unselected tools fail closed; a new capability isn't silently granted mcp-grant-restrictions.spec.ts: "MCP grants retain exact selections through deploys and live narrowing" (a tool added by a later deploy, later, and a hidden app are both refused under the existing selection) passed

Self-host: 4 passed. bun run check passes.

caller-identity.spec.ts
member-api-keys.spec.ts
warm-request-auth.spec.ts
mcp-grant-restrictions.spec.ts

#15 asks that substituting member, organization or approver identifiers cannot
impersonate another principal. The caller scenario now has a tool whose input
carries a forged caller (another member's subject, a foreign organization) and a
forged approver. The member's call still sees their own verified caller and no
approver.
@shuv1337
shuv1337 merged commit cbaeeb9 into v2 Oct 23, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant