Skip to content

Commit 44c3d2f

Browse files
dpark01claude
andcommitted
Apply Ruby json gem fix to phylo and mega Dockerfiles
The Ruby json gem (CVE-2026-33210) enters via mummer4 → yaggo → ruby, not just sequip. Since phylo and mega build independently from core (not from assemble), they each need the same fix: remove the old bundled default json gem and install >=2.19.2. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent fe939b2 commit 44c3d2f

File tree

3 files changed

+18
-8
lines changed

3 files changed

+18
-8
lines changed

docker/Dockerfile.assemble

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,8 @@ COPY docker/install-conda-deps.sh /tmp/
3030
# All files resolved together in single micromamba call; x86-only files skipped on ARM
3131
# Post-install fixups (inline so vulnerable files never appear in a committed layer):
3232
# - mafft's dash_client: Go 1.22.1 binary with Go stdlib CVEs; we never use --dash mode
33-
# - Ruby json gem: sequip pulls in Ruby, whose bundled json gem has CVE-2026-33210;
34-
# remove the old default gem and install patched version (>=2.19.2)
33+
# - Ruby json gem: mummer4/sequip pull in Ruby (via yaggo), whose bundled json gem
34+
# has CVE-2026-33210; remove the old default gem and install patched version (>=2.19.2)
3535
RUN /tmp/install-conda-deps.sh /tmp/requirements/baseimage.txt /tmp/requirements/core.txt /tmp/requirements/assemble.txt \
3636
--x86-only:/tmp/requirements/assemble-x86.txt && \
3737
rm -f /opt/conda/libexec/mafft/dash_client && \

docker/Dockerfile.mega

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,13 +25,18 @@ COPY docker/install-conda-deps.sh /tmp/
2525

2626
# Install ALL conda dependencies in single resolver call for proper dependency resolution
2727
# All files resolved together; x86-only files skipped on ARM
28-
# Remove mafft's dash_client (Go 1.22.1 binary with 11 Go stdlib CVEs) — we
29-
# never use --dash mode; delete inline so it never appears in any layer.
28+
# Post-install fixups (inline so vulnerable files never appear in a committed layer):
29+
# - mafft's dash_client: Go 1.22.1 binary with Go stdlib CVEs; we never use --dash mode
30+
# - Ruby json gem: mummer4 → yaggo → Ruby, whose bundled json gem has CVE-2026-33210;
31+
# remove the old default gem and install patched version (>=2.19.2)
3032
RUN /tmp/install-conda-deps.sh /tmp/requirements/baseimage.txt /tmp/requirements/core.txt /tmp/requirements/assemble.txt /tmp/requirements/classify.txt /tmp/requirements/phylo.txt \
3133
--x86-only:/tmp/requirements/assemble-x86.txt \
3234
--x86-only:/tmp/requirements/classify-x86.txt \
3335
--x86-only:/tmp/requirements/phylo-x86.txt && \
34-
rm -f /opt/conda/libexec/mafft/dash_client
36+
rm -f /opt/conda/libexec/mafft/dash_client && \
37+
find /opt/conda/lib/ruby -maxdepth 3 -name 'json*' -not -path '*/psych/*' -exec rm -rf {} + && \
38+
rm -f /opt/conda/lib/ruby/gems/*/specifications/default/json-*.gemspec && \
39+
gem install json --version '>=2.19.2' --no-document
3540

3641
# Copy source code (includes all modules)
3742
COPY src/ /opt/viral-ngs/source/src/

docker/Dockerfile.phylo

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,16 @@ COPY docker/install-conda-deps.sh /tmp/
2525

2626
# Install conda dependencies (phylo tools)
2727
# All files resolved together in single micromamba call; x86-only files skipped on ARM
28-
# Remove mafft's dash_client (Go 1.22.1 binary with 11 Go stdlib CVEs) — we
29-
# never use --dash mode; delete inline so it never appears in any layer.
28+
# Post-install fixups (inline so vulnerable files never appear in a committed layer):
29+
# - mafft's dash_client: Go 1.22.1 binary with Go stdlib CVEs; we never use --dash mode
30+
# - Ruby json gem: mummer4 pulls in yaggo → Ruby, whose bundled json gem has
31+
# CVE-2026-33210; remove the old default gem and install patched version (>=2.19.2)
3032
RUN /tmp/install-conda-deps.sh /tmp/requirements/baseimage.txt /tmp/requirements/core.txt /tmp/requirements/phylo.txt \
3133
--x86-only:/tmp/requirements/phylo-x86.txt && \
32-
rm -f /opt/conda/libexec/mafft/dash_client
34+
rm -f /opt/conda/libexec/mafft/dash_client && \
35+
find /opt/conda/lib/ruby -maxdepth 3 -name 'json*' -not -path '*/psych/*' -exec rm -rf {} + && \
36+
rm -f /opt/conda/lib/ruby/gems/*/specifications/default/json-*.gemspec && \
37+
gem install json --version '>=2.19.2' --no-document
3338

3439
# Copy source code (includes phylo module)
3540
COPY src/ /opt/viral-ngs/source/src/

0 commit comments

Comments
 (0)