Automated CVE Analysis and Remediation Using Event-Driven RAG and AI Agents
nvidia · Tech · 2024 · source Agentic: yes · promotional bias: med · source-backed · extracted with prompt 0.5.4 (schema v2)
Generated from extraction.json — do not edit by hand. Every claim cites verbatim source evidence; stated means the quote directly asserts the claim, implied means it supports it indirectly.
Problem
Domain: Cybersecurity
NVIDIA needed to triage container CVEs at enterprise scale, distinguishing vulnerabilities that are merely detected from ones that are actually exploitable in a specific software image.
Constraints:
- enterprise container publishing can surface many CVEs per container
- exploitability requires project-specific context from SBOMs, source code, documentation, vulnerability intelligence, and package versions
- security analysts still need final review and peer-reviewed VEX publication
Architecture
Agent Morpheus is an event-driven CVE analysis workflow connected to NVIDIA's container registry and security tooling. A container upload triggers a traditional scanner; scan results and threat intelligence feed a LoRA-tuned planning model that creates an exploitability checklist. A LoRA-tuned AI agent executes checklist tasks against SBOMs, source code, documentation, internet search, and helper tools such as version comparison. A summarization model condenses findings, a base Llama3 model formats non-exploitability justifications as VEX, and analysts review, peer-review, publish, and feed corrections back into training data. NIM serves the base model plus LoRA adapters, while Morpheus runs the independent CVEs and checklist items asynchronously in parallel.
Diagram confidence: explicit (topology described by the source).
flowchart LR container-registry[Container registry] --> traditional-cve-scanner[Traditional CVE scanner] traditional-cve-scanner --> agent-morpheus-workflow[Agent Morpheus workflow] vulnerability-intelligence-sources[Vulnerability intelligence sources] --> agent-morpheus-workflow agent-morpheus-workflow --> planning-llm[Planning LLM] planning-llm --> ai-agent[AI agent] ai-agent --> project-assets[Project assets] ai-agent --> version-comparison-tool[Version comparison tool] ai-agent --> summarization-llm[Summarization LLM] summarization-llm --> vex-formatting-llm[VEX formatting LLM] vex-formatting-llm --> vex-document-publishing[VEX document publishing] agent-morpheus-workflow --> security-analyst-dashboard[Security analyst dashboard] security-analyst-dashboard --> vex-document-publishing[VEX document publishing] morpheus-parallel-pipeline[Morpheus parallel pipeline] --> agent-morpheus-workflow nvidia-nim-inference-service[NVIDIA NIM inference service] --> planning-llm nvidia-nim-inference-service --> ai-agent nvidia-nim-inference-service --> summarization-llm nvidia-nim-inference-service --> vex-formatting-llm
Components
| Component | Role | Interacts with |
|---|---|---|
Container registry |
Publishes container upload events that initiate the vulnerability workflow. | Traditional CVE scanner |
Traditional CVE scanner |
Detects known CVE signatures in uploaded containers before AI exploitability analysis begins. | Container registry, Agent Morpheus workflow |
Agent Morpheus workflow |
Event-driven orchestration layer that combines RAG, agent execution, summarization, VEX formatting, and analyst handoff. | Traditional CVE scanner, Vulnerability intelligence sources, Planning LLM, AI agent, Summarization LLM, VEX formatting LLM, Security analyst dashboard, Morpheus parallel pipeline |
Vulnerability intelligence sources |
Provide current exploit and vulnerability context for detected CVEs. | Agent Morpheus workflow, Planning LLM |
Planning LLM |
LoRA-tuned Llama3 model that turns CVE context into unique investigation checklists. | Agent Morpheus workflow, AI agent |
AI agent |
LoRA-tuned agent model that executes checklist items against project assets and helper tools. | Planning LLM, Project assets, Version comparison tool, Summarization LLM |
Project assets |
Source code, SBOMs, documentation, and search-accessible context used to determine whether a CVE is exploitable. | AI agent |
Version comparison tool |
Deterministic helper tool for package-version ordering, a known weak point for LLMs. | AI agent |
Summarization LLM |
LoRA-tuned model that combines agent findings into analyst-readable summaries. | AI agent, VEX formatting LLM, Security analyst dashboard |
VEX formatting LLM |
Base Llama3 model that standardizes non-exploitability justifications into machine-readable VEX documents. | Summarization LLM, VEX document publishing |
NVIDIA NIM inference service |
Hosts the base Llama3 model and LoRA adapters behind OpenAI-compatible inference APIs. | Planning LLM, AI agent, Summarization LLM, VEX formatting LLM |
Morpheus parallel pipeline |
Runs independent CVE and checklist work asynchronously and exposes the workflow as a microservice. | Agent Morpheus workflow, NVIDIA NIM inference service |
Security analyst dashboard |
Presents the improved summary and justification to analysts for final recommendation. | Agent Morpheus workflow, VEX document publishing |
VEX document publishing |
Peer-reviewed distribution path for final VEX documents attached to containers. | VEX formatting LLM, Security analyst dashboard |
Data flow
A new container upload triggers a vulnerability scan, and the detected CVEs are passed into Agent Morpheus. The workflow retrieves current vulnerability and threat intelligence, then the planning LLM produces a checklist tailored to each CVE. The agent executes checklist items against project assets and tools, summarizes its findings, and classifies exploitability. The result is shown on a security analyst dashboard for human recommendation and peer review, then published as a VEX document; analyst edits become new fine-tuning data for the models.
4 supporting quotes
Why this architecture
NVIDIA chose an agentic RAG workflow because CVE exploitability is contextual: the same detected vulnerability may be harmless if runtime dependencies, vulnerable functions, or actual packages are absent. Specialized LoRA adapters separate planning, agent execution, and summarization rather than forcing one model to perform every role. Deterministic tools cover package-version and calculation weaknesses. NIM and Morpheus address production pressure: the system produces many LLM calls per CVE, so it needs burst-tolerant serving and parallel execution, while analyst review keeps final publication accountable.
4 supporting quotes
Models used: Llama3 · LoRA fine-tuned Llama3 · NVIDIA NIM
Scale
- The CVE database had more than 200,000 cumulative vulnerabilities by the end of 2023.“With over two hundred thousand cumulative vulnerabilities reported as of the end of 2023, it’s clear that a traditional approach to scanning and patching has become unmanageable.”article, stated
- Agent Morpheus averages about 41 LLM queries per CVE.“On average, Agent Morpheus requires about 41 LLM queries per CVE! As container scans can generate dozens of CVEs per container, the number of outstanding LLM requests can easily reach into the thousands for a single container.”article, stated
- A single container scan can create thousands of outstanding LLM requests.“As container scans can generate dozens of CVEs per container, the number of outstanding LLM requests can easily reach into the thousands for a single container.”article, stated
- Parallelizing 20 CVEs reduced processing time from 2842.35 seconds to 304.72 seconds, a 9.3x speedup.“When run serially, it can take 2842.35 seconds to process a container with 20 CVEs. When run in parallel using Morpheus, that same container takes 304.72 seconds to process—a 9.3x speedup!”article, stated
Alternatives considered (roads not taken)
Generate pull requests for every detected CVE
Rejected because: Blindly upgrading every detected package is unrealistic at enterprise scale and may be impossible when patched versions do not exist or dependency chains break.
Make the LLM compare package versions itself
Rejected because: The model struggled with version ordering, so NVIDIA externalized that operation into a deterministic tool.
Run CVE and checklist work serially
Rejected because: Serial execution made a 20-CVE container take 2842.35 seconds; the independent nature of CVEs and checklist items made parallel execution a better fit.
Patterns
tool-use-orchestration (agent-architecture)
The AI agent executes CVE checklist tasks using project assets plus deterministic helper tools for package versions and calculations.
rag-retrieval (knowledge-access)
Agent Morpheus retrieves CVE intelligence, threat intelligence, source code, SBOMs, documentation, and search results before making exploitability judgments.
fine-tuning-adaptation (model-operations)
NVIDIA uses LoRA-tuned Llama3 variants for planning, agent execution, and summarization, and feeds analyst corrections back into future training data.
human-in-the-loop-gate (governance)
The AI workflow prepares exploitability findings, but human analysts make final recommendations and peer review before VEX publication.
batch-offline-processing (execution)
The Morpheus pipeline parallelizes independent CVEs and checklist items rather than treating each container analysis as one serial LLM chain.
Tradeoffs
Exploitability investigation before remediation
Chose AI-assisted exploitability analysis and VEX justification over patching or pull-requesting every detected CVE.
Rationale: Enterprise dependency graphs make universal upgrades unrealistic, and detected CVEs can be false positives or non-executable in a given container.
Specialized model roles
Chose four Llama3 roles with three LoRA-tuned task models over a single general model for planning, acting, summarizing, and VEX formatting.
Rationale: The workflow separates planning, agent execution, summarization, and formatting into distinct tasks that can be optimized independently.
Parallel CVE execution
Chose Morpheus asynchronous parallelization over serial processing of CVEs and checklist items.
Rationale: CVE investigations and checklist items are independent, so parallel execution turns a nearly hour-long 20-CVE analysis into about five minutes.
Gotchas (what bit them)
Detected CVEs are not automatically exploitable CVEs.
Root cause: Package presence alone ignores runtime dependencies, false positives, unreachable vulnerable code, and missing execution environments.
Resolution: Agent Morpheus investigates exploitability with CVE-specific checklists and project-context retrieval before recommending patching or VEX exemption.
LLMs mis-handle package version comparisons.
Root cause: Language models are unreliable at deterministic ordering such as recognizing that 1.9.1 comes before 1.10.
Resolution: NVIDIA added a version comparison tool the agent can invoke instead of asking the model to reason about versions unaided.
Agentic CVE analysis creates bursty inference demand.
Root cause: Each CVE generates many LLM calls, and a container can contain dozens of independent CVEs.
Resolution: NVIDIA serves LoRA adapters with NIM and uses Morpheus to parallelize CVEs and checklist items asynchronously.
Evaluation
NVIDIA compared serial and Morpheus-parallel execution for a 20-CVE container and relies on analyst review plus peer review before publication.
Metrics: 2842.35 seconds serial processing for 20 CVEs · 304.72 seconds parallel processing for 20 CVEs · 9.3x speedup
Outcomes
- Agent Morpheus reduces CVE triage from hours or days to seconds for the investigation stage described in the case study.
- Parallelization improved the 20-CVE benchmark by 9.3x.
- The workflow automates the path from container upload through analyst-reviewed VEX document publication.
The system is positioned for enterprise container publishing, where containers can produce dozens of CVEs and thousands of outstanding LLM requests.