Back to Featured Skills

k8s-manifest-security-auditor

guangyusong
guangyusong
Enterprise-skills

Lint Kubernetes YAML manifests for security and reliability risks (privileged, hostNetwork/hostPID/hostIPC, hostPath, runAsNonRoot, allowPrivilegeEscalation, missing limits, latest tag).


Install Command

npx skills add https://github.com/XSpoonAi/spoon-awesome-skill/tree/master/enterprise-skills/k8s-manifest-security-auditor

Content

4 files
Skill.md
1.5 KB
enterprise-skills
k8s-manifest-security-auditor
SKILL.md
requirements.txt
scripts
main.py

Skill.md

/ Read Only

Kubernetes Manifest Security Auditor

Static analysis for Kubernetes YAML manifests to catch common security and reliability risks (no cluster access required).

Overview

This skill parses Kubernetes multi-document YAML and emits a deterministic JSON report with findings ranked by severity.

Features

  • Flags privileged containers
  • Flags host namespace sharing (hostNetwork, hostPID, hostIPC)
  • Flags hostPath volumes
  • Flags missing runAsNonRoot: true
  • Flags missing allowPrivilegeEscalation: false
  • Flags missing resource requests/limits
  • Flags :latest or missing image tags

Quickstart

python3 -m pip install -r requirements.txt # Demo python3 scripts/main.py --demo # Audit a file python3 scripts/main.py --params '{"manifest_path":"./k8s.yaml","ruleset":"restricted"}'

Parameters

NameTypeRequiredDescription
manifests_yamlstringnoMulti-doc YAML string
manifest_pathstringnoPath to a YAML file
rulesetstringnobaseline or restricted (default: baseline)
max_findingsintnoMaximum findings to return (default: 200)

Example Output (Short)

{"ok":true,"data":{"risk_level":"CRITICAL","findings":[{"rule_id":"SEC_PRIVILEGED"}]}}

Demo Screenshot

Demo output

Installations

297

Skills Information

Created
2026-02-13
Last Updated
2026-03-23