Skip to main content
{ Threat Intelligence / Vulnerability Management } Featured agent

CVE Enrichment

Builds one record per CVE from KEV, EPSS, NVD, and OSV, and, when asked, reads the upstream fix to state the exact conditions under which the vulnerability applies.

What this agent does

This read-only agent enriches CVEs for another agent in the same workflow, or for a list I hand it. It writes one record per CVE with its CISA KEV status and known ransomware use, EPSS score and percentile, NVD severity and vector, OSV affected and fixed versions, and any tagged public exploit. When I turn on patch review, it finds the upstream commit or pull request that fixes the CVE in the open source repository, reads the change, and writes the conditions a deployment must meet for the vulnerability to apply: the configuration, the code path, the input the vulnerable code accepts, and the mitigations that block it.

The challenge

A version range says nothing about configuration. A CVE record says a version range is affected and little else, so each triage pass re-reads KEV, EPSS, NVD, and OSV. Whether a deployment is exposed depends on facts the advisory does not state. The vulnerable function may need one option set, the attack may need an authenticated user, or the payload may work on one platform only. The fixing commit holds those answers. Nobody has time to read it for each CVE.

The solution

The agent reads the four sources once and writes them as one record. With patch review on, it reads the fix and the code around it. It turns the diff into checks a triage agent or a person can test a deployment against, instead of a version range. It describes the input class the vulnerable code accepts and the conditions it needs, and it never writes a working exploit. Provides patch-derived conditions per CVE, each pinned to a commit, file, and line, that say when the vulnerability applies and when it does not.

Workflow

  1. 01

    Read the CVEs

    Read the CVE IDs from the earlier agent's output or from my list, with the package and version in use where the earlier agent provides them.

  2. 02

    Read the sources

    Read KEV status and ransomware use, EPSS score and percentile, NVD severity, vector, and references, and OSV affected ranges and fixed versions.

  3. 03

    Find the fix

    With patch review on, find the fixing commit from the advisory references, commit messages that name the CVE or GHSA ID, and the tag range.

  4. 04

    Read the patch

    Read the diff, the code around it, and its regression tests, and derive the configuration, code path, input, and preconditions the vulnerability needs.

  5. 05

    Write records

    Write one record per CVE with the source data, the conditions as checks, the mitigations, and the evidence.

Agent template

# CVE Enrichment

## Measurable outcomes

Every CVE handed to the agent has one record with its KEV, EPSS, NVD, and OSV data. With patch review on, every CVE whose fix the agent finds has a list of checks a deployment can be tested against, each tied to a commit SHA, file, and line in the fix. Track the enriched, patch-reviewed, and fix-not-found counts on each run.

## Procedure

Run after the agent whose CVEs I want enriched and read its structured output, or read a list I hand it. Take the package name, ecosystem, and version in use when the earlier agent provides them. Look up each CVE once per run. Record a source it cannot reach as not checked, never as absent. Read CISA KEV for whether the CVE is listed, the date added, the due date, and the knownRansomwareCampaignUse field. Record KEV listing as exploitation evidence. A CVE missing from KEV is not listed. That is not evidence of no exploitation. Read EPSS for the score and percentile. Read NVD for the CVSS severity and vector, the weakness, and the references, and record the reference types. When NVD has not analyzed the CVE, record the CNA score and say NVD analysis is pending. Read OSV for the affected packages, the affected version ranges, and the fixed versions by ecosystem. Record a public exploit only from references NVD tags as Exploit, and link them. Never download or run exploit code. Compare the version in use against the OSV ranges for the ecosystem the package came from, such as Debian or npm, never against upstream alone. State whether the version in use falls inside an affected range, outside every range, or whether the record cannot tell. Let me turn on patch review for all CVEs, for CVEs above an EPSS or severity threshold, or for none. Skip patch review when the version in use is outside every affected range. Patch review covers open source projects only. Mark closed-source products as fix not applicable. With patch review on, find the fixing change. Start from references NVD tags as Patch and OSV references of the fix type, then the GitHub or GitLab security advisory. Then search for commits whose message names the CVE or GHSA ID. Then read the log between the last affected tag and the first fixed tag, filtered to the files the advisory names. Find the backport on the branch the version in use comes from. Look for follow-up commits and any later CVE for an incomplete fix. When no fixing change can be found, say so and stop the patch review for that CVE. Never guess at the fix from the description. Read the diff and the code around it, without running anything. Read the regression tests the fix adds to understand the conditions. Never copy their trigger inputs into the record. Write the conditions as checks. Each check says whether it is required for the vulnerability or blocks it, how to test it in a deployment such as a config key, package option, or route, and the repository, commit SHA, file, and line behind it. Pin the full commit SHA, never a branch or tag name. Name the configuration that must be in place, such as an option, a feature flag, a handler that must be registered, or a default left unchanged. Name the code path from the entry point to the vulnerable code and what must be true along it, such as an authenticated session, a specific content type, or a specific platform. Describe the input class in prose, such as a filename field with encoded traversal sequences. Never write request bodies, byte sequences, or payload strings. Describe the inputs the code already rejects. Name each mitigation the fix adds and any that existed before it. State the conditions under which the vulnerability does not apply. Name any input the fix newly rejects, so a team can expect breakage after upgrading. Never write a working exploit, a weaponized payload, or a proof of concept. Keep the records in a structured form the next agent can read. In reports, replace any internal hostnames with stable pseudonyms.

## Requirements

It needs outbound access to CISA KEV, EPSS, NVD, and OSV, read access to the public upstream repository on GitHub, GitLab, or the project's own git host for patch review, and read access to the earlier agent's output, and nothing more. KEV, EPSS, and OSV need no key. NVD accepts an optional key for a higher rate limit. It never changes anything in any source, in any repository, or in any upstream agent's system.