Skip to content

fix(security): no absolute server paths in job errors or create_workspace; watchdog false stall - #581

Merged
dkackman merged 2 commits into
developfrom
fix/ghsa-server-path-disclosure
Oct 3, 2026
Merged

dkackman merged 2 commits into
developfrom
fix/ghsa-server-path-disclosure

Conversation

@dkackman

@dkackman dkackman commented Oct 3, 2026

Copy link
Copy Markdown
Owner

Fixes the two draft advisories GHSA-fwg5-jfjg-fxpf and GHSA-crqf-hw9p-r739. It applies the rule from #521/#527: no response an MCP client sees carries an absolute server path.

Security (d983feb)

  • When a job fails, the worker rewrites the failure message and traceback before replying (dw/path_redaction.py, called from dw/worker.py). A file under the asset search path becomes asset:<name>, a file under the job's output directory becomes output:<name>, and a bare root becomes "the asset library" or "the output folder". The references are built through dw.references, the only module allowed to spell a prefix.
  • An asset that isn't found is reported with the library's origin, not its path. This applies to both resolve_asset_reference and the asset 404 in dw/server/outputs.py.
  • The MCP tool create_workspace now returns only name and default. list_workspaces(detail=True) is still how a client opts in to seeing folder paths. The HTTP API is unchanged.
  • The modules baseline goes from 168 to 171: the new path_redaction module, plus the two modules #471 stage 1: upscale_h3_latents + decode_h3_latents tasks, no refine (the measurement) #499 relanded.

Test fixes (7a0fdd5)

  • dw/events.py: note_phase now restarts the stall watchdog's clock. Before this, a quiet stretch before a phase made the watchdog report a stall 0.0 s into it, which is what made test_watchdog_fires_after_threshold_with_no_events flaky. A new regression test fails without the fix.
  • tests/conftest.py: VRAM estimate checks no longer read the capacity of the accelerator the suite runs on. On a 24 GB Mac this had caused 36 failures that only happened there.
  • tests/test_step_cache.py: regenerated four pipeline-key hashes that went stale when M-F025: FLUX prompt-weighting and step-caching OOM on idle 24 GB card despite offload: model #580 changed four templates' offload setting.

Not covered: traceback lines still show paths to the source code and to site-packages.

Test plan

  • Full suite, three runs in a row: 7984 passed, 15 skipped, 1 xfailed
  • python scripts/arch_metrics.py --check docs/stabilization/baseline.json

🤖 Generated with Claude Code

dkackman and others added 2 commits October 2, 2026 22:37
… server paths in job errors or create_workspace

GHSA-fwg5-jfjg-fxpf: a task failing on an 'asset:' input reported the path
the reference had resolved to, so a job error read over MCP or the HTTP API
carried the server's home directory and workspace layout. The worker's
failure reply now runs its message and traceback through
dw/path_redaction.py's redact_paths: a file under the job's asset search
path becomes 'asset:<name>', one under its output directory
'output:<name>', and a bare root the library's name. The log keeps the
paths. The asset not-found messages (dw/assets.py, the gallery metadata
404 in dw/server/outputs.py) name the libraries searched by origin
(workspace, common, examples) instead of by directory.

GHSA-crqf-hw9p-r739: create_workspace's MCP result is name/default/
current/next only; list_workspaces(detail=True) stays the opt-in for
folder paths. The HTTP POST /api/workspaces response is unchanged.

Still open: a traceback's frame lines name the server's source and
site-packages paths; get_job returns the traceback.

Raises the `modules` baseline 168 -> 171: dw/path_redaction.py (this
change), plus dw/tasks/h3_latent_upscale.py and
dw/tasks/h3_latent_upscaler_model.py, which the #499 reland (924a973)
added without raising it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@dkackman
dkackman merged commit c352d19 into develop Oct 3, 2026
7 checks passed
@dkackman
dkackman deleted the fix/ghsa-server-path-disclosure branch October 3, 2026 03:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant