fix(security): remove readiness check from MemPalace MCP server startup#28340
fix(security): remove readiness check from MemPalace MCP server startup#28340
Conversation
This comment has been minimized.
This comment has been minimized.
…n mempalace MCP server startup Resolves RGS-012: Secret Exfiltration via Outbound HTTP Request in daily-fact The curl -sf http://127.0.0.1:8765/mcp health check was flagged by runner-guard because the structural pattern (outbound HTTP + secrets access) is identical to credential exfiltration attacks. Replace with a Python TCP socket check that: - Makes no HTTP requests - Is hardcoded to 127.0.0.1:8765 (no env var injection possible) - Cannot be repurposed to send data to external domains - Still validates that the MCP server port is accepting connections Regenerate daily-fact.lock.yml from the updated mempalace.md import. Agent-Logs-Url: https://github.com/github/gh-aw/sessions/b6c02014-7697-4aa7-ae9a-6d32188da0fb Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
|
Hey A few things to address before this is ready for review:
Once you've implemented the changes, you can use the prompt below to complete the work:
|
|
@copilot remove /mcp curl check |
|
@copilot merge main and recompile |
There was a problem hiding this comment.
Pull request overview
Replaces an HTTP curl readiness check with a TCP-only socket probe when starting the MemPalace MCP server to avoid Runner-Guard RGS-012 triggering on outbound HTTP requests.
Changes:
- Updated MemPalace MCP server startup to wait on TCP port readiness via a Python socket connect.
- Regenerated
daily-fact.lock.ymlto reflect the updated shared MCP startup snippet and updated metadata hashes.
Show a summary per file
| File | Description |
|---|---|
.github/workflows/shared/mcp/mempalace.md |
Swaps the curl HTTP health check for a Python TCP socket probe during server startup. |
.github/workflows/daily-fact.lock.yml |
Regenerated lockfile reflecting the updated MemPalace startup logic and updated prompt/config heredoc IDs. |
Copilot's findings
Tip
Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Files reviewed: 2/2 changed files
- Comments generated: 1
| # Wait for server to start (TCP port check avoids outbound HTTP requests) | ||
| for i in $(seq 1 10); do | ||
| if curl -sf http://127.0.0.1:8765/mcp >/dev/null 2>&1; then | ||
| if python3 -c "import socket; s=socket.socket(); s.settimeout(1); s.connect(('127.0.0.1', 8765)); s.close()" 2>/dev/null; then |
…filtration-issue # Conflicts: # .github/workflows/daily-fact.lock.yml Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Agent-Logs-Url: https://github.com/github/gh-aw/sessions/8aa3a000-3801-4330-9c9a-e9fd3c23e17a Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Done in 2f61b7e — merged Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
|
Remove the check entirely. Do not use python or curl. @copilot |
Agent-Logs-Url: https://github.com/github/gh-aw/sessions/5bdc92a0-9f68-4219-8fba-e5a425fa5384 Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Done in de1ecc4 — the entire readiness check (loop, python socket probe, and error handler) has been removed. The step now simply starts the server in the background and logs the PID. Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
Runner-Guard RGS-012 flags any outbound HTTP request co-located with secrets access as a structural exfiltration risk — even a localhost
curl. Theshared/mcp/mempalace.mdstartup step usedcurl -sf http://127.0.0.1:8765/mcpto wait for the MemPalace MCP server to become ready.Change
Remove the readiness check entirely. The server is launched in the background and the step exits immediately after logging the PID — no
curl, no Python socket probe, no wait loop.This eliminates the flagged exfiltration surface without introducing any alternative probe mechanism.
All lock files regenerated via
make recompile.