lookout audit cluster
Cluster-level configuration posture, read from the cloud provider: Workload Identity off cluster-wide or bypassed by a node pool, node pools still serving the legacy metadata endpoints, a control-plane endpoint the internet can reach with nothing narrowing it, and a node pool whose autoscaler can never add a node. Reads the provider’s cluster record, not Kubernetes objects, so it takes no —namespace/-A/—workload; scanned counts the cluster plus its node pools. Without a provider capability it reports an explicit unavailable rather than silence.
MCP tool: k8s_audit_cluster (MCP profile: audit)
lookout audit cluster [flags]| Flag | Type | Default | Meaning |
|---|---|---|---|
--policy | string | — | path to a YAML posture policy file |
--profile | string | — | built-in posture profile: default|strict|onboarding|gke-autopilot |
--only | string | — | comma-separated check kind or kind/reason globs to run exclusively |
--skip | string | — | comma-separated check kind or kind/reason globs to skip |
--min-severity | string | — | minimum finding severity to emit: info|warning|critical |
--set | string | — | comma-separated check parameter overrides (<kind>.<param>=<val>) |
Common flags (every lookout command)
Section titled “Common flags (every lookout command)”| Flag | Type | Default | Meaning |
|---|---|---|---|
--namespace | string | — | limit the scan to one namespace |
-A | bool | — | scan all namespaces |
--workload | string | — | target one workload as <Kind>/<namespace>/<name>, e.g. Deployment/prod/api |
--since | duration | — | how far back to look (0 = command default) |
--format | string | logfmt | output format: logfmt|json (one record per line either way) |
--timeout | duration | 10s | abort the invocation after this long (exit 1) |
--kubeconfig | string | — | path to a kubeconfig file, instead of $KUBECONFIG / ~/.kube/config |
--kubeconfig-dir | string | — | directory of kubeconfig files to fan out across (mutually exclusive with —kubeconfig); each finding is stamped with cluster=<label> and the summary reports clusters=<n> |
--context | string | — | kubeconfig context to read, instead of its current-context. Selects a cluster for THIS invocation only — nothing is written back — so concurrent invocations can target different clusters. Reported as context=<name> in the summary line |
--contexts | string | — | comma-separated kubeconfig contexts to fan out across, or ’*’ for every context in the selected kubeconfig(s) (mutually exclusive with —context); each finding is stamped with cluster=<label> and the summary reports clusters=<n> |
--concurrency | int | 4 | maximum concurrent cluster executions when fanning out with —contexts or —kubeconfig-dir |
--google-auth | string | — | how Google Cloud and GKE DNS requests authenticate: auto (default: honors LOOKOUT_GOOGLE_AUTH, CORE_AGENT_GOOGLE_AUTH, MAST_GOOGLE_AUTH), adc, or injected (static placeholder bearer token, zero GCE metadata lookups) |
--exemptions | string | — | path to a git-reviewed exemption file (YAML); covered findings are ANNOTATED with their reason and expiry and counted as exempt=<n> in the summary, never dropped |
Finding kinds
Section titled “Finding kinds”Every kind= this command can emit, and the severities it carries them at. Nothing else appears in its output; a kind absent from a run means the check looked and found nothing. See the finding-kind glossary for the whole vocabulary.
| Kind | Severity | Claim |
|---|---|---|
audit.workload_identity_off | warning | Workload Identity is off cluster-wide, or a node pool bypasses it — pods authenticate to the cloud as the node |
audit.legacy_metadata | warning | a node pool still serves the pre-v1 instance-metadata endpoints, which any pod can read |
audit.public_control_plane | warning, info | the control-plane endpoint is reachable from the internet; info when authorized networks narrow it |
audit.nodepool_cannot_grow | warning | a node pool has autoscaling on with a maximum of 0 nodes: it can never hold a node, so a pod only it could host stays Pending forever |
audit.cluster_security_posture | warning, info | cluster-level security posture gap: Shielded Nodes disabled, Binary Authorization disabled, application-layer etcd secrets encryption disabled, or legacy ABAC enabled |
audit.cluster_network_posture | warning, info | cluster-level network posture gap: nodes carry public IPs, Dataplane V2 is disabled, or master global access is off on a private control-plane endpoint |
audit.cluster_observability_off | warning, info | cluster-level observability disabled: Cloud Logging, Cloud Monitoring, or Managed Service for Prometheus is turned off |
audit.cluster_backup_off | info | Backup for GKE addon is disabled on the cluster |
cloud.unavailable | info | the cloud capability this check needs is unavailable, so nothing was examined — an explicit degradation record, never silence |
Output fields
Section titled “Output fields”Beyond the shared envelope fields (kind, severity, namespace, kind_of_object, name, reason, message, fingerprint, exempt_reason, exempt_expires):
| Field | Meaning |
|---|---|
cluster | on a node-pool finding: the cluster the pool belongs to, so the record stands alone |
workload_pool | the cluster-wide workload identity pool that this node pool’s pods bypass |
metadata_mode | how the node pool exposes instance metadata to pods: node-identity means any pod can mint tokens for the node’s service account |
disable_legacy_endpoints | the pool’s legacy-metadata setting as the provider records it: enabled when someone turned the pre-v1 endpoints back on, unset when the pool was never configured either way |
node_pools | summary note: node pools examined — the cluster itself is the other unit scanned counts |
endpoint | the control plane’s internet-facing address |
authorized_networks | how many source ranges the allow-list permits |
authorized_network_cidrs | those ranges, sorted as the provider returned them and capped at 8 with a +N more tail |
gcp_public_cidrs | whether the provider’s own public ranges are admitted in addition to the allow-list |
capability | cloud.unavailable: the provider capability this command needed (cluster-config) |
provider | cloud.unavailable: the provider that was asked |
unavailable | summary-line note: why the cloud read could not be served |
Output contract
Section titled “Output contract”Output: one finding per line (logfmt; —format=json for one JSON object
per line), keys in fixed order; healthy resources emit nothing. The final
line is always the summary: scanned=
Examples
Section titled “Examples”lookout audit clusterlookout audit cluster --format=jsonlookout audit cluster --exemptions=exemptions.yaml