OPNSenseMCP MCP Server

Model Context Protocol server for OPNSense firewall management with inter-VLAN routing diagnostics, ARP table, DNS filtering and HAProxy support via

Local serverstdio

What is the OPNSenseMCP MCP Server?

Model Context Protocol server for OPNSense firewall management with inter-VLAN routing diagnostics, ARP table, DNS filtering and HAProxy support via Claude Desktop

What it actually does

A Model Context Protocol (MCP) server for comprehensive OPNsense firewall management. This server enables AI assistants like Claude to directly manage firewall configurations, diagnose network issues, and automate complex networking tasks.

Configuration

  • Node.js 18+ or Bun 1.0+ - OPNsense firewall (v24.7+ recommended) - API credentials for OPNsense - SSH access (optional, for advanced features)

More MCP options

Compare MCP servers by category, or browse hosted MCP servers if you prefer an endpoint over a local process.

Maintainer setup documentation.

Recorded tools

Check the linked publisher documentation and your connected client's tool list. Names and availability can vary with the server version and account permissions.

ToolWhat it does
firewall_list_rulesList all firewall rules
firewall_create_ruleCreate a new rule
firewall_update_ruleUpdate existing rule
firewall_delete_ruleDelete a rule
firewall_apply_changesApply pending changes
nat_list_outboundList outbound NAT rules
nat_set_modeSet NAT mode
nat_create_outbound_ruleCreate NAT rule
nat_fix_dmzFix DMZ NAT issues
nat_analyze_configAnalyze NAT configuration
arp_listList ARP table entries
routing_diagnosticsDiagnose routing issues
routing_fix_allAuto-fix routing problems
interface_listList network interfaces
vlan_createCreate VLAN
system_execute_commandExecute CLI command
backup_createCreate configuration backup
service_restartRestart a service

How to install the OPNSenseMCP MCP Server

{
  "mcpServers": {
    "opnsense": {
      "command": "bun",
      "args": [
        "run",
        "/path/to/OPNSenseMCP/src/index.ts"
      ],
      "env": {
        "OPNSENSE_HOST": "https://your-opnsense:port",
        "OPNSENSE_API_KEY": "YOUR_OPNSENSE_API_KEY",
        "OPNSENSE_API_SECRET": "YOUR_OPNSENSE_API_SECRET",
        "OPNSENSE_VERIFY_SSL": "false"
      }
    }
  }
}

From the project documentation. Replace placeholders and example paths before connecting.

Configuration

  • Node.js 18+ or Bun 1.0+ - OPNsense firewall (v24.7+ recommended) - API credentials for OPNsense - SSH access (optional, for advanced features)
VariableDescriptionRequired
OPNSENSE_HOSTDeclared in the maintainer’s client configuration.Check documentation
OPNSENSE_API_KEYDeclared in the maintainer’s client configuration.Check documentation
OPNSENSE_API_SECRETDeclared in the maintainer’s client configuration.Check documentation
OPNSENSE_VERIFY_SSLDeclared in the maintainer’s client configuration.Check documentation

Example prompts to try

  • “Use OPNSenseMCP to firewall list rules.”
  • “Use OPNSenseMCP to firewall create rule.”
  • “Use OPNSenseMCP to firewall update rule.”

Frequently asked questions

Model Context Protocol server for OPNSense firewall management with inter-VLAN routing diagnostics, ARP table, DNS filtering and HAProxy support via Claude Desktop Confirm the tools offered by your installed version in the connected client. Tool availability and permissions depend on the server and account configuration.