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
Copy file name to clipboardExpand all lines: design/credential-group-authorization.md
+13-39Lines changed: 13 additions & 39 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,7 +8,7 @@ Credential Groups collect external users' managed credentials and let workflows
8
8
9
9
The default is simple:
10
10
11
-
> An execution with a verified actor may list and use only that actor's credentials.
11
+
> An execution may list every non-secret credential reference, but it may use only the verified actor's credential.
12
12
13
13
Explicit resource-policy grants can expand a user, Access Control Group, workspace role, or deployed workflow to every credential in the Credential Group.
14
14
@@ -60,7 +60,7 @@ List Credentials
60
60
61
61
Its contract is:
62
62
63
-
> Return every credential that this execution is currently authorized to use.
63
+
> Return every active credential reference in the group; selecting a reference does not authorize its use.
64
64
65
65
Inputs may select the Credential Group, provider option, and pagination. Inputs never select identity or authorization scope:
66
66
@@ -83,28 +83,7 @@ The input does not contain:
83
83
84
84
## List authorization
85
85
86
-
The application operation loads the canonical Credential Group, verifies workspace access, and evaluates the current resource policy.
87
-
88
-
```text
89
-
matching credentials.list grant
90
-
-> list all active credentials in the group
91
-
92
-
otherwise verified actor with active enrollment
93
-
-> list only credentials for that exact enrollment
94
-
95
-
otherwise
96
-
-> fail
97
-
```
98
-
99
-
The internal result is a database query constraint, not persisted policy state:
100
-
101
-
```ts
102
-
typeCredentialListAuthorization=
103
-
| { enrollmentId:string }
104
-
| { grantId:string }
105
-
```
106
-
107
-
The exact enrollment constraint is applied to cursor validation and every page query. A credential ID returned from an earlier call is not an authorization capability.
86
+
The application operation loads the canonical Credential Group, verifies executor delegation, workspace binding, group scope, status, and entitlement, then returns a bounded page of all active credential references in the group. The result contains opaque IDs and account metadata but no token material, and a returned credential ID is never an authorization capability.
108
87
109
88
## Credential use authorization
110
89
@@ -131,7 +110,6 @@ Tokens and refresh tokens never appear in block output or execution logs. List r
131
110
The Credential Group resource policy can grant:
132
111
133
112
```text
134
-
credential_groups.credentials.list
135
113
credential_groups.credentials.use
136
114
```
137
115
@@ -144,10 +122,7 @@ Example workflow grant:
144
122
"type": "workflow",
145
123
"workflowId": "wf_support"
146
124
},
147
-
"actions": [
148
-
"credential_groups.credentials.list",
149
-
"credential_groups.credentials.use"
150
-
]
125
+
"actions": ["credential_groups.credentials.use"]
151
126
}
152
127
```
153
128
@@ -162,18 +137,17 @@ Example Access Control Group grant:
162
137
"type": "access_control_group",
163
138
"accessControlGroupId": "pg_support_admins"
164
139
},
165
-
"actions": [
166
-
"credential_groups.credentials.list",
167
-
"credential_groups.credentials.use"
168
-
]
140
+
"actions": ["credential_groups.credentials.use"]
169
141
}
170
142
```
171
143
172
144
Membership is evaluated at operation time. Removing a user from the Access Control Group revokes access immediately on the next protected operation.
173
145
174
146
## Execution behavior
175
147
176
-
| Execution | Result |
148
+
All executions that pass the list operation's workspace and group checks can see the same credential references. Using a selected credential resolves as follows:
149
+
150
+
| Execution | Credential use result |
177
151
| --- | --- |
178
152
| Manual actor without an explicit grant | Actor's enrollment only |
179
153
| Manual actor in a granted Access Control Group | All credentials |
@@ -184,7 +158,7 @@ Membership is evaluated at operation time. Removing a user from the Access Contr
184
158
| Actorless schedule without a workflow grant | Fail |
185
159
| Actor with no enrollment and no explicit grant | Fail |
186
160
187
-
There is no silent fallback from a requested all-credentials mode because the block has no caller-controlled access mode. It simply returns the set authorized for the current execution.
161
+
There is no silent fallback from a requested all-credentials mode because the block has no caller-controlled access mode. Authorization happens when the selected credential is assumed.
188
162
189
163
Manual testing exercises the actor path with the tester's credential. Full group-wide behavior is tested through a deployed execution, preferably against a staging Credential Group in a forked workspace.
190
164
@@ -197,7 +171,7 @@ Slack signature and installation verified
197
171
-> webhook Principal with (teamId, userId) subject
198
172
-> workflow execution
199
173
-> Credential Group enrollment resolution
200
-
-> actor-scopedcredentiallist/use
174
+
-> actor-scoped credential use
201
175
```
202
176
203
177
The Slack trigger subscription credential only receives events. It is not the external user's downstream credential.
@@ -208,7 +182,7 @@ Bot events and events without a verified human subject have no actor. They requi
208
182
209
183
Credential Group creation, options, invitations, enrollment lifecycle, and resource-policy changes remain control-plane operations requiring current workspace-admin authorization and audit.
210
184
211
-
Managing the policy does not automatically grant the administrator permission to list or use credentials. Data-plane access still requires actor ownership or an explicit grant.
185
+
Managing the policy does not automatically grant the administrator permission to use credentials. Data-plane credential use still requires actor ownership or an explicit grant.
212
186
213
187
## Current implementation delta
214
188
@@ -217,12 +191,12 @@ The branch:
217
191
- threads the original Principal into Credential Group executor delegation;
218
192
- removes caller-supplied email filtering from credential listing;
219
193
- resolves a verified Sim user to an exact active enrollment;
220
-
- filters list pagination by that enrollment;
194
+
-lists bounded non-secret references for every active credential in the group;
221
195
- rechecks the same enrollment when resolving managed OAuth tokens;
222
196
- fails actorless execution instead of substituting a billing or workflow owner.
223
197
- stores and evaluates generic allow-only resource policies;
224
198
- resolves user, workspace-role, Access Control Group, external-identity, and deployed-workflow subjects;
225
-
- grants whole-group list and use access when an explicit policy matches;
199
+
- grants whole-group credential use when an explicit policy matches;
226
200
- binds Slack's verified provider subject to an active enrollment;
227
201
- exposes an audited, optimistic-concurrency admin management API and structured Access tab.
Copy file name to clipboardExpand all lines: design/resource-policies.md
+4-10Lines changed: 4 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -100,21 +100,15 @@ Policies store stable subject references, never session IDs, API keys, delegatio
100
100
"type":"workflow",
101
101
"workflowId":"wf_support"
102
102
},
103
-
"actions": [
104
-
"credential_groups.credentials.list",
105
-
"credential_groups.credentials.use"
106
-
]
103
+
"actions": ["credential_groups.credentials.use"]
107
104
},
108
105
{
109
106
"id":"support-admins",
110
107
"subject": {
111
108
"type":"access_control_group",
112
109
"accessControlGroupId":"pg_support_admins"
113
110
},
114
-
"actions": [
115
-
"credential_groups.credentials.list",
116
-
"credential_groups.credentials.use"
117
-
]
111
+
"actions": ["credential_groups.credentials.use"]
118
112
}
119
113
]
120
114
}
@@ -261,7 +255,7 @@ Routes, blocks, tools, Copilot adapters, and executor handlers do not query poli
261
255
262
256
## Current implementation
263
257
264
-
The generic policy document, strict parser, optimistic repository, subject evaluator, and subject-management validation are implemented. Credential Groups are the first resource type and currently expose one managed permission in the UI: list and use every credential in the group.
258
+
The generic policy document, strict parser, optimistic repository, subject evaluator, and subject-management validation are implemented. Credential Groups are the first resource type and currently expose one managed permission in the UI: use every credential in the group.
265
259
266
260
Future resource types extend the exact resource/action registry and call the same evaluator from their application operations. Knowledge Base/table enforcement and log-provenance redaction remain separate follow-up work.
267
261
@@ -288,7 +282,7 @@ Provenance and viewer-specific log shielding are a later phase. They use the sam
288
282
1. Add strict policy types, validation, storage, and evaluator.
289
283
2. Add admin policy read/write application operations and audit.
290
284
3. Add deployed-workflow authority to execution identity.
291
-
4. Integrate Credential Group list and use authorization.
285
+
4. Integrate Credential Group credential-use authorization.
292
286
5. Add user, workspace-role, and Access Control Group subject resolution.
293
287
6. Add policy management UI on Credential Groups.
294
288
7. Extend the same evaluator to Knowledge Bases and tables.
0 commit comments