deadbyte-mcp 0.15.27 → 0.15.29

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (42) hide show
  1. package/MANIFEST.SHA256 +41 -25
  2. package/PROVENANCE.json +16 -10
  3. package/README.txt +32 -14
  4. package/RELEASE.json +55 -15
  5. package/SBOM.cdx.json +3 -3
  6. package/TEST-MATRIX.json +147 -23
  7. package/bin/deadbyte-process-host.exe +0 -0
  8. package/bin/deadbyte-process-host.obj +0 -0
  9. package/controller/deadbyte-controller.ps1 +4 -1
  10. package/controller/deadbyte-process-policy.json +1 -1
  11. package/docs/R51-PROVENANCE.json +18 -0
  12. package/docs/R51-RELEASE.json +115 -0
  13. package/docs/R51-TEST-MATRIX.json +166 -0
  14. package/docs/R52-ACTIVATION-FORENSICS.md +85 -0
  15. package/native/deadbyte-process-host.cpp +5 -3
  16. package/package.json +95 -93
  17. package/scripts/deploy-r48.mjs +1 -1
  18. package/scripts/gate-windows-r51.ps1 +58 -0
  19. package/scripts/gate-windows-r52.ps1 +58 -0
  20. package/scripts/windows-gate-evidence-r51.mjs +84 -0
  21. package/scripts/windows-gate-evidence-r52.mjs +94 -0
  22. package/src/coding-plane.mjs +190 -28
  23. package/src/coding-task-runtime.mjs +10 -4
  24. package/src/deadbyte-cli.mjs +88 -28
  25. package/src/remote-live-log.mjs +17 -5
  26. package/src/remote-session-guardian.mjs +1 -1
  27. package/src/runtime-coherence.mjs +50 -0
  28. package/src/runtime-update.mjs +8 -2
  29. package/src/version.mjs +1 -1
  30. package/test/coding-runtime.test.mjs +104 -1
  31. package/test/helpers/coding-disconnect-server.mjs +11 -0
  32. package/test/production-docs.test.mjs +5 -3
  33. package/test/r48-release-contract.test.mjs +7 -30
  34. package/test/r49-windows-gate.test.mjs +17 -11
  35. package/test/r51-live-log-polling.test.mjs +28 -0
  36. package/test/r51-release-contract.test.mjs +58 -0
  37. package/test/r51-runtime-coherence.test.mjs +59 -0
  38. package/test/r52-host-revocation.test.mjs +65 -0
  39. package/test/r52-offline-predecessor-recovery.test.mjs +77 -0
  40. package/test/r52-release-contract.test.mjs +58 -0
  41. package/test/remote-live-log-r37.test.mjs +14 -0
  42. package/test/remote-session-cli.test.mjs +24 -24
package/package.json CHANGED
@@ -1,95 +1,97 @@
1
1
  {
2
- "name": "deadbyte-mcp",
3
- "version": "0.15.27",
4
- "private": false,
5
- "type": "module",
6
- "description": "Authenticated MCP agentic runtime with signed skills, persistent model backends, identity-bound remote devices, durable job supervision, immutable release slots, and separately revocable machine authority.",
7
- "engines": {
8
- "node": ">=22"
9
- },
10
- "scripts": {
11
- "test": "node --test test/*.test.mjs",
12
- "manifest:write": "node scripts/release-manifest.mjs write",
13
- "manifest:verify": "node scripts/release-manifest.mjs verify",
14
- "r41:parent:verify": "node scripts/verify-r41-parent.mjs",
15
- "r41:memory:verify": "node scripts/verify-memory-r41.mjs",
16
- "r42:parent:verify": "node scripts/verify-r42-parent.mjs",
17
- "r42:eval": "node scripts/agent-eval-r42.mjs",
18
- "self-update:runtime": "node scripts/runtime-self-update.mjs",
19
- "self-update:deferred": "node scripts/deferred-slot-operation-r46.mjs",
20
- "release:parity": "node scripts/release-parity-r46.mjs",
21
- "release:final:write": "node scripts/final-closure-r46.mjs",
22
- "release:final:verify": "node scripts/final-closure-verify-r46.mjs",
23
- "proof": "node src/proof-cli.mjs workspaces/demo input.txt",
24
- "verify": "node src/verifier-cli.mjs workspaces/demo evidence/latest.json",
25
- "trust:init": "node src/trust-init.mjs",
26
- "mcp": "node src/mcp-server.mjs",
27
- "mcp:smoke": "node src/mcp-smoke-client.mjs",
28
- "mcp:agent:smoke": "node --test test/agent-runtime.test.mjs test/agent-runtime-adversarial.test.mjs test/agent-runtime-crash.test.mjs test/agent-task-receipt.test.mjs",
29
- "mcp:coding:smoke": "node --test test/coding-plane.test.mjs test/coding-plane-adversarial.test.mjs test/coding-runtime.test.mjs test/coding-crash.test.mjs",
30
- "mcp:machine-fs:smoke": "node src/machine-fs-smoke-client.mjs",
31
- "mcp:observation:smoke": "node src/observation-smoke-client.mjs",
32
- "mcp:process:smoke": "node src/process-smoke-client.mjs",
33
- "process:policy:refresh": "node scripts/refresh-process-policy.mjs",
34
- "mcp:autonomous:smoke": "node --test test/autonomous-runtime.test.mjs test/autonomous-loop.test.mjs test/autonomous-adversarial.test.mjs test/autonomous-supervisor-integration.test.mjs test/native-diff.test.mjs",
35
- "containment:build": "powershell -NoProfile -ExecutionPolicy Bypass -File scripts/build-containment.ps1",
36
- "containment:smoke": "node src/containment-smoke.mjs appcontainer",
37
- "containment:bootstrap": "node src/containment-bootstrap.mjs",
38
- "containment:smoke:lpac": "node src/containment-smoke.mjs lpac",
39
- "containment:smoke:appcontainer": "node src/containment-smoke.mjs appcontainer",
40
- "containment:construction": "node src/containment-construction.mjs",
41
- "containment:child-control": "node src/containment-child-control.mjs",
42
- "contained:run": "node src/contained-cli.mjs workspaces/demo input.txt",
43
- "contained:smoke": "node src/contained-smoke.mjs",
44
- "mcp:contained:smoke": "node src/mcp-contained-smoke-client.mjs",
45
- "gate:windows": "powershell -NoProfile -ExecutionPolicy Bypass -File scripts/gate-windows-r50.ps1",
46
- "authority:smoke": "node src/authority-smoke.mjs",
47
- "mcp:remote:smoke": "node src/remote-mcp-smoke-client.mjs",
48
- "mcp:host:smoke": "node src/mcp-host-smoke-client.mjs",
49
- "host:policy:init": "powershell -NoProfile -ExecutionPolicy Bypass -File scripts/init-host-policy.ps1",
50
- "mcp:remote:host:smoke": "node src/remote-mcp-host-smoke-client.mjs",
51
- "mcp:remote:autonomous:smoke": "node src/remote-mcp-autonomous-smoke-client.mjs",
52
- "mcp:tunnel-compat:smoke": "node src/tunnel-stdio-compat-smoke.mjs",
53
- "audit:verify": "node src/deadbyte-cli.mjs audit verify",
54
- "audit:status": "node src/deadbyte-cli.mjs audit status",
55
- "desktop:build": "powershell -NoProfile -ExecutionPolicy Bypass -File scripts/build-desktop-r40.ps1",
56
- "desktop:policy:refresh": "powershell -NoProfile -ExecutionPolicy Bypass -File scripts/init-desktop-policy-r40.ps1",
57
- "r43:parent:verify": "node scripts/verify-r43-parent.mjs",
58
- "r43:full:test": "node scripts/full-regression-r43.mjs",
59
- "r44:parent:verify": "node scripts/verify-r44-parent.mjs",
60
- "r44:full:test": "node scripts/full-regression-r44.mjs",
61
- "finalize:r44": "node scripts/finalize-r44.mjs",
62
- "hardware:build": "powershell -NoProfile -ExecutionPolicy Bypass -File scripts/build-hardware-r45.ps1",
63
- "doctor": "node src/deadbyte-cli.mjs doctor",
64
- "r45:parent:verify": "node scripts/verify-r45-parent.mjs",
65
- "r45:full:test": "node scripts/full-regression-r45.mjs",
66
- "finalize:r45": "node scripts/finalize-r45.mjs",
67
- "r46:fileless:test": "node --test --test-concurrency=1 test/process-policy.test.mjs test/process-policy-refresh.test.mjs test/release-generation.test.mjs test/process-runtime.test.mjs test/process-mcp-tools.test.mjs test/compact-gateway-r36.test.mjs test/capability-ledger-r36.test.mjs test/remote-device-r44.test.mjs test/observation-runtime.test.mjs test/observation-mcp-tools.test.mjs",
68
- "r46:full:test": "node scripts/full-regression-r46.mjs",
69
- "r47:full:test": "node scripts/full-regression-r47.mjs",
70
- "r47:catalog:test": "node --test --test-concurrency=1 test/full-max-catalog-r47.test.mjs",
71
- "r47:hardening:test": "node scripts/commander-hardening-gate-r47.mjs",
72
- "r48:full:test": "node scripts/full-regression-r48.mjs",
73
- "r48:release:test": "node --test --test-concurrency=1 test/r48-release-contract.test.mjs test/commander-reference-contract-r48.test.mjs test/commander-extended-wire-r48.test.mjs test/commander-external-process-r48.test.mjs test/commander-office-reader-r48.test.mjs test/commander-pdf-r48.test.mjs test/commander-url-reader-r48.test.mjs test/commander-wire-contract-r47.test.mjs test/commander-protocol-adversarial-r48.test.mjs",
74
- "r48:catalog:test": "node --test --test-concurrency=1 test/full-max-catalog-r48.test.mjs",
75
- "release:npm": "node scripts/npm-release-r48.mjs"
76
- },
77
- "bundleDependencies": [
78
- "@modelcontextprotocol/server",
79
- "@modelcontextprotocol/client",
80
- "typescript",
81
- "zod"
82
- ],
83
- "dependencies": {
84
- "@modelcontextprotocol/client": "2.1.0",
85
- "@modelcontextprotocol/server": "2.1.0",
86
- "typescript": "5.9.3",
87
- "zod": "4.4.3"
88
- },
89
- "bin": {
90
- "deadbyte-mcp": "src/deadbyte-cli.mjs"
91
- },
92
- "publishConfig": {
93
- "access": "public"
94
- }
2
+ "name": "deadbyte-mcp",
3
+ "version": "0.15.29",
4
+ "private": false,
5
+ "type": "module",
6
+ "description": "Authenticated MCP agentic runtime with signed skills, persistent model backends, identity-bound remote devices, durable job supervision, immutable release slots, and separately revocable machine authority.",
7
+ "engines": {
8
+ "node": ">=22"
9
+ },
10
+ "scripts": {
11
+ "test": "node --test test/*.test.mjs",
12
+ "manifest:write": "node scripts/release-manifest.mjs write",
13
+ "manifest:verify": "node scripts/release-manifest.mjs verify",
14
+ "r41:parent:verify": "node scripts/verify-r41-parent.mjs",
15
+ "r41:memory:verify": "node scripts/verify-memory-r41.mjs",
16
+ "r42:parent:verify": "node scripts/verify-r42-parent.mjs",
17
+ "r42:eval": "node scripts/agent-eval-r42.mjs",
18
+ "self-update:runtime": "node scripts/runtime-self-update.mjs",
19
+ "self-update:deferred": "node scripts/deferred-slot-operation-r46.mjs",
20
+ "release:parity": "node scripts/release-parity-r46.mjs",
21
+ "release:final:write": "node scripts/final-closure-r46.mjs",
22
+ "release:final:verify": "node scripts/final-closure-verify-r46.mjs",
23
+ "proof": "node src/proof-cli.mjs workspaces/demo input.txt",
24
+ "verify": "node src/verifier-cli.mjs workspaces/demo evidence/latest.json",
25
+ "trust:init": "node src/trust-init.mjs",
26
+ "mcp": "node src/mcp-server.mjs",
27
+ "mcp:smoke": "node src/mcp-smoke-client.mjs",
28
+ "mcp:agent:smoke": "node --test test/agent-runtime.test.mjs test/agent-runtime-adversarial.test.mjs test/agent-runtime-crash.test.mjs test/agent-task-receipt.test.mjs",
29
+ "mcp:coding:smoke": "node --test test/coding-plane.test.mjs test/coding-plane-adversarial.test.mjs test/coding-runtime.test.mjs test/coding-crash.test.mjs",
30
+ "mcp:machine-fs:smoke": "node src/machine-fs-smoke-client.mjs",
31
+ "mcp:observation:smoke": "node src/observation-smoke-client.mjs",
32
+ "mcp:process:smoke": "node src/process-smoke-client.mjs",
33
+ "process:policy:refresh": "node scripts/refresh-process-policy.mjs",
34
+ "mcp:autonomous:smoke": "node --test test/autonomous-runtime.test.mjs test/autonomous-loop.test.mjs test/autonomous-adversarial.test.mjs test/autonomous-supervisor-integration.test.mjs test/native-diff.test.mjs",
35
+ "containment:build": "powershell -NoProfile -ExecutionPolicy Bypass -File scripts/build-containment.ps1",
36
+ "containment:smoke": "node src/containment-smoke.mjs appcontainer",
37
+ "containment:bootstrap": "node src/containment-bootstrap.mjs",
38
+ "containment:smoke:lpac": "node src/containment-smoke.mjs lpac",
39
+ "containment:smoke:appcontainer": "node src/containment-smoke.mjs appcontainer",
40
+ "containment:construction": "node src/containment-construction.mjs",
41
+ "containment:child-control": "node src/containment-child-control.mjs",
42
+ "contained:run": "node src/contained-cli.mjs workspaces/demo input.txt",
43
+ "contained:smoke": "node src/contained-smoke.mjs",
44
+ "mcp:contained:smoke": "node src/mcp-contained-smoke-client.mjs",
45
+ "gate:windows": "powershell -NoProfile -ExecutionPolicy Bypass -File scripts/gate-windows-r52.ps1",
46
+ "authority:smoke": "node src/authority-smoke.mjs",
47
+ "mcp:remote:smoke": "node src/remote-mcp-smoke-client.mjs",
48
+ "mcp:host:smoke": "node src/mcp-host-smoke-client.mjs",
49
+ "host:policy:init": "powershell -NoProfile -ExecutionPolicy Bypass -File scripts/init-host-policy.ps1",
50
+ "mcp:remote:host:smoke": "node src/remote-mcp-host-smoke-client.mjs",
51
+ "mcp:remote:autonomous:smoke": "node src/remote-mcp-autonomous-smoke-client.mjs",
52
+ "mcp:tunnel-compat:smoke": "node src/tunnel-stdio-compat-smoke.mjs",
53
+ "audit:verify": "node src/deadbyte-cli.mjs audit verify",
54
+ "audit:status": "node src/deadbyte-cli.mjs audit status",
55
+ "desktop:build": "powershell -NoProfile -ExecutionPolicy Bypass -File scripts/build-desktop-r40.ps1",
56
+ "desktop:policy:refresh": "powershell -NoProfile -ExecutionPolicy Bypass -File scripts/init-desktop-policy-r40.ps1",
57
+ "r43:parent:verify": "node scripts/verify-r43-parent.mjs",
58
+ "r43:full:test": "node scripts/full-regression-r43.mjs",
59
+ "r44:parent:verify": "node scripts/verify-r44-parent.mjs",
60
+ "r44:full:test": "node scripts/full-regression-r44.mjs",
61
+ "finalize:r44": "node scripts/finalize-r44.mjs",
62
+ "hardware:build": "powershell -NoProfile -ExecutionPolicy Bypass -File scripts/build-hardware-r45.ps1",
63
+ "doctor": "node src/deadbyte-cli.mjs doctor",
64
+ "r45:parent:verify": "node scripts/verify-r45-parent.mjs",
65
+ "r45:full:test": "node scripts/full-regression-r45.mjs",
66
+ "finalize:r45": "node scripts/finalize-r45.mjs",
67
+ "r46:fileless:test": "node --test --test-concurrency=1 test/process-policy.test.mjs test/process-policy-refresh.test.mjs test/release-generation.test.mjs test/process-runtime.test.mjs test/process-mcp-tools.test.mjs test/compact-gateway-r36.test.mjs test/capability-ledger-r36.test.mjs test/remote-device-r44.test.mjs test/observation-runtime.test.mjs test/observation-mcp-tools.test.mjs",
68
+ "r46:full:test": "node scripts/full-regression-r46.mjs",
69
+ "r47:full:test": "node scripts/full-regression-r47.mjs",
70
+ "r47:catalog:test": "node --test --test-concurrency=1 test/full-max-catalog-r47.test.mjs",
71
+ "r47:hardening:test": "node scripts/commander-hardening-gate-r47.mjs",
72
+ "r48:full:test": "node scripts/full-regression-r48.mjs",
73
+ "r48:release:test": "node --test --test-concurrency=1 test/r48-release-contract.test.mjs test/commander-reference-contract-r48.test.mjs test/commander-extended-wire-r48.test.mjs test/commander-external-process-r48.test.mjs test/commander-office-reader-r48.test.mjs test/commander-pdf-r48.test.mjs test/commander-url-reader-r48.test.mjs test/commander-wire-contract-r47.test.mjs test/commander-protocol-adversarial-r48.test.mjs",
74
+ "r48:catalog:test": "node --test --test-concurrency=1 test/full-max-catalog-r48.test.mjs",
75
+ "release:npm": "node scripts/npm-release-r48.mjs",
76
+ "r51:focused:test": "node --test --test-concurrency=1 test/r51-release-contract.test.mjs test/r51-runtime-coherence.test.mjs test/r51-live-log-polling.test.mjs test/coding-runtime.test.mjs test/remote-live-log-r37.test.mjs",
77
+ "r52:focused:test": "node --test --test-concurrency=1 test/r52-release-contract.test.mjs test/r52-offline-predecessor-recovery.test.mjs test/r52-host-revocation.test.mjs test/r51-runtime-coherence.test.mjs test/r51-live-log-polling.test.mjs test/coding-runtime.test.mjs test/remote-live-log-r37.test.mjs test/runtime-self-update.test.mjs"
78
+ },
79
+ "bundleDependencies": [
80
+ "@modelcontextprotocol/server",
81
+ "@modelcontextprotocol/client",
82
+ "typescript",
83
+ "zod"
84
+ ],
85
+ "dependencies": {
86
+ "@modelcontextprotocol/client": "2.1.0",
87
+ "@modelcontextprotocol/server": "2.1.0",
88
+ "typescript": "5.9.3",
89
+ "zod": "4.4.3"
90
+ },
91
+ "bin": {
92
+ "deadbyte-mcp": "src/deadbyte-cli.mjs"
93
+ },
94
+ "publishConfig": {
95
+ "access": "public"
96
+ }
95
97
  }
@@ -8,7 +8,7 @@ import { loadPowerShellDataFile, runSlotUpdateCli } from '../src/runtime-update.
8
8
  import { parseActivePointer } from '../src/release-slot.mjs';
9
9
 
10
10
  const root=path.resolve(path.dirname(fileURLToPath(import.meta.url)),'..');
11
- const state=path.join(os.homedir(),'.deadbyte-mcp');
11
+ const state=path.resolve(process.env.DEADBYTE_STATE_ROOT||path.join(os.homedir(),'.deadbyte-mcp'));
12
12
  const sha=async f=>createHash('sha256').update(await readFile(f)).digest('hex');
13
13
  const sleep=ms=>new Promise(resolve=>setTimeout(resolve,ms));
14
14
 
@@ -0,0 +1,58 @@
1
+ $ErrorActionPreference = 'Stop'
2
+ Set-StrictMode -Version 3.0
3
+
4
+ function Invoke-GateStep {
5
+ param([Parameter(Mandatory)][string]$Name,[Parameter(Mandatory)][string[]]$NpmArgs)
6
+ Write-Host "==== $Name ===="
7
+ & npm.cmd @NpmArgs
8
+ if ($LASTEXITCODE -ne 0) { throw "DEADBYTE 0.15.28 / R51 gate failed at $Name with exit code $LASTEXITCODE" }
9
+ }
10
+
11
+ function Invoke-NodeTest {
12
+ param([Parameter(Mandatory)][string]$Name,[Parameter(Mandatory)][string[]]$TestFiles)
13
+ Write-Host "==== $Name ===="
14
+ & node.exe --test --test-concurrency=1 @TestFiles
15
+ if ($LASTEXITCODE -ne 0) { throw "DEADBYTE 0.15.28 / R51 gate failed at $Name with exit code $LASTEXITCODE" }
16
+ }
17
+
18
+ Invoke-NodeTest 'r51-package-boundary' @('test/package-boundary.test.mjs')
19
+ Invoke-NodeTest 'r51-release-smoke-isolation' @('test/release-smoke-isolation.test.mjs')
20
+ Invoke-GateStep 'r51-focused-contracts' @('run','r51:focused:test')
21
+ Invoke-GateStep 'containment-build' @('run','containment:build')
22
+ Invoke-GateStep 'process-policy-refresh' @('run','process:policy:refresh')
23
+ Write-Host "==== desktop-policy-refresh ===="
24
+ & (Join-Path $PSScriptRoot 'init-desktop-policy-r40.ps1')
25
+ Invoke-GateStep 'hardware-build' @('run','hardware:build')
26
+
27
+ $hostPolicy = [System.IO.Path]::GetFullPath((Join-Path $PSScriptRoot '..\controller\deadbyte-host-policy.json'))
28
+ Remove-Item -LiteralPath $hostPolicy -Force -ErrorAction SilentlyContinue
29
+ if (Test-Path -LiteralPath $hostPolicy) { throw 'could not establish hermetic Host policy absence' }
30
+
31
+ Invoke-GateStep 'r51-release-focused' @('run','r48:release:test')
32
+ Invoke-NodeTest 'r49-donor-proof' @('test/r49-remote-control-donors.test.mjs')
33
+ Invoke-NodeTest 'r49-desktop-wait' @('test/desktop-runtime-r40.test.mjs','test/desktop-mcp-tools-r40.test.mjs','test/autonomous-desktop-r40.test.mjs')
34
+ Invoke-GateStep 'r49-catalog' @('run','r48:catalog:test')
35
+ Invoke-GateStep 'commander-hardening' @('run','r47:hardening:test')
36
+ Invoke-GateStep 'full-regression' @('run','r48:full:test')
37
+ Invoke-GateStep 'mcp-smoke' @('run','mcp:smoke')
38
+ Invoke-GateStep 'mcp-agent-smoke' @('run','mcp:agent:smoke')
39
+ Invoke-GateStep 'mcp-coding-smoke' @('run','mcp:coding:smoke')
40
+ Invoke-GateStep 'mcp-machine-fs-smoke' @('run','mcp:machine-fs:smoke')
41
+ Invoke-GateStep 'mcp-observation-smoke' @('run','mcp:observation:smoke')
42
+ Invoke-GateStep 'mcp-process-smoke' @('run','mcp:process:smoke')
43
+ Invoke-GateStep 'mcp-autonomous-smoke' @('run','mcp:autonomous:smoke')
44
+ Invoke-GateStep 'tunnel-stdio-compat-smoke' @('run','mcp:tunnel-compat:smoke')
45
+ Invoke-GateStep 'containment-smoke' @('run','containment:smoke')
46
+ Invoke-GateStep 'contained-smoke' @('run','contained:smoke')
47
+ Invoke-GateStep 'mcp-contained-smoke' @('run','mcp:contained:smoke')
48
+ Invoke-GateStep 'host-policy-refresh' @('run','host:policy:init')
49
+ Invoke-GateStep 'manifest-write' @('run','manifest:write')
50
+ Invoke-GateStep 'manifest-verify' @('run','manifest:verify')
51
+ Invoke-GateStep 'doctor' @('run','doctor')
52
+ Invoke-GateStep 'mcp-host-smoke' @('run','mcp:host:smoke')
53
+ Invoke-GateStep 'authority-smoke' @('run','authority:smoke')
54
+ Invoke-GateStep 'manifest-final-verify' @('run','manifest:verify')
55
+
56
+ & node.exe (Join-Path $PSScriptRoot 'windows-gate-evidence-r51.mjs')
57
+ if ($LASTEXITCODE -ne 0) { throw "R51 evidence writer failed with exit code $LASTEXITCODE" }
58
+ Write-Host '==== DEADBYTE 0.15.28 / R51 WINDOWS GATE: PASS ===='
@@ -0,0 +1,58 @@
1
+ $ErrorActionPreference = 'Stop'
2
+ Set-StrictMode -Version 3.0
3
+
4
+ function Invoke-GateStep {
5
+ param([Parameter(Mandatory)][string]$Name,[Parameter(Mandatory)][string[]]$NpmArgs)
6
+ Write-Host "==== $Name ===="
7
+ & npm.cmd @NpmArgs
8
+ if ($LASTEXITCODE -ne 0) { throw "DEADBYTE 0.15.29 / R52 gate failed at $Name with exit code $LASTEXITCODE" }
9
+ }
10
+
11
+ function Invoke-NodeTest {
12
+ param([Parameter(Mandatory)][string]$Name,[Parameter(Mandatory)][string[]]$TestFiles)
13
+ Write-Host "==== $Name ===="
14
+ & node.exe --test --test-concurrency=1 @TestFiles
15
+ if ($LASTEXITCODE -ne 0) { throw "DEADBYTE 0.15.29 / R52 gate failed at $Name with exit code $LASTEXITCODE" }
16
+ }
17
+
18
+ Invoke-NodeTest 'r52-package-boundary' @('test/package-boundary.test.mjs')
19
+ Invoke-NodeTest 'r52-release-smoke-isolation' @('test/release-smoke-isolation.test.mjs')
20
+ Invoke-GateStep 'r52-focused-contracts' @('run','r52:focused:test')
21
+ Invoke-GateStep 'containment-build' @('run','containment:build')
22
+ Invoke-GateStep 'process-policy-refresh' @('run','process:policy:refresh')
23
+ Write-Host "==== desktop-policy-refresh ===="
24
+ & (Join-Path $PSScriptRoot 'init-desktop-policy-r40.ps1')
25
+ Invoke-GateStep 'hardware-build' @('run','hardware:build')
26
+
27
+ $hostPolicy = [System.IO.Path]::GetFullPath((Join-Path $PSScriptRoot '..\controller\deadbyte-host-policy.json'))
28
+ Remove-Item -LiteralPath $hostPolicy -Force -ErrorAction SilentlyContinue
29
+ if (Test-Path -LiteralPath $hostPolicy) { throw 'could not establish hermetic Host policy absence' }
30
+
31
+ Invoke-GateStep 'r52-release-focused' @('run','r48:release:test')
32
+ Invoke-NodeTest 'r49-donor-proof' @('test/r49-remote-control-donors.test.mjs')
33
+ Invoke-NodeTest 'r49-desktop-wait' @('test/desktop-runtime-r40.test.mjs','test/desktop-mcp-tools-r40.test.mjs','test/autonomous-desktop-r40.test.mjs')
34
+ Invoke-GateStep 'r49-catalog' @('run','r48:catalog:test')
35
+ Invoke-GateStep 'commander-hardening' @('run','r47:hardening:test')
36
+ Invoke-GateStep 'full-regression' @('run','r48:full:test')
37
+ Invoke-GateStep 'mcp-smoke' @('run','mcp:smoke')
38
+ Invoke-GateStep 'mcp-agent-smoke' @('run','mcp:agent:smoke')
39
+ Invoke-GateStep 'mcp-coding-smoke' @('run','mcp:coding:smoke')
40
+ Invoke-GateStep 'mcp-machine-fs-smoke' @('run','mcp:machine-fs:smoke')
41
+ Invoke-GateStep 'mcp-observation-smoke' @('run','mcp:observation:smoke')
42
+ Invoke-GateStep 'mcp-process-smoke' @('run','mcp:process:smoke')
43
+ Invoke-GateStep 'mcp-autonomous-smoke' @('run','mcp:autonomous:smoke')
44
+ Invoke-GateStep 'tunnel-stdio-compat-smoke' @('run','mcp:tunnel-compat:smoke')
45
+ Invoke-GateStep 'containment-smoke' @('run','containment:smoke')
46
+ Invoke-GateStep 'contained-smoke' @('run','contained:smoke')
47
+ Invoke-GateStep 'mcp-contained-smoke' @('run','mcp:contained:smoke')
48
+ Invoke-GateStep 'host-policy-refresh' @('run','host:policy:init')
49
+ Invoke-GateStep 'manifest-write' @('run','manifest:write')
50
+ Invoke-GateStep 'manifest-verify' @('run','manifest:verify')
51
+ Invoke-GateStep 'doctor' @('run','doctor')
52
+ Invoke-GateStep 'mcp-host-smoke' @('run','mcp:host:smoke')
53
+ Invoke-GateStep 'authority-smoke' @('run','authority:smoke')
54
+ Invoke-GateStep 'manifest-final-verify' @('run','manifest:verify')
55
+
56
+ & node.exe (Join-Path $PSScriptRoot 'windows-gate-evidence-r52.mjs')
57
+ if ($LASTEXITCODE -ne 0) { throw "R52 evidence writer failed with exit code $LASTEXITCODE" }
58
+ Write-Host '==== DEADBYTE 0.15.29 / R52 WINDOWS GATE: PASS ===='
@@ -0,0 +1,84 @@
1
+ import { createHash } from 'node:crypto';
2
+ import { mkdir, open, readFile } from 'node:fs/promises';
3
+ import os from 'node:os';
4
+ import path from 'node:path';
5
+ import { fileURLToPath } from 'node:url';
6
+ import { doctor } from '../src/doctor-r45.mjs';
7
+
8
+ const root = path.resolve(path.dirname(fileURLToPath(import.meta.url)), '..');
9
+ const stateRoot = path.resolve(process.env.DEADBYTE_STATE_ROOT || path.join(os.homedir(), '.deadbyte-mcp'));
10
+ const sha256 = bytes => createHash('sha256').update(bytes).digest('hex');
11
+ const insist = (ok, message) => { if (!ok) throw new Error(message); };
12
+ const pkg = JSON.parse(await readFile(path.join(root, 'package.json'), 'utf8'));
13
+ const release = JSON.parse(await readFile(path.join(root, 'RELEASE.json'), 'utf8'));
14
+ const active = JSON.parse(await readFile(path.join(stateRoot, 'active-release.json'), 'utf8'));
15
+ const manifestSha256 = sha256(await readFile(path.join(root, 'MANIFEST.SHA256')));
16
+
17
+ insist(pkg.version === '0.15.28' && release.version === pkg.version && release.train === 'R51', 'R51 candidate identity mismatch');
18
+ insist(
19
+ active.release_id === release.parent.release_id &&
20
+ active.manifest_sha256 === release.parent.manifest_sha256 &&
21
+ active.generation_manifest_sha256 === release.parent.generation_manifest_sha256,
22
+ 'active runtime is not the exact sealed R51 parent'
23
+ );
24
+
25
+ const health = await doctor();
26
+ insist(health.status === 'ok' && health.package_version === pkg.version && health.manifest?.verified === true, 'R51 doctor evidence invalid');
27
+ insist(health.policy?.host_v2_ready === true, 'R51 Host policy v2 is not ready');
28
+
29
+ const evidence = {
30
+ schema: 'deadbyte.r51-windows-gate.v1',
31
+ status: 'passed',
32
+ exit_code: 0,
33
+ version: pkg.version,
34
+ train: 'R51',
35
+ completed_at_utc: new Date().toISOString(),
36
+ manifest_sha256: manifestSha256,
37
+ parent: release.parent,
38
+ active_predecessor: {
39
+ release_id: active.release_id,
40
+ version: active.version,
41
+ manifest_sha256: active.manifest_sha256,
42
+ generation_manifest_sha256: active.generation_manifest_sha256
43
+ },
44
+ doctor: { verified_entries: health.manifest.verified_entries, host_v2_ready: true },
45
+ gates: {
46
+ package_boundary: true,
47
+ release_smoke_isolation: true,
48
+ runtime_coherence: true,
49
+ coding_command_singleflight: true,
50
+ foreground_desktop_host_fail_closed: true,
51
+ livelog_optimizer: true,
52
+ full_regression: true,
53
+ commander_hardening: true,
54
+ donor_proof: true,
55
+ desktop_wait: true,
56
+ exact_catalog: true,
57
+ stdio_smokes: true,
58
+ manifest_final_verify: true
59
+ }
60
+ };
61
+
62
+ const bytes = Buffer.from(`${JSON.stringify(evidence, null, 2)}\n`);
63
+ const dir = path.join(stateRoot, 'evidence', 'release');
64
+ await mkdir(dir, { recursive: true });
65
+ const target = path.join(dir, `r51-windows-gate-${manifestSha256.slice(0, 16)}.json`);
66
+
67
+ try {
68
+ const handle = await open(target, 'wx', 0o600);
69
+ try { await handle.writeFile(bytes); await handle.sync(); }
70
+ finally { await handle.close(); }
71
+ } catch (error) {
72
+ if (error?.code !== 'EEXIST') throw error;
73
+ const prior = JSON.parse(await readFile(target, 'utf8'));
74
+ insist(
75
+ prior.schema === evidence.schema &&
76
+ prior.status === 'passed' &&
77
+ prior.version === evidence.version &&
78
+ prior.manifest_sha256 === manifestSha256 &&
79
+ prior.parent?.release_id === release.parent.release_id,
80
+ 'conflicting R51 gate evidence identity'
81
+ );
82
+ }
83
+
84
+ console.log(JSON.stringify({ status: 'passed', path: target, sha256: sha256(bytes), manifest_sha256: manifestSha256 }));
@@ -0,0 +1,94 @@
1
+ import { createHash } from 'node:crypto';
2
+ import { mkdir, open, readFile } from 'node:fs/promises';
3
+ import os from 'node:os';
4
+ import path from 'node:path';
5
+ import { fileURLToPath } from 'node:url';
6
+ import { doctor } from '../src/doctor-r45.mjs';
7
+
8
+ const root = path.resolve(path.dirname(fileURLToPath(import.meta.url)), '..');
9
+ const stateRoot = path.resolve(process.env.DEADBYTE_STATE_ROOT || path.join(os.homedir(), '.deadbyte-mcp'));
10
+ const sha256 = bytes => createHash('sha256').update(bytes).digest('hex');
11
+ const insist = (ok, message) => { if (!ok) throw new Error(message); };
12
+ const pkg = JSON.parse(await readFile(path.join(root, 'package.json'), 'utf8'));
13
+ const release = JSON.parse(await readFile(path.join(root, 'RELEASE.json'), 'utf8'));
14
+ const provenance = JSON.parse(await readFile(path.join(root, 'PROVENANCE.json'), 'utf8'));
15
+ const active = JSON.parse(await readFile(path.join(stateRoot, 'active-release.json'), 'utf8'));
16
+ const manifestSha256 = sha256(await readFile(path.join(root, 'MANIFEST.SHA256')));
17
+
18
+ insist(pkg.version === '0.15.29' && release.version === pkg.version && release.train === 'R52', 'R52 candidate identity mismatch');
19
+ insist(
20
+ active.release_id === release.runtime_predecessor.release_id &&
21
+ active.manifest_sha256 === release.runtime_predecessor.manifest_sha256 &&
22
+ active.generation_manifest_sha256 === release.runtime_predecessor.generation_manifest_sha256,
23
+ 'active runtime is not the exact sealed R52 runtime rollback target'
24
+ );
25
+ insist(release.parent.version === '0.15.28' && release.parent.manifest_sha256 === release.source_predecessor.manifest_file_sha256 && release.parent.tarball_sha256 === release.source_predecessor.tarball_sha256, 'R52 published parent binding mismatch');
26
+ insist(release.source_predecessor.version === '0.15.28', 'R52 source predecessor version mismatch');
27
+ insist(release.source_predecessor.tarball_sha256 === '0a74332ba715d80a532dc871ece4826bdb917b8c7a442e71388a06d44698c411', 'R52 source predecessor tarball mismatch');
28
+ insist(provenance.source_predecessor_activation_failure_receipt_sha256 === '090f165c96da0d5a8e9c0815fd389fe94e8fe36c23a6878ee825b8f46bfb0bc2', 'R52 failure receipt binding mismatch');
29
+
30
+ const health = await doctor();
31
+ insist(health.status === 'ok' && health.package_version === pkg.version && health.manifest?.verified === true, 'R52 doctor evidence invalid');
32
+ insist(health.policy?.host_v2_ready === true, 'R52 Host policy v2 is not ready');
33
+
34
+ const evidence = {
35
+ schema: 'deadbyte.r52-windows-gate.v1',
36
+ status: 'passed',
37
+ exit_code: 0,
38
+ version: pkg.version,
39
+ train: 'R52',
40
+ completed_at_utc: new Date().toISOString(),
41
+ manifest_sha256: manifestSha256,
42
+ parent: release.parent,
43
+ runtime_predecessor: release.runtime_predecessor,
44
+ source_predecessor: release.source_predecessor,
45
+ activation_failure_receipt_sha256: provenance.source_predecessor_activation_failure_receipt_sha256,
46
+ active_predecessor: {
47
+ release_id: active.release_id,
48
+ version: active.version,
49
+ manifest_sha256: active.manifest_sha256,
50
+ generation_manifest_sha256: active.generation_manifest_sha256
51
+ },
52
+ doctor: { verified_entries: health.manifest.verified_entries, host_v2_ready: true },
53
+ gates: {
54
+ offline_predecessor_host_revoke_before_capture: true,
55
+ package_boundary: true,
56
+ release_smoke_isolation: true,
57
+ runtime_coherence: true,
58
+ coding_command_singleflight: true,
59
+ foreground_desktop_host_fail_closed: true,
60
+ livelog_optimizer: true,
61
+ full_regression: true,
62
+ commander_hardening: true,
63
+ donor_proof: true,
64
+ desktop_wait: true,
65
+ exact_catalog: true,
66
+ stdio_smokes: true,
67
+ manifest_final_verify: true
68
+ }
69
+ };
70
+
71
+ const bytes = Buffer.from(`${JSON.stringify(evidence, null, 2)}\n`);
72
+ const dir = path.join(stateRoot, 'evidence', 'release');
73
+ await mkdir(dir, { recursive: true });
74
+ const target = path.join(dir, `r52-windows-gate-${manifestSha256.slice(0, 16)}.json`);
75
+
76
+ try {
77
+ const handle = await open(target, 'wx', 0o600);
78
+ try { await handle.writeFile(bytes); await handle.sync(); }
79
+ finally { await handle.close(); }
80
+ } catch (error) {
81
+ if (error?.code !== 'EEXIST') throw error;
82
+ const prior = JSON.parse(await readFile(target, 'utf8'));
83
+ insist(
84
+ prior.schema === evidence.schema &&
85
+ prior.status === 'passed' &&
86
+ prior.version === evidence.version &&
87
+ prior.manifest_sha256 === manifestSha256 &&
88
+ prior.parent?.release_id === release.parent.release_id &&
89
+ prior.activation_failure_receipt_sha256 === evidence.activation_failure_receipt_sha256,
90
+ 'conflicting R52 gate evidence identity'
91
+ );
92
+ }
93
+
94
+ console.log(JSON.stringify({ status: 'passed', path: target, sha256: sha256(bytes), manifest_sha256: manifestSha256 }));