Title: fix(logs): remove the client log-persistence route that let a run's actor rewrite its log and cost by waleedlatif1 · Pull Request #9183 · simstudioai/sim · GitHub
Open Graph Title: fix(logs): remove the client log-persistence route that let a run's actor rewrite its log and cost by waleedlatif1 · Pull Request #9183 · simstudioai/sim
X Title: fix(logs): remove the client log-persistence route that let a run's actor rewrite its log and cost by waleedlatif1 · Pull Request #9183 · simstudioai/sim
Description: Summary Remove POST /api/workflows/[id]/log. It let whoever started a run re-complete that run with a client-supplied result: overwrite the status, output, and trace spans of an already finished log, and record client-controlled cost into the payer's usage ledger. The ledger only adds increments, so this could inflate charges and burn through the workspace's usage limit The route was gated by validateWorkflowAccess(..., false), which only checks read. Read-only members can run deployed workflows, so they could reach it too. Bumping it to write would still leave the cost and log forgery open to every write member, so the route goes Its only caller was debug mode's persistLogs, which has no UI entry point. It also sent a freshly generated execution ID, so the route answered 404 and the client swallowed the error. Nothing has been persisted through this route, so removing it changes no behaviour Drop the contract and schemas, the client persistLogs path (the debug handlers are now synchronous), and the deleted route's entries from the explicit-any, source-conventions, and unused-exports baselines No other callers in this repo (SDKs, CLI, docs, realtime, desktop) or in the copilot repo. No other route feeds request-supplied trace spans or cost into run completion. The remaining validateWorkflowAccess(..., false) callers are all read-only GETs Type of Change Bug fix Testing use-workflow-execution.test.tsx, middleware.test.ts (15 passing) bun run lint, block-registry check, generators (no drift), check:api-validation:strict, check:unused-exports, check:explicit-any, check:source-conventions, check:test-patterns, check:boundaries Full check:audits, type-check, and suite left to CI Checklist Code follows project style guidelines Self-reviewed my changes Tests added/updated and passing (new tests pass the test-audit authoring gate) No new warnings introduced I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)
Open Graph Description: Summary Remove POST /api/workflows/[id]/log. It let whoever started a run re-complete that run with a client-supplied result: overwrite the status, output, and trace spans of an already finished l...
X Description: Summary Remove POST /api/workflows/[id]/log. It let whoever started a run re-complete that run with a client-supplied result: overwrite the status, output, and trace spans of an already finished l...
Opengraph URL: https://github.com/simstudioai/sim/pull/9183
X: @github
Domain: github.com
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react-reconciler,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@d5750093facf |
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:14fca50f-fe45-e1e2-591e-6e44def0da4f |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | C9E0:19FA2E:90A2FB:CD1023:6AFB509A |
| html-safe-nonce | 3f75dc87fcaf57b0e8990e4f723908fd36cffd92fbf8e540cd92037f2f6b30cf |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDOUUwOjE5RkEyRTo5MEEyRkI6Q0QxMDIzOjZBRkI1MDlBIiwidmlzaXRvcl9pZCI6IjM3OTQzMjY5MDQ1NDI4MTAyNjYiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 94995724d925eef5ddbcac9db1995f01e132640a17022cd5ebc9c3b7fc852816 |
| hovercard-subject-tag | pull_request:4903997088 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/simstudioai/sim/pull/9183/files |
| twitter:image | https://avatars.githubusercontent.com/u/40672544?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/40672544?s=400&v=4 |
| og:image:alt | Summary Remove POST /api/workflows/[id]/log. It let whoever started a run re-complete that run with a client-supplied result: overwrite the status, output, and trace spans of an already finished l... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | 7122bb414b542dba14d71a3f0b9f6fd2abce715b9f5912d082800563e6c806d1 |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/simstudioai/sim git https://github.com/simstudioai/sim.git |
| octolytics-dimension-user_id | 199344406 |
| octolytics-dimension-user_login | simstudioai |
| octolytics-dimension-repository_id | 912559512 |
| octolytics-dimension-repository_nwo | simstudioai/sim |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 912559512 |
| octolytics-dimension-repository_network_root_nwo | simstudioai/sim |
| turbo-body-classes | logged-out env-production page-responsive full-width |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | cbf66c024bb6d10e6955baa7413c54cf13a201bb |
| ui-target | canary-1 |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width