Stranger pass of 21 Oct: x402 verify-payments reads all wallet transfers in windows under the endpoint range limit (was UNMEASURED on the live testnet; now VALID), device-operation reputation is byte-identical in JS --canonical and Python, module README figures as measured, .gitignore for the keys the examples write, temporary directories removed by the probes
This commit is contained in:
1 parent
82c5b261ac
commit
fcece14a12
18 files changed
+266
-45
No files matched your search
@@ -330,9 +330,9 @@ spune('9. the command line, through files only');
|
||||
const js = oc(['reputation', '--facts', f('facts.json'), '--from', from, '--to', to, '--window', '60', '--canonical']);
|
||||
const pyr = py ? spawnSync(py, [path.join(AICI, 'reputation.py'), '--facts', f('facts.json'), '--from', from, '--to', to, '--window', '60'], { encoding: 'utf8' }) : null;
|
||||
const rep = js.status === 0 ? JSON.parse(js.stdout) : null;
|
||||
rand('C01', 'two device keys, two credentials, ten records with a rotation, an anchor, and the blocks read by the block command from a local endpoint, all through files: verify says VALID (exit 0), 10 of 10 minutes covered and 1 witnessed, and the reputation is the same text from both implementations',
|
||||
!py ? 'NEMASURAT' : facuti && ver.status === 0 && /^VALID/m.test(ver.stdout) && !!rep && rep.availability.claimed === 10 && rep.availability.windows === 10 && rep.availability.witnessed === 1 && pyr.status === 0 && pyr.stdout.trim() === js.stdout.trim() ? 'VERDE' : 'ROSU',
|
||||
`steps ${pasi.map((x) => x.status).join('')}, verify ${ver.status}: ${String(ver.stdout).trim().split('\n').slice(-3).join(' | ')} ${String(ver.stderr).slice(0, 200)}` + (rep ? ' ' + JSON.stringify(rep.availability) : ''));
|
||||
rand('C01', 'two device keys, two credentials, ten records with a rotation, an anchor, and the blocks read by the block command from a local endpoint, all through files: verify says VALID (exit 0), 10 of 10 minutes covered and 1 witnessed, and the reputation is the same BYTES from both command lines (`operation-cli.mjs reputation --canonical` and `reputation.py --facts`, the line end included: before 2026-10-21 Python wrote CRLF on Windows and this row compared trimmed text)',
|
||||
!py ? 'NEMASURAT' : facuti && ver.status === 0 && /^VALID/m.test(ver.stdout) && !!rep && rep.availability.claimed === 10 && rep.availability.windows === 10 && rep.availability.witnessed === 1 && pyr.status === 0 && pyr.stdout === js.stdout ? 'VERDE' : 'ROSU',
|
||||
`steps ${pasi.map((x) => x.status).join('')}, verify ${ver.status}: ${String(ver.stdout).trim().split('\n').slice(-3).join(' | ')} ${String(ver.stderr).slice(0, 200)}` + (rep ? ' ' + JSON.stringify(rep.availability) : '') + (pyr && pyr.stdout !== js.stdout ? ` | the two outputs differ: JS ${Buffer.byteLength(js.stdout)} bytes ending ${JSON.stringify(js.stdout.slice(-2))}, Python ${Buffer.byteLength(pyr.stdout)} bytes ending ${JSON.stringify(pyr.stdout.slice(-2))}` : ''));
|
||||
const Lf = JSON.parse(fs.readFileSync(f('log.json'), 'utf8')); Lf.records[3].statement.counter = 999; fs.writeFileSync(f('tampered.json'), JSON.stringify(Lf));
|
||||
const t1 = oc(['verify', ...comun.map((x) => (x === f('log.json') ? f('tampered.json') : x))]), t2 = oc(['verify', ...comun.filter((x, i, a) => x !== '--status' && a[i - 1] !== '--status')]), t3 = oc(['verify', '--log', f('log.json')]);
|
||||
const t4 = oc(['verify', '--log', f('log.json'), '--now', 'yesterday']);
|
||||
|
||||
Reference in new issue
Block a user