论文精选

ChainGraph:用 Neo4j 图数据库增强 LLM 渗透测试智能体的攻击链推理

Thinking in Graphs: Neo4j-Backed Exploit-Chain Reasoning for LLM Penetration-Testing Agents

精选理由

把渗透测试发现存进 Neo4j 图再让 Claude Code 查询,孤立的 Medium 漏洞能串出 Critical 攻击链,token 还省了 98%。

论文提出 ChainGraph 模式,把渗透测试中的攻击链推理外化到 Neo4j 属性图中,通过 Model Context Protocol 连接 Claude Code 和 Codex 等现成智能体,无需定制框架。发现、攻击步骤、凭据和资产作为带前置/后置条件边的类型化节点存储。作者将下一跳推断、入口到核心资产路径等五个问题形式化为可复用的 Cypher 和 Graph Data Science 查询。在基于 GOAD 建模的合成多森林 Active Directory 环境中,3 个单独评级为 Medium 的发现串联成到 forest root 的路径后升级为 Critical,token 负载下降约 98%。

原文 · arXiv: OpenAI

Thinking in Graphs: Neo4j-Backed Exploit-Chain Reasoning for LLM Penetration-Testing Agents

LLM coding agents such as Claude Code and OpenAI Codex can drive penetration-testing tools, but they reason about an engagement as a flat list of findings in a context window. Attackers think in graphs: isolated low-severity exposures turn catastrophic once chained through credential capture, privilege escalation, and lateral movement. This gap feeds a common belief that AI agents cannot truly chain exploitation; we argue this describes the flat context window, not the model. We present ChainGraph, a pattern that externalizes exploit-chain reasoning into a Neo4j property graph wired to an off-the-shelf agent via the Model Context Protocol, no bespoke harness. Findings, attack steps, credentials, assets, and tamper-evident evidence receipts are typed nodes with pre/post-condition edges; JSON/Markdown holds documentary memory while Neo4j holds reasoning memory. We formalize five operator questions (next-step inference, entry-to-crown-jewel pathing, combined-severity promotion, evidence provenance, and chokepoint identification) as reusable Cypher and Graph Data Science queries, plus a chain-severity score distinct from per-finding local severity. On a synthetic multi-forest Active Directory engagement modeled on GOAD, in live Neo4j with GDS, three findings rated Medium in isolation become Critical once their path to the forest root is materialized, and betweenness centrality names the best chain break-points. Scoping each decision to a graph result rather than re-reading the engagement cut the reasoning payload by about 98% on a token proxy. We give a reproducible setup for Claude Code and Codex. Results are illustrative single-run measurements, not a benchmark.