ctias-lab

CTIAS Lab Architecture

Overview

CTIAS Lab is a multi-language, modular architecture designed for extensibility and scalability. The system uses a gateway-and-modules pattern, allowing new threat analysis capabilities to be added without modifying core infrastructure.

System Components

1. Frontend (User Interface)

2. Gateway API (Orchestration)

3. Module System

Python Modules

Java Modules

JavaScript Modules

4. Data Storage

Data Flow

IOC Analysis Workflow

1. User submits IOC (IP/domain/URL/hash) via Frontend
2. Gateway receives request, stores in job queue
3. Gateway spawns tasks:
   - Python module: IP reputation lookup
   - Java module: Protocol analysis
   - JS module: URL parsing
4. Modules process in parallel, return results
5. Gateway aggregates results
6. Frontend displays unified findings

Log Processing Workflow

1. User uploads logfile to Gateway
2. Java log-normalizer parses and normalizes events
3. Events stored in PostgreSQL
4. Python anomaly detector runs ML models
5. Java rule engine applies detection rules
6. Detections highlighted in Frontend dashboard

Module Contract

All modules expose a standardized interface:

{
  "/health": {
    "status": "healthy"
  },
  "/meta": {
    "name": "ioc-enrichment",
    "version": "1.0.0",
    "inputs": {"ioc": "string", "ioc_type": "enum"},
    "outputs": {"reputation": "object", "confidence": "float"}
  },
  "/run": {
    "POST": "Execute module task"
  }
}

Deployment Architecture

Docker Compose (Local Dev)

Kubernetes (Production)

Security Architecture

Extension Points

Adding New Python Module

  1. Create modules-python/new-module/
  2. Implement /health, /meta, /run endpoints
  3. Register in Gateway config
  4. Gateway auto-discovers and exposes

Adding New Detection Rule

  1. Create rules/sigma/new-rule.yml
  2. Submit PR for community review
  3. Once merged, rule available in rule engine

Performance Considerations

Monitoring & Observability

Development Workflow

  1. Clone repo
  2. docker-compose up for local stack
  3. Frontend at http://localhost:3000
  4. API at http://localhost:8000/docs
  5. Logs via docker-compose logs -f