Skip to content

feat: cross-agent lateral movement visualization in attack flow#322

Merged
andres-linero merged 1 commit intomainfrom
feat/lateral-movement-visualization
Mar 8, 2026
Merged

feat: cross-agent lateral movement visualization in attack flow#322
andres-linero merged 1 commit intomainfrom
feat/lateral-movement-visualization

Conversation

@msaad00
Copy link
Owner

@msaad00 msaad00 commented Mar 8, 2026

Summary

  • build_lateral_movement_flow(): new function that builds a React Flow graph showing cross-agent lateral movement paths — agents connected through shared MCP servers, with cross-agent poison risks highlighted
  • build_attack_flow(): new context_graph_data param overlays lateral movement edges onto existing blast radius graph
  • Stats now include lateral_edges and cross_poison_servers counts

Edge types

Type Style Meaning
cross_poison Red dashed, animated Shared server with write+read tool pair — one agent can poison another's context
lateral Orange dashed Shared server or explicit lateral path

Test plan

  • 11 new tests in TestBuildLateralMovementFlow — all passing
  • Existing 9 attack flow tests — all passing

Adds build_lateral_movement_flow() — a dedicated React Flow graph for
visualizing how agents are connected through shared MCP servers and which
connections are cross-agent poison risks.

attack_flow.py:
- build_lateral_movement_flow(context_graph_data): builds nodes/edges from
  shared_servers and lateral_paths; detects write+read tool pairs on shared
  servers (cross_poison); cross-poison edges are red dashed + animated,
  lateral edges are orange dashed
- build_attack_flow(): new context_graph_data param — overlays lateral
  movement edges onto the blast radius graph; stats now include
  lateral_edges and cross_poison_servers counts

Tests: 11 new test cases in TestBuildLateralMovementFlow
@msaad00 msaad00 requested a review from andres-linero as a code owner March 8, 2026 00:16
@github-actions
Copy link
Contributor

github-actions bot commented Mar 8, 2026

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Scanned Files

None

@andres-linero andres-linero merged commit 5a93b6e into main Mar 8, 2026
18 checks passed
@andres-linero andres-linero deleted the feat/lateral-movement-visualization branch March 8, 2026 00:22
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.

2 participants