Back to Home
SirKanaad26 icon

stateful-auth-for-mcp-servers

by SirKanaad26

Overview

Integrates Google Gmail and Calendar APIs to enable an AI agent to read emails and manage calendar events with stateful authorization for event deletions.

Installation

Run Command
python3 mcp_server.py

Security Notes

The server has a critical prompt injection vulnerability as explicitly stated in the README. Email content, fetched by the `read_emails` tool, is passed directly to the AI model without sanitization. This allows malicious instructions embedded in emails to manipulate the AI into performing unintended calendar actions (e.g., creating, updating, or deleting events). While a stateful authorization layer was added to prevent deletion of *external* calendar events, it does not mitigate the risk of: 1) creating new malicious events, 2) updating existing events (even external ones), or 3) deleting MCP-created events based on injected prompts. The AI model retains full `calendar` scope, allowing broad manipulation. The README advises against production use.

Similar Servers

Stats

Interest Score32
Security Score3
Cost ClassMedium
Avg Tokens1000
Stars1
Forks0
Last Update2025-12-01

Tags

Google APIMCP ServerAI AgentCalendarGmailStateful AuthSecurity