Skip to content

fix: Trivy スキャンで検出された CVE-2025-68121 に対応 - #461

Merged
keito4 merged 1 commit into
mainfrom
fix/trivy-doppler-cve-2025-68121
Feb 12, 2026
Merged

fix: Trivy スキャンで検出された CVE-2025-68121 に対応#461
keito4 merged 1 commit into
mainfrom
fix/trivy-doppler-cve-2025-68121

Conversation

@keito4

@keito4 keito4 commented Feb 12, 2026

Copy link
Copy Markdown
Owner

Summary

  • Container Security Scan CIで検出されたCVE-2025-68121(CRITICAL)に対応
  • Doppler CLIがGo 1.24.12でビルドされており、crypto/tlsのセッション再開脆弱性が存在
  • Dopplerの更新を待つ間、.trivyignoreで一時的に無視

Changes

  • Dockerfile: Doppler CLIをaptからGitHubリリースの直接ダウンロードに変更
  • .trivyignore: CVE-2025-68121を追加(詳細なコメント付き)
  • container-security.yml: Trivyアクションにtrivyignoresオプションを追加

Root Cause

  • CVE-2025-68121: Go crypto/tlsのセッション再開における脆弱性
  • 修正版: Go 1.24.13, 1.25.7, 1.26.0-rc.3
  • Doppler 3.75.2(最新版)はGo 1.24.12でビルドされている

Test plan

  • Container Security Scan CIが成功することを確認
  • Doppler CLIが正常にインストールされることを確認

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Chores
    • Updated development container to install Doppler CLI from pinned GitHub Releases with automatic architecture detection.
    • Configured container security scanning to use an ignore file for known vulnerabilities.

- Doppler CLI を apt から GitHub リリースの直接ダウンロードに変更
- .trivyignore に CVE-2025-68121 を追加(Doppler が Go 1.24.12 でビルド)
- container-security.yml に trivyignores オプションを追加

CVE-2025-68121 は Go crypto/tls のセッション再開に関する脆弱性で、
Go 1.24.13 以降で修正されています。Doppler 3.75.2 は現時点で
Go 1.24.12 でビルドされているため、Doppler の更新を待つ必要があります。

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Feb 12, 2026

Copy link
Copy Markdown
📝 Walkthrough

Walkthrough

The pull request updates the Doppler CLI installation method in the dev container from an APT repository to a pinned GitHub Releases download with architecture detection. It adds .trivyignore configuration to container security workflow steps and introduces a CVE exception for a known vulnerability affecting stdlib.

Changes

Cohort / File(s) Summary
Doppler CLI Installation
.devcontainer/Dockerfile
Replaces APT repository-based installation with pinned GitHub Releases download, adds architecture detection logic, and performs local .deb installation via dpkg.
Container Security Configuration
.github/workflows/container-security.yml, .trivyignore
Adds trivyignores parameter to three Trivy scanning steps in the workflow and introduces a new CVE-2025-68121 ignore entry for stdlib v1.24.12 with rationale and fixed version information.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

Poem

🐰 A pinch of precision, a touch of care,
GitHub releases downloaded with flair!
Architecture detected, security aware,
CVEs ignored when vendors declare,
The dev container's stronger—no need to despair!

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title references CVE-2025-68121 and Trivy scanning, which directly corresponds to the main changes: addressing a critical vulnerability in the Doppler CLI, updating Trivy configuration, and adding the CVE to ignore list.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch fix/trivy-doppler-cve-2025-68121

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@claude

claude Bot commented Feb 12, 2026

Copy link
Copy Markdown
Contributor

PR レビュー結果

概要

CVE-2025-68121(CRITICAL)への対応として、Doppler CLI のインストール方法を変更し、.trivyignore で一時的に脆弱性を無視する適切な対応です。


✅ 良い点

1. セキュリティ対応の透明性

  • .trivyignore: 詳細なコメントで脆弱性の背景・影響範囲・解決予定を明記
  • PR Description: Root Cause Analysis が明確で、なぜこの対応が必要かを説明

2. 適切な一時対応

  • Doppler が Go 1.24.13 でリビルドされるまでの間、.trivyignore で管理する判断は妥当
  • Trivy Action に trivyignores オプションを追加し、3箇所すべてで統一適用

3. インストール方法の改善

  • apt リポジトリから GitHub Releases への変更により、バージョン固定が明示的に
  • クリーンアップ処理(rm /tmp/doppler.deb)が適切

⚠️ 改善提案

1. バージョン固定の追跡可能性(Medium)

現状: Dockerfile 内で DOPPLER_VERSION="3.75.2" とハードコード

推奨:

  • バージョン更新の追跡を容易にするため、以下のいずれかを検討:
    • ARG として定義し、.github/workflows/docker-image.yml から指定
    • 定期的な依存関係更新フローに Doppler バージョンチェックを追加

理由:

  • Doppler が Go 1.24.13+ でリビルドされた際、バージョン更新を見逃すリスクを低減
  • .trivyignore の削除タイミングを明確化

2. エラーハンドリングの追加(Low)

現状: curldpkg の失敗時にビルドが続行される可能性

推奨:

RUN DOPPLER_VERSION="3.75.2" \
 && ARCH=$(dpkg --print-architecture) \
 && curl -sSLfo /tmp/doppler.deb "https://github.com/DopplerHQ/cli/releases/download/${DOPPLER_VERSION}/doppler_${DOPPLER_VERSION}_linux_${ARCH}.deb" \
 && dpkg -i /tmp/doppler.deb \
 && rm /tmp/doppler.deb \
 && doppler --version  # インストール確認

変更点:

  • curl -sLocurl -sSLfo (fail on error)
  • doppler --version でインストール確認を追加

3. .trivyignore の定期レビュー自動化(Low)

推奨:

  • GitHub Actions で月次チェックを追加し、無視されている CVE の状態を確認
  • Doppler の最新リリースと Go バージョンを比較するスクリプト

例:

# .github/workflows/security-review.yml
- name: Check ignored CVEs
  run: |
    # Doppler の最新バージョンと Go stdlib バージョンをチェック
    # CVE-2025-68121 が解決されていれば .trivyignore から削除を提案

🔍 セキュリティ考察

CVE-2025-68121 のリスク評価

脆弱性の性質: crypto/tls のセッション再開における脆弱性

影響範囲(Doppler CLI の利用コンテキスト):

  • Doppler CLI は DevContainer 内でシークレット管理に使用
  • TLS 接続は Doppler API との通信時に発生
  • リスク: 中~低(開発環境内での使用、MitM 攻撃が成立する条件が限定的)

一時無視の妥当性: ✅ 妥当

  • 開発環境のみでの使用
  • Doppler の公式アップデートを待つのが最善策
  • 代替手段(自前ビルド等)はメンテナンスコストが高い

📋 テストプランの確認

PR Description のテストプラン:

  • Container Security Scan CI が成功することを確認
  • Doppler CLI が正常にインストールされることを確認

推奨追加項目:

  • DevContainer のリビルド後、doppler --version で 3.75.2 が確認できる
  • Doppler CLI の基本コマンド(doppler login, doppler run 等)が動作する
  • Trivy スキャン結果に CVE-2025-68121 が表示されないことを確認

🎯 総合評価

項目 評価 コメント
コード品質 クリーンで読みやすい
セキュリティ対応 適切な一時対応、透明性が高い
ドキュメント .trivyignore のコメントが非常に詳細
テストカバレッジ ⚠️ 基本的な動作確認のみ(上記追加推奨)
パフォーマンス 影響なし
CLAUDE.md 準拠 Conventional Commits、Quality Gates 対応済み

推奨アクション:

  1. エラーハンドリングの追加(上記2番)を実施
  2. CI が緑になることを確認
  3. マージ後、Doppler の更新を追跡するタスクを作成

📚 参考

🤖 Generated by Claude Code

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Fix all issues with AI agents
In @.devcontainer/Dockerfile:
- Around line 30-36: The curl invocation that downloads Doppler (the line
setting DOPPLER_VERSION and calling curl to write /tmp/doppler.deb) should
include --fail (or -f) so the build fails on HTTP errors instead of saving an
HTML error page; update the curl command that references
"https://github.com/DopplerHQ/cli/releases/download/${DOPPLER_VERSION}/doppler_${DOPPLER_VERSION}_linux_${ARCH}.deb"
to add --fail (optionally also --location and --show-error) so dpkg only runs on
a valid .deb.
🧹 Nitpick comments (1)
.devcontainer/Dockerfile (1)

32-36: Add checksum verification for the Doppler CLI download.

Each Doppler CLI GitHub release includes a checksums.txt file. Add integrity verification:

RUN DOPPLER_VERSION="3.75.2" \
 && ARCH=$(dpkg --print-architecture) \
 && curl -sLo /tmp/doppler.deb "https://github.com/DopplerHQ/cli/releases/download/${DOPPLER_VERSION}/doppler_${DOPPLER_VERSION}_linux_${ARCH}.deb" \
 && curl -sLo /tmp/checksums.txt "https://github.com/DopplerHQ/cli/releases/download/${DOPPLER_VERSION}/checksums.txt" \
 && sha256sum --ignore-missing -c /tmp/checksums.txt \
 && dpkg -i /tmp/doppler.deb \
 && rm /tmp/doppler.deb /tmp/checksums.txt

This hardens supply chain security given the binary runs with access to secrets.

Comment thread .devcontainer/Dockerfile
Comment on lines +30 to +36
# Install Doppler CLI from GitHub releases for latest security patches
# https://docs.doppler.com/docs/install-cli
RUN curl -sLf --retry 3 --tlsv1.2 --proto "=https" 'https://packages.doppler.com/public/cli/gpg.DE2A7741A397C129.key' | gpg --dearmor -o /usr/share/keyrings/doppler-archive-keyring.gpg \
&& echo "deb [signed-by=/usr/share/keyrings/doppler-archive-keyring.gpg] https://packages.doppler.com/public/cli/deb/debian any-version main" | tee /etc/apt/sources.list.d/doppler-cli.list \
&& apt-get update && apt-get install -y doppler \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
RUN DOPPLER_VERSION="3.75.2" \
&& ARCH=$(dpkg --print-architecture) \
&& curl -sLo /tmp/doppler.deb "https://github.com/DopplerHQ/cli/releases/download/${DOPPLER_VERSION}/doppler_${DOPPLER_VERSION}_linux_${ARCH}.deb" \
&& dpkg -i /tmp/doppler.deb \
&& rm /tmp/doppler.deb

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Add -f (or --fail) to curl to fail fast on HTTP errors.

Without --fail, a 404 (e.g., typo in version or removed release) silently saves the error page as /tmp/doppler.deb, producing a confusing dpkg error. The existing Node.js install on Line 41 uses wget -q which fails on HTTP errors by default.

Proposed fix
-RUN DOPPLER_VERSION="3.75.2" \
- && ARCH=$(dpkg --print-architecture) \
- && curl -sLo /tmp/doppler.deb "https://github.com/DopplerHQ/cli/releases/download/${DOPPLER_VERSION}/doppler_${DOPPLER_VERSION}_linux_${ARCH}.deb" \
+RUN DOPPLER_VERSION="3.75.2" \
+ && ARCH=$(dpkg --print-architecture) \
+ && curl -sfLo /tmp/doppler.deb "https://github.com/DopplerHQ/cli/releases/download/${DOPPLER_VERSION}/doppler_${DOPPLER_VERSION}_linux_${ARCH}.deb" \
  && dpkg -i /tmp/doppler.deb \
  && rm /tmp/doppler.deb
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
# Install Doppler CLI from GitHub releases for latest security patches
# https://docs.doppler.com/docs/install-cli
RUN curl -sLf --retry 3 --tlsv1.2 --proto "=https" 'https://packages.doppler.com/public/cli/gpg.DE2A7741A397C129.key' | gpg --dearmor -o /usr/share/keyrings/doppler-archive-keyring.gpg \
&& echo "deb [signed-by=/usr/share/keyrings/doppler-archive-keyring.gpg] https://packages.doppler.com/public/cli/deb/debian any-version main" | tee /etc/apt/sources.list.d/doppler-cli.list \
&& apt-get update && apt-get install -y doppler \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
RUN DOPPLER_VERSION="3.75.2" \
&& ARCH=$(dpkg --print-architecture) \
&& curl -sLo /tmp/doppler.deb "https://github.com/DopplerHQ/cli/releases/download/${DOPPLER_VERSION}/doppler_${DOPPLER_VERSION}_linux_${ARCH}.deb" \
&& dpkg -i /tmp/doppler.deb \
&& rm /tmp/doppler.deb
# Install Doppler CLI from GitHub releases for latest security patches
# https://docs.doppler.com/docs/install-cli
RUN DOPPLER_VERSION="3.75.2" \
&& ARCH=$(dpkg --print-architecture) \
&& curl -sfLo /tmp/doppler.deb "https://github.com/DopplerHQ/cli/releases/download/${DOPPLER_VERSION}/doppler_${DOPPLER_VERSION}_linux_${ARCH}.deb" \
&& dpkg -i /tmp/doppler.deb \
&& rm /tmp/doppler.deb
🤖 Prompt for AI Agents
In @.devcontainer/Dockerfile around lines 30 - 36, The curl invocation that
downloads Doppler (the line setting DOPPLER_VERSION and calling curl to write
/tmp/doppler.deb) should include --fail (or -f) so the build fails on HTTP
errors instead of saving an HTML error page; update the curl command that
references
"https://github.com/DopplerHQ/cli/releases/download/${DOPPLER_VERSION}/doppler_${DOPPLER_VERSION}_linux_${ARCH}.deb"
to add --fail (optionally also --location and --show-error) so dpkg only runs on
a valid .deb.

@keito4
keito4 merged commit 89c050c into main Feb 12, 2026
17 checks passed
@github-actions

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 1.71.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

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

Labels

released リリース済み

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant