mcp-pfsense
Provides read-only access to a pfSense firewall's REST API, exposing tools for viewing system status, interfaces, gateways, firewall rules, aliases, NAT, DHCP, DNS, WireGuard, and ARP.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@mcp-pfsenseshow me the current firewall states"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
mcp-pfsense
Read-only MCP server for the
pfSense REST API (community package pfSense-pkg-RESTAPI).
No write tools in v0. Designed for local MCP clients against a pfSense box reached over a private network (VPN / reverse proxy recommended).
Features
API key auth (
X-API-Key)HTTP client that only issues
GETAggressive secret redaction (WireGuard keys, passwords, bcrypt hashes…)
Tools: system, interfaces, gateways, firewall, aliases, NAT, DHCP, DNS, WireGuard, ARP
Related MCP server: coreyhines/opnsense-mcp
Requirements
Python 3.11+
pfSense CE with
pfSense-pkg-RESTAPI≥ v2.9.0 installed (see SETUP.md)Network path to the webGUI API (VPN + private reverse proxy recommended)
Setup
cp .env.example .env # set PFSENSE_URL, PFSENSE_API_KEY
poetry installSee SETUP.md for creating user mcp and a read-only API key.
Run (stdio)
poetry run mcp-pfsenseMCP client config
Point your client at the in-project Poetry venv (after poetry install with virtualenvs.in-project = true):
{
"mcpServers": {
"pfsense": {
"command": "/absolute/path/to/mcp-pfsense/.venv/bin/python",
"args": ["-m", "mcp_pfsense"],
"envFile": "/absolute/path/to/mcp-pfsense/.env"
}
}
}On Windows, use .venv\\Scripts\\python.exe instead of .venv/bin/python.
Works the same way for Cursor, Claude Desktop, Codex, or any stdio MCP client.
Inspector
npx @modelcontextprotocol/inspector poetry run mcp-pfsenseConnectivity check
poetry run mcp-pfsense-check
poetry run mcp-pfsense-check --check-write-denied # optional ACL probeTests
poetry run pytest
poetry run ruff check .
poetry run ruff format --check .Env vars
Variable | Description |
| Base URL, no trailing slash (required) |
| API key (required) |
|
|
| Seconds |
Security model
The HTTP wrapper exposes only
GET; non-GET methods are not available on the client.Responses are recursively redacted for known secret keys (WireGuard private/preshared keys, passwords, bcrypt hashes, …).
Prefer three locks: package Read only, a GET-only user, and this GET-only client.
Do not expose the pfSense webGUI on the WAN; reach it over VPN or a private reverse proxy.
License
MIT
This server cannot be deployed
Maintenance
Related MCP Connectors
Read-only MCP access to a documented IT fleet: state, changes, posture. 15 tools.
XFA's remote MCP server — query device posture, compliance, policies & CVEs. Read-only.
49 developer tools via MCP: DNS, WHOIS, IP lookup, JWT, hashing, QR, and more.
Censys MCP — internet-scan search over the Censys Platform API (censys.com)
Related MCP Servers
- AlicenseAqualityDmaintenanceSlim OPNsense MCP Server — 62 tools for managing firewall infrastructure via the OPNsense REST API. Covers DNS/Unbound, Firewall rules, Diagnostics, Interfaces, DHCP (ISC + Kea), System/Backups, ACME/Let's Encrypt, and Firmware. No SSH, no shell, API-only with 3 runtime dependencies. AGPL-3.0 + Commercial dual-licensed.10054 npm2AGPL 3.0
- AlicenseBqualityAmaintenanceOPNsense firewall operations via API & mcp. Query ARP, DHCP, firewall rules, logs, interfaces, system status, and packet capture via STDIO or SSE.1410MIT
- AlicenseAqualityBmaintenanceEnables AI assistants to manage pfSense firewalls using 17 tools for system status, firewall rules, DHCP, DNS, monitoring, and service management via the pfSense REST API.1730 PyPI6MIT
- AlicenseCqualityCmaintenanceA read-only MCP server that provides 60+ tools to query Sophos XGS firewall configurations via the XML API, covering firewall rules, NAT, VPN, web filtering, and more.63AGPL 3.0