Files
management/docs/issues/0090-gitops-59-kein-kubernetes-audit-log-zugriffe-an-der-api.md
Thore CimbalandClaude Opus 5 a1def8666e feat(issues): adopt the component trackers — one backlog, one numbering (ADR-0019)
ADR-0012 made docs/issues/ canonical for the management scope only and left
gitops, ThreadNet-Web and threadnet-call on GitLab "until the component adopts".
That split produced exactly what it invited: two numbering worlds where
management#20 and gitops#20 are different issues, drift nobody had to answer for
(gitops#61 carried no milestone since 2026-08-11), and component backlogs that
host sessions without lab access cannot read at all.

The 46 open component issues are now files 0056-0101. The file id is the
group-wide identifier; provenance lives in the frontmatter (new field `projekt`
plus gitlab_iid) and in the filename, so "gitops#61" still finds 0091. Bodies are
copied verbatim; comments and history stay on GitLab, as with the 2026-08-11
management import.

Both scripts learned the second dimension: spiegel_issues.py routes each file to
its origin project, reopens issues that are open in the repo but closed on the
board, and writes the new iid back after creating one; gruppenpruefung.py checks
drift across all four trackers instead of management alone. What the mirror
cannot decide stays a finding, not a silent state.

Two things needed a hand, both recorded in the files: gitops#61 had no milestone
(M1 - it is a live account-takeover path) and carried two area labels where the
schema holds one. The Gitea migration footers in the imported bodies point at
decommissioned trackers; their links are removed, the provenance sentence stays.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-18 12:00:00 +00:00

35 lines
1.9 KiB
Markdown

---
type: issue
id: "0090"
status: open
created: 2026-08-06
milestone: M5
priority: low
projekt: gitops
gitlab_iid: "59"
related: []
---
# Kein Kubernetes-Audit-Log — Zugriffe an der API werden nicht protokolliert
> Adoptiert aus [gitops#59](https://git.lab/axion1337.chat/axion1337.chat-gitops/-/issues/59) (2026-08-18, ADR-0019). Kommentare und Verlauf bleiben dort; kanonisch ist ab jetzt diese Datei.
`auditd` (gitops#26) protokolliert Dateizugriffe und Syscalls **auf dem Host**. Was jemand über die **Kubernetes-API** getan hat — Secret gelesen, Deployment geändert, in einen Pod exec-t — steht dort nicht. Dafür gibt es das Audit-Log des API-Servers, und das ist bei uns nicht konfiguriert.
## Warum das gerade hier fehlt
Zwei Dinge treffen zusammen:
- **ADR-0008** hält fest, dass Agenten-Sessions auf CFGMON root-äquivalent über die docker-Gruppe laufen und dabei **keinen Eintrag in `auth.log`** hinterlassen. Die ADR nennt als Ersatz ausdrücklich Git-Historie, Issues und AARs.
- Im Cluster gibt es dieselbe Lücke eine Ebene höher: Wer `kubectl` benutzt, hinterlässt nichts.
Solange alles über Flux und Git läuft, ist die Git-Historie tatsächlich das Protokoll. Der Punkt ist der Zugriff **daneben** — und genau der ist heute unsichtbar.
## Was zu tun ist
1. Audit-Policy schreiben (K3s: `--kube-apiserver-arg=audit-policy-file=…` plus `audit-log-path`). ⚠️ Das ist eine **Host-Änderung am K3s-Dienst**, kein Flux-Objekt — gehört zu `host-config/`.
2. Auf `Metadata` als Grundstufe beginnen und Secret-Zugriffe auf `RequestResponse` heben. Alles auf `RequestResponse` erzeugt riesige Logs **und schreibt Secret-Inhalte im Klartext ins Protokoll** — genau das nicht tun.
3. Über Alloy nach Loki einsammeln, damit es nicht nur auf der Platte liegt.
4. Sinnvoll zusammen mit gitops#25 (K3s API Hardening) — dieselbe Datei, derselbe Neustart.
*Gefunden am 2026-08-06 bei einer Bestandsaufnahme der Sicherheitslage.*