Scope down container permissions further to reduce attack surface #3130
[APPROVALNOTIFIER] This PR is NOT APPROVED
This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign mdzraf for approval. For more information see the Code Review Process.
The full list of commands accepted by this bot can be found here.
<details open>
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment
</details>
<!-- META={"approvers":["mdzraf"]} -->
/hold
/unhold
Thoughts on adding a helm-template test that renders with all sidecars enabled and fails if any container other than ebs-plugin and metadata-labeler is missing from the annotation? this would prevent a future sidecar silently getting IRSA/Pod Identity credentials if it doesnt need it.
/lgtm
/lgtm +1 to eddies comment on helm-template test
Not a bad idea, I'll add in rev2
/test pull-aws-ebs-csi-driver-test-e2e-external-windows-hostprocess
ElijahQuinones
ConnorJC3
What type of PR is this?
<!--
Add one of the following kinds:
/kind bug
/kind cleanup
/kind documentation
/kind feature
-->
/kind cleanup
What is this PR about? / Why do we need it?
Scope down permissions and reduce attack surface further as part of our investigation into https://github.com/aws/containers-roadmap/issues/2713
eks.amazonaws.com/skip-containersannotation for non-driver containers. This prevents pod identity and IRSA from injecting credentials into those containers (docs ref)seccompProfilewhich was missing on some sidecarsprobeDirVolume(this was used for the exec-basednode-driver-registrarprobe we replaced with a gRPC based solution many releases ago). This is technically a super minor breaking change, it removes a parameter that was effectively a no-op.How was this change tested?
Manually ran all relevant E2E tests, including those our CI doesn't normally run (e.g. windows hostprocess, older windows server versions).
Does this PR introduce a user-facing change?
<!--
If no, just write "NONE" in the release-note block below.
If yes, enter your extended release note in the block below.
-->
``
release-notenode.probeDirVolumeIMPORTANT - for release owner - need to add "must read" section (copy it from previous changelog entries) and include some wording like below (this part should be in the Helm-only changelog):
Helm parameter
has been removed. If you were customizing this parameter, remove it from your configuration before installing or upgrading.node.probeDirVolumeenabled customizing theemptyDirvolume used for the previous exec-basednode-driver-registrarprobe. The exec-based probe is no longer used, and the parameter has been an effective no-op for several driver releases.``Scope down container permissions and reduce attack surface.