Commit Graph
9935 Commits
Author SHA1 Message Date
Huanqi Cao 2ecfe383c7 fix(cli): resolve the pwsh-sandbox layer row from the cold-start module closure
The launcher's healProfilesModuleFallback BFS-links the apps/cli dependency closure into the profile's node_modules (the pwsh-local precedent): without dsh-pwsh-sandbox in apps/cli dependencies, a fresh Windows host cannot resolve the inserted row. Assert the closure reaches both inserted packages in the real-layers composition; rewrap the windows-shell layer comment.
2026-08-08 13:44:05 +08:00
Huanqi Cao 83f288993f fix(sandbox): mark the pwsh-sandbox executor's deliberate twin mirror for the clone gate
The duplication gate flags the call-for-call mirror of bash-sandbox's executor (the pwsh-tool-and-executor decision): wrap the class body in jscpd ignore markers, the same convention the invariant companions use.
2026-08-08 12:35:27 +08:00
Huanqi Cao e660ec8cf5 fix(sandbox): pack the windows-acl rung in the publish-path rehearsal
sandbox-local now depends on @deepseek-ai/dsh-sandbox-windows-acl, so the packed-install e2e must carry its tarball in the workspace closure — npm cannot resolve the private package from the registry. koffi and the shared peers (dsh-invariants, cordis) already resolve from the registry or the existing closure.
2026-08-08 12:20:49 +08:00
Huanqi Cao b60e64c592 Merge remote-tracking branch 'origin/feat/windows-pwsh-default' into feat/windows-acl-sandbox
# Conflicts:
#	apps/cli/reference/README.i18n.yaml
2026-08-08 12:13:23 +08:00
Huanqi Cao 94f1a7741c Merge remote-tracking branch 'origin/master' into HEAD
# Conflicts:
#	apps/cli/reference/README.i18n.yaml
2026-08-08 12:09:04 +08:00
Huanqi Cao ae7d16815d chore: retrigger CI (no workflow run was created for the previous push) 2026-08-08 11:51:53 +08:00
Huanqi Cao d8acd2b656 fix(ci): pass the pwsh-less self-hosted Linux runners
The self-hosted Linux runners ship no pwsh, and the pwshAvailable probes used spawnSync('where.exe'), which reports a missing binary as status null instead of throwing — the suites never skipped and failed with spawn pwsh ENOENT. Probe with resolvePwshPath() status instead, the same gate the coverage exemption uses. Exempt pwsh-sandbox src from coverage on pwsh-less hosts (its remaining helpers branch and the invariant companion ride the executor suites' real pwsh runs); pwsh-ful hosts keep the full 100% bar. Cover the windows-acl probe case and the runner-entry resolution in sandbox-local on Linux (chain-seam tests plus a windowsAclRunnerEntry seam) — the package's POSIX-only suites are Linux's only chance to cover the new lines. Static gate fixes: declare dsh-pwsh-sandbox in the base bundle, register the runner files entry in constraints, knip entries for the e2e suite and where.exe, regenerate the module graph. Verified in WSL (no-pwsh Linux): pwsh-sandbox 5 pass/13 skip with the exemption active, sandbox-local coverage 100%.
2026-08-08 11:46:05 +08:00
Huanqi Cao aa790346e4 docs(sandbox): explain why the token intersection needs no new identity
Add the mechanism section to the Windows rung Agent Note: identity routes (restricted-user, AppContainer) default-deny everything from a fresh SID and pay per-path ACE writes for every read, while the WRITE_RESTRICTED token keeps the caller's SID and double-checks write-class access only — reads pass on the normal check alone. Covers DISABLE_MAX_PRIVILEGE/LUA_TOKEN as the token-side limited-user synthesis and why SidsToDisable read restriction is unused.
2026-08-08 02:42:47 +08:00
Huanqi Cao 264420127a docs(sandbox): record the Windows rung design choice — raw ACL restricted tokens over mxc and AppContainer
Add the implemented Agent Note owning the win32 rung decision: mxc rejected (OS floor 24H2, BaseContainer tier only on 25H2+ with the OS feature enabled, and arbitrary-path reads demand wholesale host DACL writes), AppContainer rejected (no ambient read access — arbitrary-path reads unsupported), landstrip already rejected and AppContainer-shaped. Link the note from the backend README pair and restate the choice in the PR description.
2026-08-08 02:32:54 +08:00
Huanqi Cao dcd5a50374 docs(sandbox): satisfy the doc-sync gates for the Windows ACL packages
JSDoc every sandbox-windows-acl export (the 138 verify-export-jsdoc violations); fix the sandbox-windows-acl README code block (undeclared workspaceRoot), bring its stale claims current (the provider wiring and kill-on-close are live), add the canonical Model Experience sections to both new packages, audited the backend's indirect Model Experience sentence, and regenerate docs/config-catalog.md.
2026-08-08 02:26:26 +08:00
Huanqi Cao bec3cba084 test(scripts): split placed-image paths on both separators in project-doc-site.spec.ts
The placer fixtures derive the basename with split('/'), which never splits a Windows absolute path (backslashes), so the two image-placement tests fail on win32 hosts. The production rewrite passes absolute paths through; the fixtures now accept both separators.
2026-08-08 02:25:44 +08:00
Huanqi Cao 7574769818 fix(bundle): drop fs-local from the Windows layer — duplicate ctx.fs registration failed load
The Windows platform layer re-enables the base fs-sandbox row (removing its disable), but still inserted dsh-fs-local: both extend FileSystem and provide ctx.fs, so every shipped win32 profile failed at load. Delete the insert; fs-sandbox stays the single fs provider exactly as on POSIX. Sync the roster specs, the base/reference README pairs, the sandbox core doc (read-only grants no sink on Windows), the windows-shell JSDoc, and re-record the i18n pairings.
2026-08-08 02:11:15 +08:00
Huanqi Cao 94991499c8 docs(pwsh-sandbox): real temp grant is a backend-defined choice aligned with Landlock, not deferred work 2026-08-08 01:36:34 +08:00
Huanqi CaoandHuo Yaoyuan f64ba40f43 feat(sandbox): Windows ACL write-restriction sandbox (restricted-token runner)
Confine Windows command execution through a WRITE_RESTRICTED token whose restricting SIDs carry an orphan-SID write allowlist, ported from https://github.com/huoyaoyuan/windows-acl-restrict-poc (@ 10e4dfb). Every Win32 call is checked and fails closed - the POC silently ran children with the FULL token when CreateRestrictedToken failed.

- @deepseek-ai/dsh-sandbox-windows-acl: koffi primitives verified against the MinGW Windows headers (verify/abi-probe.cpp) plus the confinement runner ([node, runner, --workspace, --temp, --mode, --, argv...]: kill-on-close job, stdio passthrough, exit-code mirroring, windows-acl-run: failure signature, grant revocation). read-only = strict zero grants (NUL device not writable; documented). Windows-only execution: exempted from the Linux coverage lane (windowsOnlyCoverageExclusions).
- @deepseek-ai/dsh-sandbox-local: PLATFORM_CHAINS.win32 filled with the windows-acl runner (full enforcement, ACL denial dialect, runner-failure rules).
- @deepseek-ai/dsh-pwsh-sandbox: sandbox-consuming pwsh executor (call-for-call mirror of dsh-bash-sandbox) over a new argv-level seam in dsh-pwsh-local; per-file coverage complete via the fake-provider spec.
- bundle/base: the Windows platform layer mounts the confined pwsh roster - sandbox/policy/fs-sandbox/permission/approval re-enabled, the POSIX bash stack stays disabled.

Co-authored-by: Huo Yaoyuan <huoyaoyuan@hotmail.com>
2026-08-08 01:24:33 +08:00
Tianyi Cui a29a0a4773 Merge pull request #1547 from deepseek-harness/claude/unified-environment-credentials-c8841a
feat(config): rank every configuration source and bound what a discovered file may set
2026-08-08 00:43:42 +08:00
Tianyi Cui 510976351c test(telemetry): restore expression-tag coverage 2026-08-08 00:34:42 +08:00
Tianyi Cui b166b837d8 Merge origin/master at bc7849b97b 2026-08-07 23:57:47 +08:00
Tianyi Cui f00f45e3f9 Merge origin/master at f1402327fa 2026-08-07 23:57:23 +08:00
Tianyi Cui 698d65de2d Merge pull request #1965 from deepseek-harness/worktree/archive-agent-notes-aggressive-20260807
docs(notes): aggressively archive low-value records
2026-08-07 23:53:34 +08:00
Tianyi Cui 8315bfdc1f fix(notes): address archive review findings 2026-08-07 23:45:28 +08:00
Tianyi Cui 62ae990c27 cleanup(config): consolidate source ownership rationale 2026-08-07 23:43:15 +08:00
Tianyi Cui b5fbcaccf8 cleanup(config): localize bootstrap policy to app boot 2026-08-07 23:37:53 +08:00
Tianyi Cui d0e052dd83 cleanup(environment): keep one lookup order 2026-08-07 23:33:11 +08:00
Tianyi Cui 2c532f3b2c cleanup(environment): remove unused layer inventory 2026-08-07 23:30:03 +08:00
Tianyi Cui 95366f6197 fix(cli): parse commands before loading environment 2026-08-07 23:28:17 +08:00
Tianyi Cui 4ee93f7944 fix(config): cover shipped bundle source ownership 2026-08-07 23:26:39 +08:00
Tianyi Cui e901d9fcca Merge pull request #1785 from deepseek-harness/fix/update-explore-unknown-copy
fix(ui): update hero headline copy
2026-08-07 23:13:37 +08:00
Tianyi Cui 1c23f196fe fix(ui): use official hero title casing 2026-08-07 23:05:55 +08:00
Tianyi Cui 356ded2ca7 Merge branch 'master' into worktree/archive-agent-notes-aggressive-20260807 2026-08-07 22:57:51 +08:00
Tianyi Cui 06a449b38f Merge pull request #1550 from deepseek-harness/worktree/pr-to-issue-lifecycle
fix(infra): advance resolving Issue status from PRs
2026-08-07 22:53:44 +08:00
Tianyi Cui db0133b4c7 docs(notes): archive low-value records 2026-08-07 22:52:19 +08:00
Tianyi Cui 38c373af65 fix(ci): keep issue policy test discovery focused 2026-08-07 22:41:09 +08:00
Tianyi Cui 2cfea8ab67 Merge branch 'master' into worktree/pr-to-issue-lifecycle 2026-08-07 22:25:01 +08:00
Tianyi Cui 356453d6cb cleanup(config): remove literal credential compatibility residue
Adapter schemas now carry only credential references, but the Models join, onboarding readiness, shipped overlays, SDK scaffolding, fixtures, and active decision prose still treated a redacted literal apiKey as a supported compatibility state. That residue made an unsupported field look contractual and pinned Schemastery silent-dropping as behavior.

Delete those branches and examples, and let compositions and scaffolds use adapter-owned reference and environment resolution. Do not add a tombstone validator or change generic unknown-key behavior: literal adapter credentials have no migration contract to preserve.
2026-08-07 22:04:04 +08:00
Tianyi Cui ac154b2dfa test(cli): cover Harness-home credential loading in built entry
Source-level environment and credential tests prove the individual loaders, but they do not prove that the published launcher runs them before Loader evaluates a shipped profile.

Start the built dsh binary with the shipped base bundle and a test-only LLM probe. Put the endpoint in $DSH_HOME/.env, put the bearer token only in $DSH_HOME/.credentials.yaml, remove inherited DeepSeek overrides, and assert the mock request received both without leaking the token. This covers launch order, profile composition, the adapter, and the credential seam without a real API.
2026-08-07 22:04:04 +08:00
Tianyi Cui 3dfb16008d docs(config): align environment and credential contracts
Code already treats $DSH_HOME/.env as ordinary launch environment and stores managed credentials in .credentials.yaml, but public docs still described the old store, old precedence, removed literal adapter keys, and the deleted TUI. That directed users to the wrong file and overstated the supported configuration surface.

Update the existing English and Chinese owners in place, document inherited > managed > project > user credential resolution, and record the loadLayeredEnv export. Regenerate only pairing records and the source-line catalog; add no new section or site route.
2026-08-07 22:04:04 +08:00
imccyu 1a7ac8fee1 Merge pull request #1777 from deepseek-harness/stack/typert-remote-gateway-1-infrastructure
feat: add TypeRT remote gateway infrastructure
2026-08-07 21:55:46 +08:00
imccyu 71ebeaa559 fix(client-runtime): localize remote namespace dependency 2026-08-07 21:47:18 +08:00
imccyu ddd43ec371 test(api-gateway): repair CI fixtures 2026-08-07 21:47:18 +08:00
imccyu 00a559bf2b test(api-gateway): assert withdrawn method failure 2026-08-07 21:47:18 +08:00
imccyu 8b51a1e95c test(api-gateway): cover namespace rollback paths 2026-08-07 21:47:18 +08:00
imccyu 14ea7e134d fix(api-remotes): await namespace assembly startup 2026-08-07 21:47:18 +08:00
imccyu 5c2625c26e docs(typert): align client remote type mapping 2026-08-07 21:47:18 +08:00
imccyu 55ccfb5a48 fix(api): preserve dynamic defaults after rebase 2026-08-07 21:47:18 +08:00
imccyu 8bbbb6fe59 fix(api-gateway): compose scoped remote fixture types 2026-08-07 21:47:18 +08:00
imccyu d362cdb54f refactor(typert): rename RemoteContext to RemoteScope 2026-08-07 21:47:18 +08:00
imccyu d6ffd87c5f refactor(api): expose traced remote namespaces 2026-08-07 21:47:18 +08:00
imccyu 146097368b fix(api-gateway): type async service disposer 2026-08-07 21:47:18 +08:00
imccyu d3b7ff17f0 fix: ci 2026-08-07 21:47:17 +08:00
imccyu 686ee5b3f6 fix(api-gateway): harden remote lifecycle and recovery 2026-08-07 21:47:17 +08:00