PO

pixelworlds/opnsense-mcp-server

Developer tools

Эта страница переведена автоматически. Технические детали смотрите в оригинале. Открыть оригинал

92 stars 27 forks Качество 69 Тренд 15MIT

pixelworlds/opnsense-mcp-server - кандидат на сервер MCP, импортированный из https://github.com/pixelworlds/opnsense-mcp-server.

Обзор

pixelworlds/opnsense-mcp-server - кандидат на сервер MCP, импортированный из https://github.com/pixelworlds/opnsense-mcp-server.

Обзор (машинный перевод)

Модульный сервер Model Context Protocol (MCP), который предоставляет инструменты на основе модулей *88, предоставляя доступ к более чем 2000 методам управления брандмауэром OPNsense через безопасный интерфейс TypeScript.

Особенности

Модульная архитектура - 88 логических инструментов (по одному на модуль) вместо 2000+ отдельных инструментов Полное покрытие API - доступ к 752 основным методам и 1271 методам плагинов

  • Type-Safe - Полная поддержка TypeScript с @richard-stovall/opnsense-typescript-client v0.5.3 Поддержка плагинов - дополнительная поддержка 64 модулей плагинов Умная организация - Связанные операции, сгруппированные по модулю для более легкого обнаружения

Сервер MCP действует как мост между помощниками ИИ (например, Claude Desktop) и брандмауэром OPNsense, обеспечивая безопасный доступ к API через модульный интерфейс инструмента.

Использование Claude Desktop

Использование в Claude Code

##Установка

###Как MCP-сервер

Этот пакет предназначен для использования в качестве сервера MCP (Model Context Protocol) с помощниками AI, такими как Claude Desktop, Cursor или другие MCP-совместимые клиенты.

Предпосылки

Node.js 18 или выше OPNsense Firewall с включенным доступом API Ключ API и секрет от установки OPNsense

Эта страница переведена автоматически. Технические детали смотрите в оригинале.

README

Показан фрагмент оригинального README. Открыть оригинал.

OPNsense MCP Server

A modular Model Context Protocol (MCP) server that provides 88 module-based tools giving access to over 2000 OPNsense firewall management methods through a type-safe TypeScript interface.

Features

  • Modular Architecture - 88 logical tools (one per module) instead of 2000+ individual tools
  • Complete API Coverage - Access to 752 core methods and 1271 plugin methods
  • Type-Safe - Full TypeScript support with @richard-stovall/opnsense-typescript-client v0.5.3
  • Plugin Support - Optional support for 64 plugin modules
  • Smart Organization - Related operations grouped by module for easier discovery

The MCP server acts as a bridge between AI assistants (like Claude Desktop) and your OPNsense firewall, providing secure API access through a modular tool interface.

Usage in Claude Desktop

Usage in Claude Code

Installation

As an MCP Server

This package is designed to be used as an MCP (Model Context Protocol) server with AI assistants like Claude Desktop, Cursor, or other MCP-compatible clients.

Prerequisites

  • Node.js 18 or higher
  • An OPNsense firewall with API access enabled
  • API key and secret from your OPNsense installation

Install from npm

npm install -g @richard-stovall/opnsense-mcp-server

Usage as an MCP Server

Claude Desktop Configuration

Add the following to your Claude Desktop configuration file:

macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json

{
  "mcpServers": {
    "opnsense": {
      "command": "npx",
      "args": ["-y", "@richard-stovall/opnsense-mcp-server"],
      "env": {
        "OPNSENSE_URL": "https://192.168.1.1",
        "OPNSENSE_API_KEY": "your-api-key",
        "OPNSENSE_API_SECRET": "your-api-secret",
        "OPNSENSE_VERIFY_SSL": "false"
      }
    }
  }
}

Alternative Configuration Methods

Using Command Line Arguments:

{
  "mcpServers": {
    "opnsense": {
      "command": "node",
      "args": [
        "/path/to/opnsense-mcp-server/index.js",
        "--url",
        "https://YOUR-OPNSENSE-IP",
        "--api-key",
        "YOUR-API-KEY",
        "--api-secret",
        "YOUR-API-SECRET",
        "--no-verify-ssl"
      ]
    }
  }
}

Enable Plugin Tools: To include all 64 plugin module tools, add "--plugins" to the args or set "INCLUDE_PLUGINS": "true" in env.

Testing the Setup

Once configured, you can test the connection by asking Claude:

  • “What MCP tools are available?”
  • “Use core_manage to get the system status”
Открыть полный README на GitHub

Установка

npx -y @richard-stovall/opnsense-mcp-server
Новичок в MCP? Начните с руководства на mcpskill.org →

Конфигурация

{ "mcpServers": { "opnsense": { "command": "npx", "args": ["-y", "@richard-stovall/opnsense-mcp-server"], "env": { "OPNSENSE_URL": "https://192.168.1.1", "OPNSENSE_API_KEY": "your-api-key", "OPNSENSE_API_SECRET": "your-api-secret", "OPNSENSE_VERIFY_SSL": "false" } } } }