k8s-debug

Warn

Audited by Socket on Mar 4, 2026

1 alert found:

Security
SecurityMEDIUM
scripts/pod_diagnostics.py

The code is a kubectl-based diagnostic utility that gathers pod, container, and node information. It does not contain obvious backdoors, network-based exfiltration, or obfuscated malicious payloads, but it dangerously constructs shell commands with unvalidated, user-supplied pod and namespace values and uses subprocess.run(shell=True). This yields a high risk of shell command injection. Additionally, writing collected diagnostics to a user-specified file can lead to leakage or overwriting of sensitive files. Fixing requires removing shell=True, using argument lists, validating inputs, and restricting output paths. The provided snippet also contains syntax errors and would not execute as-is.

Confidence: 90%Severity: 70%
Audit Metadata
Analyzed At
Mar 4, 2026, 08:59 AM
Package URL
pkg:socket/skills-sh/akin-ozer%2Fcc-devops-skills%2Fk8s-debug%2F@102bb6dea0ae4cac75a8c69d5934dfb219e91992