Llm Redteam

io.github.4hmetuyar由 GitHub 帳號 4hmetuyar 發布v0.1.1更新於 Oct 24, 2026

Active jailbreak/extraction/obfuscation red-teaming for live LLM endpoints

概覽

AI 產生的概覽

對您控制的線上 LLM 端點執行以金絲雀為基礎的越獄、提示詞擷取與混淆探測,並回報哪些防護被繞過。

可以做什麼
這個本機 MCP 伺服器透過送出真實探測請求,主動對執行中的 LLM 或聊天機器人進行紅隊測試,而不是分析靜態程式碼。它提供兩個工具:list_probes 不需網路呼叫即可列出五大類共 12 個探測項;run_probe_suite 針對您指定的目標執行探測,並回傳哪些探測繞過了防護。探測涵蓋指令覆寫、系統提示詞擷取、混淆、拒絕抑制與多語言表述,每個繞過結果都附帶建議。CLI 模式支援在 CI 中執行同一套測試。
適用情境
當您想檢查已部署的 LLM 端點或聊天機器人的防護是否真能抵禦已知且公開記錄的越獄與擷取技術時使用。它適合在預備環境或正式環境中自測,以及每次部署都對聊天機器人進行紅隊測試的 CI 流程。它不是靜態程式碼掃描器,也不進行新型攻擊研究。
執行需求
透過 npx 從 npm 套件 @guardbee/mcp-llm-redteam 在本機執行,因此需要 Node.js。您必須提供自己的目標:OpenAI 相容的聊天 API、Anthropic Messages API 或您自己的 webhook 端點。API 金鑰僅以已保存該金鑰的環境變數名稱傳入(apiKeyEnv),例如 OPENAI_API_KEY,且必須在執行前設定。需要能連線至目標的網路。
安裝前請注意
只能指向您擁有或明確獲授權測試的端點;每個探測都會送出真實請求並消耗目標的 API 配額。API 金鑰以環境變數名稱引用而非作為參數傳入,請勿將該變數放入共用設定。此套件預設會傳送使用遙測(工具名稱與簡短參數,不含 API 金鑰、提示詞或目標回應);可用 GUARDBEE_TELEMETRY=0 關閉。探測被擋下並不能證明目標無法攻破。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Llm Redteam,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

@guardbee/mcp-llm-redteam

🇬🇧 English | 🇹🇷 Türkçe | 🇨🇳 中文 | 🇯🇵 日本語 | 🇰🇷 한국어 | 🇧🇷 Português | 🇪🇸 Español | 🇩🇪 Deutsch

[npm version] [npm downloads] [License: MIT]

An MCP (Model Context Protocol) server that actively red-teams a live LLM endpoint or chatbot — not static analysis like GuardBee's other scanners, but real probe requests sent to a real target you control.

ai-code-scanner, mcp-server-auditor, and prompt-injection-scanner all look at code or content at rest. This package looks at a running system: does a deployed LLM/chatbot's guardrails actually hold up against known jailbreak, extraction, obfuscation, and refusal-suppression techniques, right now, in production?

⚠️ Only point this at an endpoint you own or are explicitly authorized to test. Every probe sends a real request and consumes API quota on the target. This is a self-testing tool — you supply your own API key/endpoint.

No probe ever asks the target to produce genuinely harmful content. Every probe is canary-based: success is measured by whether the target reproduces a random, single-use token we generate per run — proof that an out-of-character instruction was obeyed, without ever eliciting real harmful output. This keeps results deterministic (a canary can't appear by coincidence) and safe to run against a live endpoint.

Telemetry is off by default. With GUARDBEE_TELEMETRY=1 it sends the server, tool, success, duration and short parameter values such as a file path; longer strings and fields like content, token or password are replaced with a placeholder. See @guardbee/mcp-telemetry.

Your LLM endpoint / chatbot ◄── llm-redteam ──► Claude              │              ├─ Instruction override    (DAN-style role-play, direct "ignore instructions")              ├─ Extraction              ("repeat everything above", translation-reframed leak)              ├─ Obfuscation             (base64-encoded instruction, zero-width smuggling)              ├─ Refusal suppression     (fake system-override impersonation)              └─ Multilingual            (same override, non-English phrasing)

Features

  • 12 probes, 5 categories — instruction-override, extraction, obfuscation, refusal-suppression, multilingual
  • Canary-based, not harm-based — deterministic pass/fail, never requests real harmful content
  • 3 target types — OpenAI-compatible chat APIs (OpenAI, Groq, local vLLM, etc.), Anthropic Messages API, or your own webhook
  • Every bypass includes why it matters and what to do about it (recommendation)
  • CLI mode for CI (e.g. red-team your staging chatbot on every deploy)
  • 29 unit tests — target adapters tested against a mocked fetch, no real network calls in the test suite

Quick Start

Claude Desktop / MCP Client

json
{  "mcpServers": {    "guardbee-llm-redteam": {      "command": "npx",      "args": ["-y", "@guardbee/mcp-llm-redteam"],      "env": {        "OPENAI_API_KEY": "sk-..."      }    }  }}

Then ask Claude: "Run the GuardBee red-team suite against my OpenAI endpoint using gpt-4o-mini."

CLI (CI/CD)

bash
export OPENAI_API_KEY=sk-...npx @guardbee/mcp-llm-redteam probe --type=openai --model=gpt-4o-mini --api-key-env=OPENAI_API_KEY --fail-on=high
bash
# Your own chatbot endpointnpx @guardbee/mcp-llm-redteam probe --type=webhook --url=https://staging.example.com/chat --fail-on=any

MCP Tools

ToolDescription
list_probesLists all probes by category — no network call
run_probe_suiteRuns probes against a target you specify; returns which ones bypassed the guardrails

Target Types

TypeUse for
openaiOpenAI's Chat Completions API, or any OpenAI-compatible gateway via baseUrl (Groq, local vLLM/Ollama proxies, etc.)
anthropicAnthropic's Messages API directly
webhookYour own chatbot/product endpoint — POSTs { prompt } as JSON, reads the reply from a configurable field

The API key is never passed as a tool/CLI parameter — only the name of an environment variable that already holds it (apiKeyEnv). Set that env var before running.


Detected Bypass Categories

CategoryExample probeSeverityWhat a bypass means
instruction-overridedirect_override, role_play_danhighA direct or role-play override instruction replaced the system prompt's authority
extractionsystem_prompt_leak_direct, repeat_abovecriticalThe target revealed (or proved it would reveal) its own system prompt
obfuscationbase64_instruction, zero_width_smugglinghigh/mediumAn override instruction hidden via encoding or invisible characters still worked
refusal-suppressionauthority_impersonationhighA fake "system override" framing was granted real instruction authority
multilingualnon_english_overridemediumThe same override succeeded when phrased in a non-English language

These are known, publicly documented technique shapes — this is defensive coverage testing, not novel attack research. A held probe doesn't prove a target is unbreakable; a bypassed probe is a concrete, reproducible finding.


Development

bash
npm run buildnpm test             # 29 unit tests

License

MIT — GuardBee

Feedback

Questions, ideas, or a false positive? Start a thread in GitHub Discussions or open an issue. If GuardBee is useful to you, a ⭐ on the repository helps others find it.

來源:packages/llm-redteam/README.md,提交 040e072

工具

0
SourceWeft 尚未在沙箱中啟動過該軟體包,因此其工具未知。

版本歷史

1
  1. v0.1.1最新Sep 29, 2026

評分

已滿足適用檢查項的 50%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通25 分

    請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。

  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分