/** * Tool Description Drift Scanner * * Detects changes to MCP tool definitions compared to a signed baseline. * This is a "rug-pull detector" that alerts when: * - Tool descriptions change (could indicate scope creep) * - Input schemas change (could introduce new attack vectors) * - Tools are added or removed * - Permissions/hints change * * @module scanners/agent/tool-description-drift */ import type { Severity } from "../../certification/types.js"; import type { AgentScannerResult, MCPManifest, DriftType, DriftFinding, ServerBaseline } from "./types.js"; /** * Create a baseline from a manifest */ export declare function createBaseline(manifest: MCPManifest): ServerBaseline; /** * Load baseline from file */ export declare function loadBaseline(baselinesDir: string, serverName: string): Promise; /** * Save baseline to file */ export declare function saveBaseline(baselinesDir: string, baseline: ServerBaseline): Promise; /** * Compare current manifest against baseline and detect drift */ export declare function detectDrift(manifest: MCPManifest, baseline: ServerBaseline): DriftFinding[]; /** * Run tool description drift scanner */ export declare function runToolDriftScanner(manifest: MCPManifest, options?: { /** Directory containing baseline files */ baselinesDir?: string; /** Create baseline if none exists (instead of failing) */ createIfMissing?: boolean; /** Force create new baseline (overwrite existing) */ forceNewBaseline?: boolean; /** Skip specific drift types */ skipTypes?: DriftType[]; }): Promise; /** * Check if drift scanner is available (always true - no external deps) */ export declare function checkToolDriftAvailable(): Promise<{ scanner: "tool-description-drift"; available: boolean; version: string; }>; /** * Get summary of drift findings */ export declare function getDriftSummary(result: AgentScannerResult): { totalDrift: number; byType: Record; bySeverity: Record; affectedTools: string[]; baselineAge?: number; }; //# sourceMappingURL=tool-description-drift.d.ts.map