We Built a CVE Remediation Agent with Plural Workbenches

Aaron Smallberg
Aaron Smallberg

Security scanners are good at finding vulnerabilities. They are less useful at getting those vulnerabilities fixed.

Once a scanner raises an alert, someone still has to determine which repository owns the vulnerable artifact, understand whether the affected code path is reachable, find a safe upgrade, make the change, run the right tests, open a pull request, respond to review, and get CI green. Multiply that by every service, image, and dependency in a modern platform, and a stream of useful alerts can quickly become a permanent engineering backlog.

We wanted a better operating model for our own repositories: continuously track every relevant CVE, preserve the audit trail we need for compliance, and turn a selected finding into a tested, reviewable fix without handing production control to an agent.

So we built that workflow with Plural Workbenches.

The result is an end-to-end CVE remediation system. It scans, deduplicates, prioritizes, files tickets, investigates the affected code, proposes and validates a fix, opens a pull request, and stays with that pull request through CI and review. Engineers decide when remediation begins, review the proposed change, and retain the final merge decision.

This is not an agent sitting in a chat window waiting for a carefully written prompt. It is a repeatable operational workflow that runs against the tools and repositories our team already uses.

Platform engineers no longer spend their weeks matching scanner findings to tickets and pushing routine patches through, or watching the backlog grow past the SLA. Their time goes to the fixes that need engineering judgment and to the projects they were hired to build. 

The workflow: continuous tracking, remediation on demand

Our setup has two stages. The first stage continuously discovers and tracks security work. The second stage implements a fix when an engineer decides the team is ready to review it. That separation is deliberate.

CVE remediation in two stages: continuous tracking of every vulnerability, and remediation on demand when an engineer is ready to review the fix. 

Stage one: scan, deduplicate, and create an audit trail

A scheduled Workbench job scans the repositories that matter to our SOC 2 Type II scope and collects code-scanning alerts from GitHub and other configured security tools.

A scheduled Workbench job scans the repositories in scope, deduplicates security findings, and routes critical and non-critical CVEs into the appropriate Linear tickets.

The Workbench deduplicates the findings, separates critical from non-critical issues, and creates or updates the appropriate Linear tickets. Severity drives priority and SLA: critical findings are treated as urgent, while non-critical findings can be scheduled based on their risk and the team's release cadence.

This gives us one continuously maintained queue instead of a collection of alerts scattered across repositories. It also creates an auditable record that findings are being monitored, categorized, and tracked over time.

Most importantly, this stage does not open a pull request for every alert the moment it appears. That would replace vulnerability backlog with review backlog.

Stage two: tell Plural to implement the fix

Workbenches can be configured to run on demand, on a schedule, or from webhooks. In this workflow we use both: a cron job maintains the security queue, and a Linear webhook starts remediation when an engineer asks for it.

That small human checkpoint matters. The system automates the work without deciding the team’s priorities for it. Engineers control when a change enters review, and they keep control of the merge.

The Linear webhook listens for the “plural implement this” wake word and passes the full ticket context into the remediation workflow.

When an engineer is ready to take on a ticket, the handoff is a Linear comment:plural implement this

An engineer starts remediation from the existing security ticket when the team is ready to review the resulting change.

That phrase is the webhook’s wake word. It starts a new Workbench job and passes along the context from the Linear thread. The coding agent then investigates the finding, locates the correct codebase, makes the change, validates it using the repository’s own tooling, and opens a pull request.

The agent does not stop at opening a pull request

Opening a pull request is an intermediate result, not the finish line.

For CVE remediation, we run the coding agent in what we call “babysit mode”. After it opens the pull request, the agent remains active for the PR lifecycle. It watches for CI failures and review comments, investigates them, updates the branch, and works toward a clean, reviewable result.

The coding agent runs in babysit mode, carrying ticket context into the repository investigation and remaining active through the pull request lifecycle.

That closes an important gap in most code-generation workflows. A first attempt can be directionally right and still fail a repository-specific test, miss a generated file, or expose a compatibility issue during review. If every failure sends the work back to an engineer, the automation has only moved the toil around.

Plural’s coding agent runs in a sandboxed Kubernetes pod, can read and modify the configured repository, and returns changes through a pull request. It does not write directly to production. CI, code review, branch protections, and the final merge remain in the same places they were before.

A real example from our public repositories

One recent run started from vulnerabilities reported against a Console image. The affected code did not actually belong in the Console repository: the image embeds the plural binary, which is built from `pluralsh/plural-cli`.

The agent followed that mapping to the correct repository and opened plural-cli PR #792. The pull request remediated two CVEs by updating golang.org/x/mod and github.com/go-git/go-git/v5, then refreshed the compatible transitive modules selected by Go tooling.

A public, agent-authored remediation PR mapped the vulnerable Console image back to “pluralsh/plural-cli,” updated the affected Go modules, passed review, and merged.

The change itself was intentionally small (two files), but the pull request also documented why the fix belonged in that repository, traced the build path for the shipped CLI, and recorded the validation it performed:

  • module download, verification, and tidy checks;
  • resolution checks for the fixed dependency versions;
  • a CLI build and runtime smoke test;
  • race-enabled package tests; and
  • a final diff check to confirm the scope stayed limited.

The pull request was opened by the Plural agent, reviewed by engineers, and merged about 25 minutes later. That is one public example, not an average or a benchmark, but it shows what the complete loop looks like: a finding tied to a deployed image became a correctly routed, tested, auditable change that was ready for human approval.

The repository mapping is worth emphasizing. Changing a version number is often the easy part. Determining which codebase owns the vulnerable artifact and proving that the proposed change will reach the image that triggered the alert is the kind of context-heavy work that simple update bots regularly miss.

Why we use two stages instead of opening PRs automatically

It would be easy to connect every finding directly to a coding agent and generate a large batch of pull requests. We chose not to.

The two-stage design gives us three useful properties.

First, it preserves a clean compliance trail. The scheduled scan keeps Linear synchronized with the findings and makes severity, status, and SLA visible.

Second, it prevents review fatigue. Engineers can choose when a remediation PR should enter the queue based on severity, release timing, and available reviewer attention.

Third, it keeps the control boundary obvious. The Workbench can investigate deeply and do the mechanical work, but the team still chooses the task and approves the result. Every code change arrives through the standard pull request workflow.

This balance is important for security automation. More autonomy is useful only when it comes with equally strong traceability and review.

What changes for the engineering team

Without this workflow, a security ticket is the beginning of a manual investigation. With it, the ticket becomes the control surface for an investigation and implementation that the Workbench can carry out in the background.

The engineer’s role moves up a level. Instead of tracing image contents back to repositories, resolving dependency graphs, producing the first patch, and babysitting CI, the engineer decides what should be fixed next and evaluates the proposed change.

The scanner still detects the issue. Linear still holds the work and the audit trail. GitHub still runs CI and hosts the review. Plural connects those systems into one durable workflow and supplies the repository and infrastructure context needed to move between them.

That is the larger point of Workbenches. They are not limited to a single prompt or a single tool call. A Workbench packages the connected tools, operational instructions, triggers, and coding capabilities required to own a complete job. For CVE remediation, that job starts with continuous discovery and ends with a pull request a human can confidently review.

Build your own remediation workflow

We built this system for our own repositories because CVE remediation is important, repetitive, and full of small context gaps that slow teams down. It is also just one example of what a configurable Workbench can own.

If your security queue is growing faster than your team can investigate it, we can show you how to build the same pattern around your repositories, ticketing system, security tooling, and review process.

Request a demo and bring us one of the CVEs currently sitting in your backlog.

ProductAnnouncements