tersign 0.4.1 → 0.4.2
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/dist/mcp/server.d.ts +1 -1
- package/dist/mcp/server.js +1 -1
- package/dist/verify-bin.js +6 -2
- package/package.json +1 -1
package/dist/mcp/server.d.ts
CHANGED
|
@@ -8,6 +8,6 @@ export declare function envDeps(env?: Record<string, string | undefined>): McpDe
|
|
|
8
8
|
* every client; mcp.test.ts pins it against package.json so a release bump can't drift it. */
|
|
9
9
|
export declare const MCP_SERVER_IDENTITY: {
|
|
10
10
|
readonly name: "tersign";
|
|
11
|
-
readonly version: "0.4.
|
|
11
|
+
readonly version: "0.4.2";
|
|
12
12
|
};
|
|
13
13
|
export declare function buildServer(deps: McpDeps): McpServer;
|
package/dist/mcp/server.js
CHANGED
|
@@ -45,7 +45,7 @@ function json(value) {
|
|
|
45
45
|
}
|
|
46
46
|
/** MUST match package.json name/version — the MCP handshake self-reports this identity to
|
|
47
47
|
* every client; mcp.test.ts pins it against package.json so a release bump can't drift it. */
|
|
48
|
-
export const MCP_SERVER_IDENTITY = { name: 'tersign', version: '0.4.
|
|
48
|
+
export const MCP_SERVER_IDENTITY = { name: 'tersign', version: '0.4.2' };
|
|
49
49
|
export function buildServer(deps) {
|
|
50
50
|
const server = new McpServer(MCP_SERVER_IDENTITY);
|
|
51
51
|
server.registerTool('issue_receipt', {
|
package/dist/verify-bin.js
CHANGED
|
@@ -38,11 +38,15 @@ const expectedSigner = arg('--signer');
|
|
|
38
38
|
async function checkLedger(digest, url) {
|
|
39
39
|
const res = await fetch(`${url.replace(/\/$/, '')}/v1/receipts/${digest}/verify`);
|
|
40
40
|
const body = (await res.json());
|
|
41
|
+
// Name the ledger that answered, always — a verifier that hides which chain it consulted is
|
|
42
|
+
// making the reader take its word for the one fact the check exists to establish. Nothing
|
|
43
|
+
// beyond that: `--ledger` is documented in usage and the README, and the failure path is not
|
|
44
|
+
// the place to advertise the alternative to the thing that just failed.
|
|
41
45
|
if (!body.found)
|
|
42
|
-
fail(
|
|
46
|
+
fail(`no record of ${digest} on the Tersign ledger (${url})`);
|
|
43
47
|
if (!body.chainOk)
|
|
44
48
|
fail('ledger record found but the counter-signed hash-chain does NOT verify');
|
|
45
|
-
console.log(`ledger: ${url}
|
|
49
|
+
console.log(`ledger: ${url}`);
|
|
46
50
|
console.log(` counter-signed OK (seller ${body.sellerId}, seq ${body.seq}, ledger key ${body.ledgerSigner})`);
|
|
47
51
|
}
|
|
48
52
|
if (/^0x[0-9a-f]{64}$/i.test(target)) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tersign",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.2",
|
|
4
4
|
"description": "Tersign \u2014 the evidence layer for the agent economy. Counter-signed receipts, agent action records, idempotency enforcement, refunds, disputes, and jury-ready evidence envelopes for x402/agent-commerce sellers.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|