Files
metasploit-gs/config/mcp_config_jsonrpc.yaml.example
T
Christophe De La Fuente 6f3884e832 Redesign the logging capability using Rex::Logging and Rake middleware
- remove the original Logger
- use Rex::Logging with helper methods (dlog, ilog, etc.)
- add `sanitize` configuration option
- create Sanitizing, JsonFlatfile and JsonStream sinks for JSON logging format
- minor updates in apply_default (Loader)
- update the re-authentication logic (fix a specific usecase)
- add a Rack middleware that logs MCP HTTP request/response
- use Rex::Socket::Tcp instead of TcpSocket
- update the ensure_rpc_available for better validation
- use around_request instead of the deprecated SDK instrumentation for logging
- update and add specs
2026-04-30 11:10:09 +02:00

33 lines
1.1 KiB
Plaintext

# Metasploit RPC API connection (JSON-RPC)
msf_api:
type: json-rpc
host: localhost
port: 8081
ssl: true
endpoint: /api/v1/json-rpc
token: YOUR_BEARER_TOKEN_HERE
# auto_start_rpc is not supported for JSON-RPC (only MessagePack)
# MCP server configuration
mcp:
transport: stdio # stdio (default) or http
# MCP server network configuration (for HTTP transport only)
host: localhost # Host to bind to (default: localhost)
port: 3000 # Port to listen on (default: 3000)
# Rate limiting (optional - defaults shown)
rate_limit:
enabled: true
requests_per_minute: 60
# If the `burst_size` is greater than `requests_per_minute`, a user will be allowed to exceed the rate limit temporarily.
# For example, with `requests_per_minute=5` and `burst_size=10`, a user could make 10 requests in a short period,
# but then would be limited to 5 requests per minute thereafter.
burst_size: 10
# Logging (optional - defaults shown)
logging:
enabled: false
level: INFO # DEBUG, INFO, WARN, ERROR
log_file: ~/.msf4/logs/msfmcp.log
sanitize: true