emgena's picture
Standardize domain navigation banner: Enterprise Architecture & SRE
2f80ab0 verified
|
Raw History Blame Contribute Delete
4.45 kB
metadata
license: cc-by-nc-4.0
tags:
  - mcp
  - cursor
  - claude-desktop
  - sre
  - ast-guard
  - apple-mlx
  - mac-ready
  - agentic
  - unsloth
size_categories:
  - n<1K
task_categories:
  - text-generation
language:
  - en
  - de
pretty_name: MCP stdio JSON-RPC Buffer Overflow & Packet Guard MCP

πŸ“‚ Fachbereich / Domain: πŸ”’ Enterprise Architecture & SRE
πŸ” Katalog-Filter: Alle verwandten Enterprise Architecture & SRE Suiten auf Hugging Face anzeigen
πŸ›’ Kommerzielle Lizenz & Webshop: emgena.com/trainingslager?product=mcp_stdio_jsonrpc_buffer_overflow_packet_guard&coupon=LAUNCH20


πŸ›‘οΈ MCP stdio JSON-RPC Buffer Overflow & Packet Guard MCP

Official Turnkey Model Context Protocol (MCP) Guard & Fine-Tuning Suite (FAANG v2.5 Gold Standard)


βš–οΈ Dual-Licensing & Fair-Use Compliance Notice

  • Community & Evaluation License (CC-BY-NC-4.0): This evaluation repository is 100% free for academic research, education, personal experimentation, and local evaluation.
  • Commercial & Enterprise License: Any integration into commercial software, SaaS applications, proprietary models, or corporate pipelines requires a valid commercial license from emgena.com/trainingslager.
  • Launch Discount: Use code LAUNCH20 at checkout for 20% off all commercial tiers (Single, Team, Enterprise).

πŸ“¦ What is Included in this Package

This repository contains the full 500-sample verified dataset and in-IDE guardrails:

  1. Parquet & JSONL Datasets (mcp_stdio_jsonrpc_buffer_overflow_packet_guard.parquet, chatml_format.jsonl):
    • 500 verified multi-turn trajectories across 30 production incidents.
    • 100% AST Invariance: Zero syntax errors (validated via ast.parse()).
  2. Deterministic MCP Engine (server.py & server_free.py):
    • Zero-dependency stdio engine (<0.15ms latency, 100% offline).
    • Compatible with Cursor IDE, Claude Desktop, and VS Code.
  3. Dual Fine-Tuning Recipes:
    • Apple Silicon Mac (train_mlx.py): Native LoRA fine-tuning for M1/M2/M3/M4 unified memory in 15 minutes.
    • Nvidia CUDA (train_lora_unsloth.py): 4-bit QLoRA fine-tuning on RTX 4090 / 5090 / Colab.
  4. Active AST Tools:
  • execute_tool('enforce_jsonrpc_packet_size_limit'): Rejects single JSON-RPC frames exceeding 10MB to prevent stdio buffer starvation.
  • execute_tool('validate_jsonrpc_protocol_version'): Verifies incoming messages contain jsonrpc: '2.0' and valid integer/string ID.
  • execute_tool('detect_malformed_partial_chunk_stream'): Assembles incomplete newline-delimited JSON chunks without blocking the event loop.
  • execute_tool('sanitize_jsonrpc_error_stacktrace'): Removes internal server file paths from JSON-RPC error responses sent to client.
  • execute_tool('quarantine_recursive_json_bomb'): Rejects payloads with deeply nested objects designed to trigger parser stack overflow.
  • execute_tool('fuzz_mcp_tool_argument_type_schema'): Validates incoming tool arguments strictly against the registered JSON Schema.
  • execute_tool('audit_stdio_stdout_polluting_print'): Catches direct print() statements corrupting the stdio protocol stream.
  • execute_tool('circuit_break_mcp_unresponsive_worker'): Terminates and restarts stuck MCP subprocess after configurable timeout.

πŸš€ Quickstart: Apple Silicon Fine-Tuning (MLX)

pip install mlx mlx-lm
python train_mlx.py

πŸ’» Quickstart: Cursor IDE & Claude Desktop MCP Setup

Add the following to your .cursor/mcp.json or claude_desktop_config.json:

{
  "mcpServers": {
    "mcp_stdio_jsonrpc_buffer_overflow_packet_guard": {
      "command": "python",
      "args": ["server.py"]
    }
  }
}

βš–οΈ License & Commercial Deployment

Distributed under Creative Commons Attribution-NonCommercial 4.0 International (CC-BY-NC-4.0).
For commercial enterprise deployment rights, BGB Β§ 97 UrhG indemnification, and EU AI Act Annex IV audit certificates, visit:
πŸ‘‰ emgena.com/trainingslager