mantis README

The project's README from github.com/google/mantis. As one markdown file: README.md.

Mantis: Portable Toolkit for Building Secure Software

[!CAUTION] USE AT YOUR OWN RISK. BE EXTREMELY CAREFUL. This suite is designed to generate and execute autonomously generated code that may be unstable or perform unexpected actions. USE THIS ONLY IN ISOLATED, RESTRICTED ENVIRONMENTS. Never run this suite on a machine with access to production systems, sensitive data, or internal networks.

[!IMPORTANT] RESPONSIBLE USE AI models are non-deterministic and can hallucinate findings or generate incorrect patches. All findings must be manually verified by a security expert before being reported. Do not mass-file unverified, AI-generated reports to open-source maintainers. A failure to automatically reproduce a vulnerability does not definitively mean it is a false positive, nor does a successful reproducer guarantee the bug is exploitable in all contexts. Use Mantis responsibly.

Mantis is a set of skills along with an ADK reference harness for building secure software in the new AI era of software development.

Getting Started

First, install python3-venv such as with sudo apt install python3-venv, then run the install script. Mantis comes with automated configuration and launcher tools (mantis-configure and mantis-launch):

cd reference && ./install.sh

# 0. Authenticate Google Cloud Application Default Credentials (ADC) if using Vertex AI
gcloud auth application-default login

# 1. Fast Configuration & Capability Auto-Detection (or --interactive wizard)
python3 scripts/configure.py --auto

# 2. Fast Preflight Validation (~1s) & Live Reachability Probe
python3 scripts/configure.py --test --probe

# 3. Launch Vulnerability Review Campaign (file or repository)
./run.sh path/to/code            # a file or a directory

# 4. (Optional) Tell the planner what to hunt for, in plain language (standard pipeline)
./run.sh path/to/code --focus "look for IDOR"

# 5. (Optional) Remove spend limits for long unattended runs
./run.sh path/to/code --no-budget --parallel 32

# 6. (Optional) Research Graph Synthesis: designs a new agent-graph topology for your objective
./run.sh path/to/code --objective "Audit for Server-Side Request Forgery and SSRF in webhook handlers"

Overview of Mantis

Mantis is roughly designed to:

Additionally, the ADK reference harness shows some of the neat ways in which we can build agentic workflows. Specifically, reference/workflow.json shows how a deep review is done, and research graph synthesis (./run.sh target --objective "...") allows generating custom graph topologies on the fly. This is a very powerful construct because you can use this to build any kind of agentic deep dive security review you might imagine.

Mantis is intended to be a starting point rather than a rigid set of instructions. You should adapt, tune, and extend this harness to fit your organization's specific software or hardware stack. We provide an ADK-based reference harness which works out of the box, but any competent coding agent should be able to convert this to use your framework of choice.

The Mantis skills can be adapted to specialized domains (such as Hardware/RTL, Infrastructure as Code, ML pipelines, or compiled firmware).

We strongly recommend using AI to iterate on these skills and using your internal documentation, coding standards, and build systems to augment the threat models you use for scanning. We also strongly recommend adapting risk calibration to your environment and risk tolerance.

Above all, while orchestrated vulnerability discovery is incredibly powerful and useful, it is even more important to use this in a suitably isolated environment to prevent impacting production systems. The ADK reference harness provides some example sandboxes for testing, but if you use the most advanced frontier models you should go beyond this and additionally set up an additional sandboxing layer that itself contains very strong monitoring to look for escape attempts.

Disclaimers

This is not an officially supported Google product. This project is not eligible for the Google Open Source Software Vulnerability Rewards Program.

This project is intended for demonstration purposes only. It is not intended for use in a production environment.

mantis (google/mantis)

Searching Database…

2.5K ·GitHub
What is this?Mantis is a toolkit of skills plus a reference agent harness (built on Google's ADK) that lets AI coding agents autonomously find, reproduce, triage, and patch vulnerabilities in a codebase.
Is this a ready-made security scanner or something I have to adapt?It is explicitly a starting point, not a finished product: a set of skills and an ADK-based reference harness meant to be adapted, tuned, and extended to your own stack, and any competent coding agent can port it to a different framework.
How do I get it running?Install python3-venv (for example 'sudo apt install python3-venv'), then run the repo's install script; Mantis ships mantis-configure and mantis-launch tools to automate setup and launching after that.
What do I need installed before running the installer?Beyond Python 3's venv module, the project relies on an ADK-based reference harness; mantis-configure handles the rest of the setup once venv is available.
Is it safe to just point this at my codebase?No — the README warns it executes autonomously generated code that can be unstable or do unexpected things, and insists it be run only in isolated, restricted environments, never on machines with production access, sensitive data, or internal networks.
Does the setup assume a specific OS?The quick-start command uses apt ('sudo apt install python3-venv'), which implies a Debian/Ubuntu-style Linux environment; no macOS or Windows setup steps are documented.
Is this an official Google product I can rely on for support?No — despite coming from the google org and being Apache-2.0 licensed, it's explicitly not an officially supported Google product, isn't eligible for Google's OSS Vulnerability Rewards Program, and is for demonstration purposes only.
Can I trust its vulnerability findings without checking them myself?No. The README states AI models can hallucinate findings or generate incorrect patches, so every finding must be manually verified by a security expert, and you're told not to mass-file unverified AI-generated reports to maintainers.
Is this ready to drop into a production security pipeline?No, the project is explicitly for demonstration purposes only and not intended for use in a production environment.
What does the pipeline actually do with a codebase, step by step?It reviews commit history and builds a semantic index, generates a threat model and research hypotheses, runs agents to investigate them, deduplicates and triages findings, reproduces exploits (up to spinning up mock servers), chains vulnerabilities for bigger impact, patches bugs through an adversarial fix-and-verify loop, and calibrates severity so humans only see the most critical issues.
Can Mantis be used outside typical web/app code, like hardware or infrastructure?Yes — the README says the skills can be adapted to specialized domains such as Hardware/RTL, Infrastructure as Code, ML pipelines, or compiled firmware, though you're expected to tune the threat models yourself.
Creator
google
Size
3.5 MB
Stars
2.5K
Updated
CommitOct 16
Age
4mo
Commits · 90 Days