Skip to content

Bump liquidjs from 10.16.1 to 10.27.2 - #24

Open
dependabot[bot] wants to merge 1 commit into
mainfrom
dependabot/npm_and_yarn/liquidjs-10.27.2
Open

dependabot[bot] wants to merge 1 commit into
mainfrom
dependabot/npm_and_yarn/liquidjs-10.27.2

Conversation

@dependabot

@dependabot dependabot Bot commented on behalf of github Sep 8, 2026

Copy link
Copy Markdown

Bumps liquidjs from 10.16.1 to 10.27.2.

Release notes

Sourced from liquidjs's releases.

v10.27.2

10.27.2 (2026-07-09)

Bug Fixes

  • charge join/json/inspect filters by produced output size (#925) (7ab49f9)
  • date: zero-pad milliseconds when formatting %N fractional seconds (#929) (2634f9d)
  • enforce ownPropertyOnly for inherited array indices (#924) (552819a)
  • filters: modulo should follow divisor sign for negative operands (#922) (568bd5f)
  • filters: return empty for out-of-range slice begin or negative length (#928) (f9a1316)

v10.27.1

10.27.1 (2026-06-23)

Bug Fixes

  • improve round function; improvement to #873 (#901) (956b51e)
  • security: charge pop filter allocation to memoryLimit (#907) (8a0c74a)
  • strip_html: infinite loop for strip_html (5c3522f)

Performance Improvements

  • parser: memoize createTrie to avoid rebuilding tries per Tokenizer (#911) (3a0d80d)

v10.27.0

10.27.0 (2026-05-15)

Features

  • context: null-prototype scope frames via createScope (#899) (47d3f1b)

v10.26.0

10.26.0 (2026-05-14)

Bug Fixes

  • date: cap strftime widths and account padding in memoryLimit (#895) (3129d46)
  • enforce renderLimit for empty renderTemplates calls (#894) (5b9c346)
  • propagate ownPropertyOnly into Context.spawn() for {% render %} (#893) (dbbf628)
  • security: block Object.prototype filter/tag lookups (RCE) (#897) (457fae0)
  • strip html newline tags (#892) (26ea285)
  • strip_html: rewrite as linear single-pass scan to avoid ReDoS (#896) (3616a74)

Features

... (truncated)

Changelog

Sourced from liquidjs's changelog.

10.27.2 (2026-07-09)

Bug Fixes

  • charge join/json/inspect filters by produced output size (#925) (7ab49f9)
  • date: zero-pad milliseconds when formatting %N fractional seconds (#929) (2634f9d)
  • enforce ownPropertyOnly for inherited array indices (#924) (552819a)
  • filters: modulo should follow divisor sign for negative operands (#922) (568bd5f)
  • filters: return empty for out-of-range slice begin or negative length (#928) (f9a1316)

10.27.1 (2026-06-23)

Bug Fixes

  • improve round function; improvement to #873 (#901) (956b51e)
  • security: charge pop filter allocation to memoryLimit (#907) (8a0c74a)
  • strip_html: infinite loop for strip_html (5c3522f)

Performance Improvements

  • parser: memoize createTrie to avoid rebuilding tries per Tokenizer (#911) (3a0d80d)

10.27.0 (2026-05-15)

Features

  • context: null-prototype scope frames via createScope (#899) (47d3f1b)

10.26.0 (2026-05-14)

Bug Fixes

  • date: cap strftime widths and account padding in memoryLimit (#895) (3129d46)
  • enforce renderLimit for empty renderTemplates calls (#894) (5b9c346)
  • propagate ownPropertyOnly into Context.spawn() for {% render %} (#893) (dbbf628)
  • security: block Object.prototype filter/tag lookups (RCE) (#897) (457fae0)
  • strip html newline tags (#892) (26ea285)
  • strip_html: rewrite as linear single-pass scan to avoid ReDoS (#896) (3616a74)

Features

  • add sha256 and hmac_sha256 filters for cryptographic operations (#889) (1c816d4)

10.25.7 (2026-04-23)

... (truncated)

Commits
  • 050f161 chore(release): 10.27.2 [skip ci]
  • 2634f9d fix(date): zero-pad milliseconds when formatting %N fractional seconds (#929)
  • f9a1316 fix(filters): return empty for out-of-range slice begin or negative length (#...
  • 7ab49f9 fix: charge join/json/inspect filters by produced output size (#925)
  • 552819a fix: enforce ownPropertyOnly for inherited array indices (#924)
  • 8bfb642 docs: add spokodev as a contributor for code (#923)
  • 568bd5f fix(filters): modulo should follow divisor sign for negative operands (#922)
  • ed48986 chore(release): 10.27.1 [skip ci]
  • afec88b docs(readme): README overhaul, used-by grid, and docs homepage (#914)
  • 3a0d80d perf(parser): memoize createTrie to avoid rebuilding tries per Tokenizer (#911)
  • Additional commits viewable in compare view
Maintainer changes

This version was pushed to npm by GitHub Actions, a new releaser for liquidjs since your current version.


Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    You can disable automated security fix PRs for this repo from the Security Alerts page.

Bumps [liquidjs](https://github.com/harttle/liquidjs) from 10.16.1 to 10.27.2.
- [Release notes](https://github.com/harttle/liquidjs/releases)
- [Changelog](https://github.com/harttle/liquidjs/blob/master/CHANGELOG.md)
- [Commits](harttle/liquidjs@v10.16.1...v10.27.2)

---
updated-dependencies:
- dependency-name: liquidjs
  dependency-version: 10.27.2
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot Bot added dependencies Pull requests that update a dependency file javascript Pull requests that update javascript code labels Sep 8, 2026
@fossabot

fossabot Bot commented Sep 8, 2026 •

Copy link
Copy Markdown

Needs Review

I recommend reviewing this upgrade before merging because, while it delivers significant security remediation by resolving 15 OSV-validated vulnerabilities across critical, high, medium, and low severity classifications, it also introduces several behavioral changes in a foundational dependency that powers the entire documentation engine. Notably, the blocking of Object.prototype filter/tag lookups (a security hardening change) and the introduction of null-prototype scope frames via createScope could subtly affect the project's custom Tag subclass in ifversion.js, which directly accesses ctx.environments.currentVersionObj in its render logic. Additionally, remove-liquid-statements.js relies on the hardcoded numeric value 4 to identify liquid tags via elem.kind === 4 rather than using the TokenKind.Tag named export — this is fragile across major enum refactors, though EdgeBit detected no symbol-level changes. The expanded memoryLimit enforcement (now covering pop, join, json, and inspect filters) is not currently a concern as no memoryLimit is configured in engine.js. The overall scope of the upgrade is large (38 new features, 39 bug fixes over 11 minor versions), making end-to-end testing of the rendering pipeline — particularly for versioned content, custom tags, and linting rules — strongly advisable before merging.

Tip: Comment @​fossabot fix to attempt automatic fixes.

Fix Suggestions

We identified 3 fixable issues in this upgrade.

  • Replace hardcoded elem.kind === 4 with elem.kind === TokenKind.Tag to avoid silent breakage if the enum values shift in a future liquidjs release
    Files: src/ghes-releases/scripts/remove-liquid-statements.js
  • Verify custom tag environment access patterns (ctx.environments.currentVersionObj and scope.environments.currentLanguage) work correctly under liquidjs 10.27.x null-prototype scope frames
    Files: src/content-render/liquid/ifversion.js, src/content-render/liquid/data.js
  • Run end-to-end rendering tests for versioned content, custom tags (ifversion, data, octicon), and linting rules to validate liquidjs 10.27.2 compatibility
    Files: src/content-render/liquid/engine.js and 4 other files

AI Assistant Prompt

Copy prompt for AI assistant
# Fix liquidjs Dependency Upgrade Issues

## Context
`liquidjs` has been upgraded spanning 11 minor versions (up to 10.27.2). This is a critical security update resolving 15 vulnerabilities, including path traversal and RCE flaws. Key behavioral changes include:
- **Object.prototype filter/tag lookup blocking** (10.26.0) — security hardening
- **Null-prototype scope frames** via `createScope` (10.27.0) — affects how `ctx.environments` works
- **Minimum Node.js 16** requirement (breaking change)

---

## Fix 1: Replace hardcoded enum value with `TokenKind.Tag` named export

**File:** `src/ghes-releases/scripts/remove-liquid-statements.js`

**Problem:** Line 216 uses `elem.kind === 4` (a hardcoded numeric value) to identify Liquid tags. This is fragile and will silently break if `TokenKind` enum values shift in a future release. The rest of the codebase already uses the named export.

**Current code (line 1):**
```js
import { Tokenizer } from 'liquidjs'
```

**Change to:**
```js
import { Tokenizer, TokenKind } from 'liquidjs'
```

**Current code (line 216):**
```js
.filter((elem) => elem.kind === 4)
```

**Change to:**
```js
.filter((elem) => elem.kind === TokenKind.Tag)
```

**Reference:** Five linting rule files already use this pattern correctly, e.g.:
- `src/content-linter/lib/linting-rules/liquid-versioning.js` (line 60): `token.kind === TokenKind.Tag`
- `src/content-linter/lib/linting-rules/liquid-tag-whitespace.js` (line 26): `token.kind === TokenKind.Tag`
- `src/content-linter/lib/linting-rules/liquid-data-tags.js` (line 25): `token.kind === TokenKind.Tag`

This is the only automated code fix needed. The changes below are verification steps.

---

## Verification 1: Custom tag environment access under null-prototype scopes

**Files to inspect (no code changes expected, just verify behavior):**
- `src/content-render/liquid/ifversion.js` — line 55: `ctx.environments.currentVersionObj`
- `src/content-render/liquid/data.js` — check for `scope.environments.currentLanguage` or similar

**What to check:** LiquidJS 10.27.0 introduced null-prototype scope frames via `createScope`. The `ifversion.js` custom `Tag` subclass accesses `ctx.environments.currentVersionObj` in its `render` method (line 55). Null-prototype objects still hold own properties, so direct property access should work. However, verify that:
1. No code uses `hasOwnProperty`, `toString`, or `in` checks on scope objects
2. No code relies on prototype chain lookups for environment values
3. The existing test suite for versioned content rendering passes without regressions

**Engine config** (`src/content-render/liquid/engine.js`): No `memoryLimit` is configured, so the expanded `memoryLimit` enforcement in new filters (`pop`, `join`, `json`, `inspect`) is not a concern.

---

## Verification 2: Run the full test suite

After making the Fix 1 code change, run the full test suite to validate compatibility:

1. **Versioned content rendering** — tests for `ifversion` tag behavior
2. **Custom tags** — `data`, `octicon`, `indented_data_reference`, `tool`, `spotlight`
3. **Content linting rules** — all five rules that use `TokenKind`:
   - `liquid-versioning.js`
   - `liquid-tag-whitespace.js`
   - `liquid-quoted-conditional-arg.js`
   - `liquid-data-tags.js`
   - `rai-reusable-usage.js`
4. **GHES release scripts** — `remove-liquid-statements.js` (the file we modified)

Pay particular attention to any rendering differences in version-gated content blocks.

What we checked

  • Dependency declared as "liquidjs": "^10.27.2" in dependencies, confirming the upgrade from 10.16.1 to 10.27.2. This is a pervasive foundational dependency used across rendering, linting, and release engineering pipelines. [1]
  • CVE-2026-45618 (Critical): Affected versions < 10.26.0. Fixed in 10.26.0, and thus remediated by upgrading to 10.27.2. This is the most severe of 15 validated CVEs resolved by this upgrade. [2]
  • CVE-2026-55575 (High): Affected versions < 10.27.1. Fixed in 10.27.1, and thus remediated by this upgrade to 10.27.2. [3]
  • CVE-2026-41311 (High): Affected versions < 10.25.7. Fixed in 10.25.7, and thus remediated by this upgrade. [4]
  • LiquidJS 10.26.0 introduced blocking of Object.prototype filter and tag lookups as a security hardening measure. While the project's custom filters (obj_size, version_num, slugify) and tags (ifversion, data, octicon, etc.) are explicitly registered via registerTag/registerFilter and are not prototype-chain-dependent, this behavioral change warrants verification that no template inadvertently relies on prototype resolution paths. [5]
  • LiquidJS 10.27.0 introduced null-prototype scope frames via createScope. This changes internal scope initialization and may affect custom tag or filter implementations that inspect scope objects. The project's ifversion.js directly accesses ctx.environments.currentVersionObj inside its render generator, and data.js accesses scope.environments.currentLanguage — these patterns should be verified against the new scope behavior. [6]
  • The custom ifversion tag (which extends Tag from liquidjs) accesses ctx.environments.currentVersionObj directly. The null-prototype scope frames introduced in 10.27.0 change how scope objects are internally initialized; this direct environment access pattern should be tested to ensure currentVersionObj is still accessible after the upgrade. [7]
  • The custom data tag accesses scope.environments.currentLanguage and scope.environments.currentLanguage directly in its render function. Like ifversion.js, this environment access pattern should be verified under the scope-frame changes in the new version. [8]
  • This file uses hardcoded numeric value elem.kind === 4 to detect liquid tags (comment on line 214 explains this is the enum value for a liquid tag). Other files in the codebase use TokenKind.Tag by name. If the TokenKind enum values shift in a future release, this will fail silently. EdgeBit reports no symbol changes, so this is low risk now, but the pattern is fragile and merits attention. [9]
  • Tokenizer is imported from liquidjs and used across five linting rules via tokenizer.readTopLevelTokens(). EdgeBit detected no API symbol changes, so this public API surface appears stable across the version range. [10]
  • new Liquid({ extname: '.html', dynamicPartials: false }) — no memoryLimit is configured, which means the extended memoryLimit enforcement added to pop, join, json, and inspect filters in 10.27.1–10.27.2 will not trigger in this deployment. [11]
  • A Dependabot bump of liquidjs 10.20.1 → 10.27.2 in the ceph.io project showed no reported breakage in PR comments, suggesting the upgrade is routine for typical usage patterns. However, this project's usage is more complex with custom Tag subclasses and direct scope access. [12]

Dependency Usage

liquidjs is a foundational templating dependency used pervasively across four major subsystems: content rendering, content linting, GHES release management, and developer tooling scripts. It powers the core documentation engine in src/content-render/liquid/ — enabling dynamic page rendering, custom tags like ifversion for version-gated content, and octicon rendering — while its Tokenizer and TokenKind primitives drive five content linting rules in src/content-linter/ that enforce Liquid syntax quality and versioning correctness. Beyond runtime rendering, liquidjs also supports operational workflows such as stripping Liquid statements from GHES release artifacts, detecting orphaned feature flags, and generating enterprise release issues, making it a cross-cutting dependency critical to both the documentation publishing pipeline and the release engineering process.

  • The custom ifversion tag (which extends Tag from liquidjs) accesses ctx.environments.currentVersionObj directly. The null-prototype scope frames introduced in 10.27.0 change how scope objects are internally initialized; this direct environment access pattern should be tested to ensure currentVersionObj is still accessible after the upgrade.
    this.currentVersionObj = ctx.environments.currentVersionObj
  • The custom data tag accesses scope.environments.currentLanguage and scope.environments.currentLanguage directly in its render function. Like ifversion.js, this environment access pattern should be verified under the scope-frame changes in the new version.
    let text = getDataByLanguage(this.path, scope.environments.currentLanguage)
View 3 more usages
  • This file uses hardcoded numeric value elem.kind === 4 to detect liquid tags (comment on line 214 explains this is the enum value for a liquid tag). Other files in the codebase use TokenKind.Tag by name. If the TokenKind enum values shift in a future release, this will fail silently. EdgeBit reports no symbol changes, so this is low risk now, but the pattern is fragile and merits attention.
    .filter((elem) => elem.kind === 4)
  • Tokenizer is imported from liquidjs and used across five linting rules via tokenizer.readTopLevelTokens(). EdgeBit detected no API symbol changes, so this public API surface appears stable across the version range.
    import { Tokenizer } from 'liquidjs'
  • new Liquid({ extname: '.html', dynamicPartials: false }) — no memoryLimit is configured, which means the extended memoryLimit enforcement added to pop, join, json, and inspect filters in 10.27.1–10.27.2 will not trigger in this deployment.
    export const engine = new Liquid({
Less Important Usages (18)

These usages were analyzed but no breaking changes were detected:

liquidjs

Changes

Critical security update: liquidjs was upgraded with 4 security fixes, including a path traversal vulnerability, a remote code execution flaw via Object.prototype filter/tag lookups, and a memoryLimit bypass in the pop filter. A breaking change increases the minimum Node.js requirement to v16, so any environments still on Node.js 14 or 15 must upgrade their runtime before deploying this change.

  • Minimum Node.js version requirement increased from >=14 to >=16 - users running Node.js 14 or 15 must upgrade their runtime environment (v10.22.0, package source)
  • path traversal vulnerability, #851 (#855) (3cd024d) (v10.24.0-10.25.0, changelog)
  • security: block Object.prototype filter/tag lookups (RCE) (#897) (457fae0) (v10.25.7-10.26.0, changelog)
View 248 more changes

View 151 more changes in the full analysis

References (12)

[1]: Dependency declared as "liquidjs": "^10.27.2" in dependencies, confirming the upgrade from 10.16.1 to 10.27.2. This is a pervasive foundational dependency used across rendering, linting, and release engineering pipelines.

"liquidjs": "^10.27.2",

[2]: CVE-2026-45618 (Critical): Affected versions < 10.26.0. Fixed in 10.26.0, and thus remediated by upgrading to 10.27.2. This is the most severe of 15 validated CVEs resolved by this upgrade. (source link)

[3]: CVE-2026-55575 (High): Affected versions < 10.27.1. Fixed in 10.27.1, and thus remediated by this upgrade to 10.27.2. (source link)

[4]: CVE-2026-41311 (High): Affected versions < 10.25.7. Fixed in 10.25.7, and thus remediated by this upgrade. (source link)

[5]: LiquidJS 10.26.0 introduced blocking of Object.prototype filter and tag lookups as a security hardening measure. While the project's custom filters (obj_size, version_num, slugify) and tags (ifversion, data, octicon, etc.) are explicitly registered via registerTag/registerFilter and are not prototype-chain-dependent, this behavioral change warrants verification that no template inadvertently relies on prototype resolution paths. (source link)

[6]: LiquidJS 10.27.0 introduced null-prototype scope frames via createScope. This changes internal scope initialization and may affect custom tag or filter implementations that inspect scope objects. The project's ifversion.js directly accesses ctx.environments.currentVersionObj inside its render generator, and data.js accesses scope.environments.currentLanguage — these patterns should be verified against the new scope behavior. (source link)

[7]: The custom ifversion tag (which extends Tag from liquidjs) accesses ctx.environments.currentVersionObj directly. The null-prototype scope frames introduced in 10.27.0 change how scope objects are internally initialized; this direct environment access pattern should be tested to ensure currentVersionObj is still accessible after the upgrade.

this.currentVersionObj = ctx.environments.currentVersionObj

[8]: The custom data tag accesses scope.environments.currentLanguage and scope.environments.currentLanguage directly in its render function. Like ifversion.js, this environment access pattern should be verified under the scope-frame changes in the new version.

let text = getDataByLanguage(this.path, scope.environments.currentLanguage)

[9]: This file uses hardcoded numeric value elem.kind === 4 to detect liquid tags (comment on line 214 explains this is the enum value for a liquid tag). Other files in the codebase use TokenKind.Tag by name. If the TokenKind enum values shift in a future release, this will fail silently. EdgeBit reports no symbol changes, so this is low risk now, but the pattern is fragile and merits attention.

.filter((elem) => elem.kind === 4)

[10]: Tokenizer is imported from liquidjs and used across five linting rules via tokenizer.readTopLevelTokens(). EdgeBit detected no API symbol changes, so this public API surface appears stable across the version range.

import { Tokenizer } from 'liquidjs'

[11]: new Liquid({ extname: '.html', dynamicPartials: false }) — no memoryLimit is configured, which means the extended memoryLimit enforcement added to pop, join, json, and inspect filters in 10.27.1–10.27.2 will not trigger in this deployment.

export const engine = new Liquid({

[12]: A Dependabot bump of liquidjs 10.20.1 → 10.27.2 in the ceph.io project showed no reported breakage in PR comments, suggesting the upgrade is routine for typical usage patterns. However, this project's usage is more complex with custom Tag subclasses and direct scope access. (source link)


fossabot analyzed this PR using static analysis, dependency research and AI. View this analysis on the web

@fossabot

fossabot Bot commented Sep 8, 2026 •

Copy link
Copy Markdown

fossabot is Thinking

@fossabot

fossabot Bot commented Sep 8, 2026 •

Copy link
Copy Markdown

fossabot is Thinking

@fossabot

fossabot Bot commented Sep 8, 2026 •

Copy link
Copy Markdown

No Issues

No application code changes were detected to scan. The PR contains only configuration files, documentation, or other non-code files.


fossabot analyzed this PR using SAST security analysis and AI (changed files only).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file javascript Pull requests that update javascript code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants