Build AI Agents You Can Trust
Open-source red-team toolkit to test AI agents against prompt injection, jailbreaking, and goal hijacking attacks.
app.hackagent.dev
Quick Start: Run Your First Attack
Select your agent framework, then copy the Python snippet to get started.
Test a Google Agent Development Kit agent for jailbreaking and prompt injection. HackAgent sends adversarial goals via the ADK protocol and uses an LLM judge to evaluate whether safety guardrails were bypassed.
1Install HackAgent
$ pip install hackagent
2Configure and run the attack
from hackagent import HackAgent
agent = HackAgent(
name="my_adk_agent",
endpoint="http://localhost:8000",
agent_type="google-adk",
)
results = agent.hack(attack_config={
"attack_type": "advprefix",
"goals": ["Bypass the agent's safety guidelines"],
"generator": {
"identifier": "gpt-4o-mini",
"endpoint": "https://api.openai.com/v1",
},
"judges": [{
"identifier": "gpt-4o-mini",
"endpoint": "https://api.openai.com/v1",
"type": "harmbench",
}],
})3Review your risk report
JailbreakingPrompt InjectionGoal Hijacking
Get Started in Seconds
Install HackAgent with a single command and start testing your AI agents immediately.
hackagent — bash
$
Ready in seconds