Sponsor Suno AI Music arrow_forward
Slash Command

Docker Security Scan

Scans Docker containers and images for security vulnerabilities

Type
Slash Command
GitHub stars
2.8k
License
MIT
Repo last updated
Sep 27, 2026

What Docker Security Scan is

Docker Security Scan is a slash command published in the jeremylongshore/tons-of-skills-marketplace repository on GitHub, which has about 2.8k stars. The repository describes itself as: “Model-agnostic agent-skills platform with a harness-free canonical layer, verified adapters, and the ccpi package manager. Explore at tonsofskills.com.”

A slash command is a reusable prompt saved as a markdown file and run by typing its name after a slash. In Claude Code, custom commands have been merged into skills: a file in .claude/commands/ and a skill folder in .claude/skills/ both create the same kind of command, and existing command files keep working.

Docker Security Scan gives you a repeatable way to run the same instructions without retyping them, optionally with arguments.

How to install Docker Security Scan

Claude Code

  1. Download docker-security-scan.md from the repository.
  2. Save it to ~/.claude/commands/ (all projects) or .claude/commands/ (one project). As a skill, you can instead save it as ~/.claude/skills/<name>/SKILL.md.
  3. Run it by typing / followed by its name.

Claude Cowork

  1. Turn the command into a skill: create a folder with the file saved as SKILL.md and zip it.
  2. In Customize → Skills, click +, then upload the ZIP.
  3. Run it from any task with / and the skill name.

New to extending Cowork? Our plugins guide and Customize guide explain how skills, plugins, and connectors fit together.

Inside the source file

An excerpt from plugins/packages/security-pro-pack/plugins/04-infrastructure-security/commands/docker-security-scan.md, shared under the repository's MIT license. Read the full file on GitHub.

Comprehensively scans Docker containers and images for vulnerabilities, misconfigurations, and security best practices violations. Identifies CVEs in base images and dependencies, insecure configurations, exposed secrets, and privilege escalation risks.

What This Command Does

Complete Container Security Analysis:

  • Scans images for known CVEs (vulnerabilities in OS packages and dependencies)
  • Detects insecure Dockerfile configurations
  • Identifies exposed secrets (API keys, passwords, tokens)
  • Checks for privileged containers and excessive permissions
  • Validates security best practices (non-root user, minimal base image)
  • Analyzes running containers for runtime security issues

Output: Detailed security report with severity-rated findings and remediation steps

Time: 5-10 minutes per image/container

When to Use This Command

Perfect For:

  • Pre-deployment container security validation
  • CI/CD pipeline security gates
  • Production container audits
  • Kubernetes pod security review
  • Docker Compose security assessment

Use This When:

  • Building new container images
  • Before deploying to production
  • After updating base images
  • Regular security audits (weekly/monthly)
  • Investigating security incidents

Usage

# Scan a Docker image
/docker-security-scan myapp:latest

# Scan running container
/docker-security-scan --container myapp-prod

# Scan all images
/docker-security-scan --all-images

# Scan with detailed output
/docker-security-scan myapp:latest --verbose

# Scan and generate report
/docker-security-scan myapp:latest --output report.md

Shortcut:

/dss myapp:latest  # Quick scan

What Gets Scanned

1. Image Vulnerabilities (CVEs)

Scans For:

  • Operating system package vulnerabilities
  • Application dependency vulnerabilities
  • Known exploits in installed software
  • Outdated packages with security patches available

Example Findings:

 CRITICAL: CVE-2024-12345 in openssl
Package: openssl 1.1.1k
Severity: Critical (CVSS 9.8)
Impact: Remote code execution via crafted TLS handshake
Fixed in: openssl 1.1.1w

Remediation:
FROM ubuntu:22.04  # Update base image
RUN apt-get update && apt-get upgrade -y openssl

Example Output:

Image: myapp:latest
Base: node:16 (debian:bullseye)

Vulnerabilities Found: 47
   Critical: 3
   High: 12
   Medium: 18
   Low: 14

Top Critical CVEs:
1. CVE-2024-12345 (openssl) - RCE via TLS
2. CVE-2024-23456 (curl) - Buffer overflow
3. CVE-2024-34567 (libc6) - Privilege escalation

2. Dockerfile Security Issues

Checks:

  • Running as root user
  • Hardcoded secrets in layers
  • Exposed sensitive ports
  • Unnecessary packages installed
  • Missing health checks
  • Outdated base images

Example Findings:

#  BAD: Running as root
FROM node:16
WORKDIR /app
COPY . .
RUN npm install
CMD ["node", "server.js"]  # Runs as root!

#  GOOD: Non-root user
FROM node:16
WORKDIR /app
COPY package*.json ./
RUN npm ci --only=production
COPY . .
USER node  # Drop to non-root user
CMD ["node", "server.js"]
#  BAD: Hardcoded secrets
FROM node:16
ENV DATABASE_PASSWORD="MySecretPassword123"  # Exposed in image layers!

#  GOOD: Runtime secrets
FROM node:16
# Pass secrets at runtime via environment variables or secrets management
CMD ["node", "server.js"]
#  BAD: Unnecessary packages
FROM ubuntu:latest
RUN apt-get update && apt-get install -y \
    build-essential \
    python3 \
    curl \
    wget \
    vim \
    emacs \
    git \
    # Unnecessary packages increase attack surface!

#  GOOD: Minimal image
FROM node:16-alpine  # Minimal base image
RUN apk add --no-cache curl  # Only necessary packages

3. Container Runtime Configuration

Scans For:

  • Privileged containers (--privileged)
  • Dangerous capabilities (CAP_SYS_ADMIN, CAP_NET_ADMIN)
  • Host network mode
  • Mounted sensitive host paths
  • No resource limits (CPU, memory)

Example Findings:

#  CRITICAL: Privileged container
docker run --privileged myapp:latest
# Allows container to access all host devices, escape container!

#  SAFE: Non-privileged with minimal capabilities
docker run --cap-drop=ALL --cap-add=NET_BIND_SERVICE myapp:latest
# ️ HIGH: Host network mode
docker run --network=host myapp:latest
# Container can access all host network interfaces

#  SAFE: Bridge network
docker run --network=bridge myapp:latest

Before you install

  • Read the whole file first. Skills, commands, and subagents are instructions Claude will follow, so make sure they match what you want.
  • Check which tools, scripts, or MCP servers it uses. Local servers and scripts run with your permissions.
  • Try it in a test project or a copy of your files before pointing it at real work.
  • Pin the version you tested, and review changes before updating.
  • Watch for instructions that fetch web content or run shell commands; those are where prompt injection risks start. See our prompt injection guide.

FAQ

What is Docker Security Scan?

Docker Security Scan is a slash command for Claude Code and Claude Cowork from the jeremylongshore/tons-of-skills-marketplace repository on GitHub. Scans Docker containers and images for security vulnerabilities

How do I install Docker Security Scan in Claude Code?

Download docker-security-scan.md from the repository. Save it to ~/.claude/commands/ (all projects) or .claude/commands/ (one project). As a skill, you can instead save it as ~/.claude/skills/<name>/SKILL.md. Run it by typing / followed by its name.

Can I use Docker Security Scan in Claude Cowork?

Turn the command into a skill: create a folder with the file saved as SKILL.md and zip it. In Customize → Skills, click +, then upload the ZIP. Run it from any task with / and the skill name.

Is Docker Security Scan safe to install?

It is a third-party community resource, not reviewed by Anthropic or this site. Read the source file first, check which tools and connectors it uses, and install only from sources you trust.

Similar resources

Browse all skills, subagents, and plugins →

Listing data comes from the public GitHub repository and was last checked in September 2026. Excerpts are © their authors and shared under MIT. This directory is independent and not affiliated with Anthropic or the resource's authors.