Skip to content

feat: finding associations via wiki-link graph for AI engagement analysis#7

Merged
Esonhugh merged 9 commits intomasterfrom
worktree-finding-association
Apr 27, 2026
Merged

feat: finding associations via wiki-link graph for AI engagement analysis#7
Esonhugh merged 9 commits intomasterfrom
worktree-finding-association

Conversation

@Esonhugh
Copy link
Copy Markdown
Collaborator

Summary

  • Add findingEdges to RelationshipGraph interface and graphBuilder, classifying edges where at least one endpoint is a finding-type node (mirrors existing hostEdges/userEdges pattern)
  • Create EngagementSummary domain module — pure function buildEngagementSummary() that walks graph edges to derive per-finding host/user/service/finding associations, host/user breakdowns, unassociated findings, and severity stats
  • Expose engagement data through MCP: get_engagement_summary tool, engagement://summary resource, and analyze-engagement prompt — AI can now understand what was found, where, and how findings chain together

Test Plan

  • 111 unit tests passing (9 new engagement tests + 1 findingEdges interface test)
  • Webpack compilation clean
  • tsc compilation clean
  • ESLint: 0 errors (only pre-existing warnings in unrelated files)
  • Manual smoke test: open workspace with wiki-linked findings, call get_engagement_summary via MCP client

🤖 Generated with Claude Code

Esonhugh and others added 9 commits April 26, 2026 21:46
Edges where at least one endpoint is type 'finding' are now classified
into findingEdges, enabling downstream code to derive which hosts,
users, and other findings each finding is connected to via wiki-links.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Pure function that walks Foam wiki-link graph findingEdges to derive
per-finding associations (hosts, users, services, chained findings).
Groups findings by host and user. Identifies orphan findings with no
wiki-link connections. No changes to Finding interface — associations
are a graph property, not a document property.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
AI can now call get_engagement_summary to get the full engagement state
in one call: hosts, credentials, findings with graph-derived associations
(which hosts/users/findings each finding connects to via wiki-links),
per-host and per-user breakdowns, attack chains, and computed stats.

The analyze-engagement prompt asks AI to identify finding chains,
coverage gaps, and recommend next steps.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…ice/severity tests

- Severity counting is now case-insensitive (.toLowerCase()) so "High",
  "CRITICAL" etc. are counted correctly
- Extract private buildSummary() in httpServer to DRY the 3 identical
  fetch-and-build blocks
- Add tests: case-insensitive severity stats, finding-to-service associations

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add logger.debug to all MCP tool handlers, resource handlers, and prompt
handlers so that every request is traceable in the output channel. Show
an information message when the MCP config is auto-updated on activation
so users know the server is ready.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@Esonhugh Esonhugh merged commit 60c44ad into master Apr 27, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant