interceptor_deactivate_all
Emergency cleanup that kills all active interceptors across all types. Stops browser instances, spawned processes, ADB tunnels, Frida, and cleans Docker.
Instructions
Kill ALL active interceptors across all types. Emergency cleanup — stops all browser instances, kills spawned processes, removes ADB tunnels, detaches Frida, cleans Docker.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/tools/interceptors.ts:117-134 (handler)MCP tool registration and handler for 'interceptor_deactivate_all'. Calls interceptorManager.deactivateAll() to shut down all active interceptors (browser, terminal, Android ADB, Android Frida, Docker).
server.tool( "interceptor_deactivate_all", "Kill ALL active interceptors across all types. Emergency cleanup — stops all browser instances, kills spawned processes, removes ADB tunnels, detaches Frida, cleans Docker.", {}, async () => { try { await interceptorManager.deactivateAll(); return { content: [{ type: "text", text: JSON.stringify({ status: "success", message: "All interceptors deactivated." }), }], }; } catch (e) { return { content: [{ type: "text", text: JSON.stringify({ status: "error", error: errorToString(e) }) }] }; } }, ); - src/tools/interceptors.ts:117-134 (registration)Tool is registered via server.tool() with name 'interceptor_deactivate_all', empty schema {}, and async handler. This is part of the Discovery group of interceptor tools.
server.tool( "interceptor_deactivate_all", "Kill ALL active interceptors across all types. Emergency cleanup — stops all browser instances, kills spawned processes, removes ADB tunnels, detaches Frida, cleans Docker.", {}, async () => { try { await interceptorManager.deactivateAll(); return { content: [{ type: "text", text: JSON.stringify({ status: "success", message: "All interceptors deactivated." }), }], }; } catch (e) { return { content: [{ type: "text", text: JSON.stringify({ status: "error", error: errorToString(e) }) }] }; } }, ); - src/interceptors/manager.ts:55-67 (helper)InterceptorManager.deactivateAll() — iterates all registered interceptors and calls deactivateAll() on each. Collects errors and throws if any interceptor fails during cleanup.
async deactivateAll(): Promise<void> { const errors: string[] = []; for (const interceptor of this.interceptors.values()) { try { await interceptor.deactivateAll(); } catch (e) { errors.push(`${interceptor.id}: ${e}`); } } if (errors.length > 0) { throw new Error(`Errors during deactivateAll: ${errors.join("; ")}`); } } - src/tools/interceptors.ts:119-120 (schema)The tool has an empty schema {} meaning it takes no input parameters.
"Kill ALL active interceptors across all types. Emergency cleanup — stops all browser instances, kills spawned processes, removes ADB tunnels, detaches Frida, cleans Docker.", {}, - src/interceptors/types.ts:46-76 (helper)Interceptor interface definition — declares the deactivateAll() method that each interceptor type must implement.
export interface Interceptor { readonly id: string; readonly name: string; /** * Check if this interceptor can be activated (required tooling exists). * Uses dynamic imports — returns false if dependencies are missing. */ isActivable(): Promise<boolean>; /** * Activate interception for a target. * Handles proxy config, certificate trust, tunnel setup, etc. */ activate(options: ActivateOptions): Promise<ActivateResult>; /** * Deactivate a specific target by ID. */ deactivate(targetId: string): Promise<void>; /** * Deactivate all active targets. Called during proxy shutdown. */ deactivateAll(): Promise<void>; /** * Get metadata for display: availability, active targets. */ getMetadata(): Promise<InterceptorMetadata>; }