Skip to content

fix(docker): pin Node.js to patched 24.22.1 for October 2026 CVEs - #2765

Open
nogara wants to merge 1 commit into
evolution-foundation:developfrom
nogara:fix/node-24.22.1-security-2761
Open

nogara wants to merge 1 commit into
evolution-foundation:developfrom
nogara:fix/node-24.22.1-security-2761

Conversation

@nogara

@nogara nogara commented Oct 23, 2026

Copy link
Copy Markdown

Summary

Addresses #2761.

Both Dockerfile stages (builder and final) used the floating node:24-alpine tag. Images built before the upstream base was refreshed stay on a Node.js release affected by the October 2026 security release, including CVE-2026-111497 (Brotli decoder out-of-bounds write). The Baileys media download path uses axios, whose Node HTTP adapter can decompress Brotli responses from external URLs.

This PR pins both stages to the patched Node.js 24 LTS image:

  • Tag: node:24.22.1-alpine3.24
  • Multi-arch index digest: sha256:06d7adf3e0ef61a13f1d28682726366f97a15aa1888c934d3ecec86c33918b53
    • covers linux/amd64 (sha256:1200d815…) and linux/arm64/v8 (sha256:398bcf38…)

A single NODE_IMAGE build arg defines the image, so both stages stay in sync. You can override it with --build-arg NODE_IMAGE=... when needed.

Notes for maintainers / operators

  • Pinning by digest means future Node.js patches need an explicit bump of NODE_IMAGE. This is intentional: builds become reproducible.
  • Operators need a new published image that includes this change. Running docker compose pull on existing tags does not update Node.js until a patched image is published.
  • After publishing, verify with: docker run --rm --entrypoint node <image> -v. The expected output is v24.22.1.

Not covered here (from the issue checklist)

  • Publishing the amd64/arm64 images and documenting digests. This needs release pipeline access.
  • Regression testing of pairing, media handling and webhooks on a real instance.
  • Auditing the npm dependencies in the lockfile.

Test plan

  • docker buildx build --platform linux/amd64,linux/arm64 . succeeds
  • node -v inside the built image reports v24.22.1
  • Container starts, runs migrations, and serves on 8080
  • WhatsApp QR pairing, media send/receive, and webhook delivery work

I did not build the image locally, because the Docker daemon was not available.

🤖 Generated with Claude Code

https://claude.ai/code/session_01CPViW4Kzn5aFydKQgfV3yq

Both builder and runtime stages used the floating node:24-alpine tag,
so images could be built on a Node.js release vulnerable to the
October 2026 security release issues (incl. CVE-2026-111497, Brotli
decoder OOB write). Pin both stages to node:24.22.1-alpine3.24 by
multi-arch index digest via a single NODE_IMAGE build arg.

Refs evolution-foundation#2761

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CPViW4Kzn5aFydKQgfV3yq
@nogara
nogara force-pushed the fix/node-24.22.1-security-2761 branch from fa78d0a to f698d12 Compare October 23, 2026 16:35
@nogara
nogara changed the base branch from main to develop October 23, 2026 16:35
nogara added a commit to nogara/evolution-api that referenced this pull request Oct 23, 2026
Both stages used the floating node:24-alpine tag, so an image built
before the base was refreshed keeps a Node.js release affected by the
October 2026 security release (including CVE-2026-111497, a Brotli
decoder out-of-bounds write reachable through axios media downloads).
Rebuilding an old commit could also pick a different Node.js than the
one it was tested on.

Pin both stages through one NODE_IMAGE build arg to
node:24.22.1-alpine3.24 at its multi-arch index digest (amd64 and
arm64). Bumping Node.js is now an explicit change, and
--build-arg NODE_IMAGE=... still allows an override.

Upstream: evolution-foundation#2761 / evolution-foundation#2765

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CPViW4Kzn5aFydKQgfV3yq
MatiasxVarela pushed a commit to purple-dice/evolution-in-purple that referenced this pull request Oct 23, 2026
Both stages used the floating node:24-alpine tag, so an image built
before the base was refreshed keeps a Node.js release affected by the
October 2026 security release (including CVE-2026-111497, a Brotli
decoder out-of-bounds write reachable through axios media downloads).
Rebuilding an old commit could also pick a different Node.js than the
one it was tested on.

Pin both stages through one NODE_IMAGE build arg to
node:24.22.1-alpine3.24 at its multi-arch index digest (amd64 and
arm64). Bumping Node.js is now an explicit change, and
--build-arg NODE_IMAGE=... still allows an override.

Upstream: evolution-foundation#2761 / evolution-foundation#2765

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CPViW4Kzn5aFydKQgfV3yq

This branch has not been deployed

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant