MCP_Authendication_example
Verified Safeby Bin4yi
Overview
AI-powered pet care chatbot leveraging an MCP server and LangGraph agent for authenticated access to veterinary tools and pet management.
Installation
python main.pyEnvironment Variables
- AUTH_ISSUER
- CLIENT_ID
- JWKS_URL
- OPENAI_API_KEY
Security Notes
The server implements robust JWT token validation using JWKS, and the agent uses OAuth2 Authorization Code Flow with PKCE for secure authentication. Sensitive credentials are correctly managed via environment variables. However, the agent's `aiohttp_cors` is configured with a highly permissive `*` origin allowing credentials, which is a significant security risk for production deployments. Additionally, the `JWTValidator` has a `ssl_verify=False` option (commented as for dev/testing) that, if used in production, would compromise security.
Similar Servers
mcp-forge-python
A production-ready MCP (Model Context Protocol) server template for building AI-powered applications with OAuth 2.0 authentication and JWT validation.
MCP_Authentication_example
An AI-powered pet care chatbot system integrating a secure Model Context Protocol (MCP) server with an intelligent LangGraph agent, using Asgardeo for authentication.
common-mcp-submodule
A production-ready framework for building HTTP MCP (Model Context Protocol) servers with FastAPI, supporting OAuth 2.1 and Personal Access Token authentication.
MCP-Servers-using-Python
Demonstrates how to build Model Context Protocol (MCP) servers using `fastmcp` and `fastapi_mcp` libraries through various examples.