Skip to content

security: inter-agent mesh messages bypass policy evaluation after decryption #10

Description

Summary

Mesh messages decrypted by the plugin are processed without policy evaluation. A trusted peer could send task requests that should be blocked by policy.

Details

File: cli/src/plugin.ts, lines 156-305 (onMessage handler)

Once E2E-decrypted, task_request messages are delegated directly to the native agent. No check whether:

  • The requested action is allowed by policy
  • The sender's trust score warrants this level of access
  • The request type (tool call, file access, spawn) is permitted from a peer

Proposed Fix

// Before delegateToNativeAgent:
const decision = await agtPolicy.evaluate({
    action: "handle_mesh_request",
    message_type: msg.message_type,
    from_agent: msg.from_agent,
    trust_score: trustStore.get(msg.from_agent)?.score
});
if (decision !== "allow") {
    console.log(`Blocked mesh request from ${msg.from_agent}: ${decision}`);
    return;
}

AGT's inter-agent trust protocol (IATP) provides exactly this pattern.

References

  • plugin.ts lines 156-305
  • AGT: trust-protocol IATP handshake verification

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions