fix(security): consolidate host environment leak guard - #1163
Conversation
…vices Eliminates Windows host env var leakage into Docker containers by standardizing a full 8-variable leak guard (SSL_CERT_FILE, SSL_CERT_DIR, REQUESTS_CA_BUNDLE, CURL_CA_BUNDLE, NODE_EXTRA_CA_CERTS, HTTP_PROXY, HTTPS_PROXY, NO_PROXY) across all services. Previously: 14 services had partial SSL-only nullification (2 vars), 3 services had SSL_CERT_FILE only, transcribe-and-fetch had zero. Now: All 14+ main compose services + 6 transcribe submodule services have the complete guard. Sanitizer allowlist, env.shared.example, and bootstrap registry extended with the 6 new proxy/CA infrastructure vars. Fixes pmoves-transcribe-backend-1 crash (SSL_CERT_FILE → FileNotFoundError). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Docker Hardening ValidationHardening Validation ReportValidated: Tue Mar 31 02:44:21 UTC 2026Services CheckedPMOVES.AI Docker Hardening Validation[INFO] Checking: pmoves/docker-compose.hardened.yml [INFO] Validating: hi-rag-gateway-v2 [INFO] Validating: extract-worker [INFO] Validating: langextract [INFO] Validating: presign [INFO] Validating: render-webhook [INFO] Validating: retrieval-eval [INFO] Validating: pdf-ingest [INFO] Validating: jellyfin-bridge [INFO] Validating: invidious-companion-proxy [INFO] Validating: ffmpeg-whisper [INFO] Validating: media-video [INFO] Validating: media-audio [INFO] Validating: hi-rag-gateway-v2-gpu [INFO] Validating: hi-rag-gateway-gpu [INFO] Validating: deepresearch [INFO] Validating: supaserch [INFO] Validating: publisher-discord [INFO] Validating: mesh-agent [INFO] Validating: nats-echo-req [INFO] Validating: nats-echo-res [INFO] Validating: publisher [INFO] Validating: analysis-echo [INFO] Validating: graph-linker [INFO] Validating: comfy-watcher [INFO] Validating: grayjay-plugin-host [INFO] Validating: agent-zero [INFO] Validating: archon [INFO] Validating: channel-monitor [INFO] Validating: pmoves-yt [INFO] Validating: notebook-sync [INFO] Validating: supabase_service_role_key [INFO] Validating: supabase_jwt_secret ====================================== |
📝 WalkthroughWalkthroughThis PR updates environment configuration to prevent Windows Docker Desktop host variable leaks by introducing proxy and CA-bundle variables (HTTP_PROXY, HTTPS_PROXY, NO_PROXY, REQUESTS_CA_BUNDLE, CURL_CA_BUNDLE, NODE_EXTRA_CA_CERTS) across bootstrap registry, docker-compose services, and sanitization tooling while updating the PMOVES-transcribe-and-fetch submodule reference. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
pmoves/docker-compose.yml (1)
1776-1831: Remove duplicated leak-guard blocks in two services.
hi-rag-gateway-v2andhi-rag-gateway-v2-gpueach define the same guard list twice in oneenvironment:block. Keep a single copy per service to avoid drift.♻️ Proposed cleanup
hi-rag-gateway-v2: @@ - # Host environment leak guard (see x-host-leak-guard docs above) - - SSL_CERT_FILE= - - SSL_CERT_DIR= - - REQUESTS_CA_BUNDLE= - - CURL_CA_BUNDLE= - - NODE_EXTRA_CA_CERTS= - - HTTP_PROXY= - - HTTPS_PROXY= - - NO_PROXY= @@ hi-rag-gateway-v2-gpu: @@ - # Host environment leak guard (see x-host-leak-guard docs above) - - SSL_CERT_FILE= - - SSL_CERT_DIR= - - REQUESTS_CA_BUNDLE= - - CURL_CA_BUNDLE= - - NODE_EXTRA_CA_CERTS= - - HTTP_PROXY= - - HTTPS_PROXY= - - NO_PROXY=Also applies to: 1946-2005
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@pmoves/docker-compose.yml` around lines 1776 - 1831, The environment leak-guard block (variables like SSL_CERT_FILE, SSL_CERT_DIR, REQUESTS_CA_BUNDLE, CURL_CA_BUNDLE, NODE_EXTRA_CA_CERTS, HTTP_PROXY, HTTPS_PROXY, NO_PROXY, etc.) is duplicated inside the environment: of the services hi-rag-gateway-v2 and hi-rag-gateway-v2-gpu; remove the second copy so each service has only one leak-guard list, keeping the first (or canonical) block and deleting the redundant repeated block to prevent drift.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In `@pmoves/docker-compose.yml`:
- Around line 1776-1831: The environment leak-guard block (variables like
SSL_CERT_FILE, SSL_CERT_DIR, REQUESTS_CA_BUNDLE, CURL_CA_BUNDLE,
NODE_EXTRA_CA_CERTS, HTTP_PROXY, HTTPS_PROXY, NO_PROXY, etc.) is duplicated
inside the environment: of the services hi-rag-gateway-v2 and
hi-rag-gateway-v2-gpu; remove the second copy so each service has only one
leak-guard list, keeping the first (or canonical) block and deleting the
redundant repeated block to prevent drift.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: 11e51f87-5c85-4a68-a7f2-f9a15fd9c2ea
📒 Files selected for processing (5)
PMOVES-transcribe-and-fetchpmoves/bootstrap/registry.jsonpmoves/docker-compose.ymlpmoves/env.shared.examplepmoves/tools/sanitize_env_shared.py
Missed in #1163 — transcribe-backend in main compose had no SSL/proxy nullification, causing persistent crash from Windows SSL_CERT_FILE leak. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Missed in #1163 — transcribe-backend in main compose had no SSL/proxy nullification, causing persistent crash from Windows SSL_CERT_FILE leak. Co-authored-by: Shaela Bello <slbello@uncg.edu> Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Standardizes 8-variable host leak guard across all Docker services. Fixes transcribe-backend crash from Windows SSL_CERT_FILE leak.
Summary by CodeRabbit