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
Commit 774d24c
Browse filesBrowse the repository at this point in the historyBrowse files
feat(identity): refuse requests of suspended tenants on every request (#797)
The ingress cookie check now reads the tenant's state with the membership
role, in the same tenant transaction. A suspended or deleted tenant gets
403 tenant_suspended without a token for every service but identity;
identity's own token carries the new optional tenant_suspended claim,
which service-kit's Requirement::Tenant refuses with 403
tenant_suspended, separate from permission_denied. The token exchange
refuses that claim, and run delegations refuse to start or exchange
while their tenant is suspended; OnBehalf and RunDelegations pass the
code through to the user.
The current session lists each tenant's state, so the app can explain
the suspension. Reading the session, switching tenants, logging out,
preferences and identity's platform endpoints (resuming the tenant)
keep working. A membership whose tenant has no row reads as active.
Closes#777
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01EnmrdxG91NgAkjWi1afk7W
Copy file name to clipboardExpand all lines: api/openapi.json
+6-1Lines changed: 6 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -2783,6 +2783,10 @@
2783
2783
"$ref": "#/components/schemas/MemberRole",
2784
2784
"description": "The user's role in the tenant."
2785
2785
},
2786
+
"state": {
2787
+
"$ref": "#/components/schemas/TenantState",
2788
+
"description": "The tenant's state (Laysi/trustiot-v2#777): while it is `suspended` or `deleted`, the\nsession reaches this service only, and every other request in the tenant answers 403\n`tenant_suspended`. A tenant without a record is `active`, as the cookie check reads it."
0 commit comments