fix: authorize native user portal tenant onboarding
Assistant: codex Assistant-Model: gpt-6-astra Assistant-Session: 01a07ff8-19d0-7820-b4d0-1353833cb7fc
This commit is contained in:
parent
88b354377c
commit
dd8dd51743
3 changed files with 378 additions and 4 deletions
|
|
@ -274,5 +274,269 @@
|
|||
"context": {}
|
||||
},
|
||||
"expect": {"effect": "deny", "reason": "unknown_action"}
|
||||
},
|
||||
{
|
||||
"id": "fixture:tenant-engine-portal-create",
|
||||
"request": {
|
||||
"id": "check:portal-create",
|
||||
"tenant": "tenant:trial:demo-company",
|
||||
"subject": {
|
||||
"id": "user-engine",
|
||||
"type": "service"
|
||||
},
|
||||
"action": "tenant.create",
|
||||
"resource": {
|
||||
"id": "tenant:trial:demo-company",
|
||||
"type": "tenant",
|
||||
"system": "tenant-engine"
|
||||
},
|
||||
"context": {}
|
||||
},
|
||||
"expect": {
|
||||
"effect": "allow",
|
||||
"reason": "write_api_policy_matched"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "fixture:tenant-engine-portal-read",
|
||||
"request": {
|
||||
"id": "check:portal-read",
|
||||
"tenant": "tenant:trial:demo-company",
|
||||
"subject": {
|
||||
"id": "user-engine",
|
||||
"type": "service"
|
||||
},
|
||||
"action": "tenant.read",
|
||||
"resource": {
|
||||
"id": "tenant:trial:demo-company",
|
||||
"type": "tenant",
|
||||
"system": "tenant-engine"
|
||||
},
|
||||
"context": {}
|
||||
},
|
||||
"expect": {
|
||||
"effect": "allow",
|
||||
"reason": "write_api_policy_matched"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "fixture:tenant-engine-portal-platform-create",
|
||||
"request": {
|
||||
"id": "check:portal-platform-create",
|
||||
"tenant": "tenant:platform",
|
||||
"subject": {
|
||||
"id": "user-engine",
|
||||
"type": "service"
|
||||
},
|
||||
"action": "tenant.create",
|
||||
"resource": {
|
||||
"id": "tenant:platform",
|
||||
"type": "tenant",
|
||||
"system": "tenant-engine"
|
||||
},
|
||||
"context": {}
|
||||
},
|
||||
"expect": {
|
||||
"effect": "deny",
|
||||
"reason": "action_not_granted"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "fixture:tenant-engine-portal-platform-read",
|
||||
"request": {
|
||||
"id": "check:portal-platform-read",
|
||||
"tenant": "tenant:platform",
|
||||
"subject": {
|
||||
"id": "user-engine",
|
||||
"type": "service"
|
||||
},
|
||||
"action": "tenant.read",
|
||||
"resource": {
|
||||
"id": "tenant:platform",
|
||||
"type": "tenant",
|
||||
"system": "tenant-engine"
|
||||
},
|
||||
"context": {}
|
||||
},
|
||||
"expect": {
|
||||
"effect": "deny",
|
||||
"reason": "action_not_granted"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "fixture:tenant-engine-portal-role-grant",
|
||||
"request": {
|
||||
"id": "check:portal-role-grant",
|
||||
"tenant": "tenant:trial:demo-company",
|
||||
"subject": {
|
||||
"id": "user-engine",
|
||||
"type": "service"
|
||||
},
|
||||
"action": "tenant.role.grant",
|
||||
"resource": {
|
||||
"id": "tenant:trial:demo-company",
|
||||
"type": "role-grant",
|
||||
"system": "tenant-engine"
|
||||
},
|
||||
"context": {}
|
||||
},
|
||||
"expect": {
|
||||
"effect": "deny",
|
||||
"reason": "action_not_granted"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "fixture:tenant-engine-portal-role-revoke",
|
||||
"request": {
|
||||
"id": "check:portal-role-revoke",
|
||||
"tenant": "tenant:trial:demo-company",
|
||||
"subject": {
|
||||
"id": "user-engine",
|
||||
"type": "service"
|
||||
},
|
||||
"action": "tenant.role.revoke",
|
||||
"resource": {
|
||||
"id": "tenant:trial:demo-company",
|
||||
"type": "role-grant",
|
||||
"system": "tenant-engine"
|
||||
},
|
||||
"context": {}
|
||||
},
|
||||
"expect": {
|
||||
"effect": "deny",
|
||||
"reason": "action_not_granted"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "fixture:tenant-engine-portal-plan-assign",
|
||||
"request": {
|
||||
"id": "check:portal-plan-assign",
|
||||
"tenant": "tenant:trial:demo-company",
|
||||
"subject": {
|
||||
"id": "user-engine",
|
||||
"type": "service"
|
||||
},
|
||||
"action": "tenant.plan.assign",
|
||||
"resource": {
|
||||
"id": "tenant:trial:demo-company",
|
||||
"type": "plan-assignment",
|
||||
"system": "tenant-engine"
|
||||
},
|
||||
"context": {}
|
||||
},
|
||||
"expect": {
|
||||
"effect": "deny",
|
||||
"reason": "action_not_granted"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "fixture:tenant-engine-portal-update",
|
||||
"request": {
|
||||
"id": "check:portal-update",
|
||||
"tenant": "tenant:trial:demo-company",
|
||||
"subject": {
|
||||
"id": "user-engine",
|
||||
"type": "service"
|
||||
},
|
||||
"action": "tenant.update",
|
||||
"resource": {
|
||||
"id": "tenant:trial:demo-company",
|
||||
"type": "tenant",
|
||||
"system": "tenant-engine"
|
||||
},
|
||||
"context": {}
|
||||
},
|
||||
"expect": {
|
||||
"effect": "deny",
|
||||
"reason": "action_not_granted"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "fixture:tenant-engine-portal-retire",
|
||||
"request": {
|
||||
"id": "check:portal-retire",
|
||||
"tenant": "tenant:trial:demo-company",
|
||||
"subject": {
|
||||
"id": "user-engine",
|
||||
"type": "service"
|
||||
},
|
||||
"action": "tenant.retire",
|
||||
"resource": {
|
||||
"id": "tenant:trial:demo-company",
|
||||
"type": "tenant",
|
||||
"system": "tenant-engine"
|
||||
},
|
||||
"context": {}
|
||||
},
|
||||
"expect": {
|
||||
"effect": "deny",
|
||||
"reason": "action_not_granted"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "fixture:tenant-engine-portal-reactivate",
|
||||
"request": {
|
||||
"id": "check:portal-reactivate",
|
||||
"tenant": "tenant:trial:demo-company",
|
||||
"subject": {
|
||||
"id": "user-engine",
|
||||
"type": "service"
|
||||
},
|
||||
"action": "tenant.reactivate",
|
||||
"resource": {
|
||||
"id": "tenant:trial:demo-company",
|
||||
"type": "tenant",
|
||||
"system": "tenant-engine"
|
||||
},
|
||||
"context": {}
|
||||
},
|
||||
"expect": {
|
||||
"effect": "deny",
|
||||
"reason": "action_not_granted"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "fixture:tenant-engine-portal-guardrail-read",
|
||||
"request": {
|
||||
"id": "check:portal-guardrail-read",
|
||||
"tenant": "tenant:trial:demo-company",
|
||||
"subject": {
|
||||
"id": "user-engine",
|
||||
"type": "service"
|
||||
},
|
||||
"action": "tenant.guardrail.read",
|
||||
"resource": {
|
||||
"id": "tenant:trial:demo-company",
|
||||
"type": "guardrail",
|
||||
"system": "tenant-engine"
|
||||
},
|
||||
"context": {}
|
||||
},
|
||||
"expect": {
|
||||
"effect": "deny",
|
||||
"reason": "action_not_granted"
|
||||
}
|
||||
},
|
||||
{
|
||||
"id": "fixture:tenant-engine-portal-guardrail-set",
|
||||
"request": {
|
||||
"id": "check:portal-guardrail-set",
|
||||
"tenant": "tenant:trial:demo-company",
|
||||
"subject": {
|
||||
"id": "user-engine",
|
||||
"type": "service"
|
||||
},
|
||||
"action": "tenant.guardrail.set",
|
||||
"resource": {
|
||||
"id": "tenant:trial:demo-company",
|
||||
"type": "guardrail",
|
||||
"system": "tenant-engine"
|
||||
},
|
||||
"context": {}
|
||||
},
|
||||
"expect": {
|
||||
"effect": "deny",
|
||||
"reason": "action_not_granted"
|
||||
}
|
||||
}
|
||||
]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue