Add structured permission failure reports to gated Gitea MCP tools #142

Closed
opened 2026-07-05 01:51:39 -05:00 by jcwalker3 · 0 comments
Owner

Purpose

Make every gated-tool denial return actionable structured information instead of only a short reason string.

Acceptance criteria

  • Permission failures include:
    • requested operation
    • missing permission
    • active profile
    • active identity if resolved
    • required permission
    • available allowed operations
    • whether matching configured profile exists, if safely knowable
    • whether runtime switching is supported
    • whether a different namespace/session is required
    • exact safe next action
  • Applies to issue comments, PR review, PR merge, issue close, branch push/create, repo commit, and other gated operations where applicable.
  • Existing fail-closed behavior is preserved.
  • No permission broadening.
  • No secrets or service URLs exposed.
  • Tests cover missing gitea.issue.comment, author attempting review, author attempting merge, reviewer attempting authoring if forbidden, and unknown/missing profile cases.

Related to #139.

## Purpose Make every gated-tool denial return actionable structured information instead of only a short reason string. ## Acceptance criteria * Permission failures include: * requested operation * missing permission * active profile * active identity if resolved * required permission * available allowed operations * whether matching configured profile exists, if safely knowable * whether runtime switching is supported * whether a different namespace/session is required * exact safe next action * Applies to issue comments, PR review, PR merge, issue close, branch push/create, repo commit, and other gated operations where applicable. * Existing fail-closed behavior is preserved. * No permission broadening. * No secrets or service URLs exposed. * Tests cover missing `gitea.issue.comment`, author attempting review, author attempting merge, reviewer attempting authoring if forbidden, and unknown/missing profile cases. Related to #139.
jcwalker3 added the status:in-progress label 2026-07-05 02:29:32 -05:00
sysadmin removed the status:in-progress label 2026-07-05 10:24:34 -05:00
Sign in to join this conversation.
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Scaled-Tech-Consulting/Gitea-Tools#142