Atlas / MCP servers / zaebee / codegraph-brain

codegraph-brainCAUTION

mcp/zaebee/codegraph-brain

Code graph for AI agents: impact analysis and call tracing over MCP (Python, TypeScript). Local, deterministic, SQLite.

Verdict
CAUTION
Grade
B
Trust score
83 /100
Exposed tools
2 2r · 0w · 0d
Transport
stdio
License
MIT
Stars
2
01

Overview

From the repository's own README, as read at the audited commit. Badges and raw HTML are left out.

A code graph your AI agent can query instead of guess

[](https://github.com/zaebee/codegraph-brain/actions/workflows/ci.yml) [](https://github.com/zaebee/codegraph-brain/actions/workflows/autodoc.yml) [](https://pypi.org/project/codegraph-brain/)

Ask "what breaks if I change this?" and get the call chain, not a guess.

CGIS parses a repository with tree-sitter into a graph of fully qualified symbols and the calls, imports and containment between them, stores it in SQLite, and serves it to AI agents over MCP. An agent that would otherwise grep and read whole files asks the graph instead.

  • Languages: Python · TypeScript / TSX
  • Runs: locally — no account, no telemetry; the graph never leaves your disk (the one opt-in exception)
$ cgis ingest src --output graph.db
$ cgis impact cgis.query.engine.QueryEngine.get_flow_graph --db graph.db --depth 2
🔍 Analyzing transitive upstream callers of: cgis.query.engine.QueryEngine.get_flow_graph

METHOD cgis.query.engine.QueryEngine.get_flow_graph (cgis/query/engine.py:215)
├── FUNCTION cgis.query.context.context_service._collect_callees (cgis/query/context/context_service.py:44)
│   └── FUNCTION cgis.query.context.context_service.build_context (cgis/query/context/context_service.py:96)
└── METHOD cgis.guardian.collector.ContextCollector._graph_sections (cgis/guardian/collector.py:174)
├── METHOD cgis.guardian.collector.ContextCollector.collect_graph_context (cgis/guardian/collector.py:213)
└── METHOD cgis.guardian.collector.Conte
Read from source at commit f4349eb94dd9OBSERVED · 2026-10-14
02

Connect

Built from this server's own package name, version and transport as found in its source — not copied from anyone's documentation, so it cannot drift against a page we do not control.

claude-code (pypi)
claude mcp add codegraph-brain -- uvx codegraph-brain==0.28.0
03

Exposed tools (2)

2 read · 0 write · 0 destructive.

ToolRiskDescription
cgis_alphareadFirst tool.
cgis_betareadSecond tool.
04

Trust audit

CAUTIONgrade B · trust 83/100 Install with care. The audit found things worth knowing before you trust its output.

LayerWhat it checksResult
L0Provenance & inventoryPASS
L1Static analysis of the codeWARN
L2Instruction surface (what it tells the agent)PASS
L3Class-specific surfacePASS
L4Behavioural (sandbox)SKIPPED

What the source does

Filesystem
declared (1 observation(s))
Network
declared (13 observation(s))
Shell
none-observed
Dependencies
not all pinned
Secrets in source
none-found

Findings (25)

MEDIUMNetwork egress · net.raw_ip · CWE-200, CWE-319
scripts/colab_bench.sh:64
curl -fsS http://127.0.0.1:11434/api/version >/dev/null 2>&1 && break
MEDIUMNetwork egress · net.raw_ip · CWE-200, CWE-319
scripts/colab_bench.sh:67
curl -fsS http://127.0.0.1:11434/api/version >/dev/null
MEDIUMNetwork egress · net.raw_ip · CWE-200, CWE-319
scripts/ollama_visitor.sh:98
==> visitor up: http://127.0.0.1:${BIND_PORT} -> ollama-worker-${WORKER_ID} (loopback only)
MEDIUMNetwork egress · net.raw_ip · CWE-200, CWE-319
scripts/ollama_visitor.sh:101
export GUARDIAN_OLLAMA_HOST=http://127.0.0.1:${BIND_PORT}
LOWInventory / provenance · inv.hidden_file · CWE-1104
.pre-commit-config.yaml
.pre-commit-config.yaml
Why it matters. hidden member outside the usual dotfiles
Fix. review its purpose
LOWInventory / provenance · inv.hidden_file · CWE-1104
.release-please-manifest.json
.release-please-manifest.json
Why it matters. hidden member outside the usual dotfiles
Fix. review its purpose
LOWInventory / provenance · inv.hidden_file · CWE-1104
ui/.env.development
.env.development
Why it matters. hidden member outside the usual dotfiles
Fix. review its purpose
LOWInventory / provenance · inv.hidden_file · CWE-1104
ui/.prettierignore
.prettierignore
Why it matters. hidden member outside the usual dotfiles
Fix. review its purpose
LOWInsecure crypto · crypto.weak_hash · CWE-327, CWE-338
src/cgis/pipeline.py:115
return hashlib.md5(content.encode("utf-8"), usedforsecurity=False).hexdigest()
LOWFilesystem / path · fs.credential_store · CWE-22, CWE-59
benchmarks/guardian/pr-313.yaml:29
target. Demonstrated: a symlink to a non-existent .ssh/authorized_keys was
Why it matters. touches a credential store
LOWFilesystem / path · fs.credential_store · CWE-22, CWE-59
tests/unit/test_guardian_metrics.py:255
victim = tmp_path / "authorized_keys.jsonl"
Why it matters. touches a credential store
LOWFilesystem / path · fs.credential_store · CWE-22, CWE-59
tests/unit/test_guardian_metrics.py:264
_record(tmp_path / "authorized_keys")
Why it matters. touches a credential store
LOWFilesystem / path · fs.credential_store · CWE-22, CWE-59
tests/unit/test_guardian_metrics.py:274
target = tmp_path / "secrets" / "authorized_keys"
Why it matters. touches a credential store
LOWFilesystem / path · fs.credential_store · CWE-22, CWE-59
tests/unit/test_mcp_server.py:915
target = tmp_path / "authorized_keys"
Why it matters. touches a credential store
LOWFilesystem / path · fs.traversal · CWE-22, CWE-59
tests/unit/test_backfill_review_fingerprint.py:158
json.dumps({"guardian_sha": "../../etc/passwd", "finder_model": "gemini-2.5-flash"}) + "\n"
LOWFilesystem / path · fs.traversal · CWE-22, CWE-59
tests/unit/test_guardian_evidence.py:162
"path", ["/etc/passwd", "../outside.py", "src/../../escape.py", "C:\\windows\\a.py"]
LOWFilesystem / path · fs.traversal · CWE-22, CWE-59
tests/unit/test_tsconfig_paths.py:121
_web_app(tmp_path, {"@components/*": ["../../../outside/*"]})
LOWFilesystem / path · fs.traversal · CWE-22, CWE-59
tests/unit/test_tsconfig_paths.py:192
"apps/web/tsconfig.json": _tsconfig(extends="../../tsconfig.base"),
LOWFilesystem / path · fs.traversal · CWE-22, CWE-59
tests/unit/test_tsconfig_paths.py:205
{"baseUrl": "./src"}, extends="../../configs/base.json"
LOWNetwork egress · net.raw_ip · CWE-200, CWE-319
docs/GUARDIAN_REMOTE_OLLAMA.md:55
export GUARDIAN_OLLAMA_HOST=http://127.0.0.1:11435
LOWSupply chain · supply.unpinned · CWE-829, CWE-1357
ui/package.json
@xyflow/react, dagre, html-to-image, react, react-dom, react-error-boundary, zustand, @eslint/js
Why it matters. 30 dependency range(s) float
Fix. pin exact versions or ship a lockfile
INFOInventory / provenance · inv.oversize · CWE-1104
ui/public/graph.json
ui/public/graph.json
Why it matters. 2510511 bytes not read
INFOPrompt injection · prompt.credential_read · CWE-94, CWE-1427
PRIVACY.md:33
CGIS reads source files under the path you point it at. It does not read your SSH keys, cloud credentials, browser data, keychain, clipboard, shell history, or files outside the directory you ingest.
Why it matters. asks the agent to read credentials
INFOPrompt injection · prompt.credential_read · CWE-94, CWE-1427
docs/AUDIT.md:31
1. **Access.** A read-only clone or a tarball. No production access, no credentials, no environment.
Why it matters. asks the agent to read credentials
INFOPrompt injection · prompt.persistence · CWE-94, CWE-1427
docs/specs/2026-07-30-guardian-precision-bench-plan.md:33
| `scripts/guardian_review.py` (modify) | `--record-finder PATH` |
Why it matters. instructs the agent to persist itself in the user's environment

Gates applied: no_behavioural_pass.

Audited 2026-10-14 · audit v0.4.1 · source sha f4349eb94dd9full audit observations/trust-audit/mcp-server/zaebee__codegraph-brain.json · Report an issue / request a re-scan
05

Audit history

Every audit this server has had. A grade with a past is a grade somebody is still checking.

DateSourceVerdictGradeScoreChange
2026-10-14f4349eb94dd9CAUTIONB83first audit
06

Questions

What is the codegraph-brain MCP server?

Code graph for AI agents: impact analysis and call tracing over MCP (Python, TypeScript). Local, deterministic, SQLite.

What tools does codegraph-brain expose?

2 in total: 2 read-only, 0 that write, and 0 that can delete or overwrite. Every one is listed on this page with its risk.

Is codegraph-brain safe to connect to an agent?

With care. The audit graded it B (83/100) and found 25 things worth knowing before you trust this server, listed below with the exact line each was found on.

What credentials does codegraph-brain need?

No credential environment variables were found in its source, so it appears to need none.

How does codegraph-brain run?

It speaks stdio, so it runs as a local process your client starts. It is published on npm as graph-debugger at 0.1.0.

How current is this page?

The grade is for one exact copy of the source (f4349eb94dd9), read on 2026-10-14. The repository is watched and re-audited when it changes.

Advertisement