Sanaan Fayaz Wani

triggerdotdev/trigger.dev

GHSA-pqxw-g93w-hj9x

Trigger.dev Self-Hosted Deployment: Default Secrets allow Unauthenticated Infrastructure Compromise

GHSA-pqxw-g93w-hj9x

8.1

High

CVSS-BT 4.0

  1. 2026-05-22Reported privately
  2. 60 days later2026-07-21Published by the maintainer

What to do

If you run trigger.dev 4.5.5 and earlier, upgrade to 4.5.6 or later.

Anyone who can reach it over the network, with no account and no user interaction, if they can defeat a protection or obtain a target-specific secret, can read and change sensitive data.Read from the CVSS 4.0 vector

CVSS 4.0 metrics

To exploit it

Attack vector
Network
Attack complexity
High
Attack requirements
None
Privileges required
None
User interaction
None

What it gets

Confidentiality
High
Integrity
High
Availability
None

Other systems

Confidentiality
None
Integrity
None
Availability
None

ThreatExploit maturity: Proof of concept. Because this is set, the score is CVSS-BT.

Open this vector in the FIRST calculator ↗

Weakness
CWE-653, CWE-1393 Improper Isolation or Compartmentalization · Use of Default Password
CVE
not assigned
Vector
CVSS:4.0/AV:N/AC:H/AT:N/PR:N/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N/E:P
Also in trigger.dev
GHSA-jc26-22qp-cgqj 7.9 · GHSA-59h8-w5q6-mfmp 5.3
2026-05-22Reported privately
60 days
2026-07-21Published by the maintainer

My analysis of this finding: root cause, the vulnerable code, the impact and the fix, in the site’s format. The official advisory of record is linked above.

Affected versions

Package Ecosystem Vulnerable Fixed in
trigger.dev npm <= 4.5.5 4.5.6

Chain · GHSA-pqxw-g93w-hj9x · trigger.dev

Five steps from a file committed to the repository to three data stores with their own credentials. Each step is paired with the control that was supposed to stop it and was not there. Every fact is taken from the published advisory; the right-hand column names the control that advisory says was missing.

Text alternative. Step 00: the repository ships hosting/docker/.env.example containing four fixed secrets, among them MAGIC_LINK_SECRET equal to 44da78b7bbb0dfe709cf38931d25dcdd; the documented install copies that file to .env. Absent control: secrets are not generated on first boot and the service does not refuse to start on a known value. Step 01: the attacker forges a magic link offline by AES-encrypting a JSON payload naming any email address with that secret, which remix-auth-email-link version 2.0.2 accepts. Absent control: the token is encryption rather than a server-side record, so nothing ties it to a link the server actually issued. Step 02: requesting /magic with the forged token returns HTTP 302 and sets a __session cookie. Absent control: validateSessionMagicLink defaults to false in the library and trigger.dev never overrides it, so no session-side check confirms this browser asked for the link. Step 03: the account is created on the spot because WHITELISTED_EMAILS is unset, which is the self-hosted default; the attacker is now any user they named. Absent control: no allowlist and no email delivery step proving control of the address. Step 04: hosting/docker/worker/docker-compose.yml line 42 sets DOCKER_RUNNER_NETWORKS to webapp and supervisor, placing runner containers on the same Docker networks as the platform's own data stores. Absent control: no segmentation between run sandboxes and infrastructure. From there the advisory verifies Postgres reachable with the default password unsafe-postgres-pw and returning the User table, Redis answering PING with no authentication, and ClickHouse answering a version query as default colon password; separately, ENCRYPTION_KEY sits in the same shipped file, so data the platform encrypted at rest is decryptable.

Scope changed. The vulnerable component is the webapp. Postgres, Redis and ClickHouse are separate security authorities with credentials of their own, and the chain reaches them anyway. That is the S:C in the vector, and it is most of what separates this from a single-app compromise.

Steps 3 to 5 of the advisory verify Postgres, Redis and ClickHouse with commands; pushing backdoored images to the registry and manipulating job queues are stated in its impact section without a verification step. Affects trigger.dev <= 4.5.5. Published 2026-07-21.

Summary

The self-hosting stack for trigger.dev v4 ships a .env.example at hosting/docker/.env.example that contains real, working secret values rather than placeholders. Operators who copy it to .env (the documented path) inherit a publicly known MAGIC_LINK_SECRET, ENCRYPTION_KEY, SESSION_SECRET, and default database, Redis, ClickHouse and object store credentials. I verified a full unauthenticated chain against a live default instance: forge a magic link, land an authenticated session with no email delivery, and reach every infrastructure service with its shipped password.

Where it lives

The secrets are committed in plaintext. These are not throwaway placeholders, they are the values the compose stack actually loads:

SESSION_SECRET=2818143646516f6fffd707b36f334bbbMAGIC_LINK_SECRET=44da78b7bbb0dfe709cf38931d25dcddENCRYPTION_KEY=f686147ab967943ebbe9ed3b496e465aMANAGED_WORKER_SECRET=447c29678f9eaf289e9c4b70d3dd8a7f...POSTGRES_PASSWORD=unsafe-postgres-pwDATABASE_URL=postgresql://postgres:unsafe-postgres-pw@postgres:5432/main?...CLICKHOUSE_URL=http://default:password@clickhouse:8123?secure=falseOBJECT_STORE_ACCESS_KEY_ID=adminOBJECT_STORE_SECRET_ACCESS_KEY=very-safe-password

The bugshipped magic link secret lets anyone mint login tokensThe bugpublished key decrypts every stored tenant secret

The MAGIC_LINK_SECRET is the keystone. trigger.dev’s passwordless login encrypts the magic link token with this secret, so knowing it lets anyone mint a valid login token for any email without ever receiving the email. My PoC reproduces the exact token the server expects:

const MAGIC_LINK_SECRET = "44da78b7bbb0dfe709cf38931d25dcdd";
const payload = JSON.stringify({ e: email, c: Date.now() });
const encrypted = CryptoJS.AES.encrypt(payload, MAGIC_LINK_SECRET).toString();
// GET /magic?token=<encodeURIComponent(encrypted)>  -> session cookie, user auto-created

Impact

Unauthenticated session forging. Visiting the forged /magic?token=... URL auto-creates the account and sets a session cookie. Against a live default instance the chain produced a working session (HTTP 302 -> /orgs/new) with no interaction from any real user.

Full infrastructure access. With the webapp network reachable (the default stack places runner containers on it), the shipped credentials opened every backend service directly: PostgreSQL via postgres:unsafe-postgres-pw with all tenant tables readable (User, SecretStore, PersonalAccessToken, EnvironmentVariable, RuntimeEnvironment, OrgMember), Redis answering PONG with no auth, and ClickHouse returning its version via default:password.

Secret decryption. ENCRYPTION_KEY=f686147ab967943ebbe9ed3b496e465a is the key used to encrypt stored secrets, so the SecretStore contents an attacker reads from PostgreSQL are decryptable with the same published value. The breach is not limited to metadata, it extends to the credentials trigger.dev holds on behalf of every tenant.

Taken together this is a complete, cross tenant compromise of any self hosted instance left on the defaults, reachable by an unauthenticated remote attacker.

Fix

Stop shipping live secrets in a file operators are told to copy. The stack should generate unique secrets at deploy time through a bootstrap step, and the webapp should refuse to start when MAGIC_LINK_SECRET, ENCRYPTION_KEY or SESSION_SECRET match a known published default or are empty. Enable Redis authentication with an auto generated password, give the task runners an isolated network that can reach only the supervisor workload API, and require real credentials on the infrastructure services rather than the committed ones.

References

The record

Weakness
CWE-653 Improper Isolation or Compartmentalization
CWE-1393 Use of Default Password
Affected
trigger.dev 4.5.5 and earlier
Fixed in
4.5.6
Disclosure
2026-05-22 Reported privately
60 days later2026-07-21 Published
Advisory
GHSA-pqxw-g93w-hj9x
Also in trigger.dev
GHSA-jc26-22qp-cgqj 7.9
GHSA-59h8-w5q6-mfmp 5.3

About this writeup

Sanaan Fayaz Wani (GitHub sfwani) reported this vulnerability to the trigger.dev maintainers under coordinated disclosure and is credited as a reporter in GHSA-pqxw-g93w-hj9x, published 2026-07-21.

All published findings: advisory index.