Symfony Stimulus Bridge build-time code execution in controllers.json loader
Affects @symfony/stimulus-bridge versions before 4.0.3 that use the controllers.json loader with a controller package whose exports map ./package.json to a script. Fixed in 4.0.3.
- Exploited
- No known exploitation
- Fix
- Fixed in 4.0.3
- Who is exposed
- Specific setups only
Summary
@symfony/stimulus-bridge loads the package.json of each package listed in controllers.json with require(), so a malicious or compromised listed package can have its mapped script run during the Webpack or Symfony Encore build. An attacker needs local access and user interaction, and the code can read build files and environment variables such as CI secrets and alter the built assets.
Written by a model
Original description
The controllers.json loader of @symfony/stimulus-bridge loads the package.json file of each package listed in controllers.json with require(). Node resolves this path through the exports field of the package, which can map ./package.json to a script. require() then runs that script during the Webpack or Symfony Encore build.
This is a build-time vulnerability: it doesn't affect browsers or end users. A malicious or compromised package listed in controllers.json can run code on the developer machine or the CI server. This works even when the package manager doesn't run install scripts. This code can read the files and environment variables of the build, like CI secrets, and change the built assets.
The loader now reads the resolved file and parses it as JSON, so that a mapped script fails to parse instead of running.
Who should check
Teams running @symfony/stimulus-bridge below 4.0.3 with a controllers.json file, including Symfony apps built with Webpack Encore and the CI servers that run those builds.
“Symfony Stimulus Bridge versions <4.0.3 are affected by this security issue.”
What to do
Check whether your setup matches what the bug needs.
Affected @symfony/stimulus-bridge versions before 4.0.3 use the controllers.json loader, which loads each listed package's package.json with require(). The controller package's exports field maps ./package.json to a script. The build runs the Webpack or Symfony Encore build that loads the package.Upgrade to a fixed version: 4.0.3.
Check your systems with an agent
Paste this into a coding or ops agent. It checks your systems read-only and reports a table per asset.
Check whether my systems are affected by CVE-2026-133781 (Build-time Code Execution in @symfony/stimulus-bridge via a Controller Package That Maps Its package.json to a Script), using the cve.now data below.
Rules: work read-only. Do not run exploit code, proof-of-concept scripts or scanners that send attack payloads, and do not change any configuration, package, image or deployment. Report findings only.
What cve.now has for CVE-2026-133781 (entry last updated 2026-11-24):
Affected:
- npm package @symfony/stimulus-bridge: fixed in 4.0.3
Fixed versions: 4.0.3.
Conditions (all must be true for the bug to be hit):
- Affected @symfony/stimulus-bridge versions before 4.0.3 use the controllers.json loader, which loads each listed package's package.json with require(). (source: https://symfony.com/blog/cve-2026-133781-build-time-code-execution-in-at-symfony-stimulus-bridge-via-a-controller-package-that-maps-its-package-json-to-a-script)
- The controller package's exports field maps ./package.json to a script. (source: https://symfony.com/blog/cve-2026-133781-build-time-code-execution-in-at-symfony-stimulus-bridge-via-a-controller-package-that-maps-its-package-json-to-a-script)
- The build runs the Webpack or Symfony Encore build that loads the package. (source: https://symfony.com/blog/cve-2026-133781-build-time-code-execution-in-at-symfony-stimulus-bridge-via-a-controller-package-that-maps-its-package-json-to-a-script)
Setup: unknown whether the bug needs a non-default feature or setting. Check the advisory.
Attacker needs: local access, no login, a user action.
CISA KEV: CVE-2026-133781 is not listed as of cve.now's last read.
This KEV status is for CVE-2026-133781 only. If you also check another CVE, look up its own KEV status; never assume it from this one.
How to check:
- Packages (npm): find every lockfile in each project and run the stack.check operation of the cve.now MCP server (execute) on each one. Compare the resolved versions, not the ranges a manifest declares, with the affected versions above. Include transitive dependencies.
Verify against the linked advisories before concluding, and cite the date you read each one:
- https://symfony.com/cve-2026-133781
- https://github.com/symfony/stimulus-bridge/security/advisories/GHSA-6rch-xhq6-7x8r
- https://github.com/symfony/stimulus-bridge/commit/1125c5c29dce467415a3d2663e682fbb9d9ab424
- https://symfony.com/blog/cve-2026-133781-build-time-code-execution-in-at-symfony-stimulus-bridge-via-a-controller-package-that-maps-its-package-json-to-a-script
Do not conclude an asset is unaffected unless you checked it and the evidence covers both its version and the conditions above. If you could not check something, mark it unknown and say what is missing.
Report a table with one row per asset and these columns: Asset | Version or build | Status (affected, fixed, not applicable, unknown) | Compensating controls | Exposure (internet-facing, internal, none) | Evidence | Next action.
Entry: https://cve.now/CVE-2026-133781
For follow-up questions, use the cve.now MCP server at https://mcp.cve.now/mcp (no authentication), for example execute with name cve.get and arguments {"id": "CVE-2026-133781"}.Affected versions
cve.now Index
- Exploitation?/40Unknown. No CISA SSVC exploitation rating yet
- Exposure5/25Specific setups only
- Reach10/20Affects npm packages
- Severity7.3/10CVSS 7.3
- No patch0/5No signal
What would change the score
- Would score about 72 if added to CISA KEV
- Would score about 67 if CISA's SSVC rates exploitation active
- Would score about 32 if CISA's SSVC rates it automatable
Timeline
- CVE published
- First seen by cve.now
Evidence 5
| Kind | Source |
|---|---|
| Vendor advisory 2Establishes: Affected and fixed versions. | |
| Advisory | symfony.com · cve-2026-133781 |
| Advisory | GitHub · symfony/stimulus-bridge · Advisory GHSA-6rch-xhq6-7x8r |
| CVE record 2Establishes: The identifier and description. | |
| Record | CVE List · CVE-2026-133781 |
| Record | NVD · CVE-2026-133781 |
| Other links 1 | |
| Patch | GitHub · symfony/stimulus-bridge · Commit 1125c5c2 |
Questions about CVE-2026-133781
Is CVE-2026-133781 being exploited?
It is not in CISA's Known Exploited Vulnerabilities catalog, and CISA's SSVC assessment does not mark exploitation as active. That does not mean it has not been attacked: vendors and researchers can report attacks before CISA lists them. No public exploit code is tracked.
Source: cve.now feed data
What does this mean?
A controller package can make the controllers.json loader run a script hidden behind its package.json path. That script runs during the Webpack or Symfony Encore build, on the developer machine or CI server, where it can read build files and environment variables such as CI secrets and change the built assets.
Source: symfony.com
Which versions are affected by CVE-2026-133781?
@symfony/stimulus-bridge (npm): before 4.0.3.
Source: cve.now feed data
Am I affected, and how do I check?
Versions of @symfony/stimulus-bridge before 4.0.3 are affected when the project uses the controllers.json loader and loads a controller package whose exports field maps ./package.json to a script. To check, look at the installed version of @symfony/stimulus-bridge in package.json or the lockfile, and whether controllers.json lists any packages.
Source: symfony.com
How do I fix CVE-2026-133781?
Upgrade @symfony/stimulus-bridge to 4.0.3 or later.
Source: symfony.com
Related
- CVE-2026-133780@symfony/stimulus-bridge lazy-controller-loader: arbitrary code execution via unsanitized Stimulus magic comments
- CVE-2026-49211Symfony UX: Information exposure via unescaped LIKE wildcards in EntitySearchUtil
- CVE-2026-49208Symfony UX: Format-less date LiveProps parsed with the permissive DateTime constructor
- CVE-2026-49212Symfony UX: LiveComponentHydrator HMAC checksum lacks component and slot binding
- CVE-2026-46644symfony/polyfill-intl-idn accepts xn-- labels whose Punycode payload decodes to ASCII-only: insecure equivalence
- CVE-2026-133778Live Components Configured With a Custom Route Can Still Be Reached Through the Default Route
No corrections so far. Something wrong on this page? Report an error.