wire real kms plugin#2170
Conversation
|
Skipping CI for Draft Pull Request. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository: openshift/coderabbit/.coderabbit.yaml Review profile: CHILL Plan: Enterprise Run ID: ⛔ Files ignored due to path filters (4)
📒 Files selected for processing (1)
WalkthroughThis PR updates module resolution for github.com/openshift/library-go via a replace directive, switches two KMS e2e tests to use librarykms.DefaultVaultEncryptionProvider instead of the fake provider, and injects the KMS plugin as a static-pod sidecar in the kube-apiserver pod spec. ChangesKMS Vault Provider Update
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Suggested reviewers
🚥 Pre-merge checks | ✅ 13 | ❌ 2❌ Failed checks (2 warnings)
✅ Passed checks (13 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@go.mod`:
- Line 140: The replace directive in go.mod that points
github.com/openshift/library-go to a personal fork (the replace line using
github.com/gangwgr/library-go at pseudo-version 2ba893b1bf49) must be removed or
replaced with an approved, traceable alternative: either revert to the official
upstream module, or add a documented, temporary replace policy consisting of (1)
a brief justification and owner/trust approval in the PR description, (2) a
target upstream commit or fork provenance link and the fork commit SHA, (3) a
retire-by date and explicit plan to remove the replace, and (4) SBOM/provenance
and Sigstore/cosign signing attestations for artifacts that build with this
dependency; update go.sum and vendor/modules.txt accordingly and mention these
controls in the PR so reviewers can verify the provenance before merging.
In `@test/e2e-encryption-kms/encryption_kms.go`:
- Line 55: Update the scenario comments that refer to deploying a mock KMS to
reflect that the test now uses the real Vault provider: find the test
configuration where EncryptionProvider is set to
librarykms.DefaultVaultEncryptionProvider and replace any step text or comments
that say “Deploys the mock KMS plugin” (and similar occurrences around the
second instance near the other mention) with wording indicating the real Vault
provider is used (e.g., “Deploys/configures Vault KMS provider” or “Uses
DefaultVaultEncryptionProvider (Vault)”), keeping the comment meaning consistent
with the existing test setup.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository: openshift/coderabbit/.coderabbit.yaml
Review profile: CHILL
Plan: Enterprise
Run ID: cd85d0e5-b82e-4dda-a7c7-acbfb788131a
⛔ Files ignored due to path filters (4)
go.sumis excluded by!**/*.sumvendor/github.com/openshift/library-go/pkg/operator/certrotation/target.gois excluded by!**/vendor/**,!vendor/**vendor/github.com/openshift/library-go/test/library/encryption/kms/vault.gois excluded by!**/vendor/**,!vendor/**vendor/modules.txtis excluded by!**/vendor/**,!vendor/**
📒 Files selected for processing (2)
go.modtest/e2e-encryption-kms/encryption_kms.go
|
|
||
| replace github.com/onsi/ginkgo/v2 => github.com/openshift/onsi-ginkgo/v2 v2.6.1-0.20251001123353-fd5b1fb35db1 | ||
|
|
||
| replace github.com/openshift/library-go => github.com/gangwgr/library-go v0.0.0-20260529041857-2ba893b1bf49 |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
set -euo pipefail
# Confirm the exact replace directive committed in this PR
rg -n 'replace github.com/openshift/library-go' go.mod
# Verify the referenced commit exists in the fork
git ls-remote https://github.com/gangwgr/library-go | rg '2ba893b1bf49' || true
# Fetch commit metadata for audit trail (requires gh auth in sandbox)
gh api repos/gangwgr/library-go/commits/2ba893b1bf49 --jq '{sha: .sha, author: .commit.author, message: .commit.message}'Repository: openshift/cluster-kube-apiserver-operator
Length of output: 434
🏁 Script executed:
#!/bin/bash
set -euo pipefail
# Ensure go.sum is updated for the forked module
rg -n 'github\.com/gangwgr/library-go' go.sum || true
rg -n 'github\.com/openshift/library-go' go.sum || true
# Check whether the same commit exists upstream (to assess derivation/audit trail)
git ls-remote https://github.com/openshift/library-go | rg '2ba893b1bf49' || true
# Look for any PR/commit rationale documenting the temporary fork + retirement plan
rg -n 'library-go|gangwgr|replace github\.com/openshift/library-go' . || trueRepository: openshift/cluster-kube-apiserver-operator
Length of output: 50398
🏁 Script executed:
# Ensure the forked commit is traceable to upstream history (not just “exists” in the fork)
git ls-remote https://github.com/openshift/library-go | rg '2ba893b1bf49' || true
# Confirm go.sum + vendor are consistent with the replace (pinning)
rg -n 'github\.com/gangwgr/library-go v0\.0\.0-20260529041857-2ba893b1bf49' go.sum
rg -n 'github\.com/openshift/library-go v0\.0\.0-20260529041857-2ba893b1bf49.*gangwgr/library-go' vendor/modules.txtRepository: openshift/cluster-kube-apiserver-operator
Length of output: 526
🏁 Script executed:
# Confirm fork commit corresponds to an upstream change (same commit/PR/tag) rather than an unrelated fork delta
git ls-remote https://github.com/openshift/library-go | rg '2ba893b1bf49' || true
# Check for any repo/pipeline evidence of required SBOM/provenance + cosign signing coverage
rg -n '(cosign|sigstore|sbom|provenance|slsa)' . || trueRepository: openshift/cluster-kube-apiserver-operator
Length of output: 3386
🏁 Script executed:
# Prove upstream linkage (same SHA) or equivalent upstream PR/commit
git ls-remote https://github.com/openshift/library-go | rg '2ba893b1bf49' || true
# Check repo/CI for SBOM/provenance + signing (cosign/sigstore/rekor)
rg -n '(cosign|sigstore|rekor|sbom|provenance|slsa|attestations)' . || trueRepository: openshift/cluster-kube-apiserver-operator
Length of output: 7324
🏁 Script executed:
#!/bin/bash
set -euo pipefail
# Show the exact replace + pinned sums
rg -n 'replace github\.com/openshift/library-go' go.mod
rg -n 'github\.com/gangwgr/library-go v0\.0\.0-20260529041857-2ba893b1bf49' go.sum vendor/modules.txt
# Map fork commit to upstream history/PR (e.g., same SHA or upstream PR)
git ls-remote https://github.com/openshift/library-go | rg '2ba893b1bf49' || true
# Look for actual SBOM/provenance/signing controls (cosign/slsa/attestations), not just Rekor schema types
rg -n '(cosign|sigstore|sbom|provenance|slsa|attestation)' . || trueRepository: openshift/cluster-kube-apiserver-operator
Length of output: 4037
🏁 Script executed:
rg -n 'replace github\.com/openshift/library-go' go.mod
rg -n 'github\.com/gangwgr/library-go v0\.0\.0-20260529041857-2ba893b1bf49' go.sum vendor/modules.txt
git ls-remote https://github.com/openshift/library-go | rg '2ba893b1bf49' || true
rg -n '(cosign|sigstore|sbom|provenance|slsa|attest|rekor)' . || trueRepository: openshift/cluster-kube-apiserver-operator
Length of output: 10248
Supply-chain: block merging go.mod replace of github.com/openshift/library-go to a personal fork without provenance/retirement controls
go.mod line 140 redirects the dependency:
replace github.com/openshift/library-go => github.com/gangwgr/library-go v0.0.0-20260529041857-2ba893b1bf49The fork pseudo-version/commit are pinned in go.sum (h1 hashes) and reflected in vendor/modules.txt; the referenced commit 2ba893b1bf49a66e91d21713c7d34b99644f7f05 exists in the fork (refs/pull/2248/head). However, there’s no accompanying evidence here of required provenance controls per prodsec-skills:
- Upstream linkage/audit trail (how this fork commit relates to
openshift/library-go) - Owner trust + explicit temporary/retirement plan to remove the
replace - Confirmation that SBOM/provenance attestations and Sigstore/cosign signing cover the build/artifacts produced from this dependency
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@go.mod` at line 140, The replace directive in go.mod that points
github.com/openshift/library-go to a personal fork (the replace line using
github.com/gangwgr/library-go at pseudo-version 2ba893b1bf49) must be removed or
replaced with an approved, traceable alternative: either revert to the official
upstream module, or add a documented, temporary replace policy consisting of (1)
a brief justification and owner/trust approval in the PR description, (2) a
target upstream commit or fork provenance link and the fork commit SHA, (3) a
retire-by date and explicit plan to remove the replace, and (4) SBOM/provenance
and Sigstore/cosign signing attestations for artifacts that build with this
dependency; update go.sum and vendor/modules.txt accordingly and mention these
controls in the PR so reviewers can verify the provenance before merging.
|
/test e2e-gcp-operator-encryption-kms |
|
/test e2e-gcp-operator-encryption-kms |
|
/test e2e-gcp-operator-encryption-kms |
|
@gangwgr: The following test failed, say
Full PR test history. Your PR dashboard. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
Summary by CodeRabbit
Tests
Chores