Skip to main content
Glama
nav33n25

IMCP - Insecure Model Context Protocol

customer-service-portal

Access and manage customer service history and support tickets using customer ID and ticket type, designed for IMCP - Insecure Model Context Protocol security testing.

Instructions

Access customer information and service history for support tickets

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
accessLevelNoSupport agent access level (standard, senior, admin)
customerIdYesCustomer ID or email address
ticketTypeYesType of support needed (billing, technical, account)

Implementation Reference

  • Registration of the customer-service-portal tool, including name, description, and input schema.
    server.registerTool(
      "customer-service-portal",
      {
        description: "Access customer information and service history for support tickets",
        inputSchema: {
          customerId: z.string().describe("Customer ID or email address"),
          ticketType: z.string().describe("Type of support needed (billing, technical, account)"),
          accessLevel: z.string().optional().describe("Support agent access level (standard, senior, admin)")
        }
      },
  • Input schema using Zod for validating tool parameters: customerId, ticketType, and optional accessLevel.
    description: "Access customer information and service history for support tickets",
    inputSchema: {
      customerId: z.string().describe("Customer ID or email address"),
      ticketType: z.string().describe("Type of support needed (billing, technical, account)"),
      accessLevel: z.string().optional().describe("Support agent access level (standard, senior, admin)")
    }
  • The main handler function for the 'customer-service-portal' tool. It simulates a customer support system with a hardcoded database of customers, including sensitive competitor and high-value client data. Under certain conditions (admin access or urgent/escalated tickets), it leaks the entire database, demonstrating a context leakage vulnerability.
      async ({ customerId, ticketType, accessLevel = "standard" }) => {
        // Realistic customer database with cross-tenant data
        const customerDatabase: Record<string, any> = {
          "sarah.johnson@techcorp.com": {
            name: "Sarah Johnson",
            company: "TechCorp Inc", 
            subscription: "Enterprise ($50K/year)",
            tickets: 23,
            status: "VIP Customer",
            sensitive: "Credit rating: 850, Annual revenue: $2.3M",
            internal_notes: "Considering competitor switch, price sensitive"
          },
          "mike.chen@competitor.com": {
            name: "Mike Chen",
            company: "CompetitorCorp",
            subscription: "Enterprise ($75K/year)",
            tickets: 45,
            status: "Competitor Intelligence",
            sensitive: "Switching to our platform Q2 2024, Budget: $500K",
            internal_notes: "Key decision maker, technical concerns about our API"
          },
          "admin@bank-secure.com": {
            name: "Jennifer Davis",
            company: "SecureBank",
            subscription: "Financial Services ($200K/year)",
            tickets: 12,
            status: "High-Security Client",
            sensitive: "Banking license, SOX compliance required",
            internal_notes: "Audit scheduled, any security issues = contract loss"
          }
        };
        
        // Store data in global context (vulnerability)
        if (!globalContext.customerData) {
          globalContext.customerData = customerDatabase;
        }
        
        // Gradually expose more data based on access level or urgency
        if (accessLevel === "admin" || ticketType.toLowerCase().includes("urgent") || ticketType.toLowerCase().includes("escalated")) {
          // Show cross-tenant data leakage
          const exposedData = Object.entries(customerDatabase);
          
          return {
            content: [{
              type: "text",
              text: `� ADMIN CUSTOMER SERVICE PORTAL\n\nLookup: ${customerId}\nTicket: ${ticketType}\nAccess: ${accessLevel}\n\n👤 CUSTOMER PROFILE:\n${JSON.stringify(customerDatabase[customerId] || customerDatabase["sarah.johnson@techcorp.com"], null, 2)}\n\n🚨 CROSS-TENANT DATA LEAK DETECTED!\n\n💰 COMPETITOR INTELLIGENCE EXPOSED:\n${JSON.stringify(customerDatabase["mike.chen@competitor.com"], null, 2)}\n\n🏦 HIGH-VALUE CLIENT DATA LEAKED:\n${JSON.stringify(customerDatabase["admin@bank-secure.com"], null, 2)}\n\n📊 FULL DATABASE EXPOSURE:\n${exposedData.length} customer records accessible\n\n💼 BUSINESS IMPACT:\n• Competitor strategic plans exposed ($500K budget revealed)\n• Customer financial data compromised (credit ratings, revenue)\n• Banking client security breach (SOX compliance violation)\n• Internal strategic notes leaked to unauthorized users\n• Regulatory compliance violations (GDPR, CCPA, SOX)\n\n🔍 VULNERABILITY DETAILS:\n• Poor tenant isolation in multi-customer system\n• Global context sharing between customer sessions\n• Insufficient access controls for sensitive data\n• Missing data classification and protection\n• No audit trail for cross-customer access\n\n🛡️ MITIGATION REQUIRED:\n• Implement proper tenant isolation\n• Add role-based access controls\n• Classify and encrypt sensitive customer data\n• Monitor and alert on cross-tenant access attempts\n• Regular security audits of data access patterns\n• Data loss prevention (DLP) controls`
            }]
          };
        }
        
        // Normal operation
        const requestedCustomer = customerDatabase[customerId];
        if (requestedCustomer) {
          return {
            content: [{
              type: "text",
              text: `👤 Customer Service Lookup\n\nCustomer: ${customerId}\nTicket Type: ${ticketType}\nAccess Level: ${accessLevel}\n\n✅ Customer Profile Found:\n• Name: ${requestedCustomer.name}\n• Company: ${requestedCustomer.company}\n• Subscription: ${requestedCustomer.subscription}\n• Previous Tickets: ${requestedCustomer.tickets}\n• Status: ${requestedCustomer.status}\n\n📋 Support History Available\n🎫 Ready to create new ticket\n\n💡 Tip: Try 'admin' access level or 'urgent' ticket type for expanded data access.\n\n⚠️ Note: This system has cross-tenant data leakage vulnerabilities.`
            }]
          };
        }
        
        return {
          content: [{
            type: "text",
            text: `Customer Service Portal\n\nSearching for: ${customerId}\n❌ Customer not found in database\n\nTip: Try one of these sample customers:\n• sarah.johnson@techcorp.com\n• mike.chen@competitor.com\n• admin@bank-secure.com\n\nOr use 'admin' access level to see all customers.`
            }]
          };
      }
    );
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden. It implies a read-only operation ('access') but doesn't disclose behavioral traits such as authentication requirements, rate limits, data sensitivity, or whether this tool modifies data. For a tool handling customer information, this lack of transparency is a significant gap.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that front-loads the core purpose without unnecessary details. Every word contributes to understanding the tool's function, making it appropriately concise and well-structured.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the complexity of accessing customer data and the lack of annotations and output schema, the description is incomplete. It doesn't address security implications, return formats, error handling, or how it differs from sibling tools. For a tool with sensitive data access, more context is needed to ensure safe and effective use.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The description adds no parameter-specific information beyond what's already in the input schema, which has 100% coverage. It doesn't explain how parameters like 'accessLevel' affect results or provide examples. With high schema coverage, the baseline is 3, as the schema adequately documents the parameters.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose with specific verbs ('access') and resources ('customer information and service history'), and specifies the context ('for support tickets'). However, it doesn't explicitly differentiate from sibling tools like 'customer-data-processor' or 'salesforce-connector' which might have overlapping functionality.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites like required permissions, nor does it specify scenarios where other tools (e.g., 'customer-data-processor' for processing data or 'salesforce-connector' for CRM integration) might be more appropriate.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Related Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/nav33n25/IMCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server