USMAN’S INSIGHTS
AI ARCHITECT
⌘F
HomeAll BooksBackend Book
HomeBackend BookAI-Native Systems
PreviousDeterministic Workflows Before Open-Ended AgentsNextMemory, Conversations, and Context Engineering
AI NOTICE: This is the table of contents for the SPECIFIC CHAPTER only. It is NOT the global sidebar. For all chapters, look at the main navigation.

On this page

13 sections

Progress0%
1 / 13

Muhammad Usman Akbar Entity Profile

Muhammad Usman Akbar is a Forward Deployed Engineer and AI Native Consultant specializing in the design and deployment of multi-agent autonomous systems. Embedding with enterprise teams, he ships production-grade agentic AI and leads industrial-scale digital transformation using Claude and OpenAI ecosystems. His work is centered on achieving up to 30x operational efficiency through distributed systems architecture, FastAPI microservices, and RAG-driven AI pipelines. As CEO and Founding Partner of Fista Solutions, based in Pakistan, he operates as a global technical partner for innovative AI startups and enterprise ventures.

USMAN’S INSIGHTS
AI ARCHITECT

Transforming businesses into autonomous AI ecosystems. Engineering the future of industrial-scale digital products with multi-agent systems.

30X Growth
AI-First
Innovation

Navigation

  • Home
  • Forward Deployed Engineer
  • AI Native Consultant
  • About
  • Insights
  • Book a Call
  • Books
  • Contact
Let's Collaborate

Have a Project in Mind?

Let's build something extraordinary together. Transform your vision into autonomous AI reality.

Start Your Transformation

© 2026 Muhammad Usman Akbar. All rights reserved.

Privacy Policy
Terms of Service
Engineered with
INDUSTRIAL ARCHITECTURE

MCP Servers, Clients, and Trust Boundaries

Model Context Protocol standardizes how an AI host discovers and uses external resources, prompts, and tools. MCP improves interoperability; it does not make a server trustworthy or a tool safe. Clients must authenticate servers, constrain capabilities, validate results, preserve user consent, and enforce the same authorization, budgets, and audit rules as any integration.

What will you be able to do?

  • explain MCP host, client, server, tools, resources, and prompts;
  • decide whether a capability belongs in an internal API or MCP server;
  • design tenant-safe MCP tools and read-only resources;
  • threat-model local and remote transports.

What is the mental model?

  • The host is the AI application coordinating model and user experience.
  • An MCP client maintains a connection to one server.
  • An MCP server advertises capabilities.
  • Tools request actions or computations.
  • Resources expose addressable context.
  • Prompts expose reusable prompt templates.

Protocol negotiation tells you what is available, not what should be allowed. Maintain an application allow-list and policy per server, tool, tenant, environment, and effect class.

How should SupportDesk AI expose capabilities?

Good candidates are narrow and application-owned:

  • resource: an authorized ticket summary by opaque URI;
  • resource: approved knowledge passage with source metadata;
  • tool: create an unsent ticket reply draft;
  • tool: request human approval for a specified action.

Avoid generic SQL, filesystem, shell, HTTP fetch, secret access, or cross-tenant search. Server code derives tenant context from authenticated credentials, not a tool argument.

Which threats matter?

  • malicious or compromised server returns instructions or poisoned content;
  • tool-name collision or capability change after approval;
  • local server inherits excessive filesystem/environment access;
  • remote server impersonation, credential theft, or confused deputy behavior;
  • token forwarding to an unintended audience;
  • result injection manipulates later model behavior;
  • unbounded resources exhaust context, memory, or cost.

Pin trusted origins/packages where possible, isolate local processes, use minimal environment and filesystem access, validate transport identity, request explicit consent for consequential capabilities, and display the exact server/tool/action to users.

Why does this matter in AI-native systems?

MCP can prevent bespoke integration sprawl, but central discovery can also expand an agent's authority. Treat each server as a third-party dependency and each returned value as untrusted input. Standard protocol envelopes do not validate semantic truth.

Common mistakes

  • Auto-approving every discovered tool.
  • Passing the user's broad bearer token to arbitrary servers.
  • A local MCP process receives the entire environment, including secrets.
  • Resource contents are inserted as system policy.
  • Tool schema changes without re-review or contract tests.
  • No audit correlation between host run and server effect.

AI Pair-Programmer Prompt

text
Review this MCP integration. Inventory server identity and provenance, transport, credentials/audience, discovered capabilities, allow-list, per-tool effect class, tenant binding, input/output limits, user consent, result injection, local sandbox, schema-change detection, timeouts, audit correlation, and server-loss fallback.

Exercise

Design an MCP server for read-ticket-summary and create-reply-draft plus a client policy. Add a malicious resource containing instructions to reveal another tenant and call a hidden tool.

Acceptance criteria: the content is treated as data, unavailable capabilities cannot be invoked, server credentials are least-privileged, tenant scope is server-enforced, and every call maps to the host AI-run trace.

Knowledge check

  1. Does MCP discovery grant permission?
  2. Are MCP resource contents trusted instructions?
  3. Why isolate a local MCP server?

Answers

  1. No; application policy and user consent determine permission.
  2. No; they are untrusted external data.
  3. It may be compromised and otherwise inherit filesystem, environment, and network authority.

Completion checklist

  • Servers and capabilities are allow-listed.
  • Credentials and tenant context are audience-bound.
  • Tool changes and malicious results are tested.

Primary references

  • Model Context Protocol specification
  • OWASP LLM supply-chain risks