secagent
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@secagentRun a reconnaissance scan on 10.0.0.5 and list exposed services."
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
SecAgent ๐
ๅบไบ MCP (Model Context Protocol) ็่ชไธปๅฎๅ จ่ฏไผฐ Agent โโ ๆ็ๅฎ็ Kali ๅฎๅ จๅทฅๅ ทๅฐ่ฃ ๆ MCP Server๏ผ่ฎฉ LLM ๆพๅผ่งๅใๅนถ/ไธฒ่ก่ฐ็จๅทฅๅ ทใๅๅฑ่ฎฐๅฟๅ็ฐใๆ ๅฐ MITRE ATT&CKใ่ชๅจ็ๆๆฅๅใ
ๅฎๅ จไผๅ ๏ผไพตๅ ฅๅผๆไฝ้ป่ฎค้่ฆไบบๅทฅๆนๅ๏ผๅทฅๅ ท่ฐ็จๅ จ็จๅฎก่ฎก๏ผๆฏๆ็ฎๆ ็ฝๅๅไธ็ง็ฝ่ฎฟ้ฎ็ฎกๆงใ
ๆๆๆผ็คบ
็ปไธไธช็ฎๆ ๏ผAgent ่ชๅทฑ่งๅใ่ชๅทฑๅณๅฎๆฏไธๆญฅๅไปไน๏ผ
$ python secagent.py --target 192.168.1.10 --report out/report.mdโญโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ plan โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฎ
โ Plan for 192.168.1.10: โ
โ โ 1. Probe the target to confirm it is live (http_probe) โ
โ โ 2. Inspect HTTP security headers (check_security_headers) โ
โ โ 3. Review robots.txt for hidden paths (check_robots) โ
โ โ 4. Enumerate sensitive directories (ffuf_dirs) [intrusive] โ
โ โ 5. Port/service scan (nmap_scan) [intrusive] โ
โ โ 6. Consolidate into a risk assessment โ
โฐโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฏ
step 1 ยท reasoning
โ nmap_server__nmap_scan {"target": "192.168.1.10"}
โ 22/tcp open ssh OpenSSH 8.2p1 / 80/tcp open http nginx 1.18.0
step 2 ยท reasoning
running 3 tool calls in parallel โ ๅนถ่กๆง่ก
โ httpx_server__http_probe {"url": "http://192.168.1.10"}
โ httpx_server__check_security_headers {"url": "http://192.168.1.10"}
โ httpx_server__check_robots {"url": "http://192.168.1.10"}
โ status 200, server nginx/1.18.0
โ missing: content-security-policy, x-frame-options (4/6)
โ interesting: /admin, /backup
step 3 ยท reasoning
โ ffuf_server__ffuf_dirs {"url": "http://192.168.1.10/FUZZ"}
โ 7 hits: /admin (301), /backup.zip (200), ...
ATT&CK: T1046, T1592, T1083
report written: out/report.md็ๆ็ๆฅๅๅ ๅซ ๆง่ก่ฎกๅ / ATT&CK ๆ ๅฐ / ้ ็ฝฎๅผฑ็น / Agent ็ป่ฎบ๏ผ
# SecAgent Assessment Report
**Steps used:** 5 **Tool calls:** 11
## Summary
- Open ports: 22, 80
- Services: ssh, nginx 1.18.0
- Missing security headers: content-security-policy, x-frame-options
## Plan execution
| # | Task | Status | Intrusive |
|---|------|--------|-----------|
| 1 | Probe the target | done | no |
...
## MITRE ATT&CK techniques observed
| ID | Technique | Tactic |
|----|-----------|--------|
| T1046 | Network Service Discovery | Discovery |
| T1592 | Gather Victim Host Information | Reconnaissance |
| T1083 | File and Directory Discovery | Discovery |
## Configuration weaknesses
- **content-security-policy** โ No CSP: reflected XSS has no browser-level mitigation.
## Agent report
### Findings
...Related MCP server: Hercules MCP
ๆถๆ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ SecAgent โ
โ โ
โ โโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโโโโโโโโโโ โ
โ โ Planner โโโโโโโโโถโ ReAct Execution Loop โ โ
โ โ โ โ โ โ
โ โ 1. plan() โ โ think โ call โ observe โ โ
โ โ 2. revise() โโโโโ3โโโโโ (parallel tool calls) โ โ
โ โโโโโโโโโโโโโโโโ steps โโโโโโโโโโโโโโฌโโโโโโโโโโโโโโ โ
โ โ โ
โ โโโโโโโโโโโโโโโดโโโโโโโโโโโโโโ โ
โ โ Tiered Memory โ โ
โ โ raw observations + โ โ
โ โ distilled findings โ โ
โ โโโโโโโโโโโโโโโโโโโโโโโโโโโโโ โ
โ โ โ
โ โโโโโโโโโโโโโโโดโโโโโโโโโโโโโโ โ
โ โ Policy Gate โ โ
โ โ deny / ask / allow โ โ
โ โโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโ โ
โ โโโโโโโโโโโโโโโดโโโโโโโโโโโโโโ โ
โ โ ATT&CK Mapper + Report โ โ
โ โ + SQLite History โ โ
โ โโโโโโโโโโโโโโโโโโโโโโโโโโโโโ โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ MCP protocol (stdio)
โโโโโโโโโโโโโโฌโโโโโโโโโดโโโโโโโโฌโโโโโโโโโโโโโ
โผ โผ โผ โผ
โโโโโโโโโโโโ โโโโโโโโโโโโ โโโโโโโโโโโโโ โโโโโโโโโโโโ
โ nmap โ โ httpx โ โ sqlmap โ โ ffuf โ
โ 2 tools โ โ 3 tools โ โ 3 tools โ โ 1 tool โ
โโโโโโฌโโโโโโ โโโโโโฌโโโโโโ โโโโโโโฌโโโโโโ โโโโโโฌโโโโโโ
โผ โผ โผ โผ
nmap httpx+re sqlmap ffufๆจกๅ่่ดฃ
ๆจกๅ | ๆไปถ | ่่ดฃ |
Planner |
| Plan-and-Execute๏ผไธๆฌกๆงๅ่งฃ็ฎๆ + ๆฏ 3 ๆญฅ้่งๅ |
ReAct Core |
| ๆจ็โ่ฐ็จๅทฅๅ ทโ่งๅฏๅพช็ฏ๏ผๆฏๆๅนถ่กๅทฅๅ ท่ฐ็จ |
MCP Manager |
| MCP Server ็ๅฝๅจๆใๅทฅๅ ทๅ็ฐใๅฝๅ็ฉบ้ด้็ฆป |
Memory |
| ๅๅฑ่ฎฐๅฟ๏ผๅๅง่งๅฏ๏ผๆ้ข็ฎ๏ผ+ ็ปๆๅๅ็ฐ |
ATT&CK Mapper |
| ๅ็ฐ โ MITRE ATT&CK ๆๆฏ ID + ้ ็ฝฎๅผฑ็น่ฏดๆ |
Policy |
| ๅทฅๅ ทๅ็บงใ็ฎๆ ็ฝๅๅใไบบๅทฅๆนๅ้จๆง |
Store |
| SQLite ๆไน ๅ + ๅๆฌกๆซๆๅฏนๆฏ |
Retry |
| ็ฌๆถ้่ฏฏๆๆฐ้้ฟ้่ฏ |
Report |
| ๆธฒๆ Markdown / JSON ๆฅๅ |
ๅฎๅ จๆจกๅ
่ชไธป Agent ๆง่ก็ๅฎ็ๆปๅปๅทฅๅ ท๏ผๆๅคง็้ฃ้ฉๆฏๅฎ่ชๅทฑๅณๅฎๅปๅไปไนใSecAgent ็จไธๅฑ็บฆๆ่งฃๅณ่ฟไธช้ฎ้ขใ
1. ๅทฅๅ ทๅ็บง โ ไพตๅ ฅๅผๆไฝ้ป่ฎค้่ฆไบบๅทฅๆนๅ
PASSIVE_TOOLS = {"http_probe", "check_security_headers", "check_robots"}
INTRUSIVE_TOOLS = {"nmap_scan", "nmap_vuln_scan", "sqlmap_scan",
"sqlmap_dump", "ffuf_dirs", ...}$ python secagent.py --target 192.168.1.10 --policy ask
step 2 ยท reasoning
โ sqlmap_server__sqlmap_scan {"url": "http://192.168.1.10/news.php?id=1"}
โญโโโโโโโโโโโโโโโโโโโโ โ approval required โโโโโโโโโโโโโโโโโโโโโฎ
โ sqlmap_scan โ
โ {"url": "http://192.168.1.10/news.php?id=1"} โ
โ โ
โ 'sqlmap_scan' sends intrusive traffic and needs approval โ
โฐโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฏ
Allow this action? [y/N]ไธ็งๆจกๅผ๏ผ
ๆจกๅผ | ่ขซๅจๅทฅๅ ท | ไพตๅ ฅๅทฅๅ ท | ้็จๅบๆฏ |
| โ ่ชๅจๆพ่ก | โ ไธๅพๆ็ป | ็ไบง็ฏๅข็ๅช่ฏปไพฆๅฏ |
| โ ่ชๅจๆพ่ก | โ ๏ธ ๅผน็ช็ญไบบๅทฅ็กฎ่ฎค | ๅธธ่งๆธ้ๆต่ฏ |
| โ | โ | ๆ็กฎๆๆ็้ถๅบ / ็บข้ๆผ็ป |
ๆช้ ็ฝฎๆนๅไบบๆถ้ป่ฎคๆ็ป๏ผfail closed๏ผโโ่ฟๆฏๅปๆ็๏ผ้ฟๅ "้ ็ฝฎๆผไบ"ๅๆ"ๅ จๆพ่ก"ใ
่ขซๆ็ป็่ฐ็จไผไปฅ็ปๆๅ JSON ๅ้ฆ็ปๆจกๅ๏ผๅนถ้ไธๆๅผ๏ผ
{
"blocked": true,
"tool": "sqlmap_server__sqlmap_scan",
"reason": "'sqlmap_scan' sends intrusive traffic and needs approval",
"guidance": "This action was blocked by the engagement policy. Do not retry it."
}ๆจกๅๆฟๅฐ่ฟไธชไธไผๆญปๅพช็ฏ้่ฏ๏ผ่ๆฏ่ฝฌๅ่ขซๅจๆๆฎตๆๅจๆฅๅ้่ฏดๆ้่ฆๆๆใ
2. ็ฎๆ ็ฎกๆง โ ็ฝๅๅ + ็ง็ฝไฟๆค
# ๅชๅ
่ฎธๆๅฎๅๅ๏ผ่ถ็ไธๅพๆ็ป
python secagent.py --target x --scope 'example\.com' --scope 'testsite\.org'
# ็ฆๆญข่ฎฟ้ฎๅ็ฏ/ๅ
็ฝๅฐๅ๏ผ้ฒ SSRF ๅผ็่ฏฏๆไฝ๏ผ
python secagent.py --target x --deny-private
# ๅฝปๅบ็ฆ็จๆไธชๅทฅๅ
ท
python secagent.py --target x --deny-tools sqlmap_dump ffuf_dirs--deny-private ๆฆๆช 127.ใ10.ใ172.16-31.ใ192.168.ใ169.254.โโ่ฟๆก่งๅๅจๆซๅ
็ฝๆถ่ฆๆณจๆๅ
ณๆใ
3. ๅ จ้พ่ทฏๅฎก่ฎก
ๆฏๆฌกๅทฅๅ ท่ฐ็จ้ฝ่ฎฐๅฝๅณ็ญไธ็็ฑ๏ผ
$ python secagent.py --target x --policy ask --json | jq '.tool_audit'
[
{"step": 1, "tool": "httpx_server__http_probe",
"decision": "allow", "reason": "passive reconnaissance"},
{"step": 2, "tool": "sqlmap_server__sqlmap_scan",
"decision": "ask-denied",
"reason": "'sqlmap_scan' sends intrusive traffic and needs approval..."}
]ๅฎก่ฎกๆฅๅฟๅๆถ่ฝๅบ๏ผๅฏไปฅๅๆบฏ"่ฟๆฌก่ฏไผฐๅฐๅบ่ท่ฟไปไนใ่ฐๆน็"ใ
ๅฟซ้ๅผๅง
็ฏๅข่ฆๆฑ
Python 3.11+
Linux๏ผnmap / sqlmap / ffuf ้่ฆ๏ผ็ผบๅคฑ็ๅทฅๅ ทไผ่ขซ่ชๅจ่ทณ่ฟ๏ผ
ไธไธช OpenAI ๅ ผๅฎน็ LLM API
sudo apt install nmap sqlmap ffufๅฎ่ฃ
git clone https://github.com/<your-username>/secagent.git
cd secagent
python3 -m venv venv
source venv/bin/activate
pip install -r requirements.txt้ ็ฝฎ
cp .env.example .env
# ็ผ่พ .env๏ผๅกซๅ
ฅ DEEPSEEK_API_KEYๅ ผๅฎนไปปๆ OpenAI ๅ่ฎฎ็ซฏ็น๏ผ
SECAGENT_BASE_URL=https://api.deepseek.com/v1 # DeepSeek
SECAGENT_BASE_URL=https://api.openai.com/v1 # OpenAI
SECAGENT_BASE_URL=http://localhost:11434/v1 # Ollama ๆฌๅฐ่ฟ่ก
# ็ป็ฎๆ ๏ผ่ชๅจ่งๅ
python secagent.py --target 192.168.1.10
# ่ช็ถ่ฏญ่จ็ฎๆ
python secagent.py "ๅฎก่ฎก example.com ็ๅฎๅ
จๅคด้
็ฝฎๅๆๆ่ทฏๅพ"
# ่พๅบๆฅๅๆไปถ
python secagent.py --target example.com --report out/example.md
# ๅ ่ฝฝๅ
จ้จ MCP Server
python secagent.py --target x --all-servers
# ๅ
ณ้ญ่งๅ/ๅนถ่ก๏ผๅฏนๆฏๅฎ้ช็จ๏ผ
python secagent.py --target x --no-planner --no-parallel
# JSON ่พๅบ๏ผไพฟไบ้ๆๅฐ CI๏ผ
python secagent.py --target x --jsonMCP ๅทฅๅ ทๆธ ๅ
nmap_server.py
ๅทฅๅ ท | ่ฏดๆ | ATT&CK |
| ็ซฏๅฃๆซๆ + ๆๅก็ๆฌ่ฏๅซ | T1046 |
| NSE ๆผๆด่ๆฌๆซๆ | T1595 |
httpx_server.py
ๅทฅๅ ท | ่ฏดๆ | ATT&CK |
| ็ถๆ็ ใๅๅบๅคดใๆ ้ขใๆๆฏๆ็บน | T1592 |
| 6 ไธชๅ ณ้ฎๅฎๅ จๅคด็ผบๅคฑๅฎก่ฎก | โ |
| robots.txt ่งฃๆ๏ผๆ ่ฎฐๆๆ่ทฏๅพ | T1590 |
sqlmap_server.py
ๅทฅๅ ท | ่ฏดๆ | ATT&CK |
| SQL ๆณจๅ ฅๆฃๆต | T1190 |
| ๆไธพๆฐๆฎๅบ่กจ | โ |
| ๅฏผๅบ่กจๆฐๆฎ๏ผ้ๆพๅผๆๅฎๅบ่กจ๏ผ | T1213 |
ffuf_server.py
ๅทฅๅ ท | ่ฏดๆ | ATT&CK |
| ็ฎๅฝ/ๆไปถ็็ ด๏ผ่ชๅธฆ่ฟทไฝ ๅญๅ ธ๏ผ | T1083 |
่ฎพ่ฎก่ฆ็น
1. ๆพๅผ่งๅ vs ็บฏ ReAct
็บฏ ReAct ็้ฎ้ข๏ผๆจกๅ่พนๆณ่พนๅ๏ผๅฎนๆๅจ็ป่้ๆ่ฝฌใSecAgent ๆๆไธค้ถๆฎต๏ผ
# ้ถๆฎตไธ๏ผๆ ๅทฅๅ
ท็ฏๅขไธ็็บฏ่งๅ๏ผๆจกๅไธไผๅฟไธไฝ็ดๆฅๅผ็ซ๏ผ
plan = planner.plan(objective, available_tools)
# ้ถๆฎตไบ๏ผๅธฆ่ฎกๅๆง่ก
result = await agent.run(objective, plan=plan)
# ้ถๆฎตไธ๏ผๆฏ 3 ๆญฅ่ฎฉ planner ๅคๆ ธ๏ผๅฏ continue / revise / done
action, plan = planner.revise(objective, plan, findings_so_far)่งๅ่ฐ็จไธๆๅทฅๅ
ท๏ผ่ฟๆฏๅ
ณ้ฎโโๆจกๅๅช่ฝๆ่ ๅไปไน๏ผไธ่ฝ็ดๆฅ ๅใ
2. ๅนถ่กๅทฅๅ ท่ฐ็จ
ๆจกๅไธ่ฝฎ่ฟๅๅคไธช tool_calls ๆถ๏ผ็จ asyncio.gather ๅนถๅๆง่ก๏ผ
if self.parallel and len(parsed) > 1:
results = await asyncio.gather(
*(mcp.call(tc.function.name, args) for tc, args in parsed),
return_exceptions=True,
)ๆ ไพ่ต็่ฐ็จ๏ผhttp_probe + check_headers + check_robots๏ผไธ่ฝฎๆๅฎ๏ผๅฎๆต็ 40%+ ๆถ้ดใ
3. ๅๅฑ่ฎฐๅฟ
ๅคงๅคๆฐ Agent ๆๅ จ้จๅทฅๅ ท่พๅบๅก่ฟ context๏ผๅพๅฟซๅฐฑ็ไบ๏ผ
# ็ฌฌไธๅฑ๏ผๅๅง่งๅฏ๏ผๆ้ฟๅบฆ้ข็ฎ๏ผ่ถ
้ฟๆชๆญ๏ผ
observations = [Observation(step=1, tool="nmap_scan", result="...")]
# ็ฌฌไบๅฑ๏ผ็ปๆๅไบๅฎ๏ผ็จๆญฃๅไปๅๅง่พๅบๆฝๅ๏ผ
findings = {
"open_ports": {"22", "80"},
"services": {"ssh", "nginx 1.18.0"},
"missing_headers": {"content-security-policy"},
"interesting_paths": {"/admin", "/backup"},
"flags": set(),
}ๆฏ่ฝฎๅชๆณจๅ ฅ ๆ่ฆ + ๆ่ฟ 2 ๆก่งๅฏ๏ผ่้ๅ จ้ๅๅฒใ
4. ๅทฅๅ ทๅฝๅ็ฉบ้ด
ๅคไธช Server ๅฏ่ฝๆๅๅๅทฅๅ ท๏ผ็ปไธๅ ๅ็ผ๏ผ
nmap_server__nmap_scan
httpx_server__http_probe5. ๅฎๅ จๅ ๅบ
ๆๆ็ณป็ปๅฝไปค็จ list ๅฝขๅผ่ฐ็จ๏ผไธ็ป shell๏ผ๏ผๅนถๅจๅๆฐๅฑ้ข่ฟๆปคๅ ๅญ็ฌฆ๏ผ
if re.search(r"[;&|`$><\n]", target): return "error: invalid characters in target"sqlmap_dump็ๅบๅ/่กจๅ/ๅๅๅ จ้จๆญฃๅ็ฝๅๅๆ ก้ชSystem prompt ๆ็กฎ Rules of Engagement๏ผๅชๅฏนๆๆ็ฎๆ ๆไฝใไผๅ ้ไพตๅ ฅใไธไผช้ ่พๅบ
ๅๅฒไธๅฏนๆฏ
ๆฏๆฌก่ฏไผฐ่ชๅจ่ฝๅบ๏ผSQLite๏ผ้ป่ฎค ~/.secagent/engagements.db๏ผ๏ผๅฏไปฅๅๆบฏๅๅฏนๆฏๅไธไธช็ฎๆ ็ๅๆฌกๆซๆใ
# ๆฅ็ๅๅฒ
$ python secagent.py history --target example.com
Engagement history
โโโโโโณโโโโโโโโโโโโโณโโโโโโโโโโโโโโโโโโโโโโณโโโโโโโโณโโโโโโโโณโโโโโโโโโโโโโโโโโโโโโ
โ ID โ Target โ Started โ Steps โ Calls โ Flags โ
โกโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฉ
โ 7 โ example.comโ 2026-09-17T14:20:11 โ 6 โ 14 โ flag{new_finding} โ
โ 3 โ example.comโ 2026-09-10T09:02:44 โ 5 โ 11 โ - โ
โโโโโโดโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโดโโโโโโโโดโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโ
# ๅฏนๆฏไธคๆฌกๆซๆ
$ python secagent.py diff 3 7
example.com #3 (2026-09-10T09:02:44) โ #7 (2026-09-17T14:20:11)
+ ports: 8080
- headers: x-frame-options
+ flags: flag{new_finding}
= services: no change (4)
# ๆๆ่ฏไผฐ่ฟ็็ฎๆ
$ python secagent.py targetsๅฏนๆฏ็ปดๅบฆ๏ผๅผๆพ็ซฏๅฃใๆๅก็ๆฌใ็ผบๅคฑ็ๅฎๅ จๅคดใๆๆ่ทฏๅพใFlagใ
ๅ
ณๆๆไน
ๅ็จ --no-store๏ผๆๆๅฎๅบ่ทฏๅพ --db /path/to.dbใ
ๅฎน้
ๅทฅๅ ท่ฐ็จ้ๅฐ็ฝ็ปๆๅจใ่ถ ๆถใ5xx ๆถ่ชๅจ้่ฏ๏ผๆๆฐ้้ฟ + ๆๅจ๏ผ๏ผๆๅค 3 ๆฌก๏ผ
TRANSIENT_MARKERS = (
"timeout", "connection refused", "connection reset",
"502 bad gateway", "503 service unavailable", "rate limit", ...
)ๅชๆ็ฌๆถ้่ฏฏๆ้่ฏโโ้ๅฐ"็ฎๆ ไธๅฏ่พพ"่ฟ็ฑป็กฎๅฎๆงๅคฑ่ดฅ็ดๆฅ่ฟๅ๏ผไธๅๆ ่ฐ็ญๅพ
ใ้่ฏ่ฟ็จไผๆๅฐ โป retry 1 ่ฎฉไฝฟ็จ่
็ๅฐใ
่ฐๆดๆฌกๆฐ๏ผretry_attempts=5๏ผๆ้ ๅๆฐ๏ผใ
CI
ๆจ้ๅฐ main ่ชๅจ่งฆๅ GitHub Actions๏ผ
matrix: python 3.11 / 3.12 / 3.13
- pytest tests/ # 54 ไธชๆต่ฏ
lint:
- ruff check . # E/F/W ่งๅ
- compileall # ๅญ่็ ็ผ่ฏๆฃๆฅCI ๆพ็ปๆๅฐ่ฟไธไธช็ bug๏ผffuf_server.py ้ ext ๅ้ๅๅ้๏ผๅบไธบ exts๏ผ๏ผ้ๆๆฃๆฅ็ดๆฅๆด้ฒใ่ฟๅฐฑๆฏๆ lint ๆพ่ฟ CI ็ไปทๅผใ
ๆฉๅฑๆฐ็ MCP Server
ๅจ mcp_servers/ ไธๆๆจกๆฟๆฐๅปบๅณๅฏ๏ผ่ฟ่กๆถ้่ชๅจๅ็ฐ๏ผ
from mcp.server import Server
from mcp.server.stdio import stdio_server
from mcp.types import TextContent, Tool
app = Server("myserver")
@app.list_tools()
async def list_tools() -> list[Tool]:
return [Tool(
name="my_tool",
description="What this tool does",
inputSchema={"type": "object", "properties": {...}, "required": [...]},
)]
@app.call_tool()
async def call_tool(name: str, arguments: dict) -> list[TextContent]:
return [TextContent(type="text", text=json.dumps(result))]
async def main():
async with stdio_server() as (r, w):
await app.run(r, w, app.create_initialization_options())python secagent.py --target X --servers nmap_server.py myserver.pyๆจ่ๆฉๅฑๆนๅ๏ผnuclei_server.pyใnikto_server.pyใgobuster_server.pyใhydra_server.py
้กน็ฎ็ปๆ
secagent/
โโโ agent/
โ โโโ __init__.py
โ โโโ core.py # ReAct ไธปๅพช็ฏ + ๅนถ่กๆง่ก
โ โโโ planner.py # Plan-and-Execute ่งๅๅฑThis server cannot be deployed
Maintenance
Related MCP Connectors
Find, vet, and run MCP tools through a secure audited gateway with prompt-injection risk scoring
AI-security knowledge as MCP: standards-mapped tools (OWASP, NIST, MITRE) for AI agents.
- gatewayOAuthai.sealgate
MCP gateway with runtime security policy, tool-call-level control, and audit of agent actions.
MEOK MCP Hardening MCP โ automated security red-team for any MCP server. Maps OWASP LLM Top 10
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceEnables LLMs to execute Kali Linux security tools like nmap, sqlmap, and hydra in a secure, sandboxed environment. Provides both MCP and HTTP API interfaces for penetration testing and security assessment tasks.-
- AlicenseAqualityBmaintenanceEnables AI agents to perform professional penetration testing through a containerized Kali Linux environment, exposing industry-standard offensive security tools as structured MCP tools.454MIT
- AlicenseNot gradedqualityDmaintenanceIntegrates 7 security tools (nmap, nuclei, dirsearch, sqlmap, hydra, Acunetix, Metasploit) via MCP protocol for AI-assisted penetration testing with enterprise-grade safety features.1MIT
- FlicenseNot gradedqualityBmaintenanceExposes a hardened Docker container with Kali Linux security tools (nmap, sqlmap, dig, whois, etc.) as MCP tools, enabling network reconnaissance, web analysis, and vulnerability scanning through natural language commands.-