Certified Tool Execution Framework for MCP-Based AI Agents: Provably Secure Defense Against Tool Poisoning and Credential Theft

The Model Context Protocol (MCP) has emerged as the de facto standard for enabling Large Language Model (LLM) agents to interact with external tools, APIs, and databases. While MCP significantly extends agent capabilities, it introduces critical security vulnerabilities: tool poisoning attacks can inject malicious behavior into seemingly benign tools, and prompt injection can trick agents into leaking credentials or performing unauthorized actions. Current defense mechanisms—including prompt filtering, guardrails, and adversarial training—are heuristic and bypassable, with reported evasion rates reaching 100% against state-of-the-art systems.We present the Certified Tool Execution Framework (CTEF), the first provably secure defense against tool poisoning in MCP-based AI agents. CTEF employs a three-layer architecture: (1) capability-based access control (CAP-MCP) that enforces cryptographically unforgeable permissions, (2) formal pre/post-condition verification using Satisfiability Modulo Theories (SMT) solvers, and (3) sandboxed execution with syscall-level monitoring. We prove that CTEF achieves (ε, δ)-certified security, where ε < 2-128 represents the probability of accepting a poisoned tool and δ bounds the capability forgery risk.Through comprehensive evaluation on the MCP-Security benchmark comprising 50 benign and 30 poisoned tools across 6 attack categories, CTEF achieves 96.7% true positive rate and 3.2% false positive rate in poisoned tool detection—a 47% improvement over the next-best baseline. We establish theoretical sample complexity bounds showing that detecting a poisoned tool with violation probability, p requires Ω(1/p log 1/δ) samples. The framework incurs 2.3--8.7x execution overhead compared to unprotected MCP, acceptable for security-critical applications. CTEF enables safe deployment of autonomous AI agents in domains where tool integrity is paramount: healthcare decision support, financial trading, infrastructure management, and legal document processing. Our open-source implementation and benchmark are available on [anonymized for review].

Authors

Publication Details

Journal
Preprints.org
Published
2026-10-27
DOI
https://doi.org/10.20944/preprints202610.2580.v1
Primary Topic
Adversarial Robustness in Machine Learning
Type
preprint
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
preprint

Certified Tool Execution Framework for MCP-Based AI Agents: Provably Secure Defense Against Tool Poisoning and Credential Theft

Sally Tachie, Ransford Oppong
1 links
Preprints.org
Adversarial Robustness in Machine Learning
preprint

Certified Tool Execution Framework for MCP-Based AI Agents: Provably Secure Defense Against Tool Poisoning and Credential Theft

Sally Tachie, Ransford Oppong
preprint en

Abstract

The Model Context Protocol (MCP) has emerged as the de facto standard for enabling Large Language Model (LLM) agents to interact with external tools, APIs, and databases. While MCP significantly extends agent capabilities, it introduces critical security vulnerabilities: tool poisoning attacks can inject malicious behavior into seemingly benign tools, and prompt injection can trick agents into leaking credentials or performing unauthorized actions. Current defense mechanisms—including prompt filtering, guardrails, and adversarial training—are heuristic and bypassable, with reported evasion rates reaching 100% against state-of-the-art systems.We present the Certified Tool Execution Framework (CTEF), the first provably secure defense against tool poisoning in MCP-based AI agents. CTEF employs a three-layer architecture: (1) capability-based access control (CAP-MCP) that enforces cryptographically unforgeable permissions, (2) formal pre/post-condition verification using Satisfiability Modulo Theories (SMT) solvers, and (3) sandboxed execution with syscall-level monitoring. We prove that CTEF achieves (ε, δ)-certified security, where ε < 2-128 represents the probability of accepting a poisoned tool and δ bounds the capability forgery risk.Through comprehensive evaluation on the MCP-Security benchmark comprising 50 benign and 30 poisoned tools across 6 attack categories, CTEF achieves 96.7% true positive rate and 3.2% false positive rate in poisoned tool detection—a 47% improvement over the next-best baseline. We establish theoretical sample complexity bounds showing that detecting a poisoned tool with violation probability, p requires Ω(1/p log 1/δ) samples. The framework incurs 2.3--8.7x execution overhead compared to unprotected MCP, acceptable for security-critical applications. CTEF enables safe deployment of autonomous AI agents in domains where tool integrity is paramount: healthcare decision support, financial trading, infrastructure management, and legal document processing. Our open-source implementation and benchmark are available on [anonymized for review].

Preprints.org
Adversarial Robustness in Machine Learning
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

Laika access coming soon
Certified Tool Execution Framework for MCP-Based AI Agents: Provably Secure Defense Against Tool Poisoning and Credential Theft — Sally Tachie, Ransford Oppong · Preprints.org (2026) | TGRS Research Map | TGRS