You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Server edition: admins cannot revoke a tenant's agent token, and un-sharing a server does not revoke live grants #1179
Two follow-ups to the #1168 fix, which made agent-token names owner-scoped.
1. The personal admin surface can no longer manage a user's token by name (accepted regression)
DELETE/POST /api/v1/tokens/{name} (behind requireAdminAuth) now operates only in the ownerless namespace, so in a server-edition deployment an admin cannot revoke, delete or regenerate a user's token by name. Those tokens still authenticate, still list, and are still fully manageable by their owner through /api/v1/user/tokens.
This was a deliberate trade — the alternative was keeping a global name bucket, which is the oracle #1168 existed to close — but it leaves the admin without a revocation path for a tenant's credential, which is the one thing an admin most needs during an incident.
Needed: cross-tenant agent-token administration on the admin surface — list every tenant's tokens with their owner, and revoke by (owner, name) or by token id. This belongs in admin_handlers as its own feature.
2. Un-sharing a server does not revoke live token grants
resolveTokenServerScope snapshots the entitled server set at mint time and nothing re-validates it at use time. So a token keeps reaching a server after the admin clears that server's shared flag. The #1168 follow-up re-runs the check on regenerate (narrowing rather than rejecting, so the repairing action is not punished), but there is no revalidation on the hot path and no backfill for tokens minted before that landed.
Decide: whether entitlement should be re-checked per request (correct, costs a lookup on every call) or on a timer, and whether existing over-broad grants need a one-time admin-facing report. Tokens minted with a literal "*" before the fix are the population to look at — though note such a token could only have been minted by a tenant who already had the ability, so this is cleanup rather than an open escalation.
Both found during the #1168 / #1166 work and deliberately not bundled.
Activity