CVE-2026-35525 LiquidJS has a root restriction bypass for partial and layout loading through symlinked templates
- Published
- Updated
- Exploit status
- No public exploit known
- CISA SSVC
- Proof of concept public · automatable: no · technical impact: partial
Description
LiquidJS is a Shopify / GitHub Pages compatible template engine in pure JavaScript. Prior to 10.25.3, for {% include %}, {% render %}, and {% layout %}, LiquidJS checks whether the candidate path is inside the configured partials or layouts roots before reading it. That check is path-based, not realpath-based. Because of that, a file like partials/link.liquid passes the directory containment check as long as its pathname is under the allowed root. If link.liquid is actually a symlink to a file outside the allowed root, the filesystem follows the symlink when the file is opened and LiquidJS renders the external target. So the restriction is applied to the path string that was requested, not to the file that is actually read. This matters in environments where an attacker can place templates or otherwise influence files under a trusted template root, including uploaded themes, extracted archives, mounted content, or repository-controlled template trees. This vulnerability is fixed in 10.25.3.
Upgrade path
3 packages: 2 fixed.
| Package | Affected | Fixed in | Status |
|---|---|---|---|
| liquidjs | < 10.25.3 | 10.25.3 | Fixed |
| npm liquidjs(npm) | < 10.25.3; <= 10.25.2 | 10.25.3 | Fixed |
| harttle liquidjs | = < 10.25.3 | No fix listed | Versions listed |
Affected products
| Product | Affected versions | Fixed in |
|---|---|---|
| harttle liquidjs | = < 10.25.3 | No fix listed |
| npm liquidjs(npm) | <= 10.25.2 | No fix listed |
| liquidjs | < 10.25.3 | 10.25.3 |
| npm liquidjs(npm) | < 10.25.3 | 10.25.3 |
References
- https://github.com/harttle/liquidjs/security/advisories/GHSA-56p5-8mhr-2fph exploit vendor-advisory
- https://github.com/harttle/liquidjs/pull/867 issue-tracking patch
- https://github.com/harttle/liquidjs/releases/tag/v10.25.3 release-notes
- nvd.nist.gov third-party-advisory vendor-advisory
- github.com
- github.com product