Problem/Motivation

The module computes a good deal about its own state that an operator or a governed agent cannot reach over MCP. Governance readiness is an HTTP route. Effective result, response-size and rate limits are resolved per profile and never shown. Audit counts, denial reasons and webhook health feed the dashboard only. Role assertions, install verification and urgent conditions are Drush commands. An agent whose write was queued for approval cannot see that its request is still pending.

The existing mcp_sentinel_security_policy tool returns allow flags, entity rules and redaction, and no budgets or limits.

Proposed resolution

Add read-only tools over services that already exist. Each extends the governed tool base, needs the context permission and the read scope, is bounded, and returns no secret, credential, IP address or other personal data.

  • mcp_sentinel_governance_status: McpGovernanceReadiness contract status and the reason code when not ready.
  • mcp_sentinel_effective_limits: for the acting profile, the effective result cap, response-size cap, rate limit and page budget from McpReadBudgetResolver.
  • mcp_sentinel_audit_metrics: McpMetrics counts for a fixed set of windows: totals, allowed against denied, denial reasons, operation mix and webhook health. Top agents are left out unless they can be shown without identifying a person.
  • mcp_sentinel_role_audit: McpRoleAssertions violations, names of roles and permissions only. Needs the administer permission.
  • mcp_sentinel_urgent_conditions: McpUrgentConditions and McpAnomalyDetector findings as codes and counts.
  • mcp_sentinel_my_approvals in the approval submodule: the acting account's own pending and recently decided requests: id, operation, target name, state and times. Never the payload, and never another account's requests.

Not tools, by design: approve or deny, break-glass grant, agent provisioning or reconcile, setup and teardown, audit purge, lock clearing, webhook replay, and install verification (it writes probe entities).

Remaining tasks

  • Kernel tests per tool: governed success, anonymous denial, governance not ready where the tool can still answer, no sensitive value in output, bounded output, own-requests-only for approvals.
  • Add the new ids to the optional-tools list so setup and the scope resolver know them. They must not become required tools.
  • Bridge configuration examples, API.md, README, CHANGELOG.

API changes

New optional tools. No change to existing tools.

Comments

jmcerda created an issue. See original summary.

jmcerda’s picture

Status: Active » Fixed

Fixed in 2.23.0. Read-only tools: governance_status, effective_limits, audit_metrics, role_audit, urgent_conditions, and my_approvals. Optional; an unregistered compiled plugin does not make the contract not-ready.

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.