feat(auth): bind workflow authority to runtime principals - #7351
feat(auth): bind workflow authority to runtime principals#7351TheodoreSpeaks wants to merge 4 commits into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
Greptile SummaryThe PR binds canonical workflow execution metadata to runtime principals and carries that authority through internal executor transport, child execution, snapshots, and resumptions.
Confidence Score: 5/5The PR appears safe to merge because no blocking failure remains within the eligible follow-up scope. No blocking failure remains.
|
| Filename | Overview |
|---|---|
| apps/sim/lib/api/server/routes/internal-json-route.ts | Refactors internal route authentication to preserve the signed runtime principal while exposing executor transport and canonical execution workspace metadata. |
| apps/sim/lib/auth/internal-delegation.ts | Replaces receiver-derived delegated-principal binding with validation and admission of canonical workflow execution principals. |
| apps/sim/executor/handlers/credential-group/credential-group-handler.ts | Uses execution-bound runtime principals and asserted execution workspace context for credential-group operations. |
| apps/sim/executor/execution/snapshot.ts | Carries runtime-principal authority through execution snapshot and restoration flows. |
| packages/auth/src/principal.ts | Defines and validates the canonical principal and workflow execution metadata used across runtime boundaries. |
Sequence Diagram
sequenceDiagram
participant Entry as Workflow Entry Point
participant Exec as Executor
participant JWT as Executor JWT
participant Route as Internal Route
participant Auth as Authorization
participant UseCase as Application Use Case
Entry->>Exec: Create runtime principal with execution metadata
Exec->>JWT: Sign canonical runtime principal
JWT->>Route: Bearer token
Route->>Route: Verify token and identify executor transport
Route->>Auth: Authorize runtime principal and operation
Auth->>UseCase: Principal plus canonical execution workspace
UseCase-->>Route: Authorized result
Reviews (5): Last reviewed commit: "fix(auth): preserve runtime authority ac..." | Re-trigger Greptile
There was a problem hiding this comment.
All reported issues were addressed across 183 files
Heads up: you’re close to your included review allowance. Set a flex budget so reviews don’t pause.
Re-trigger cubic
08e5585 to
6415e24
Compare
|
@cubic-dev-ai review this PR |
@TheodoreSpeaks I have started the AI code review. It will take a few minutes to complete. |
There was a problem hiding this comment.
All reported issues were addressed across 226 files
Note: This PR contains a large number of files. cubic selects up to 200 of the highest-priority eligible files for this review, so some files may not have been reviewed.
Re-trigger cubic
6415e24 to
59e43ed
Compare
|
@cubic-dev-ai review this PR |
@TheodoreSpeaks I have started the AI code review. It will take a few minutes to complete. |
There was a problem hiding this comment.
No issues found across 226 files
Confidence score: 5/5
- Automated review surfaced no issues in the provided summaries.
- No files require special attention.
Note: This PR contains a large number of files. cubic selects up to 200 of the highest-priority eligible files for this review, so some files may not have been reviewed.
Re-trigger cubic
Summary
Type of Change
Testing
Checklist