Gemini-MCP-Integration
by NanthagopalEswaran
Overview
A simple MCP server exposing calculator, file read, and file write tools for interaction with the Gemini CLI agent.
Installation
poetry run python src/server.pyEnvironment Variables
- MCP_PROXY_AUTH_TOKEN
Security Notes
The `handle_calculator` function uses `eval()`, which is an inherent security risk. While an empty `__builtins__` dictionary is passed to `eval`, it does not fully mitigate all potential code injection vectors, especially if the input expression is crafted maliciously. The `handle_file_read` and `handle_file_write` functions directly use the `path` parameter provided by the agent. This introduces a critical path traversal vulnerability, allowing an attacker to read from or write to arbitrary files on the system that the server process has permissions for. This could lead to information disclosure, data corruption, or arbitrary code execution by overwriting critical system files or injecting malicious scripts.
Similar Servers
gemini-mcp
The server provides a Model Context Protocol (MCP) interface to Google Gemini AI services, enabling multimodal generation including image creation, image editing, and video production.
GeminiMCP
Integrate Google's Gemini API for AI-powered tasks and search with Model Control Protocol (MCP) clients, focusing on developer-centric features like code analysis and context handling.
mcp
Integrate Google Gemini API features (text generation, chat, image analysis, web search, embeddings, image/video generation) into a Model Context Protocol (MCP) server for local or remote AI client applications.
mcp-server
Integrates an MCP server with Google Gemini for AI-powered chat, allowing the AI to execute predefined tools and access resources.