@motebit/verifier 1.7.0 → 1.8.0
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/README.md +2 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +8 -0
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -45,6 +45,8 @@ The unified `verify()` dispatcher in [`@motebit/crypto`](https://www.npmjs.com/p
|
|
|
45
45
|
|
|
46
46
|
This package wraps the dispatcher with `verifyFile` (path → result), `verifyArtifact` (string → result), `verifySkillDirectory` (path-to-a-skill-directory → result, for skill bundles shipped as a tree rather than a single file), and `formatHuman` (result → printable banner).
|
|
47
47
|
|
|
48
|
+
It also re-exports the structured-verdict surface from `@motebit/crypto`: **`verifyReceiptVerdict`** (a signed receipt → a `VerificationVerdict` whose independent axes — integrity, identityBinding, authority, revocation, temporalBasis, evidenceBasis, plus a first-class `repair` — cannot silently collapse to `true`; there is no top-level `valid` boolean to over-read), **`verifyDelegationTokenVerdict`** (a per-tick token against its standing grant — `authority` and `revocation` stay orthogonal, and `temporalMode` selects whether a clock-rollback is load-bearing), and **`isFullyVerified`** (the fail-closed collapse to a boolean: `true` only when every load-bearing axis passes — stricter than the legacy per-function booleans by design). See [`verify-family-fail-closed.md`](https://github.com/motebit/motebit/blob/main/docs/doctrine/verify-family-fail-closed.md).
|
|
49
|
+
|
|
48
50
|
It also re-exports **`verifyApprovalDecision`** from `@motebit/crypto` — the "approve" governance band's signed human-consent artifact (`ApprovalDecision`). Unlike the auto-detected artifact types above, an `ApprovalDecision` is verified explicitly against a **pinned approver key** (it carries no `motebit_id → key` binding, so verifying against its own embedded key is circular). See [the governance-triad guide](https://docs.motebit.com/docs/developer/governance-triad) for where a verified decision sits on the binding ladder.
|
|
49
51
|
|
|
50
52
|
For the same reason — authority is the scope/chain, not a `motebit_id → key` ladder resolvable from the artifact alone — the **delegation family** is also re-exported as explicit verifiers (not auto-detected): **`verifyDelegation`** (a standalone or per-tick `DelegationToken`), **`verifyStandingDelegation`** (a standing grant: signature, activation, expiry, and an injected revocation seam), **`verifyTokenAgainstGrant`** (a per-tick token IS a valid tick of its grant — scope narrows, TTL bounded, grant not revoked), and **`verifyDelegationRevocation`** (a revocation's signature; the caller binds it to the grant). A standing grant's revocation check is the consumer's responsibility — the verifiers are I/O-free and cannot fetch a feed — so **`findGrantRevocation`** does that check correctly: it returns the revocation that authoritatively revokes a grant from a candidate set, binding on `grant_id` **and** the grant's `delegator_public_key` **and** a valid signature, so matching `grant_id` alone (the foot-gun) cannot spoof a revocation. Build the `verifyStandingDelegation` `isRevoked` seam from it. This lets a consumer validate a standing monitor's authorization root, every tick token, and revocation through this package alone. See [`standing-delegation@1.0`](https://github.com/motebit/motebit/blob/main/spec/standing-delegation-v1.md).
|
package/dist/index.d.ts
CHANGED
|
@@ -38,4 +38,6 @@ export { verifyDelegation, verifyStandingDelegation, verifyTokenAgainstGrant, ve
|
|
|
38
38
|
export { signRequestEnvelope, verifyRequestEnvelope } from "@motebit/crypto";
|
|
39
39
|
export type { SignedRequestEnvelope } from "@motebit/crypto";
|
|
40
40
|
export type { VerifyResult, ArtifactType, SkillVerifyResult, SkillFileVerifyResult, ApprovalDecision, DelegationToken, StandingDelegation, DelegationRevocation, SubjectBindingV1, } from "@motebit/crypto";
|
|
41
|
+
export type { VerificationVerdict, VerdictSubject, IntegrityVerdict, IdentityBindingVerdict, AuthorityVerdict, RevocationStatus, RevocationVerdict, RevocationFreshness, TemporalBasis, EvidenceRef, RepairInstruction, } from "@motebit/crypto";
|
|
42
|
+
export { verifyReceiptVerdict, verifyDelegationTokenVerdict, isFullyVerified, } from "@motebit/crypto";
|
|
41
43
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA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AAE,qBAAqB,EAAE,MAAM,iBAAiB,CAAC;AAC7D,YAAY,EACV,YAAY,EACZ,YAAY,EACZ,iBAAiB,EACjB,qBAAqB,EACrB,gBAAgB,EAChB,eAAe,EACf,kBAAkB,EAClB,oBAAoB,EACpB,gBAAgB,GACjB,MAAM,iBAAiB,CAAC;AAMzB,YAAY,EACV,mBAAmB,EACnB,cAAc,EACd,gBAAgB,EAChB,sBAAsB,EACtB,gBAAgB,EAChB,gBAAgB,EAChB,iBAAiB,EACjB,mBAAmB,EACnB,aAAa,EACb,WAAW,EACX,iBAAiB,GAClB,MAAM,iBAAiB,CAAC;AAQzB,OAAO,EACL,oBAAoB,EACpB,4BAA4B,EAC5B,eAAe,GAChB,MAAM,iBAAiB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -59,4 +59,12 @@ export { verifyDelegation, verifyStandingDelegation, verifyTokenAgainstGrant, ve
|
|
|
59
59
|
// like the delegation family — verified against the identity's REGISTERED key
|
|
60
60
|
// (resolved by the caller from `motebit_id`), never a key the request carries.
|
|
61
61
|
export { signRequestEnvelope, verifyRequestEnvelope } from "@motebit/crypto";
|
|
62
|
+
// The verdict producers and the fail-closed collapse. `verifyReceiptVerdict`
|
|
63
|
+
// (A.2.1) returns the structured verdict for a signed receipt;
|
|
64
|
+
// `verifyDelegationTokenVerdict` (A.2.2) does so for a per-tick token against
|
|
65
|
+
// its standing grant (authority + revocation orthogonal; temporalMode selects
|
|
66
|
+
// the temporal basis); `isFullyVerified` collapses any verdict to the
|
|
67
|
+
// fail-closed boolean (true only when every load-bearing axis passes — stricter
|
|
68
|
+
// than the legacy booleans by design).
|
|
69
|
+
export { verifyReceiptVerdict, verifyDelegationTokenVerdict, isFullyVerified, } from "@motebit/crypto";
|
|
62
70
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;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,0FAA0F;AAC1F,sGAAsG;AACtG,gFAAgF;AAChF,2FAA2F;AAC3F,oIAAoI;AACpI,kHAAkH;AAClH,yHAAyH;AACzH,OAAO,EACL,gBAAgB,EAChB,wBAAwB,EACxB,uBAAuB,EACvB,0BAA0B,EAC1B,mBAAmB,EACnB,oBAAoB,EACpB,oBAAoB,GACrB,MAAM,iBAAiB,CAAC;AACzB,gFAAgF;AAChF,8EAA8E;AAC9E,+EAA+E;AAC/E,OAAO,EAAE,mBAAmB,EAAE,qBAAqB,EAAE,MAAM,iBAAiB,CAAC;AA+B7E,6EAA6E;AAC7E,+DAA+D;AAC/D,8EAA8E;AAC9E,8EAA8E;AAC9E,sEAAsE;AACtE,gFAAgF;AAChF,uCAAuC;AACvC,OAAO,EACL,oBAAoB,EACpB,4BAA4B,EAC5B,eAAe,GAChB,MAAM,iBAAiB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@motebit/verifier",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.8.0",
|
|
4
4
|
"description": "Apache-2.0 library for verifying signed Motebit artifacts (identity files, execution receipts, credentials, presentations) — file-reading and human-formatting helpers on top of @motebit/crypto. The canonical `motebit-verify` CLI now lives at @motebit/verify; this package is the Apache-2.0 library it sits on.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -54,7 +54,7 @@
|
|
|
54
54
|
]
|
|
55
55
|
},
|
|
56
56
|
"dependencies": {
|
|
57
|
-
"@motebit/crypto": "3.
|
|
57
|
+
"@motebit/crypto": "3.11.0",
|
|
58
58
|
"@motebit/protocol": "3.5.0"
|
|
59
59
|
},
|
|
60
60
|
"devDependencies": {
|