Securing The Agentic Layer: A Defense-in-Depth Security Framework For MCP-Connected AI Coding Agents

AI coding agents connected via the Model Context Protocol (MCP) are rapidly becoming standard in professional software development, yet they introduce a critical and under-explored attack surface. Empirical benchmarks report attack success rates exceeding 85% against unprotected MCP-connected agents, with existing defenses achieving less than 30% average effectiveness [14]. This paper proposes and implements MASF-CC (Multi-layer Agentic Security Framework for Claude Code), a Python-based security gateway enforcing four complementary defense layers—Validation (L1), Authorization (L2), Integrity (L3), and Audit (L4)—as a transparent proxy between Claude Code and its MCP servers. Evaluated in a controlled proof-of-concept setting against a self-constructed corpus of 100 structured attack scenarios and 50 legitimate developer tasks, MASF-CC achieves a Defense Success Rate (DSR) of 100% within the evaluated corpus across all four threat categories, with a mean gateway latency overhead of 0.06 ms under mock-server conditions. Task Completion Rate reached 96% after capability token reconfiguration. All results are explicitly scoped to the self-constructed evaluation corpus; independent benchmark replication remains the highest-priority future work.

Authors

Institutions

Publication Details

Journal
Zenodo (CERN European Organization for Nuclear Research)
Published
2026-06-18
DOI
https://doi.org/10.5281/zenodo.20745156
Primary Topic
Advanced Malware Detection Techniques
Type
article
Field-Weighted Citation Impact
0.00
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

Securing The Agentic Layer: A Defense-in-Depth Security Framework For MCP-Connected AI Coding Agents

Ayush Basnet
Zenodo (CERN European Organization for Nuclear Research)
Advanced Malware Detection Techniques
article

Securing The Agentic Layer: A Defense-in-Depth Security Framework For MCP-Connected AI Coding Agents

Ayush Basnet
article en

Abstract

AI coding agents connected via the Model Context Protocol (MCP) are rapidly becoming standard in professional software development, yet they introduce a critical and under-explored attack surface. Empirical benchmarks report attack success rates exceeding 85% against unprotected MCP-connected agents, with existing defenses achieving less than 30% average effectiveness [14]. This paper proposes and implements MASF-CC (Multi-layer Agentic Security Framework for Claude Code), a Python-based security gateway enforcing four complementary defense layers—Validation (L1), Authorization (L2), Integrity (L3), and Audit (L4)—as a transparent proxy between Claude Code and its MCP servers. Evaluated in a controlled proof-of-concept setting against a self-constructed corpus of 100 structured attack scenarios and 50 legitimate developer tasks, MASF-CC achieves a Defense Success Rate (DSR) of 100% within the evaluated corpus across all four threat categories, with a mean gateway latency overhead of 0.06 ms under mock-server conditions. Task Completion Rate reached 96% after capability token reconfiguration. All results are explicitly scoped to the self-constructed evaluation corpus; independent benchmark replication remains the highest-priority future work.

Zenodo (CERN European Organization for Nuclear Research)
Lincoln College (US)
Peace, Justice and strong institutions
Openalex Percentile: Top 4%
Advanced Malware Detection Techniques
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.

Securing The Agentic Layer: A Defense-in-Depth Security Framework For MCP-Connected AI Coding Agents — Ayush Basnet · Zenodo (CERN European Organization for Nuclear Research) (2026) | TGRS Research Map | TGRS