Public
CTIIntel as CodePythonCIYAMLAgentsPrompt Injection

CTI as Code

The threat intelligence program itself, held as version-controlled records whose claims about each other are enforced in CI. A priority intelligence requirement names the decision it serves. Every question under it resolves to a collection source or names a gap, and the build fails when it does neither. Agents declare a contract before they may run.

The Problem

Detection engineering moved its rules into git years ago. Threat intelligence never moved its program. Requirements live in a slide deck, the collection plan in a spreadsheet, campaigns in a wiki, and none of them can fail. They go stale silently, and the program finds out when an incident asks one of them a question.

Program management is where most of CTI's time goes, and it has stayed in prose where no model can help. What keeps CTI from being truly agentic is those foundations, not the models.

Approach

The program becomes a repository of records. A requirement names the decision it serves and who makes it. Each question under it resolves to a collection source or names a gap, and the build fails when it does neither. Decoys, detection candidates and campaigns each point back up to a requirement, and an agent is a record with a contract it must satisfy before it may run. Three commands read the chain: trace prints requirement to collection to candidate to campaign, gaps prints everything the program says it cannot see, and report gives a coverage summary. The worked example is a fictional freight-booking platform, small on purpose and honest about its gaps.

Key Design Decisions

Built, and Designed

Built and tested: the eight record trees and a worked example, a validator enforcing every gate marked enforced with 42 tests, the validate, trace, gaps and report commands, the deterministic sanitiser with a golden test, a decoy canary predicate, and CI. Designed and not built: the read API, the model-driven extraction pipeline, the filter audit, actor clustering and ranking, the sharing pipeline, and the retrieval and drift loop over adjudicated cases. Every fixture is synthetic and nothing has run against real telemetry.

Direction

The next records would sit beside detection candidates: exposure and emulation candidates, so vulnerability management and red teams are consumers from day one, and reviews triggered by events and not by calendars. The example's ACTOR-06 ("intent is zero, exposure is not") is the essay's thesis in miniature. The test that would matter is a real program run under these gates, measuring whether named gaps turn into sources. That has not been done.

← All Development