Welcome to Day 19 of the 30 Days AWS Security Challenge. Yesterday we found sensitive data with Macie. Today we look at a different kind of exposure, not what data you have, but what weaknesses exist in the software actually running your workloads. That's the job of AWS Inspector.
What a Vulnerability Actually Is
A vulnerability is a known weakness in a piece of software, usually documented publicly with an ID like a CVE (Common Vulnerabilities and Exposures) number, along with details on how severe it is and how it could be exploited. Software vendors patch these regularly, but patches only help if you actually apply them, and across dozens of EC2 instances, containers, and Lambda functions, keeping track of what needs patching by hand quickly becomes unrealistic.
What Inspector Actually Does
Amazon Inspector automatically and continuously scans your workloads for known vulnerabilities, without you needing to run manual scans or maintain a separate scanning tool. It covers three main areas:
- EC2 instances, scanning the operating system and installed software packages for known vulnerabilities
- Container images, scanning images in Amazon ECR both when they're pushed and on an ongoing basis afterward
- Lambda functions, scanning function code and its dependencies for known vulnerabilities
Unlike a one time scan you might run manually, Inspector re-evaluates continuously. If a new vulnerability is publicly disclosed today that affects a package you already have installed on an existing instance, Inspector flags it automatically, even though nothing on your instance actually changed.
How Scanning Works Under the Hood
For EC2, Inspector uses the AWS Systems Manager agent already running on many instances to inventory installed software, then compares that inventory against a continuously updated vulnerability database. For container images in ECR, it scans layers directly at the registry level. For Lambda, it analyzes function code and dependency packages without requiring any change to how your functions run.
This agent based, continuous approach means you get coverage automatically as your infrastructure changes, rather than needing to remember to re-scan after every deployment.
Turning It On
Enable Inspector from Inspector > Get Started, or Activate Inspector. It automatically discovers eligible EC2 instances, ECR repositories, and Lambda functions in your account and begins scanning. For EC2 coverage, make sure the SSM agent is installed and running, since Inspector relies on it for the software inventory it needs to check.
Reading and Prioritizing Findings
Findings appear under Inspector > Findings, each one showing the specific vulnerability, its severity (Critical, High, Medium, or Low), the affected resource, and importantly, a score reflecting how exploitable the vulnerability actually is in practice, not just how severe it theoretically sounds.
This scoring matters because not every Critical vulnerability deserves the same urgency. A Critical vulnerability in a package that's actually reachable from the internet is a very different risk than the same vulnerability in a package sitting unused on an internal instance. Inspector factors in this kind of context, which helps you avoid drowning in a backlog of findings that all look equally urgent on paper.
Fitting Inspector Into Your Workflow
A practical approach is treating Critical and High findings on internet facing resources as immediate priorities, patching them as soon as reasonably possible, while tracking Medium and Low findings as part of regular maintenance rather than emergency work. Since Inspector findings also flow into Security Hub, which we set up on Day 17, they show up alongside your GuardDuty and Config findings in that same consolidated dashboard, rather than needing yet another separate check-in.
For container images specifically, it's worth catching vulnerabilities before deployment rather than after. Inspector's scan on push to ECR means you can catch a vulnerable base image before it ever reaches production, which is a much cheaper fix than patching a live, running container later.
A Practical Example
Say a new critical vulnerability is disclosed in a common Linux package used across your fleet of EC2 instances. Without Inspector, you'd need to manually check every instance to see which ones have that package installed and at what version. With Inspector already running, every affected instance shows up automatically as a new finding within hours of the vulnerability being disclosed, letting you patch the exposed instances quickly instead of hoping you catch it during your next manual review.
Key Takeaways
- Inspector continuously scans EC2 instances, ECR container images, and Lambda functions for known vulnerabilities
- It re-evaluates automatically as new vulnerabilities are disclosed, not just when you change something
- Findings include an exploitability score to help you prioritize beyond just theoretical severity
- Focus on Critical and High findings on internet facing resources first
- Catching vulnerabilities in container images before deployment is far cheaper than patching them in production later
Tomorrow we move from vulnerabilities inside your workloads to attacks coming from outside, with AWS WAF and how it blocks common web attacks before they ever reach your application.
Loading article