deadbyte-mcp 0.15.70 → 0.15.72
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.
- package/MANIFEST.SHA256 +54 -30
- package/PROVENANCE.json +64 -15
- package/README.txt +19 -11
- package/RELEASE.json +76 -17
- package/SBOM.cdx.json +2 -2
- package/TEST-MATRIX.json +58 -2
- package/bridge/package.json +1 -1
- package/controller/deadbyte-process-policy.json +4 -4
- package/docs/R184-package-lock.json +109 -16
- package/docs/R192-LIVE-LOG-HARDENING.txt +39 -0
- package/package.json +1 -1
- package/scripts/deploy-r48.mjs +17 -4
- package/scripts/r191-acceptance-readonly.mjs +7 -0
- package/scripts/r191-existing-regression.mjs +5 -0
- package/scripts/r191-existing-stage-audit.mjs +21 -0
- package/scripts/r191-extended-security-gate.mjs +14 -0
- package/scripts/r191-focused-tests.mjs +3 -0
- package/scripts/r191-full-runner.mjs +18 -0
- package/scripts/r191-historical-release-regression.mjs +9 -0
- package/scripts/r191-live-claim-inspect.mjs +15 -0
- package/scripts/r191-npm-registry-readonly.mjs +14 -0
- package/scripts/r191-old-version-audit.mjs +12 -0
- package/scripts/r191-privilege-readonly.mjs +6 -0
- package/scripts/r191-process-policy-focused.mjs +1 -0
- package/scripts/r191-protected-failure-gate.mjs +3 -0
- package/scripts/r191-release-contract-runner.mjs +1 -0
- package/scripts/r191-unreached-focused.mjs +29 -0
- package/scripts/r192-focused.mjs +10 -0
- package/scripts/r192-release-tests.mjs +8 -0
- package/src/activation-lock-r65.mjs +9 -1
- package/src/deadbyte-cli.mjs +4 -2
- package/src/remote-live-log.mjs +22 -1
- package/src/runtime-update.mjs +2 -2
- package/src/trusted-epoch-bootstrap-r158.mjs +8 -0
- package/src/version.mjs +1 -1
- package/test/process-policy-refresh.test.mjs +11 -1
- package/test/r130-release-security-contract.test.mjs +8 -8
- package/test/r132-release-identity.test.mjs +7 -7
- package/test/r153-prepublish-identity.test.mjs +1 -1
- package/test/r160-release-contract.test.mjs +3 -3
- package/test/r165-live-cli-skew.test.mjs +1 -1
- package/test/r167-release-contract.test.mjs +11 -11
- package/test/r168-release-contract.test.mjs +4 -2
- package/test/r172-release-contract.test.mjs +6 -6
- package/test/r173-release-contract.test.mjs +15 -15
- package/test/r179-release-contract.test.mjs +10 -10
- package/test/r190-foreground-cli.test.mjs +14 -4
- package/test/r190-release-contract.test.mjs +10 -10
- package/test/r191-epoch-root-selection.test.mjs +24 -0
- package/test/r191-epoch-source-claim.test.mjs +88 -0
- package/test/r191-inherited-epoch-preflight.test.mjs +65 -0
- package/test/r191-release-contract.test.mjs +31 -0
- package/test/r192-live-log-hardening.test.mjs +50 -0
- package/test/r192-release-identity.test.mjs +40 -0
- package/test/r59-tool-surface-compat.test.mjs +1 -1
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import test from 'node:test';
|
|
2
|
+
import assert from 'node:assert/strict';
|
|
3
|
+
import {readFile} from 'node:fs/promises';
|
|
4
|
+
import {fileURLToPath} from 'node:url';
|
|
5
|
+
import path from 'node:path';
|
|
6
|
+
import {DEADBYTE_VERSION} from '../src/version.mjs';
|
|
7
|
+
const root=path.resolve(fileURLToPath(new URL('..',import.meta.url)));
|
|
8
|
+
const json=async f=>JSON.parse(await readFile(path.join(root,f),'utf8'));
|
|
9
|
+
const predecessor='v0.15.71-1818abc327478a96';
|
|
10
|
+
const publishedManifest='1818abc327478a96d935c200e25aad8515f15edc1842845b73bd0de57606da8c';
|
|
11
|
+
const publishedTarball='20ed3b20e72b4e4226736a1e432b05b851e9fa265e9bc2966b74f266477b7e27';
|
|
12
|
+
test('R191 exact version identity includes bundled bridge, lock snapshot, SBOM, provenance and matrix',async()=>{
|
|
13
|
+
const [pkg,bridge,lock,release,provenance,matrix,bom]=await Promise.all(['package.json','bridge/package.json','docs/R184-package-lock.json','RELEASE.json','PROVENANCE.json','TEST-MATRIX.json','SBOM.cdx.json'].map(json));
|
|
14
|
+
for(const ver of [pkg.version,bridge.version,lock.version,lock.packages[''].version,release.version,provenance.version,matrix.version,bom.metadata.component.version,DEADBYTE_VERSION])assert.equal(ver,'0.15.72');
|
|
15
|
+
for(const train of [release.train,matrix.train])assert.equal(train,'R192');
|
|
16
|
+
assert.equal(bom.serialNumber,'urn:cdx:deadbyte-mcp:r192:0.15.72');
|
|
17
|
+
assert.equal(release.parent.release_id,predecessor);
|
|
18
|
+
assert.equal(provenance.parent_release_id,predecessor);
|
|
19
|
+
assert.equal(release.source_predecessor.version,'0.15.71');
|
|
20
|
+
assert.equal(release.source_predecessor.manifest_sha256,publishedManifest);
|
|
21
|
+
assert.equal(release.source_predecessor.tarball_sha256,publishedTarball);
|
|
22
|
+
assert.equal(provenance.source_predecessor_version,'0.15.71');
|
|
23
|
+
assert.equal(provenance.parent_tarball_sha256,publishedTarball);
|
|
24
|
+
assert.equal(provenance.source_predecessor_tarball_sha256,publishedTarball);
|
|
25
|
+
assert.equal(provenance.source_predecessor_manifest_file_sha256,publishedManifest);
|
|
26
|
+
assert.equal(release.r191_activation_repair.npm_publish,'NOT_RUN');
|
|
27
|
+
assert.equal(release.r191_activation_repair.production_activation,'NOT_RUN');
|
|
28
|
+
assert.equal(release.r190_foreground_recovery.status,'PREPUBLISH_VERIFIED');
|
|
29
|
+
assert.equal(release.r179.stable_final_claim,false);
|
|
30
|
+
assert.equal(matrix.required.some(x=>x.id==='r191-trusted-successor-epoch-root'),true);
|
|
31
|
+
});
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import test from 'node:test';
|
|
2
|
+
import assert from 'node:assert/strict';
|
|
3
|
+
import {formatRuntimeDiagnosticLine,createLiveTimelineTracker,
|
|
4
|
+
pruneLiveLogReaders} from '../src/remote-live-log.mjs';
|
|
5
|
+
|
|
6
|
+
const compact=(reason)=>'[TOOL] 2026-10-28T14:00:00.000Z #12 ✗ coding_command_run 10ms — '+reason;
|
|
7
|
+
|
|
8
|
+
test('R192 runtime verbose diagnostics never disclose secret-bearing reasons',()=>{
|
|
9
|
+
const raw=compact('password=canaryNotForConsole123');
|
|
10
|
+
const out=formatRuntimeDiagnosticLine('bridge.stdout.log',raw,{verbose:true,displayMode:'ascii'});
|
|
11
|
+
assert.equal(typeof out,'string');
|
|
12
|
+
assert.match(out,/coding_command_run/);
|
|
13
|
+
assert.match(out,/REDACTED/);
|
|
14
|
+
assert.doesNotMatch(out,/canaryNotForConsole123/);
|
|
15
|
+
assert.equal(formatRuntimeDiagnosticLine('bridge.stdout.log',raw,{verbose:false}),null);
|
|
16
|
+
});
|
|
17
|
+
|
|
18
|
+
test('R192 runtime diagnostic detail is short, single-line and status-preserving',()=>{
|
|
19
|
+
const out=formatRuntimeDiagnosticLine('bridge.stdout.log',compact('slow write rejected '+('x'.repeat(800))),{verbose:true,displayMode:'ascii'});
|
|
20
|
+
assert.match(out,/\[BRIDGE.STDOUT.DEBUG\].*coding_command_run 10ms/);
|
|
21
|
+
assert.ok(out.length<350,'a single runtime diagnostic cannot flood the foreground');
|
|
22
|
+
assert.equal(out.split(/\r?\n/).length,1);
|
|
23
|
+
});
|
|
24
|
+
|
|
25
|
+
test('R192 audit result redacts secrets without hiding outcome classification',()=>{
|
|
26
|
+
const tracker=createLiveTimelineTracker({clock:()=>1000,displayMode:'ascii'});
|
|
27
|
+
tracker.observe({event_type:'tool.request',request_id:'123456789012',tool:'host_exec',args:{root_id:'core',mode:'native'}});
|
|
28
|
+
const out=tracker.observe({event_type:'tool.result',request_id:'123456789012',tool:'host_exec',
|
|
29
|
+
outcome:{status:'denied',is_error:true,duration_ms:24,reason:'authorization: Bearer supersensitive123456'}});
|
|
30
|
+
assert.match(out,/ERR/);
|
|
31
|
+
assert.doesNotMatch(out,/supersensitive123456/);
|
|
32
|
+
assert.match(out,/REDACTED/);
|
|
33
|
+
});
|
|
34
|
+
|
|
35
|
+
test('R192 rotation prunes stale cursors and partial line fragments without touching current streams',()=>{
|
|
36
|
+
const live=new Map([['current.log',{offset:12}],['gone.log',{offset:77}]]);
|
|
37
|
+
const fragments=new Map([['current.log','half'],['gone.log','secret']]);
|
|
38
|
+
const result=pruneLiveLogReaders(live,fragments,['current.log','other.log']);
|
|
39
|
+
assert.deepEqual(result,{cursors_removed:1,fragments_removed:1});
|
|
40
|
+
assert.deepEqual([...live.keys()],['current.log']);
|
|
41
|
+
assert.deepEqual([...fragments], [['current.log','half']]);
|
|
42
|
+
});
|
|
43
|
+
|
|
44
|
+
test('R192 reject malformed discovery before mutating any reader state',()=>{
|
|
45
|
+
const live=new Map([['current.log',{offset:12}]]);
|
|
46
|
+
const fragments=new Map([['current.log','half']]);
|
|
47
|
+
assert.throws(()=>pruneLiveLogReaders(live,fragments,[123]),/invalid/i);
|
|
48
|
+
assert.equal(live.has('current.log'),true);
|
|
49
|
+
assert.equal(fragments.get('current.log'),'half');
|
|
50
|
+
});
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import test from 'node:test';import assert from 'node:assert/strict';
|
|
2
|
+
import {readFile} from 'node:fs/promises';import {createHash} from 'node:crypto';import path from 'node:path';import {fileURLToPath} from 'node:url';
|
|
3
|
+
import {DEADBYTE_VERSION} from '../src/version.mjs';
|
|
4
|
+
const root=path.resolve(fileURLToPath(new URL('..',import.meta.url)));
|
|
5
|
+
const read=async name=>JSON.parse(await readFile(path.join(root,name),'utf8'));
|
|
6
|
+
const prevHash='1818abc327478a96d935c200e25aad8515f15edc1842845b73bd0de57606da8c';
|
|
7
|
+
const prevTar='20ed3b20e72b4e4226736a1e432b05b851e9fa265e9bc2966b74f266477b7e27';
|
|
8
|
+
test('R192 exact package, bridge, lock, metadata and runtime version are 0.15.72',async()=>{
|
|
9
|
+
const [pkg,bridge,lock,release,prov,matrix,bom]=await Promise.all([
|
|
10
|
+
read('package.json'),read('bridge/package.json'),read('docs/R184-package-lock.json'),
|
|
11
|
+
read('RELEASE.json'),read('PROVENANCE.json'),read('TEST-MATRIX.json'),read('SBOM.cdx.json')]);
|
|
12
|
+
for(const actual of [pkg.version,bridge.version,lock.version,lock.packages[''].version,
|
|
13
|
+
release.version,prov.version,matrix.version,bom.metadata.component.version,DEADBYTE_VERSION])
|
|
14
|
+
assert.equal(actual,'0.15.72');
|
|
15
|
+
assert.equal(release.train,'R192');assert.equal(matrix.train,'R192');
|
|
16
|
+
assert.equal(bom.serialNumber,'urn:cdx:deadbyte-mcp:r192:0.15.72');
|
|
17
|
+
assert.equal(release.parent.release_id,'v0.15.71-1818abc327478a96');
|
|
18
|
+
assert.equal(release.parent.manifest_sha256,prevHash);
|
|
19
|
+
assert.equal(release.source_predecessor.tarball_sha256,prevTar);
|
|
20
|
+
assert.equal(release.source_predecessor.manifest_sha256,prevHash);
|
|
21
|
+
assert.equal(prov.parent_tarball_sha256,prevTar);
|
|
22
|
+
assert.equal(prov.parent_manifest_sha256,prevHash);
|
|
23
|
+
assert.equal(release.r192.production_activation,'NOT_RUN');
|
|
24
|
+
assert.equal(release.r192.public_tool_schema_changed,false);
|
|
25
|
+
assert.equal(release.r192.authority_grants_changed,false);
|
|
26
|
+
});
|
|
27
|
+
test('R192 foreground reader enforces caller-safe telemetry rather than changing authority',async()=>{
|
|
28
|
+
const [cli,log]=await Promise.all([
|
|
29
|
+
readFile(path.join(root,'src','deadbyte-cli.mjs'),'utf8'),
|
|
30
|
+
readFile(path.join(root,'src','remote-live-log.mjs'),'utf8')]);
|
|
31
|
+
assert.match(cli,/pruneLiveLogReaders\(activeOffsets,partialLines,liveFiles\)/);
|
|
32
|
+
assert.match(log,/export function pruneLiveLogReaders/);
|
|
33
|
+
assert.match(log,/sanitizeAuditArgs\(compact\[6\]\)/);
|
|
34
|
+
const [policy,release]=await Promise.all([
|
|
35
|
+
read('controller/deadbyte-process-policy.json'),read('RELEASE.json')]);
|
|
36
|
+
const approved=release.r192.development_policy_root;
|
|
37
|
+
assert.equal(typeof approved,'string');
|
|
38
|
+
assert.ok(path.isAbsolute(approved));
|
|
39
|
+
assert.equal(path.resolve(policy.roots.core.path),path.resolve(approved));
|
|
40
|
+
});
|
|
@@ -83,7 +83,7 @@ test('R72 compact baseline permits only R64 read offset and authorized coding-on
|
|
|
83
83
|
assert.deepEqual(diff.added,[]);
|
|
84
84
|
assert.deepEqual(diff.removed,[]);
|
|
85
85
|
const packageVersion=JSON.parse(await readFile(path.join(repoRoot,'package.json'),'utf8')).version;
|
|
86
|
-
if(['0.15.41','0.15.42','0.15.43','0.15.44','0.15.45','0.15.46','0.15.47','0.15.48','0.15.49','0.15.50','0.15.51','0.15.52','0.15.53','0.15.54','0.15.55','0.15.56','0.15.57','0.15.58','0.15.59','0.15.60','0.15.61','0.15.62','0.15.63','0.15.64','0.15.65','0.15.66','0.15.67','0.15.68','0.15.69','0.15.70'].includes(packageVersion)){
|
|
86
|
+
if(['0.15.41','0.15.42','0.15.43','0.15.44','0.15.45','0.15.46','0.15.47','0.15.48','0.15.49','0.15.50','0.15.51','0.15.52','0.15.53','0.15.54','0.15.55','0.15.56','0.15.57','0.15.58','0.15.59','0.15.60','0.15.61','0.15.62','0.15.63','0.15.64','0.15.65','0.15.66','0.15.67','0.15.68','0.15.69','0.15.70','0.15.71','0.15.72'].includes(packageVersion)){
|
|
87
87
|
assert.deepEqual([...diff.schema_changed].sort(),['machine_fs','native_diff_preview']);
|
|
88
88
|
assert.equal(diff.unchanged.length,41);
|
|
89
89
|
const prior=baseline.tools.find(tool=>tool.name==='machine_fs');
|