Safeguard
Developer Tools•

Can you scan a container image without a Docker daemon?

Yes. A scanner can read an image from a tar archive, an OCI layout directory or a registry, with no daemon or running container. Here is when to use each.

Safeguard Security Team
3 min read

Yes. An image is just files: a manifest, a config and layer blobs. A scanner can read them from a registry, a tar archive made by docker save, or an OCI layout directory, with no daemon and no running container. That suits CI runners, air-gapped hosts and locked-down laptops.

What an image looks like on disk

The OCI image layout specification defines a directory with three parts: a blobs directory of content-addressed files, an oci-layout file that marks the root and records a version, and an index.json that points to manifests. A scanner follows the index to a manifest, reads the layers in order, and looks inside.

docker image save writes images and their parent layers as a tar archive. The documentation notes you can limit it to one platform with the platform option, for example linux/amd64. Without it, all platform variants present in the local store are saved.

Three ways to feed an image to a scanner

SourceNeedsGood for
Registry referenceNetwork and pull credentialsCI and scheduled scans
Tar archiveA fileAir-gapped scanning, handoffs, evidence
OCI layout directoryA directoryBuild pipelines that never push yet

Steps for a daemonless scan

  1. Produce the image as an archive or layout in your build step.
  2. Store it as an artifact so the scan reads the same bytes you built.
  3. Point the scanner at the file or directory.
  4. Record the image digest from the manifest in your results.
  5. Fail the pipeline on your policy, then push only if it passes.

Scanning before push is a useful ordering. A failing image never reaches the registry, so nobody can deploy it by mistake.

Why this matters for security

A daemon is a privileged service. On shared runners, mounting its socket gives a job host-level power; see the Docker socket risk. A scan that reads files avoids that need.

What you give up

Reading an archive tells you what is in the image, not how it behaves when run. For that you need cluster or runtime context, which we compare in image vs cluster vs runtime scanning.

Try it yourself

Click through it at your own pace, or open it full screen.

Follow one finding back to a layer and a package.

Safeguard scans dependencies and SBOMs from the CLI and CI; the free scan needs no install.

Quick check

Is a tar archive safe to scan on a shared host?

Treat it as untrusted input. Scan in an isolated job and never extract it into a sensitive directory.

Does the archive keep the image digest?

The manifest and config blobs are addressed by digest, so you can compute and record it. Do so in your results.

Sources

Last reviewed: 19 October 2026.

Never miss an update

Weekly insights on software supply chain security, delivered to your inbox.

Self-healing security runs on Safeguard.

Your first fix PR is minutes away.

No sales call required, even your agent can complete the purchase over MCP.