ci: a publish_snapshot.yml dry run still passes the Nexus secrets to the build
メンテナーはふだん 2 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 2/5
- 見積もり時間
- 1〜3時間
- 初心者へのやさしさ
- 74/100
調査の方向性
publish_snapshot.ymlを読み、Build and installステップの環境と、issueで説明されているdry_runの条件を調べてください。dry runと公開実行の両方でworkflowが認証情報をどのように扱うかを確認し、dry runではNexus secretsが公開されず、通常の公開では引き続きデプロイできることを確かめてください。両方の経路についてworkflowのdiffを確認してください。
索引モデルが issue の本文から書いたものです。
説明
What is the problem?
publish_snapshot.yml has a dry_run input that builds and verifies the jars without deploying them. A dry run skips the "Configure Maven server credentials" step and uses the install goal, but the Build and install step still sets both Nexus secrets in its environment:
- name: Build and ${{ inputs.dry_run && 'install' || 'deploy' }}
env:
NEXUS_USER: ${{ secrets.NEXUS_USER }}
NEXUS_PW: ${{ secrets.NEXUS_PW }}
GOAL: ${{ inputs.dry_run && 'install' || 'deploy' }}
So a dry run is not credential-free. Maven, its plugins and the build scripts they run can all read NEXUS_USER and NEXUS_PW, though a dry run never needs them.
This is hardening, not a known leak. The secrets are repository Actions secrets, and anyone with write access can already run a modified workflow that uses them. The point is that a run advertised as safe to try, and one that changes allows in a fork (if: github.repository == 'apache/datafusion-comet' || inputs.dry_run), should not carry the publishing credentials at all.
Proposal
Make a dry run credential-free. The smallest change is to leave the variables empty when dry_run is set:
NEXUS_USER: ${{ inputs.dry_run && '' || secrets.NEXUS_USER }}
NEXUS_PW: ${{ inputs.dry_run && '' || secrets.NEXUS_PW }}
A stronger form builds and verifies the jars in one job with no secrets, uploads them, and deploys from a second job that has the secrets and runs only deploy on the verified output. That also keeps the credentials away from the five-variant clean and compile loop in a real run.
Raised in review of #7311, which does not touch this file.
- 主要言語
- Scala
- スター
- 1.3k
- フォーク
- 398
- 平均マージ
- 3日 4時間
- マージ済み PR(30日)
- 363
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
apache/datafusion-comet のほかの issue
-
area:ci bug priority:low requires-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
apache/datafusion-comet#7315 ·
メンテナーはふだん 2 日以内に返信
-
requires-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
apache/datafusion-comet#7240 ·
メンテナーはふだん 2 日以内に返信
-
bug priority:low
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
apache/datafusion-comet#7176 ·
メンテナーはふだん 2 日以内に返信
-
docs: update Scala comments that reference the removed iceberg-writes.md page対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープンenhancement
難易度 1/5 1〜3時間 初心者へのやさしさ 83/100
apache/datafusion-comet#7101 ·
メンテナーはふだん 2 日以内に返信
-
requires-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
apache/datafusion-comet#7001 ·
メンテナーはふだん 2 日以内に返信
apache/datafusion-comet の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
lichess-org/lila#22324 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
Users who join a new meeting at the same moment: one sometimes gets "Ops, something went wrong" because bbb-web drops their registration (race on `Meeting.userCustomData`)対応中かも @antobinary が今日担当しました。 オープンmodule: core
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
bigbluebutton/bigbluebutton#26318 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 73/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
canton-network/splice#8087 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信