garak
RepositoryFreeLLM vulnerability scanner
Capabilities11 decomposed
multi-model vulnerability scanning with pluggable harnesses
Medium confidenceGarak scans LLMs for vulnerabilities by routing prompts through a modular harness system that abstracts different model providers (OpenAI, Anthropic, Ollama, vLLM, etc.) behind a unified interface. Each harness handles authentication, rate limiting, and response parsing for its target model, allowing the same vulnerability test suite to run against any LLM without code changes. The architecture uses a plugin-based loader pattern to dynamically instantiate harnesses at runtime based on configuration.
Uses a harness abstraction layer that decouples vulnerability tests from model provider implementations, enabling the same test suite to run against OpenAI, Anthropic, open-source models, and custom endpoints without modification. Most competitors either target specific providers or require test rewrites per model.
Garak's harness-based design allows security teams to test heterogeneous LLM deployments with a single tool, whereas alternatives like Promptfoo focus on prompt evaluation and Rebuff targets specific attack patterns.
probe-based vulnerability test generation and execution
Medium confidenceGarak organizes vulnerability tests as 'probes' — modular test units that generate adversarial prompts, send them to a target LLM via a harness, and evaluate responses against detection criteria. Probes are organized into taxonomies (e.g., 'jailbreak', 'prompt-injection', 'hallucination') and can be composed into test suites. Each probe implements a generate() method that produces test prompts (often using templates or programmatic construction) and a detect() method that classifies model responses as vulnerable or safe based on heuristics, keyword matching, or semantic similarity.
Implements a two-stage probe architecture (generate + detect) that separates test prompt creation from response evaluation, allowing probes to be reused across different detection strategies and enabling custom detection logic without modifying prompt generation. This is more flexible than monolithic test frameworks that couple prompt and evaluation logic.
Garak's probe taxonomy provides broader coverage of LLM vulnerabilities (jailbreaks, prompt injection, hallucination, bias) compared to narrower tools like Rebuff (jailbreak-focused) or Promptfoo (prompt optimization-focused).
cli and programmatic api for test execution
Medium confidenceGarak exposes both a command-line interface (CLI) and a Python API for executing vulnerability scans. The CLI uses argparse to parse configuration and invoke the orchestrator, making garak accessible to non-programmers. The Python API provides classes and functions for programmatic test execution, enabling integration into Python-based workflows, notebooks, and CI/CD pipelines. Both interfaces share the same underlying orchestrator, ensuring consistent behavior. The architecture uses a facade pattern to abstract CLI and API differences, allowing users to choose the interface that best fits their workflow.
Provides both CLI and Python API interfaces backed by the same orchestrator, allowing users to choose the interface that best fits their workflow (command-line for one-off scans, Python API for automation). The facade pattern ensures consistent behavior across interfaces.
Garak's dual interface (CLI + API) is more flexible than CLI-only tools (like some security scanners) or API-only tools (like some Python libraries), enabling broader adoption across different user types and workflows.
configurable test suite orchestration and reporting
Medium confidenceGarak provides a configuration-driven orchestration layer that chains together harnesses, probes, and detectors into executable test suites. Users define test runs in YAML/JSON config files specifying which models to test, which probes to run, and how to aggregate results. The orchestrator handles sequential or parallel probe execution (depending on harness concurrency support), collects results, and generates structured reports (JSON, CSV, HTML) with vulnerability metrics, model comparisons, and risk summaries. The architecture uses a run manager pattern to track test state and enable resumable/incremental scanning.
Uses a declarative YAML/JSON configuration model to define test suites, allowing non-programmers to compose complex multi-model security tests without writing code. The run manager pattern enables resumable scans and incremental result collection, reducing cost and time for large-scale audits.
Garak's configuration-driven orchestration is more flexible than CLI-only tools and provides better auditability than programmatic test frameworks, making it suitable for compliance-heavy environments.
adversarial prompt generation with template and programmatic strategies
Medium confidenceGarak's probes generate adversarial prompts using multiple strategies: template-based (filling placeholders in predefined jailbreak/injection patterns), programmatic (constructing prompts via Python logic to vary parameters), and potentially LLM-based (using auxiliary models to generate novel attack prompts). Probes can combine strategies — e.g., a jailbreak probe might use templates for known attacks and programmatic generation for variations. The generation layer abstracts prompt construction, allowing probes to focus on detection logic and enabling reuse of generation strategies across multiple probes.
Separates prompt generation from detection, allowing probes to use multiple generation strategies (templates, programmatic, LLM-based) and enabling reuse of generation logic across different detection criteria. This modularity makes it easier to add new attack patterns without duplicating generation code.
Garak's multi-strategy generation approach is more comprehensive than single-strategy tools; it supports both curated jailbreak templates and programmatic variation, whereas competitors often use only one approach.
response evaluation and vulnerability detection with multiple criteria
Medium confidenceGarak's detection layer evaluates LLM responses against multiple criteria to classify them as vulnerable or safe. Detection strategies include keyword/regex matching (e.g., detecting refusal phrases or harmful content keywords), semantic similarity (comparing responses to known vulnerable outputs using embeddings), classifier-based detection (using auxiliary ML models to score response safety), and custom heuristics. Probes compose these strategies — e.g., a jailbreak probe might use keyword matching for obvious bypasses and semantic similarity for subtle ones. The detection layer is decoupled from prompt generation, allowing the same response to be evaluated by multiple detectors.
Implements a composable detection architecture where multiple detection strategies (keyword, semantic, classifier) can be combined per probe, allowing fine-grained control over false positive/negative tradeoffs. Most competitors use single detection strategies, making them less flexible for diverse vulnerability types.
Garak's multi-strategy detection is more robust than keyword-only tools (like simple regex scanners) and more flexible than single-model approaches (like classifier-only tools), enabling better accuracy across diverse attack types.
taxonomy-based vulnerability classification and organization
Medium confidenceGarak organizes vulnerabilities into a hierarchical taxonomy (e.g., 'jailbreak', 'prompt-injection', 'hallucination', 'bias', 'privacy') with subtypes and specific probes for each category. The taxonomy is exposed as a discoverable API — users can list available probes, filter by vulnerability type, and understand the coverage of each category. The taxonomy structure enables organized reporting (grouping results by vulnerability class) and helps users understand which attack vectors are tested. The architecture uses a registry pattern to dynamically load probes and organize them by taxonomy.
Provides a discoverable, hierarchical taxonomy of LLM vulnerabilities with explicit probe mappings, allowing users to understand test coverage and plan audits systematically. Most competitors lack explicit taxonomy organization, making it harder to assess what vulnerabilities are tested.
Garak's taxonomy-based organization makes it easier for non-security experts to understand vulnerability scope and plan comprehensive audits, whereas competitors often require deep knowledge of attack types.
batch scanning and result aggregation across multiple models
Medium confidenceGarak supports scanning multiple LLMs in a single test run, aggregating results across models to enable comparative analysis. The orchestrator manages harness instances for each model, routes probes to all harnesses, and collects results in a unified format. Aggregation includes per-model vulnerability counts, cross-model comparisons (e.g., 'Model A is vulnerable to X, Model B is not'), and overall risk rankings. The architecture uses a result collector pattern to normalize outputs from different harnesses and enable flexible aggregation strategies.
Normalizes results across heterogeneous LLM providers (OpenAI, Anthropic, open-source, custom) into a unified format, enabling direct comparative analysis without manual result reconciliation. The result collector pattern abstracts provider-specific output formats, making it easy to add new models.
Garak's multi-model aggregation is more comprehensive than single-model tools and more flexible than provider-specific benchmarks, enabling fair comparisons across diverse LLM ecosystems.
extensible harness framework for custom llm integration
Medium confidenceGarak provides a harness base class that developers can subclass to add support for new LLM providers or custom deployments. A harness implements methods for authentication, prompt submission, response retrieval, and error handling. The framework handles harness discovery and instantiation via a plugin loader, allowing new harnesses to be added without modifying core garak code. Harnesses can implement provider-specific optimizations (e.g., batch API calls, streaming responses, custom retry logic) while maintaining a uniform interface for the orchestrator. The architecture uses dependency injection to pass configuration to harnesses at runtime.
Provides a well-defined harness abstraction with plugin-based discovery, allowing developers to add new LLM providers without modifying core code. The dependency injection pattern enables flexible configuration and testing. This is more extensible than monolithic tools that hardcode provider support.
Garak's harness framework is more flexible than tools with fixed provider support, enabling integration with proprietary or custom LLMs that competitors cannot easily support.
probe extensibility and custom vulnerability test development
Medium confidenceGarak provides a probe base class that developers can subclass to implement custom vulnerability tests. A probe implements generate() (to produce test prompts) and detect() (to evaluate responses) methods. The framework handles probe discovery, instantiation, and execution via a plugin loader. Custom probes can implement domain-specific attacks, novel detection strategies, or variations of existing probes. The architecture uses a probe registry to organize probes by taxonomy and enable dynamic filtering/selection. Probes can depend on external resources (templates, models, APIs) injected at runtime.
Provides a modular probe architecture where generate() and detect() are separate methods, allowing developers to create custom probes by implementing only the methods relevant to their use case. The probe registry enables dynamic discovery and filtering, making it easy to compose test suites from custom and built-in probes.
Garak's probe extensibility is more flexible than fixed test suites, enabling researchers and security teams to develop custom tests without forking the codebase or reimplementing core functionality.
result persistence and historical tracking
Medium confidenceGarak can persist test results to local files (JSON, CSV) or external databases, enabling historical tracking of vulnerability trends across test runs. The result storage layer abstracts persistence details, allowing results to be written to multiple backends. Users can query historical results to track vulnerability remediation, model improvement, or regression detection. The architecture uses a result writer pattern to normalize outputs from different harnesses and enable flexible storage strategies. Results include metadata (timestamp, model version, probe version) to enable accurate historical comparison.
Provides a result writer abstraction that enables flexible persistence strategies (files, databases, APIs) without modifying core scanning logic. Results include rich metadata (timestamps, model versions, probe versions) enabling accurate historical comparison and trend analysis.
Garak's result persistence enables long-term vulnerability tracking, whereas competitors often focus on single-run reporting without historical context.
Capabilities are decomposed by AI analysis. Each maps to specific user intents and improves with match feedback.
Related Artifactssharing capabilities
Artifacts that share capabilities with garak, ranked by overlap. Discovered automatically through the match graph.
hexstrike-ai
HexStrike AI MCP Agents is an advanced MCP server that lets AI agents (Claude, GPT, Copilot, etc.) autonomously run 150+ cybersecurity tools for automated pentesting, vulnerability discovery, bug bounty automation, and security research. Seamlessly bridge LLMs with real-world offensive security capa
hexstrike-ai
HexStrike AI MCP Agents is an advanced MCP server that lets AI agents (Claude, GPT, Copilot, etc.) autonomously run 150+ cybersecurity tools for automated pentesting, vulnerability discovery, bug bounty automation, and security research. Seamlessly bridge LLMs with real-world offensive security capa
OSV
** - Access the [OSV (Open Source Vulnerabilities) database](https://osv.dev/) for vulnerability information. Query vulnerabilities by package version or commit, batch query multiple packages, and get detailed vulnerability information by ID.
RunSybil
Revolutionize cybersecurity: AI-driven, rapid, accurate pentesting...
strix
Open-source AI hackers to find and fix your app’s vulnerabilities.
Pentest Copilot
AI-enhanced, efficient cybersecurity penetration testing...
Best For
- ✓security teams evaluating LLM deployment risk
- ✓LLM providers building internal red-teaming infrastructure
- ✓enterprises auditing third-party LLM integrations
- ✓red teamers building custom attack test suites
- ✓LLM safety researchers evaluating mitigation strategies
- ✓compliance teams documenting LLM risk assessments
- ✓security teams using garak in CI/CD pipelines
- ✓researchers using garak in Python notebooks
Known Limitations
- ⚠Harness coverage limited to explicitly implemented providers — custom models require writing new harness code
- ⚠Rate limiting and quota handling delegated to harness implementations — inconsistent behavior across providers
- ⚠No built-in cost tracking — high-volume scanning against paid APIs can incur unexpected charges
- ⚠Synchronous harness execution creates bottlenecks when scanning many models sequentially
- ⚠Detection heuristics are often rule-based (keyword/regex matching) — brittle against paraphrased or obfuscated responses
- ⚠Probe coverage is manually curated — emerging attack patterns require new probe implementations
Requirements
Input / Output
UnfragileRank
UnfragileRank is computed from adoption signals, documentation quality, ecosystem connectivity, match graph feedback, and freshness. No artifact can pay for a higher rank.
Package Details
About
LLM vulnerability scanner
Categories
Alternatives to garak
Are you the builder of garak?
Claim this artifact to get a verified badge, access match analytics, see which intents users search for, and manage your listing.
Get the weekly brief
New tools, rising stars, and what's actually worth your time. No spam.
Data Sources
Looking for something else?
Search →