Back to Home
samaye-pro icon

mcp-server

Verified Safe

by samaye-pro

Overview

Demonstrates a Model Context Protocol (MCP) WebSocket server in Go for bidirectional JSON messaging and executing predefined tools.

Installation

Run Command
go run main.go

Security Notes

The server's `websocket.Upgrader` is configured with `CheckOrigin: func(r *http.Request) bool { return true }`, which disables origin checking. This makes the WebSocket server vulnerable to Cross-Site WebSocket Hijacking (CSWSH) attacks if deployed in a production environment without proper remediation. While acceptable for a local demo, it's a critical security flaw for anything beyond that. There are no obvious hardcoded secrets, 'eval' equivalents, or other direct code execution vulnerabilities.

Similar Servers

Stats

Interest Score0
Security Score4
Cost ClassLow
Avg Tokens50
Stars0
Forks0
Last Update2025-11-27

Tags

WebSocketMCPGoServerTools