Skip to content

fix(helm): tighten readonly-access guards and grant /version - #66

Merged
tim-thacker-nullify merged 3 commits into
feat/helm-readonly-access-chartfrom
feat/helm-readonly-access-review
Sep 15, 2026
Merged

tim-thacker-nullify merged 3 commits into
feat/helm-readonly-access-chartfrom
feat/helm-readonly-access-review

Conversation

@tim-thacker-nullify

Copy link
Copy Markdown
Member

Claude

#61's guards let extraSubjects bind system:anonymous and extraRules add pods/exec, and a denied /version fails the strict scan.

Merge order: this into #61; #61 after #60 (see #60's fix PR).

  • F61-1: every subject kind is checked.
    • Names starting system: fail (trimmed, any case); groupName too.
    • Kinds limited to User, Group, ServiceAccount.
    • ServiceAccounts in kube-system, kube-public, kube-node-lease fail.
  • F61-2: extraRules rejects:
    • * in apiGroups or resources;
    • exec, attach, portforward, proxy, log subresources, so nodes/proxy, services/proxy and pods/log too (log added: README promises no log access);
    • nonResourceURLs other than /version.
  • F61-3: ClusterRole and raw manifest grant get on /version (collect.go:106-111); check-rbac-manifest.sh fails if either side drops it.
  • F61-4 chart README: Helm 3.2+ adopts the manifest objects via ownership label and annotations, replacing "delete first".
  • F61-4 egress IPs per region in chart README and NOTES; note says an API endpoint will serve them later.
  • F61-4 root README: comparison row drops the collector Namespace; grant line adds /version.
  • Tests: 8 must-fail cases (system User, kube-system SA, bad kind, pods/exec, nodes/proxy, * resource, * apiGroup, /metrics); ci/customised.yaml adds an SA subject and get deployments/scale.

Root README tree lines for pre-install-job.yaml are left to #63: both PRs edit them and conflict anyway.

Nothing rendered locally; CI runs lint, render, must-fail cases and the manifest diff.

🤖 Generated with Claude Code

tim-thacker-nullify and others added 3 commits September 15, 2026 02:11
…ra rules

- extraSubjects: any name starting "system:" (trimmed, case-insensitive)
  fails whatever its kind; kinds are limited to User, Group and
  ServiceAccount; ServiceAccounts in kube-system, kube-public and
  kube-node-lease fail.
- extraRules: reject wildcard apiGroups or resources, the exec, attach,
  portforward, proxy and log subresources, and nonResourceURLs other than
  /version.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
The strict managed scan records a ServerVersion() failure and fails the
cluster, so a cluster without the default system:public-info-viewer binding
could not be scanned. The raw manifest carries the same rule, and the
manifest check fails if either side drops it. NOTES lists the egress IPs.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
…ctor Namespace

- Helm 3.2+ adopts the manifest's objects once they carry Helm ownership
  metadata, so moving to Helm no longer needs a delete and a scan outage.
- List Nullify egress IPs per region for the EKS public endpoint.
- The collector no longer creates a Namespace (#63).

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@tim-thacker-nullify

Copy link
Copy Markdown
Member Author

Claude

Collapsed into #61 at e978621 after passing adversarial review; all of this PR's commits are now in #61. GitHub auto-marked this PR merged once the commits became reachable from its base branch feat/helm-readonly-access-chart — no merge to main occurred.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant