pfsense-mcp-server
by gensecaihq·★ 69·Score 47
pfSense MCP Server enables security administrators to manage firewalls through natural language commands with 327 tools and 9 safety layers.
Overview
This MCP server connects AI assistants like Claude Desktop to pfSense firewalls via REST/XML-RPC/SSH connections. It provides comprehensive access to firewall management capabilities while implementing robust safety measures including automatic backups, explicit confirmations for destructive operations, and input sanitization. The server supports multiple pfSense versions and authentication methods, making it suitable for diverse enterprise environments.
Try asking AI
After installing, here are 5 things you can ask your AI assistant:
When to choose this
Teams managing pfSense firewalls who want to reduce configuration complexity through natural language interfaces with built-in safety guardrails.
When NOT to choose this
You're using non-pfSense firewalls, as this MCP server is specifically designed for pfSense integration only.
Tools this server exposes
12 tools extracted from the READMEcreate_firewall_ruleCreates a new firewall rule with specified action, interface, protocol, and source/destination
get_firewall_rulesRetrieves current firewall rules with filtering options
create_port_forwardCreates a new NAT port forward rule to redirect external traffic to internal hosts
start_openvpn_serverStarts an OpenVPN server with specified configuration
create_static_routeAdds a static route to the routing table
get_system_statusRetrieves comprehensive system status including uptime, interfaces, and services
create_dns_overrideCreates a DNS override entry for specific hosts or domains
run_system_health_checkPerforms a comprehensive health check of the pfSense system
add_dhcp_static_mappingAdds a static DHCP mapping for a specific MAC address
generate_self_signed_certGenerates a self-signed SSL certificate for internal services
block_ipBlocks a specific IP address at the firewall level
run_pci_compliance_checkPerforms a PCI compliance check on firewall configuration
Comparable tools
Installation
Installation
**Prerequisites:** Python 3.10+, pfSense with [REST API v2 package](https://github.com/pfrest/pfSense-pkg-RESTAPI) installed
git clone https://github.com/gensecaihq/pfsense-mcp-server.git
cd pfsense-mcp-server
pip install -r requirements.txt
cp .env.example .env
# Edit .env: set PFSENSE_URL, AUTH_METHOD, and credentials**Connect to Claude Desktop** — add to ~/Library/Application Support/Claude/claude_desktop_config.json:
{
"mcpServers": {
"pfsense": {
"command": "python3",
"args": ["-m", "src.main"],
"cwd": "/path/to/pfsense-mcp-server",
"env": {
"PFSENSE_URL": "https://192.168.1.1",
"AUTH_METHOD": "basic",
"PFSENSE_USERNAME": "admin",
"PFSENSE_PASSWORD": "your-password",
"PFSENSE_VERSION": "CE_2_8_0",
"VERIFY_SSL": "false"
}
}
}
}FAQ
- What safety measures does this server implement?
- The server includes 9 layers of security: input sanitization, explicit confirmations for destructive operations, automatic config backups before changes, rate limiting to prevent runaway AI loops, and audit logging with redacted sensitive parameters.
- Which pfSense versions are supported?
- Verified versions include pfSense CE 2.8.1 and pfSense Plus 25.11 with REST API v2.7.3. Also supported are pfSense CE 2.8.0 and pfSense Plus 24.11 with REST API v2.6.0+.
Compare pfsense-mcp-server with
Last updated · Auto-generated from public README + GitHub signals.