What is CERT-X-GEN
Modern security scanning has outgrown static templates. Today's vulnerability detection often requires real programming logic, protocol-level control, data processing, and reuse of existing scripts — yet most scanners force everything into YAML-only abstractions.
CERT-X-GEN is a different kind of scanner. It is a polyglot security execution engine that treats vulnerability detection as code, not configuration. You write detection logic in the language that fits the problem — CERT-X-GEN handles orchestration, sandboxing, and output.
What this means in practice:
# Run a Python template for stateful protocol checks
# Run a Go template for high-performance database probing
# Mix multiple languages in one scan
Highlights
- A language-agnostic runtime for vulnerability detection logic
- A unified execution layer for security checks across 12 languages
- A bridge between research scripts and production scanners
- A scanner designed for CI, automation, and agentic systems
Why This Matters
The Problem
YAML DSLs hit a wall when you need:
- Multi-step protocol conversations
- Binary protocol parsing
- Conditional branching logic
- Performance-critical operations
- Native library access
The Solution
CERT-X-GEN runs templates written in:
- Python — stateful protocols, data analysis
- Go — concurrent operations, binary protocols
- Rust/C — maximum performance
- Shell — native tool integration
- YAML — simple checks, compatibility
Real-World Examples
| Scenario | Template | Why It Can't Be YAML |
|---|---|---|
| SMTP relay testing | smtp-open-relay.py |
Multi-step conversation: EHLO → MAIL FROM → RCPT TO with branching |
| PostgreSQL auth check | postgresql-default-credentials.go |
PostgreSQL wire protocol + MD5 challenge-response |
| SNMP community strings | snmp-default-community.sh |
Native snmpwalk integration |
| VNC no-auth detection | vnc-no-auth.c |
RFB binary protocol handshake |
Installation
Homebrew (macOS/Linux)
Quick Install Script
|
Docker
# Scan with Docker
From Source
Using Cargo
Download Binary
Download pre-built binaries from GitHub Releases:
cxg-linux-amd64— Linux x86_64cxg-linux-arm64— Linux ARM64cxg-darwin-amd64— macOS Intelcxg-darwin-arm64— macOS Apple Siliconcxg-windows-amd64.exe— Windows x86_64
Verify Installation
Quick Start
Basic Scanning
# Scan a single target
# Scan with specific ports
# Scan a network range
# Scan targets from a file
Template Operations
# List available templates
# Search templates
# Validate a template
# Get template info
Output Formats
# JSON output
# HTML report
# SARIF for CI/CD
Templates
Templates are maintained in a separate repository for community contributions:
github.com/Bugb-Technologies/cert-x-gen-templates
| Language | Count | Best For |
|---|---|---|
| Python | 15 | Stateful protocols, HTTP APIs, data processing |
| Go | 5 | Binary protocols, high concurrency |
| C | 5 | Low-level protocols, maximum performance |
| Rust | 4 | Memory-safe performance, async I/O |
| Shell | 5 | Native tool integration, system checks |
| YAML | 24 | Simple HTTP checks, Nuclei compatibility |
Templates auto-download on first scan. Update with cxg template update.
Writing Templates
All templates follow a simple contract:
- Read
CERT_X_GEN_TARGET_HOSTandCERT_X_GEN_TARGET_PORTfrom environment - Perform detection logic
- Output JSON with findings array
Python example:
#!/usr/bin/env python3
# @id: redis-unauth
# @name: Redis Unauthenticated Access
# @severity: high
=
=
=
=
Design Principles
- Code over configuration — use real languages for real logic
- Deterministic execution — same input, same output
- Sandboxed by default — templates run with strict resource limits
- Composable scans — mix languages, reuse logic across templates
- Automation-first — built for CI, pipelines, and agentic systems
Features
Execution Engine
- 12 supported languages (Python, Go, Rust, C, C++, Java, JavaScript, Ruby, Perl, PHP, Shell, YAML)
- Sandboxed execution with configurable resource limits
- Compilation caching for compiled languages
- Parallel template execution with rate limiting
CLI
- Unified
--scopefor targets (single, file, CIDR, URL) - Smart
--templatesselection (glob patterns, tags, severity) - Multiple output formats (JSON, HTML, CSV, Markdown, SARIF)
- Built-in template management and validation
Integration
- Git-based template repositories with auto-update
- CI/CD friendly (exit codes, SARIF output)
- Configurable via CLI, config file, or environment variables
Documentation
| Document | Description |
|---|---|
| Usage Guide | Comprehensive CLI usage and examples |
| Architecture | System design and internals |
| Engine Guide | Language-specific execution details |
| Sandbox Guide | Security model and resource limits |
| Contributing | How to contribute code and templates |
Contributing
We welcome contributions. See CONTRIBUTING.md for guidelines.
Priority areas:
- New detection templates (any language)
- Protocol handler improvements
- Documentation and examples
# Development setup
License
CERT-X-GEN is licensed under Apache License 2.0.
Security
Report vulnerabilities to security@bugb.io. See SECURITY.md.