Updated on November 4, 2026
Container registry vulnerability scanning checks images stored in a registry, such as Amazon ECR, Azure Container Registry, Google Artifact Registry or Harbor, against vulnerability databases when they are pushed, and again over time as new CVEs are published. It sits between build-time checks in CI and runtime detection in the cluster. Its main value is continuous rescanning. An image that passed CI last month can carry a critical CVE today without a single byte changing. This guide, updated in November 2026, explains how container vulnerability scanning works in each of the four major registries. It covers the commands to run, the findings fields to read, the policies to enforce and the reasons scanners disagree.
Key takeaways
- ✓Registry scanning catches CVEs disclosed after an image was built, which build-time scanning in CI cannot do on its own.
- ✓Amazon ECR offers basic scanning and enhanced scanning through Amazon Inspector, and only enhanced scanning rescans continuously and covers language packages.
- ✓Azure Container Registry has no standalone scanner, so vulnerability assessment comes from Microsoft Defender for Cloud.
- ✓Google Artifact Registry scans through Artifact Analysis, and teams still on legacy Container Registry (gcr.io) need to plan around the migration.
- ✓Harbor uses pluggable scanner adapters, usually Trivy, and enforces severity thresholds at the project level.
| Registry | Native scanner | Continuous rescanning | OS / language packages | Policy gate |
|---|---|---|---|---|
| Amazon ECR | Basic scanning; enhanced via Amazon Inspector | Enhanced only | Basic: OS. Enhanced: OS and language | CI, EventBridge, admission controllers |
| Azure Container Registry | Microsoft Defender for Cloud (Defender for Containers) | Yes, with the plan enabled | OS and language | Azure Policy and admission control |
| Google Artifact Registry | Artifact Analysis (Container Scanning API) | For recently pushed or pulled images | OS and major language ecosystems | Binary Authorization |
| Harbor | Scanner adapters (Trivy by default, Clair optional) | Scheduled “scan all” jobs | Depends on adapter | Project-level severity block |
What is container registry vulnerability scanning?
Container registry vulnerability scanning analyzes images at rest in a registry and keeps re-evaluating them against updated vulnerability feeds. General container scanning covers every stage of the lifecycle, while registry scanning covers the stage where images wait to be pulled.
Every container vulnerability scanner works the same way underneath. It builds an inventory or SBOM of the image, compares each component against sources such as NIST NVD and vendor advisories, then reports severity and fix availability. Good tools inspect four layers:
- Base OS packages (apk, dpkg, rpm)
- Runtime and language libraries (npm, pip, Maven, Go modules)
- Application dependencies
- Binary fingerprints, in some tools
For the mechanics of the inventory step, see our explainer on how container image scanning works.
| Registry scanning is | Registry scanning is not |
|---|---|
| Container image vulnerability scanning of stored artifacts | Proof that a vulnerable package is loaded or reachable at runtime |
| Continuous re-evaluation as new CVEs land | A replacement for failing builds in CI |
| A central inventory of what you could deploy | A view of what is actually deployed or exposed |
| A source for promotion and deployment gates | Detection of drift, exploitation or malicious behavior |
Container registry scanning vs runtime scanning: which approach is better?
Neither approach works alone, because each stage catches a different class of problem. Teams that scan container images for vulnerabilities only in CI miss CVEs published after the build. A sound container security scanning pipeline follows one flow:
- Developer builds the image and CI scans it, stopping known-bad images early.
- The image is pushed and the registry scans it, then rescans as newly disclosed CVEs arrive.
- A policy gate and admission control block anything that slipped through.
- Runtime monitoring shows which remaining findings sit in running, internet-facing workloads, which is where prioritization happens.
How to scan images in Amazon ECR
Amazon ECR scans images once you enable either basic scanning or enhanced scanning, which is powered by Amazon Inspector, and you then read the findings per image. Both options are set at the registry level for each AWS region, so a multi-region estate needs the configuration applied in every region.
Basic vs enhanced scanning
- ✓Basic scanning runs on push or on demand and covers OS packages.
- ✓Enhanced scanning hands the work to Amazon Inspector, covers OS and programming-language packages, and rescans continuously as new CVEs are published.
- ✓Basic scan completions emit EventBridge events and enhanced findings flow through Inspector, so you can route both to ticketing or Security Hub.
CLI workflow
- Turn on scan-on-push for a repository (basic scanning):
aws ecr put-image-scanning-configuration \ --repository-name payments-api \ --image-scanning-configuration scanOnPush=true - Or switch the registry to enhanced, continuous scanning:
aws ecr put-registry-scanning-configuration --scan-type ENHANCED \ --rules '[{"scanFrequency":"CONTINUOUS_SCAN","repositoryFilters":[{"filter":"*","filterType":"WILDCARD"}]}]' - Trigger a manual basic scan and read the severity counts:
aws ecr start-image-scan --repository-name payments-api --image-id imageTag=1.4.2 aws ecr describe-image-scan-findings --repository-name payments-api \ --image-id imageTag=1.4.2 --query 'imageScanFindings.findingSeverityCounts' # Example output { "CRITICAL": 2, "HIGH": 11, "MEDIUM": 27 }
Fields worth reporting on
AWS’s reporting guidance groups the useful fields into two levels. At the repository level, scanOnPush shows whether images are scanned automatically. At the image level, imageScanStatus, imageScanCompletedAt and findingSeverityCounts give scan state, freshness and severity. Use consolidated basic findings or Inspector’s enhanced findings to prioritize. A stale imageScanCompletedAt on an image still in production is a red flag.
How to scan images in Azure Container Registry
Azure Container Registry vulnerability scanning is delivered through Microsoft Defender for Cloud, specifically the Defender for Containers plan, rather than a scanner built into ACR itself. With the plan enabled on the subscription, Defender assesses images that are pushed, recently pulled or running, and re-evaluates them on a recurring basis.
- Enable the plan for the subscription:
az security pricing create --name Containers --tier Standard - Push images as usual (
az acr login --name contosoacr, thendocker push contosoacr.azurecr.io/web:2.3.0). - Query findings at scale with Azure Resource Graph:
az graph query -q "securityresources | where type == 'microsoft.security/assessments/subassessments' | where id contains 'Microsoft.ContainerRegistry' | project cve=properties.displayName, severity=properties.status.severity"
Operational notes
- Reading findings requires a role such as Security Reader on the subscription. ACR roles like AcrPull do not grant access to Defender results.
- Continuous export to Log Analytics or Event Hubs, plus workflow automation with Logic Apps, turns findings into tickets.
- Azure Policy and an admission controller in AKS can block deployment of images with unresolved high-severity findings.
The main consideration is cost and scope. Scanning depends on a paid Defender plan, and findings live in Defender rather than in the registry, so CI pipelines have to query a separate service.
How to scan images in Google Container Registry and Artifact Registry
GCP container scanning runs through Artifact Analysis. Once you enable the Container Scanning API, new images pushed to Artifact Registry in the project are scanned automatically. Legacy Container Registry (gcr.io) is deprecated in favor of Artifact Registry. Teams still referencing gcr.io paths should migrate repositories and update scan tooling, Pub/Sub subscriptions and IAM bindings, because findings and policies attach to Artifact Registry resources.
- Enable the APIs:
gcloud services enable containerscanning.googleapis.com artifactregistry.googleapis.com - Authenticate, tag and push:
gcloud auth configure-docker us-central1-docker.pkg.dev docker tag app us-central1-docker.pkg.dev/PROJECT/prod-repo/app:1.8.0 docker push us-central1-docker.pkg.dev/PROJECT/prod-repo/app:1.8.0 - Read findings from the CLI:
gcloud artifacts docker images describe \ us-central1-docker.pkg.dev/PROJECT/prod-repo/app:1.8.0 \ --show-package-vulnerability - Scan locally before pushing with On-Demand Scanning:
gcloud artifacts docker images scan app:1.8.0 --remote gcloud artifacts docker images list-vulnerabilities SCAN_NAME
Google’s documentation notes that scanning is disabled by default for packages pushed to Artifact Registry repositories, so check repository-level scanning settings. For images with more than 1,200 vulnerabilities, only gcloud or the API returns the full list.
Artifact Analysis publishes occurrences to the container-analysis-occurrences-v1 Pub/Sub topic for event-driven ticketing. Binary Authorization enforces deploy-time policy on GKE and Cloud Run.
How to scan Harbor images
Harbor scans images through scanner adapters. You register a pluggable scanner, Trivy by default with Clair as an option, and Harbor calls it on push, on demand or on a schedule. The adapter determines coverage. Trivy handles OS packages and most language ecosystems, so swapping adapters changes your results.
- Enable “Automatically scan images on push” in the project configuration.
- Enable “Prevent vulnerable images from running” and set a severity threshold, for example High, so pulls of non-compliant artifacts fail.
- Trigger a scan from CI by sending an authenticated POST to the artifact’s
/scanendpoint in the Harbor API (/api/v2.0/projects/{project}/repositories/{repository}/artifacts/{digest}/scan). - Schedule a registry-wide “scan all” job so stored images are re-evaluated against fresh vulnerability data.
Operational notes for self-hosted teams
- You own feed freshness, so air-gapped installs need a process to load the Trivy database offline.
- Scan results do not travel with replication, so replicated artifacts are scanned again in the target Harbor instance.
- Robot accounts with scoped permissions let CI trigger scans and read reports without personal credentials.
How to enforce policy, prioritize findings and troubleshoot gaps
Registry findings only reduce risk when they block promotion or deployment and feed a prioritized remediation queue.
Gate CI, promotion and admission
Docker image vulnerability scanning in CI should fail the build on a clear threshold before anything reaches the registry:
trivy image --exit-code 1 --severity CRITICAL,HIGH --ignore-unfixed \
registry.example.com/api@sha256:3f1c...At deploy time, a Kyverno or OPA Gatekeeper policy can reject pods whose images lack a valid Cosign signature or SBOM attestation. Pair that with a registry-side check that blocks promotion from staging to prod repositories while fixable critical findings remain open. Vulnerability scanning alone does not establish provenance, a point Red Hat makes in its guide to container image security beyond vulnerability scanning. Signing and attestations close that gap.
Prioritize by exploitability, not count
A sound container vulnerability management workflow ranks findings in this order:
- Exploit maturity: known exploited, or public exploit code available.
- Running workloads: is the image actually deployed anywhere?
- Exposure: internet-facing services and privileged pods come first.
- Reachability: is the vulnerable package loaded into memory at runtime?
- Fix availability: a patched version or a newer base image exists.
For example, an image might carry 140 findings, of which 9 are critical, 3 have fixes and only 1 sits in a package loaded by an internet-facing service. That single finding becomes the ticket. The other 139 go to the next scheduled base-image rebuild.
Base image hygiene and SBOMs
- ✓Use distroless or minimal bases (Alpine, Wolfi, Chainguard, Google distroless) to shrink the OS package surface.
- ✓Pin by digest (
@sha256:...) rather than mutable tags, and enable immutable tags in the registry. - ✓Rebuild on a fixed cadence, for example weekly, so upstream patches land without waiting for a code change.
- ✓Generate SBOMs at build time (
syft image -o cyclonedx-json) and attach them withcosign attest --type cyclonedx, so new CVEs can be matched against stored SBOMs without pulling images again. - ✓Sign images and record SLSA provenance, then require both at admission.
Why images go unscanned or results differ
| Symptom | Likely cause | Fix |
|---|---|---|
| Scan status “unsupported” | Distro or base the scanner does not recognize | Move to a supported base, or use an adapter that supports it |
| Missing language findings | Basic scanner covers OS packages only, or private dependencies lack public metadata | Enable enhanced or language scanning; add SBOMs |
| Different counts across tools | Different feeds, vendor severity overrides, unfixed-CVE handling | Standardize on one source of truth per gate |
| Old findings on prod images | Stale CVE feed or expired continuous-scan window | Check feed update jobs and rescan schedules |
| Only one architecture scanned | Multi-arch manifest lists | Scan each platform digest |
| Findings vanish | Ephemeral tags overwritten or garbage-collected | Track by digest; retain release images |
| Throttled scans | API rate limits during bulk pushes | Batch or queue scan requests |
Is native registry scanning enough? For one cloud, one registry and a small fleet, native scanning plus CI gates is usually sufficient. Teams running multiple registries, multiple clouds or large Kubernetes estates typically add third-party container vulnerability scanning tools for consistent policy, unified reporting and runtime context. Our guide to choosing a container vulnerability scanner covers the evaluation criteria.
Bringing registry findings into runtime context with Upwind
Upwind adds runtime context to registry findings by showing which scanned images are running and which vulnerable packages are actually loaded. Its lightweight eBPF sensors observe live workloads, so ECR, ACR, Artifact Registry and Harbor findings can be ranked by real exposure instead of raw severity. Users rate it 4.8/5 from 88 reviews on Gartner Peer Insights as of November 2026. Teams that only need scan-on-push for a single registry may find a full platform more than they require.
- ✓Runtime reachability shows which CVEs sit in loaded packages.
- ✓Kubernetes and internet-exposure context identifies the riskiest running images.
- ✓Agentic Pack AI agents validate exposure and generate fixes.
- ✓One sensor covers posture, workload protection and detection and response.
Effective container registry vulnerability scanning combines scan-on-push, continuous rescanning, digest-pinned and signed images, admission gates and runtime prioritization. Turn on the strongest native scanner in each registry, enforce thresholds in CI and at deploy time, and spend remediation effort on the findings that running workloads actually expose.
FAQ
Why is container registry vulnerability scanning needed if images were already scanned in CI?
Registry scanning catches CVEs disclosed after an image was built. An image that passed CI can become vulnerable later, so registry rescanning helps detect newly published issues while the image is still stored and waiting to be deployed.
What is the difference between basic and enhanced scanning in Amazon ECR?
Basic ECR scanning covers OS packages and runs on push or on demand. Enhanced scanning uses Amazon Inspector, adds language package coverage, and continuously rescans images as new CVEs are published.
Does Azure Container Registry include its own native vulnerability scanner?
No. Azure Container Registry relies on Microsoft Defender for Cloud, specifically the Defender for Containers plan, for vulnerability assessment and recurring re-evaluation.
What should teams using Google Container Registry know about scanning in 2026?
Legacy Container Registry (gcr.io) is deprecated in favor of Artifact Registry. Teams should migrate repositories and update scan tooling, Pub/Sub subscriptions, and IAM bindings because findings and policies attach to Artifact Registry resources.
Why do different container scanners report different vulnerability counts for the same image?
Scanners can disagree because they use different vulnerability feeds, apply vendor severity overrides, and handle unfixed CVEs differently. The article recommends standardizing on one source of truth for each policy gate.
