GHSA-qxpp-qjg8-x4jv: Trigger.dev Run Replay Injects A Task Vulnerability
HIGHGHSA-qxpp-qjg8-x4jv is a HIGH (CVSS 7.1) run replay injects a task vulnerability (CWE-639: Authorization Bypass Through User-Controlled Key) affecting Trigger.dev libraries in the npm ecosystem. The issue involves run replay injects a task run into an attacker-chosen environment (cross-tenant write). Remediation is available by upgrading affected packages to version 4.5.2.
GHSA-qxpp-qjg8-x4jv at a Glance
Security Impact
CVSS: 7.1
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:L).
How to Fix GHSA-qxpp-qjg8-x4jv
To remediate this vulnerability, upgrade all affected Trigger.dev dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
npm install trigger.dev@4.5.2
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
npm ls trigger.dev
How to Check if You Are Affected
To determine whether your Node.js application is affected by GHSA-qxpp-qjg8-x4jv, inspect your project dependencies using npm:
npm ls trigger.dev
Analyze the terminal output to locate any version of Trigger.dev in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 4.5.2), your application is affected.
Note: The npm ls trigger.dev command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-639: Authorization Bypass Through User-Controlled Key, where the system's authorization functionality does not prevent one user from gaining access to another user's data or record by modifying the key value identifying the data. In Trigger.dev, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
GHSA-qxpp-qjg8-x4jv Affected Trigger.dev Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
trigger.dev
|
npm |
< 4.5.2
|
4.5.2
|
References
Frequently Asked Questions
What is GHSA-qxpp-qjg8-x4jv?
Which Trigger.dev versions are affected?
What version fixes GHSA-qxpp-qjg8-x4jv?
Is trigger.dev affected?
What is the CVSS score of GHSA-qxpp-qjg8-x4jv?
What CWE is associated with GHSA-qxpp-qjg8-x4jv?
How can I check npm dependencies for GHSA-qxpp-qjg8-x4jv?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-qxpp-qjg8-x4jv",
"modified" : "2026-10-02T19:31:17Z",
"published" : "2026-10-02T19:31:17Z",
"aliases" : [ ],
"summary" : "Trigger.dev: Run replay injects a task run into an attacker-chosen environment (cross-tenant write)",
"details" : "### Summary\nThe dashboard replay action authorizes the source run (it must belong to the caller's org), but the target environment for the replayed run is taken verbatim from the request body and is never checked for org or project membership. The environment lookup used by the replay path filters by id only. As a result, an authenticated user can replay one of their own runs into another organization's or project's environment, creating a task run there that consumes the victim tenant's queue and compute and pollutes their run history.\n\n### Details\nThe replay action member-scopes the source run correctly (apps/webapp/app/routes/resources.taskruns.$runParam.replay.ts, the findFirst on taskRun filtered by `project.organization.members.some.userId`), but passes the target environment straight from the submitted form, resources.taskruns.$runParam.replay.ts:344-346:\n```js\nconst replayRunService = new ReplayTaskRunService();\nconst newRun = await replayRunService.call(taskRun, {\n environmentId: submission.value.environment, // attacker-controlled, unvalidated\n payload: submission.value.payload,\n ...\n});\n```\n`submission.value.environment` comes from ReplayRunData (apps/webapp/app/v3/replayTask.ts: `environment: z.string().optional()`), so it is fully client-controlled.\n\nReplayTaskRunService resolves it with no ownership check, apps/webapp/app/v3/services/replayTaskRun.server.ts:26-28:\n```js\nconst authenticatedEnvironment = await findEnvironmentById(\n overrideOptions.environmentId ?? existingTaskRun.runtimeEnvironmentId\n);\n```\nfindEnvironmentById, apps/webapp/app/models/runtimeEnvironment.server.ts:197-211:\n```js\nexport async function findEnvironmentById(id) {\n const environment = await $replica.runtimeEnvironment.findFirst({\n where: { id }, // no membership / org / project filter\n include: authIncludeWithParent,\n });\n if (!environment || environment.project.deletedAt !== null) return null;\n return toAuthenticated(environment);\n}\n```\nThe resolved environment is then handed to TriggerTaskService.call (apps/webapp/app/v3/services/triggerTask.server.ts), which trusts the passed authenticatedEnvironment and performs no further authorization. The replay loader does constrain the environment picker to the run's own project (replay.ts around 178-184), but the action does not re-impose that constraint, so the server-side control is missing (UI-gated only).\n\n### PoC\nAs an authenticated user who owns a run in their own org (run param runParam), and who knows a target environment id belonging to another org or project (a CUID, obtained or guessed):\n```http\nPOST /resources/taskruns/<own runParam>/replay\nContent-Type: application/x-www-form-urlencoded\n\nenvironment=<environment id of the victim org/project>&failedRedirect=/...\n```\nThe replay resolves the victim environment with no membership check and calls TriggerTaskService against it, creating a run in the victim tenant.\n\nLive-validated: a Postgres database was seeded with two tenants (orgA with env_A, orgB with env_B_victim) and the verbatim findEnvironmentById lookup (findFirst joining the environment to its project, `WHERE id = $1`, the exact query the replay path runs) was executed with the victim env id as an orgA attacker. Captured:\n```\n[002 replay findEnvironmentById] attacker(orgA) supplied env_B_victim -> {\"id\":\"env_B_victim\",\"organization_id\":\"orgB\",\"project_id\":\"proj_B\",\"deleted_at\":null}\nCROSS-TENANT: CONFIRMED (resolved another org's env with no membership check -> replay would run there)\n```\nThe lookup returned another organization's environment with no membership filter. That the replay action passes the client-supplied environmentId straight into this lookup (and TriggerTaskService trusts the returned env) is verified at source.\n\n### Impact\nAn authenticated user can create task runs in another tenant's environment (including production), consuming that tenant's queue concurrency and compute and inserting entries into their run history. Practical exploitation requires knowing a target environment id (not enumerable) and, for the injected run to actually execute rather than error, a task identifier that exists in the target environment; this bounds reliability but not the unauthorized cross-tenant write itself.\n\n### Remediation\nIn the replay action (or in ReplayTaskRunService), require the resolved target environment to belong to the source run's project/organization, for example assert `environment.projectId === existingTaskRun.projectId`, or re-validate the supplied environment id against the caller's membership (findEnvironmentBySlug with the validated projectId, or a members.some.userId filter), mirroring the constraint the loader already applies to the picker.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:L"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "npm",
"name" : "trigger.dev"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "4.5.2"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/triggerdotdev/trigger.dev/security/advisories/GHSA-qxpp-qjg8-x4jv"
}, {
"type" : "WEB",
"url" : "https://github.com/triggerdotdev/trigger.dev/pull/4199"
}, {
"type" : "WEB",
"url" : "https://github.com/triggerdotdev/trigger.dev/commit/34b1a181c2a1d33a53ebab88f84b05f81fea4254"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/triggerdotdev/trigger.dev"
}, {
"type" : "WEB",
"url" : "https://github.com/triggerdotdev/trigger.dev/releases/tag/v4.5.2"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-639" ],
"severity" : "HIGH",
"github_reviewed" : true,
"github_reviewed_at" : "2026-10-02T19:31:17Z",
"nvd_published_at" : null
}
}