Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Hide secrets from `docker inspect` command (and commit, debug, etc.)

オープン
#676 コメント 0 件 リアクション 1 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
35/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
活発
技術スタック
docker, go
領域
security

調査の方向性

Start by reading the Docker secrets-engine documentation and tracing how se:// values are resolved into container environment variables; the issue does not name implementation files or tests. Investigate how resolved values reach inspectable container configuration and committed images, then define and test behavior that prevents secret values from persisting or being exposed while preserving the intended runtime use.

索引モデルが issue の本文から書いたものです。

説明

I understand this is beyond the scope of the secrets engine (which is primarily for guarding secrets access), but wanted to share my first impressions coming into docker pass, and I suspect other users.

My mental model was images get a se:// pointer, so secrets never get pushed to Hub. But the resolved secret value appears to be written back to disk, survive reference deletion and commited into image metadata.

Not sure what set my expectation. Probably secrets usage in cloud Sandboxes so 'credentials never enter the VM', or maybe 'you no longer need plaintext secrets on disk' in the readme, or 'secrets resolve just before the container starts' and 'the same reference can be reused across environments ... resolve against your local OS keychain in dev and against a prod vault in CI' in the docs docs made me think this was ephemeral runtime injection.

docker pass set db-password=supersecret123

cat > compose.yaml <<'EOF'
services:
  db:
    image: postgres:alpine
    environment:
      - POSTGRES_PASSWORD=se://db-password
EOF

docker compose up -d

docker inspect $(docker compose ps -q db) --format '{{json .Config.Env}}'
# ["POSTGRES_PASSWORD=supersecret123", ...]   <- plaintext secret stored on disk

docker pass rm db-password
docker commit $(docker compose ps -q db) db:snapshot
docker inspect db:snapshot --format '{{json .Config.Env}}'
# ["POSTGRES_PASSWORD=supersecret123", ...]    <- baked into any image you commit or push

Mostly concerned about accidental (agentic or otherwise) push/save, and anyone who pull/load the image reads the resolved secret value without access to the original keychain. Keeping the se:// reference in Config.Env would keep the value out of there but I doubt it's that trivial to solve.

Image
主要言語
Go
スター
95
フォーク
18
平均マージ
7時間 52分
マージ済み PR(30日)
31

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

docker/secrets-engine のほかの issue

docker/secrets-engine の issue をすべて見る

似ている issue

Go の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。