@peac/protocol 0.13.0 → 0.13.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/_internal/record-core/bounded-validator.d.ts +83 -0
- package/dist/_internal/record-core/bounded-validator.d.ts.map +1 -0
- package/dist/_internal/record-core/codec/index.d.ts +27 -0
- package/dist/_internal/record-core/codec/index.d.ts.map +1 -0
- package/dist/_internal/record-core/codec/jws-jwt.d.ts +25 -0
- package/dist/_internal/record-core/codec/jws-jwt.d.ts.map +1 -0
- package/dist/_internal/record-core/codec/types.d.ts +80 -0
- package/dist/_internal/record-core/codec/types.d.ts.map +1 -0
- package/dist/_internal/record-core/index.d.ts +14 -0
- package/dist/_internal/record-core/index.d.ts.map +1 -0
- package/dist/_internal/record-core/normalize.d.ts +24 -0
- package/dist/_internal/record-core/normalize.d.ts.map +1 -0
- package/dist/_internal/record-core/shadow-hook.d.ts +46 -0
- package/dist/_internal/record-core/shadow-hook.d.ts.map +1 -0
- package/dist/_internal/record-core/types.d.ts +15 -0
- package/dist/_internal/record-core/types.d.ts.map +1 -0
- package/dist/_internal/record-core/validators/extension-budget.d.ts +47 -0
- package/dist/_internal/record-core/validators/extension-budget.d.ts.map +1 -0
- package/dist/_internal/record-core/validators/index.d.ts +13 -0
- package/dist/_internal/record-core/validators/index.d.ts.map +1 -0
- package/dist/_internal/record-core/validators/issuer-form.d.ts +58 -0
- package/dist/_internal/record-core/validators/issuer-form.d.ts.map +1 -0
- package/dist/_internal/record-core/validators/jose-hardening.d.ts +58 -0
- package/dist/_internal/record-core/validators/jose-hardening.d.ts.map +1 -0
- package/dist/_internal/record-core/validators/kernel-constraints.d.ts +48 -0
- package/dist/_internal/record-core/validators/kernel-constraints.d.ts.map +1 -0
- package/dist/_internal/record-core/validators/temporal.d.ts +50 -0
- package/dist/_internal/record-core/validators/temporal.d.ts.map +1 -0
- package/dist/_internal/record-core/validators/type-extension-mapping.d.ts +51 -0
- package/dist/_internal/record-core/validators/type-extension-mapping.d.ts.map +1 -0
- package/dist/_internal/record-core/validators/types.d.ts +42 -0
- package/dist/_internal/record-core/validators/types.d.ts.map +1 -0
- package/dist/_internal/shadow-observe.d.ts +93 -0
- package/dist/_internal/shadow-observe.d.ts.map +1 -0
- package/dist/_internal/shadow-redact.d.ts +74 -0
- package/dist/_internal/shadow-redact.d.ts.map +1 -0
- package/dist/_internal/shadow-types.d.ts +62 -0
- package/dist/_internal/shadow-types.d.ts.map +1 -0
- package/dist/_internal/shadow.d.ts +134 -0
- package/dist/_internal/shadow.d.ts.map +1 -0
- package/dist/_internal/test-helpers/canonical-runner.d.ts +43 -0
- package/dist/_internal/test-helpers/canonical-runner.d.ts.map +1 -0
- package/dist/_internal/test-helpers/corpus-loader.d.ts +61 -0
- package/dist/_internal/test-helpers/corpus-loader.d.ts.map +1 -0
- package/dist/_internal/test-helpers/fixture-manifest.d.ts +46 -0
- package/dist/_internal/test-helpers/fixture-manifest.d.ts.map +1 -0
- package/dist/_internal/test-helpers/parity-verdict.d.ts +31 -0
- package/dist/_internal/test-helpers/parity-verdict.d.ts.map +1 -0
- package/dist/index.cjs +684 -11
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +685 -12
- package/dist/index.mjs.map +1 -1
- package/dist/issue.d.ts +12 -12
- package/dist/issue.d.ts.map +1 -1
- package/dist/policy-binding.d.ts +1 -1
- package/dist/verify-local.cjs +645 -3
- package/dist/verify-local.cjs.map +1 -1
- package/dist/verify-local.d.ts.map +1 -1
- package/dist/verify-local.mjs +647 -5
- package/dist/verify-local.mjs.map +1 -1
- package/package.json +6 -4
package/dist/issue.d.ts
CHANGED
|
@@ -6,7 +6,7 @@ import type { JsonValue, EvidencePillar, PolicyBlock } from '@peac/kernel';
|
|
|
6
6
|
import { PEACReceiptClaims, SubjectProfileSnapshot, type PEACError, type PurposeToken, type CanonicalPurpose, type PurposeReason, type WorkflowContext } from '@peac/schema';
|
|
7
7
|
import { type TelemetryHook } from './telemetry.js';
|
|
8
8
|
/**
|
|
9
|
-
* Wire 0.1
|
|
9
|
+
* Wire 0.1 record options (frozen legacy).
|
|
10
10
|
*
|
|
11
11
|
* @deprecated Use {@link IssueWire02Options} (or the {@link IssueOptions} alias)
|
|
12
12
|
* for current stable issuance.
|
|
@@ -100,39 +100,39 @@ export declare class IssueError extends Error {
|
|
|
100
100
|
constructor(peacError: PEACError);
|
|
101
101
|
}
|
|
102
102
|
/**
|
|
103
|
-
* Issue a Wire 0.1 PEAC
|
|
103
|
+
* Issue a Wire 0.1 PEAC record.
|
|
104
104
|
*
|
|
105
105
|
* @deprecated Wire 0.1 issuance is frozen legacy. Use {@link issue} (current stable format)
|
|
106
|
-
* or {@link issueWire02} (explicit wire-pinned API) for Wire 0.2
|
|
106
|
+
* or {@link issueWire02} (explicit wire-pinned API) for Wire 0.2 records.
|
|
107
107
|
*
|
|
108
|
-
* @param options - Wire 0.1
|
|
108
|
+
* @param options - Wire 0.1 record options
|
|
109
109
|
* @returns Issue result with JWS and optional subject_snapshot
|
|
110
110
|
* @throws IssueError if evidence contains non-JSON-safe values
|
|
111
111
|
*/
|
|
112
112
|
export declare function issueWire01(options: IssueWire01Options): Promise<IssueResult>;
|
|
113
113
|
/**
|
|
114
|
-
* Issue a Wire 0.1 PEAC
|
|
114
|
+
* Issue a Wire 0.1 PEAC record and return just the JWS string
|
|
115
115
|
*
|
|
116
116
|
* @deprecated Wire 0.1 issuance is frozen legacy. Use {@link issue} for the current stable format.
|
|
117
117
|
*
|
|
118
|
-
* @param options - Wire 0.1
|
|
118
|
+
* @param options - Wire 0.1 record options
|
|
119
119
|
* @returns JWS compact serialization
|
|
120
120
|
*/
|
|
121
121
|
export declare function issueJws(options: IssueWire01Options): Promise<string>;
|
|
122
122
|
/**
|
|
123
|
-
* Issue a PEAC
|
|
123
|
+
* Issue a PEAC record in the current stable public format.
|
|
124
124
|
*
|
|
125
|
-
* This is the canonical public issuance API. It issues Wire 0.2
|
|
125
|
+
* This is the canonical public issuance API. It issues Wire 0.2 records
|
|
126
126
|
* (`typ: interaction-record+jwt`). For an explicit wire-pinned API, use
|
|
127
127
|
* {@link issueWire02} directly.
|
|
128
128
|
*
|
|
129
|
-
* @param options -
|
|
129
|
+
* @param options - Record options (same as {@link IssueWire02Options})
|
|
130
130
|
* @returns Issue result with JWS
|
|
131
131
|
* @throws IssueError if iss is not canonical or schema validation fails
|
|
132
132
|
*/
|
|
133
133
|
export declare function issue(options: IssueWire02Options): Promise<IssueResult>;
|
|
134
134
|
/**
|
|
135
|
-
* Options for issuing a Wire 0.2
|
|
135
|
+
* Options for issuing a Wire 0.2 record
|
|
136
136
|
*/
|
|
137
137
|
export interface IssueWire02Options {
|
|
138
138
|
/**
|
|
@@ -186,7 +186,7 @@ export interface IssueWire02Options {
|
|
|
186
186
|
*/
|
|
187
187
|
export type IssueOptions = IssueWire02Options;
|
|
188
188
|
/**
|
|
189
|
-
* Issue a Wire 0.2
|
|
189
|
+
* Issue a Wire 0.2 record (explicit wire-pinned API).
|
|
190
190
|
*
|
|
191
191
|
* Most callers should use {@link issue} instead, which delegates here.
|
|
192
192
|
* Use `issueWire02` directly for conformance tests, benchmarks, and
|
|
@@ -195,7 +195,7 @@ export type IssueOptions = IssueWire02Options;
|
|
|
195
195
|
* Validates the iss canonical form and Wire02ClaimsSchema before signing.
|
|
196
196
|
* Always sets typ to 'interaction-record+jwt' (WIRE_02_JWS_TYP).
|
|
197
197
|
*
|
|
198
|
-
* @param options - Wire 0.2
|
|
198
|
+
* @param options - Wire 0.2 record options
|
|
199
199
|
* @returns Issue result with JWS
|
|
200
200
|
* @throws IssueError if iss is not canonical or schema validation fails
|
|
201
201
|
*/
|
package/dist/issue.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"issue.d.ts","sourceRoot":"","sources":["../src/issue.ts"],"names":[],"mappings":"AAAA;;;GAGG;
|
|
1
|
+
{"version":3,"file":"issue.d.ts","sourceRoot":"","sources":["../src/issue.ts"],"names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UAAU,EAAE,UAAU,CAAC;IAEvB,sDAAsD;IACtD,GAAG,EAAE,MAAM,CAAC;IAEZ;;;OAGG;IACH,GAAG,CAAC,EAAE,MAAM,CAAC;IAEb,oDAAoD;IACpD,GAAG,CAAC,EAAE,MAAM,CAAC;IAEb;;;OAGG;IACH,OAAO,CAAC,EAAE,cAAc,EAAE,CAAC;IAE3B;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB,wDAAwD;IACxD,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAE1B;;;OAGG;IACH,MAAM,CAAC,EAAE,WAAW,CAAC;IAErB,mEAAmE;IACnE,UAAU,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CACtC;AAED;;;;GAIG;AACH,MAAM,MAAM,YAAY,GAAG,kBAAkB,CAAC;AAE9C;;;;;;;;;;;;;GAaG;AACH,wBAAsB,WAAW,CAAC,OAAO,EAAE,kBAAkB,GAAG,OAAO,CAAC,WAAW,CAAC,CAmFnF"}
|
package/dist/policy-binding.d.ts
CHANGED
|
@@ -24,7 +24,7 @@ import type { PolicyBindingStatus } from './verifier-types.js';
|
|
|
24
24
|
* `'sha256:<64 lowercase hex>'`.
|
|
25
25
|
*
|
|
26
26
|
* This is the normative digest format for the policy.digest field in
|
|
27
|
-
* Wire 0.2
|
|
27
|
+
* Wire 0.2 records. The format is stable and identical across
|
|
28
28
|
* implementations. Output is byte-identical to
|
|
29
29
|
* `computeJsonDocumentDigestJcs(policy)` from `document-binding.ts`.
|
|
30
30
|
*
|