PROJECT RECORD / ENG-001DOCUMENTED BUILD
THREAT INTELLIGENCE / DETECTION ENGINEERING

ThreatIntel — AI-Powered Threat Intelligence

A modular Python pipeline that turns roughly 30 security news sources into correlated, prioritised threat events, analyst-reviewable hunts, and JSON/PDF reports.

Threat IntelligencePythonSecurity EngineeringCVE EnrichmentThreat HuntingAI
VIEW SOURCE ON GITHUB ↗
THREATINTEL / PROCESS VISUALISATION
SIMULATION / NOT LIVE DATA
ENG-001 / DATAFLOW MONITOR

From threat feeds to hunt hypotheses.

A visual map of the actual processing stages — deterministic collection and enrichment first, optional AI only when the evidence warrants it.

  1. 01COLLECT

    ~30 security sources

    Articles + feeds
  2. 02NORMALISE

    CVE / IOC extraction

    Clean evidence
  3. 03ENRICH

    NVD + CISA KEV

    Vulnerability context
  4. 04CORRELATE

    Conservative deduplication

    Grouped events
  5. 05PRIORITISE

    Scoring + asset matching

    Relevant events
  6. 06AI + HUNTS

    Optional and budget-limited

    Review-only KQL / UDM / XQL
  7. 07REPORT

    JSON + PDF + terminal

    Analyst-ready output
ACTIVE STAGE 01 / 07COLLECT / Articles + feeds
DETERMINISTIC CORE → OPTIONAL AI → HUMAN REVIEWVISUAL EXPLANATION ONLY / NO LIVE TELEMETRY
FILE CONTENTS // ENGINEERING CASE STUDY

Why I built it

ThreatIntel was my first real project. Manually checking 20+ cybersecurity feeds every day was miserable. I wanted to turn a repetitive reading task into a focused, repeatable intelligence workflow: collect the signal, enrich and correlate the evidence, determine what matters, then produce something an analyst can actually use.

ThreatIntel is a defensive threat-intelligence aggregation and analysis tool. It collects reporting from approximately 30 security news sources, extracts CVEs and candidate indicators of compromise (IOCs), correlates related stories, checks vulnerability context against the National Vulnerability Database (NVD) and CISA Known Exploited Vulnerabilities (KEV) catalogue, and scores relevance against a configurable technology estate.

For higher-priority events, optional OpenAI-assisted analysis can draft focused threat-hunting packs for Microsoft Defender XDR (KQL), Google SecOps (UDM) and Cortex XDR (XQL). The output includes JSON and PDF reports and readable terminal output.

What the animation above shows: an illustrative walkthrough of the processing stages. It is not a live connection to feeds, deployed detections, or real-time security telemetry.

How the pipeline works

  1. Collect — Fetch recent intelligence items from configured sources using feedparser and BeautifulSoup. COLLECTION_HOURS defaults to 24 hours.
  2. Process deterministically — Clean article text; extract CVEs and candidate IOCs; enrich vulnerability context using NVD and KEV; calculate initial priority.
  3. Correlate — Merge related reports conservatively, using shared CVEs, substantial CVE overlap, nearly identical titles, or distinctive token overlap. Preserve sources and evidence and recalculate priority after merging.
  4. Score and match — Evaluate operational relevance and compare reported technologies with a configurable customer technology estate.
  5. Analyse selectively — Run optional OpenAI analysis only for qualifying events above AI_MIN_PRIORITY, constrained by a total token budget.
  6. Draft hunts — Generate a small number of evidence-grounded hunt packs for suitable top events, with explicit review status and validation checks.
  7. Report — Produce structured JSON, PDF summaries using ReportLab, and readable terminal reporting with Rich.

The main orchestrator lives in threatintel.py. The actual processing stages live in separate Python modules, keeping collection, analysis and reporting independently maintainable.

Code structure

ThreatIntel/
├── collectors/          # Source feeds and article retrieval
├── processing/          # Parsing, enrichment, priority, correlation
├── ai/                  # Optional analysis and hunt generation
├── reporting/           # JSON, PDF and terminal output
├── config/              # Configuration and data
├── threatintel.py       # Main orchestration
├── requirements.txt
└── Run-ThreatIntel.bat   # Windows launcher

Core dependencies: openai, feedparser, beautifulsoup4, reportlab, pydantic, httpx, and rich.

Decisions that mattered

Deterministic first. AI second.

An intelligence event is already useful before an LLM is called: it contains extracted evidence, vulnerability enrichment, relevance and priority. If the OpenAI step is disabled with --no-ai or fails, the deterministic pipeline can still produce useful output.

Important distinction: --no-ai disables AI API usage; fetching live feeds and NVD data can still require network access. It isn’t the same as fully offline execution.

Evidence-grounded threat hunts

Generated hunt queries are constrained to supplied evidence rather than fabricated CVEs, IOCs or behaviours. The generation step uses structured responses, schema validation and quality checks. Unsupported queries are marked for review or as insufficient.

Hunt packs are analyst-reviewable drafts, not automatically deployed detection rules or response actions. A match to a technology catalogue is a relevance signal, not proof that a customer is vulnerable or compromised.

Conservative correlation over noisy merging

Aggressive merging turns unrelated articles into misleading threat events. Correlation instead requires concrete overlap (such as the same CVE) or very strong textual similarity. Merge reasons and source evidence remain inspectable.

Predictable cost and resilience

AI_MAX_TOTAL_TOKENS_PER_RUN, event caps and priority gates put boundaries around model use. Failed article fetches, NVD lookups, item processing, and AI calls are handled as non-fatal errors and recorded when appropriate instead of stopping the entire run.

Output and analyst workflow

A completed run produces a set of prioritised intelligence records. Higher-priority events can carry:

  • CVEs, IOCs, source evidence, NVD and KEV enrichment
  • Priority and managed-technology relevance
  • Optional AI analysis and confidence/limitations
  • Hunting hypotheses and telemetry expectations
  • KQL, UDM and XQL candidate queries marked for analyst review
  • JSON export, a PDF report and rich terminal output

No public performance or accuracy benchmarks are claimed here; the repository is the source for code and implementation details.

What I learned

Feed data is messy. Aggressive cleaning and fallback to summaries were essential when full article retrieval failed.

Correlation is genuinely difficult. Conservative merge rules and explicit reasons were more useful than simply deduplicating everything that looked similar.

LLMs need tight boundaries. Evidence grounding, validation and deterministic records prevented unsupported model output from becoming the source of truth.

Reliability and cost matter. Priority gates, token budgets and a no-AI execution path kept the system practical to operate.

Modularity pays off. The collect → process → correlate → enrich → report separation made targeted testing and iterative fixes much easier.

An early MVP was enough. The original goal was to remove the daily burden of manually reading security feeds, not to build an entire threat-intelligence platform.

Source and next improvements

Explore ThreatIntel on GitHub →

Planned documentation additions for this case study include screenshots of sample reports, a sanitised walkthrough of a completed run, and measured runtime/cost figures if available. These are not presented as features already demonstrated.

← BACK TO ENGINEERING DIVISIONNULLWIRE // FILE TERMINUS