Back to Home
Koggitechorg icon

koggi-mcp-server-database

by Koggitechorg

Overview

An MCP server acting as a proxy for an external RAG engine to understand database schemas and an external API for executing SQL queries based on natural language input.

Installation

Run Command
npx -y @koggitechorg/koggi-mcp-server

Environment Variables

  • EXTERNAL_URL
  • API_TOKEN
  • PORT

Security Notes

CRITICAL: The `get_request_database_sql` tool takes user-provided `sql_query` and directly forwards it to an external API endpoint (`/api/mcp/run-query-from-rag`). This design makes the server a proxy for a severe SQL injection vulnerability if the downstream API does not rigorously sanitize and validate the incoming SQL. CRITICAL: `src/config/config.ts` includes a hardcoded default `API_TOKEN`. If the `API_TOKEN` environment variable is not explicitly set, this hardcoded secret is used for authentication against an external validation service and subsequent API calls, creating a severe authentication bypass risk. HIGH: The `EXTERNAL_URL` environment variable (configurable by the user) dictates the base URL for all external API calls. If an attacker can manipulate this variable, it could lead to Server-Side Request Forgery (SSRF) by directing the server to make requests to internal or unintended external resources.

Similar Servers

Stats

Interest Score0
Security Score4
Cost ClassMedium
Avg Tokens600
Stars0
Forks0
Last Update2025-12-09

Tags

MCPRAGSQLVertex AIDatabaseAI/ML