@oma3/omatrust 0.1.0-alpha.10 → 0.1.0-alpha.12
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 +3 -0
- package/dist/app-registry/index.cjs +53 -0
- package/dist/app-registry/index.cjs.map +1 -1
- package/dist/app-registry/index.js +53 -0
- package/dist/app-registry/index.js.map +1 -1
- package/dist/identity/index.cjs +1028 -6
- package/dist/identity/index.cjs.map +1 -1
- package/dist/identity/index.d.cts +2 -1
- package/dist/identity/index.d.ts +2 -1
- package/dist/identity/index.js +984 -7
- package/dist/identity/index.js.map +1 -1
- package/dist/index-B5OC9_8B.d.cts +480 -0
- package/dist/index-Bu-xxcv9.d.ts +407 -0
- package/dist/index-C6WNgPRx.d.ts +480 -0
- package/dist/index-C7odEbp6.d.cts +407 -0
- package/dist/index.cjs +2498 -373
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +4 -3
- package/dist/index.d.ts +4 -3
- package/dist/index.js +2342 -236
- package/dist/index.js.map +1 -1
- package/dist/reputation/index.browser.cjs +949 -67
- package/dist/reputation/index.browser.cjs.map +1 -1
- package/dist/reputation/index.browser.d.cts +2 -2
- package/dist/reputation/index.browser.d.ts +2 -2
- package/dist/reputation/index.browser.js +947 -67
- package/dist/reputation/index.browser.js.map +1 -1
- package/dist/reputation/index.cjs +1745 -232
- package/dist/reputation/index.cjs.map +1 -1
- package/dist/reputation/index.d.cts +3 -2
- package/dist/reputation/index.d.ts +3 -2
- package/dist/reputation/index.js +1727 -232
- package/dist/reputation/index.js.map +1 -1
- package/dist/{subject-ownership-CXvzEjpH.d.cts → subject-ownership-B7cFlm8c.d.cts} +256 -26
- package/dist/{subject-ownership-CXvzEjpH.d.ts → subject-ownership-B7cFlm8c.d.ts} +256 -26
- package/dist/types-Dn0OwaNj.d.cts +307 -0
- package/dist/types-Dn0OwaNj.d.ts +307 -0
- package/dist/widgets/index.cjs +70 -27
- package/dist/widgets/index.cjs.map +1 -1
- package/dist/widgets/index.d.cts +45 -18
- package/dist/widgets/index.d.ts +45 -18
- package/dist/widgets/index.js +67 -26
- package/dist/widgets/index.js.map +1 -1
- package/package.json +5 -2
- package/dist/index-B9KW02US.d.cts +0 -119
- package/dist/index-DXrwBex9.d.ts +0 -119
- package/dist/index-QZDExA4I.d.cts +0 -90
- package/dist/index-QZDExA4I.d.ts +0 -90
|
@@ -0,0 +1,407 @@
|
|
|
1
|
+
import { A as AuthorizationMetadata, J as JwkValidationResult, a as JwsVerificationError, b as JwsVerificationFailure, c as JwsVerificationResult, P as PublicJwk, d as PublicKeySource, R as ResolveKeyOptions, e as ResolvedControllerDid, f as ResolvedPublicKey, V as VerificationResultInput, g as computeJwkThumbprint, h as didJwkToJwk, i as extractAuthorizationMetadata, j as formatJktValue, k as jwkToDidJwk, p as publicJwkEquals, r as resolveDidUrlToControllerDid, l as resolveDidUrlToPublicKey, v as validatePublicJwk } from './types-Dn0OwaNj.js';
|
|
2
|
+
|
|
3
|
+
type Hex$1 = `0x${string}`;
|
|
4
|
+
type Did = string;
|
|
5
|
+
declare function isValidDid(did: string): boolean;
|
|
6
|
+
declare function extractDidMethod(did: Did): string | null;
|
|
7
|
+
declare function extractDidIdentifier(did: Did): string | null;
|
|
8
|
+
declare function normalizeDomain(domain: string): string;
|
|
9
|
+
declare function normalizeDidWeb(input: string): Did;
|
|
10
|
+
declare function normalizeDidPkh(input: string): Did;
|
|
11
|
+
declare function normalizeDidHandle(input: string): Did;
|
|
12
|
+
declare function normalizeDidKey(input: string): Did;
|
|
13
|
+
declare function normalizeDid(input: string): Did;
|
|
14
|
+
declare function computeDidHash(did: Did): Hex$1;
|
|
15
|
+
declare function computeDidAddress(didHash: Hex$1): Hex$1;
|
|
16
|
+
declare function didToAddress(did: Did): Hex$1;
|
|
17
|
+
declare function validateDidAddress(did: Did, address: Hex$1): boolean;
|
|
18
|
+
declare function buildDidWeb(domain: string): Did;
|
|
19
|
+
declare function buildDidPkh(namespace: string, chainId: string | number, address: string): Did;
|
|
20
|
+
declare function buildEvmDidPkh(chainId: string | number, address: string): Did;
|
|
21
|
+
declare function buildDidPkhFromCaip10(caip10: string): Did;
|
|
22
|
+
declare function getChainIdFromDidPkh(did: Did): string | null;
|
|
23
|
+
declare function getAddressFromDidPkh(did: Did): string | null;
|
|
24
|
+
declare function getNamespaceFromDidPkh(did: Did): string | null;
|
|
25
|
+
declare function isEvmDidPkh(did: Did): boolean;
|
|
26
|
+
declare function getDomainFromDidWeb(did: Did): string | null;
|
|
27
|
+
/**
|
|
28
|
+
* Extract an EVM address from a DID or address-like identifier.
|
|
29
|
+
*
|
|
30
|
+
* Supports:
|
|
31
|
+
* - did:pkh (extracts the address portion — currently EVM only)
|
|
32
|
+
* - did:ethr (extracts the Ethereum address)
|
|
33
|
+
* - CAIP-10 format (e.g. eip155:1:0xABC)
|
|
34
|
+
* - Raw EVM addresses (0x + 40 hex chars)
|
|
35
|
+
*
|
|
36
|
+
* NOTE: This function is EVM-specific. It does not support non-EVM chains
|
|
37
|
+
* (e.g. Solana, Cosmos). Non-EVM did:pkh identifiers will throw.
|
|
38
|
+
* A future version may generalize to support multiple chain families.
|
|
39
|
+
*
|
|
40
|
+
* @param identifier - A DID, CAIP-10 string, or raw EVM address
|
|
41
|
+
* @returns The checksummed EVM address
|
|
42
|
+
* @throws OmaTrustError if the identifier cannot be resolved to an EVM address
|
|
43
|
+
*/
|
|
44
|
+
declare function extractAddressFromDid(identifier: string): string;
|
|
45
|
+
/** Result of private-key DID validation */
|
|
46
|
+
interface PrivateKeyDidValidation {
|
|
47
|
+
valid: boolean;
|
|
48
|
+
method: "pkh" | "jwk" | null;
|
|
49
|
+
error?: string;
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* Check if a DID uses a private-key method (can sign transactions/messages).
|
|
53
|
+
* Quick boolean check — use validatePrivateKeyDid() for detailed errors.
|
|
54
|
+
*/
|
|
55
|
+
declare function isPrivateKeyDid(did: string): boolean;
|
|
56
|
+
/**
|
|
57
|
+
* Validate that a DID is a well-formed private-key DID.
|
|
58
|
+
* Returns detailed validation result with method identification and error messages.
|
|
59
|
+
*
|
|
60
|
+
* Supported methods:
|
|
61
|
+
* - did:pkh — CAIP-10 blockchain account (deep validation for eip155)
|
|
62
|
+
* - did:jwk — JSON Web Key (structural validation)
|
|
63
|
+
*/
|
|
64
|
+
declare function validatePrivateKeyDid(did: string): PrivateKeyDidValidation;
|
|
65
|
+
/**
|
|
66
|
+
* Normalize a did:jwk DID.
|
|
67
|
+
* Validates structure and returns the DID unchanged (did:jwk is already canonical).
|
|
68
|
+
*/
|
|
69
|
+
declare function normalizeDidJwk(input: string): Did;
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* DID URL Parsing — Phase 1
|
|
73
|
+
*
|
|
74
|
+
* Parses DID URLs (e.g. did:web:api.example.com#key-1) into their components.
|
|
75
|
+
* DID URLs are mutable key references / lookup handles, not durable controller DIDs.
|
|
76
|
+
*/
|
|
77
|
+
/** Parsed DID URL components */
|
|
78
|
+
interface ParsedDidUrl {
|
|
79
|
+
/** The original full DID URL */
|
|
80
|
+
didUrl: string;
|
|
81
|
+
/** The base DID (without fragment) */
|
|
82
|
+
did: string;
|
|
83
|
+
/** The fragment identifier (without the '#'), or null if no fragment */
|
|
84
|
+
fragment: string | null;
|
|
85
|
+
}
|
|
86
|
+
/**
|
|
87
|
+
* Parse a DID URL into its components.
|
|
88
|
+
*
|
|
89
|
+
* A DID URL may include a fragment (e.g. `did:web:api.example.com#key-1`).
|
|
90
|
+
* The fragment identifies a verification method, key reference, or other
|
|
91
|
+
* resource under the DID.
|
|
92
|
+
*
|
|
93
|
+
* DID URLs are mutable key references. They should not be used as durable
|
|
94
|
+
* controller DIDs. Use `resolveDidUrlControllerDid()` to derive a durable
|
|
95
|
+
* `did:jwk` from a DID URL.
|
|
96
|
+
*
|
|
97
|
+
* @param input - A DID URL string
|
|
98
|
+
* @returns Parsed components: didUrl, did, fragment
|
|
99
|
+
* @throws OmaTrustError with code INVALID_DID_URL if input is malformed
|
|
100
|
+
*/
|
|
101
|
+
declare function parseDidUrl(input: string): ParsedDidUrl;
|
|
102
|
+
/**
|
|
103
|
+
* Check whether a string is a DID URL (contains a fragment).
|
|
104
|
+
* Useful for guards that need to reject DID URLs where a bare DID is expected.
|
|
105
|
+
*/
|
|
106
|
+
declare function isDidUrl(input: string): boolean;
|
|
107
|
+
/**
|
|
108
|
+
* Assert that a string is a bare DID (not a DID URL with a fragment).
|
|
109
|
+
* Throws if the input contains a fragment.
|
|
110
|
+
*
|
|
111
|
+
* Use this in functions that expect a subject DID and must reject DID URLs.
|
|
112
|
+
*/
|
|
113
|
+
declare function assertBareDid(input: string, paramName?: string): void;
|
|
114
|
+
|
|
115
|
+
/**
|
|
116
|
+
* Controller ID Comparison
|
|
117
|
+
*
|
|
118
|
+
* Determines whether two controller DIDs refer to the same entity.
|
|
119
|
+
* Handles DID normalization and EVM address-based fallback (chain-agnostic).
|
|
120
|
+
*/
|
|
121
|
+
/**
|
|
122
|
+
* Check if two controller DIDs refer to the same entity.
|
|
123
|
+
*
|
|
124
|
+
* Matching strategies (tried in order):
|
|
125
|
+
* 1. Exact normalized DID string match
|
|
126
|
+
* 2. EVM address match (chain-agnostic): if both DIDs resolve to the same
|
|
127
|
+
* EVM address, they match regardless of chain ID. This handles cases like
|
|
128
|
+
* did:pkh:eip155:1:0xABC matching did:pkh:eip155:137:0xABC.
|
|
129
|
+
* 3. JWK material match: if both are did:jwk, compare the decoded public key
|
|
130
|
+
* material directly (handles non-canonical encoding differences).
|
|
131
|
+
*
|
|
132
|
+
* @param a - First controller DID
|
|
133
|
+
* @param b - Second controller DID
|
|
134
|
+
* @returns true if both DIDs refer to the same controller
|
|
135
|
+
*/
|
|
136
|
+
declare function isSameControllerId(a: string, b: string): boolean;
|
|
137
|
+
/**
|
|
138
|
+
* Extract an EVM address from a controller DID, if possible.
|
|
139
|
+
* Returns null for non-EVM controllers (did:jwk, non-eip155 did:pkh, etc.)
|
|
140
|
+
*/
|
|
141
|
+
declare function extractControllerEvmAddress(controllerDid: string): string | null;
|
|
142
|
+
|
|
143
|
+
type Caip10 = string;
|
|
144
|
+
type ParsedCaip10 = {
|
|
145
|
+
namespace: string;
|
|
146
|
+
reference: string;
|
|
147
|
+
address: string;
|
|
148
|
+
};
|
|
149
|
+
type ParsedCaip2 = {
|
|
150
|
+
namespace: string;
|
|
151
|
+
reference: string;
|
|
152
|
+
};
|
|
153
|
+
declare function parseCaip10(input: string): ParsedCaip10;
|
|
154
|
+
declare function buildCaip10(namespace: string, reference: string, address: string): Caip10;
|
|
155
|
+
declare function normalizeCaip10(input: string): Caip10;
|
|
156
|
+
declare function buildCaip2(namespace: string, reference: string): string;
|
|
157
|
+
declare function parseCaip2(caip2: string): ParsedCaip2;
|
|
158
|
+
|
|
159
|
+
type Hex = `0x${string}`;
|
|
160
|
+
/**
|
|
161
|
+
* Parse JSON strictly, rejecting duplicate keys.
|
|
162
|
+
* Standard JSON.parse() silently accepts duplicates (last-wins).
|
|
163
|
+
* This function detects duplicates at any nesting depth and throws.
|
|
164
|
+
*/
|
|
165
|
+
declare function parseJsonStrict(input: string): unknown;
|
|
166
|
+
/**
|
|
167
|
+
* Assert that a value is JSON-safe (representable in JSON without lossy conversion).
|
|
168
|
+
* Rejects: undefined, NaN, Infinity, -Infinity, BigInt, functions, symbols, Date objects.
|
|
169
|
+
* These values would be silently coerced or dropped by JSON.stringify / canonicalize.
|
|
170
|
+
*/
|
|
171
|
+
declare function assertJsonSafe(value: unknown, path?: string, depth?: number): void;
|
|
172
|
+
declare function canonicalizeJson(obj: unknown): string;
|
|
173
|
+
/**
|
|
174
|
+
* Canonicalize a JSON object (JCS / RFC 8785) and compute its keccak256 hash.
|
|
175
|
+
* Returns both the canonical JCS string and the 0x-prefixed hash.
|
|
176
|
+
*/
|
|
177
|
+
declare function canonicalizeAndKeccak256(obj: unknown): {
|
|
178
|
+
jcsJson: string;
|
|
179
|
+
hash: Hex;
|
|
180
|
+
};
|
|
181
|
+
/** @deprecated Use canonicalizeAndKeccak256 instead. */
|
|
182
|
+
declare function canonicalizeForHash(obj: unknown): {
|
|
183
|
+
jcsJson: string;
|
|
184
|
+
hash: Hex;
|
|
185
|
+
};
|
|
186
|
+
declare function hashCanonicalizedJson(obj: unknown, algorithm: "keccak256" | "sha256"): Hex;
|
|
187
|
+
|
|
188
|
+
/**
|
|
189
|
+
* did:artifact — Content-Addressed DID Method
|
|
190
|
+
*
|
|
191
|
+
* Implements construction, parsing, and verification for the did:artifact DID method.
|
|
192
|
+
* A did:artifact DID names an immutable byte sequence by its SHA-256 content hash,
|
|
193
|
+
* encoded as a CIDv1 with raw multicodec and base32-lower multibase.
|
|
194
|
+
*
|
|
195
|
+
* Construction:
|
|
196
|
+
* - artifactDidFromBytes: hash raw bytes (binary artifacts)
|
|
197
|
+
* - artifactDidFromJson: canonicalize JSON then hash (JSON artifacts)
|
|
198
|
+
*
|
|
199
|
+
* Verification:
|
|
200
|
+
* - verifyDidArtifact: verify content matches a did:artifact DID
|
|
201
|
+
* (tries canonical JSON first, then raw bytes)
|
|
202
|
+
*
|
|
203
|
+
* Spec: https://oma3dao.github.io/omatrust-docs/specification/did-artifact-method-spec.html
|
|
204
|
+
*/
|
|
205
|
+
/** Parsed components of a did:artifact DID */
|
|
206
|
+
interface ParsedArtifactDid {
|
|
207
|
+
/** The full DID string */
|
|
208
|
+
did: string;
|
|
209
|
+
/** The method-specific identifier (base32-encoded CIDv1) */
|
|
210
|
+
identifier: string;
|
|
211
|
+
/** The SHA-256 digest as a Uint8Array (32 bytes) */
|
|
212
|
+
digest: Uint8Array;
|
|
213
|
+
/** The SHA-256 digest as lowercase hex */
|
|
214
|
+
digestHex: string;
|
|
215
|
+
}
|
|
216
|
+
/**
|
|
217
|
+
* Construct a did:artifact DID from raw bytes.
|
|
218
|
+
*
|
|
219
|
+
* Use this when the artifact is a binary blob (installer, archive, image, etc.)
|
|
220
|
+
* where no canonicalization is needed. The bytes are hashed as-is.
|
|
221
|
+
*
|
|
222
|
+
* @param bytes - The artifact's raw octets
|
|
223
|
+
* @returns The did:artifact DID string
|
|
224
|
+
* @throws OmaTrustError if bytes is empty or not a Uint8Array
|
|
225
|
+
*/
|
|
226
|
+
declare function artifactDidFromBytes(bytes: Uint8Array): Promise<string>;
|
|
227
|
+
/**
|
|
228
|
+
* Construct a did:artifact DID from a JSON value.
|
|
229
|
+
*
|
|
230
|
+
* The input is canonicalized using JCS (RFC 8785), then the canonical UTF-8 bytes
|
|
231
|
+
* are hashed with SHA-256. If the input is a string, it is parsed strictly
|
|
232
|
+
* (rejecting duplicate keys, non-JSON-safe values, etc.) before canonicalization.
|
|
233
|
+
*
|
|
234
|
+
* Use this when the artifact is a JSON document and you want identity based on
|
|
235
|
+
* the JSON *value* rather than the exact serialization.
|
|
236
|
+
*
|
|
237
|
+
* @param input - A parsed JSON value (object/array/primitive) or a JSON string
|
|
238
|
+
* @returns The did:artifact DID string
|
|
239
|
+
* @throws OmaTrustError if canonicalization fails (malformed JSON, duplicate keys, etc.)
|
|
240
|
+
*/
|
|
241
|
+
declare function artifactDidFromJson(input: unknown): Promise<string>;
|
|
242
|
+
/**
|
|
243
|
+
* Parse and validate a did:artifact DID string.
|
|
244
|
+
*
|
|
245
|
+
* Validates:
|
|
246
|
+
* - Correct prefix
|
|
247
|
+
* - Valid base32-lower multibase encoding
|
|
248
|
+
* - CID version 1
|
|
249
|
+
* - Multicodec is raw (0x55)
|
|
250
|
+
* - Multihash function is sha2-256 (0x12) with 32-byte digest
|
|
251
|
+
*
|
|
252
|
+
* @param did - The DID string to parse
|
|
253
|
+
* @returns Parsed components including the SHA-256 digest
|
|
254
|
+
* @throws OmaTrustError if the DID is malformed or uses unsupported parameters
|
|
255
|
+
*/
|
|
256
|
+
declare function parseArtifactDid(did: string): ParsedArtifactDid;
|
|
257
|
+
/** Result of artifact verification */
|
|
258
|
+
interface ArtifactVerificationResult {
|
|
259
|
+
/** Whether the content matches the DID */
|
|
260
|
+
valid: boolean;
|
|
261
|
+
/** Which interpretation matched: "json" if canonical JSON matched, "binary" if raw bytes matched */
|
|
262
|
+
matchedAs?: "json" | "binary";
|
|
263
|
+
/** Error reason when valid is false */
|
|
264
|
+
reason?: string;
|
|
265
|
+
}
|
|
266
|
+
/**
|
|
267
|
+
* Verify that content matches a did:artifact DID.
|
|
268
|
+
*
|
|
269
|
+
* Verification strategy:
|
|
270
|
+
* 1. Try to interpret the content as JSON: parse strictly, canonicalize, hash, compare.
|
|
271
|
+
* 2. If JSON interpretation fails or doesn't match, hash the raw bytes and compare.
|
|
272
|
+
* 3. If either matches, verification succeeds.
|
|
273
|
+
*
|
|
274
|
+
* This dual approach is necessary because the verifier doesn't know which path
|
|
275
|
+
* (artifactDidFromJson vs artifactDidFromBytes) was used at construction time.
|
|
276
|
+
*
|
|
277
|
+
* @param did - The did:artifact DID to verify against
|
|
278
|
+
* @param content - The candidate content (Uint8Array for binary, or string/object for JSON)
|
|
279
|
+
* @returns Verification result indicating whether and how the content matched
|
|
280
|
+
*/
|
|
281
|
+
declare function verifyDidArtifact(did: string, content: Uint8Array | string | unknown): Promise<ArtifactVerificationResult>;
|
|
282
|
+
|
|
283
|
+
/**
|
|
284
|
+
* DID Method Migration Helpers
|
|
285
|
+
*
|
|
286
|
+
* Provides conversion functions for deprecated DID methods:
|
|
287
|
+
* - did:ethr → did:pkh:eip155 (wallet addresses)
|
|
288
|
+
* - did:key → did:jwk (non-blockchain keys)
|
|
289
|
+
*
|
|
290
|
+
* These methods are being deprecated in favor of their canonical replacements.
|
|
291
|
+
* Use these functions to convert existing identifiers to the preferred format.
|
|
292
|
+
*/
|
|
293
|
+
/**
|
|
294
|
+
* Convert a did:ethr DID to the equivalent did:pkh:eip155 DID.
|
|
295
|
+
*
|
|
296
|
+
* did:ethr format: did:ethr:<address> or did:ethr:<chainId>:<address>
|
|
297
|
+
* did:pkh format: did:pkh:eip155:<chainId>:<address>
|
|
298
|
+
*
|
|
299
|
+
* If the did:ethr DID omits the chain ID, defaults to chain 1 (Ethereum mainnet).
|
|
300
|
+
*
|
|
301
|
+
* @param did - A did:ethr DID string
|
|
302
|
+
* @returns The equivalent did:pkh:eip155 DID
|
|
303
|
+
* @throws OmaTrustError if the input is not a valid did:ethr DID
|
|
304
|
+
*/
|
|
305
|
+
declare function didEthrToDidPkh(did: string): string;
|
|
306
|
+
/**
|
|
307
|
+
* Convert a did:key DID to the equivalent did:jwk DID.
|
|
308
|
+
*
|
|
309
|
+
* did:key encodes a public key as a multicodec-prefixed, base58btc-encoded value.
|
|
310
|
+
* This function decodes the key, identifies the algorithm from the multicodec prefix,
|
|
311
|
+
* constructs a JWK, and wraps it as did:jwk.
|
|
312
|
+
*
|
|
313
|
+
* Supported key types:
|
|
314
|
+
* - Ed25519 (multicodec 0xed)
|
|
315
|
+
* - X25519 (multicodec 0xec)
|
|
316
|
+
*
|
|
317
|
+
* EC keys (secp256k1, P-256, P-384) are stored compressed in did:key and require
|
|
318
|
+
* elliptic curve decompression to produce a valid JWK. This is not supported;
|
|
319
|
+
* use didEthrToDidPkh() for EVM wallet keys instead.
|
|
320
|
+
*
|
|
321
|
+
* @param did - A did:key DID string
|
|
322
|
+
* @returns The equivalent did:jwk DID
|
|
323
|
+
* @throws OmaTrustError if the input is invalid or uses an unsupported key type
|
|
324
|
+
*/
|
|
325
|
+
declare function didKeyToDidJwk(did: string): string;
|
|
326
|
+
|
|
327
|
+
type index_ArtifactVerificationResult = ArtifactVerificationResult;
|
|
328
|
+
declare const index_AuthorizationMetadata: typeof AuthorizationMetadata;
|
|
329
|
+
type index_Caip10 = Caip10;
|
|
330
|
+
type index_Did = Did;
|
|
331
|
+
declare const index_JwkValidationResult: typeof JwkValidationResult;
|
|
332
|
+
declare const index_JwsVerificationError: typeof JwsVerificationError;
|
|
333
|
+
declare const index_JwsVerificationFailure: typeof JwsVerificationFailure;
|
|
334
|
+
declare const index_JwsVerificationResult: typeof JwsVerificationResult;
|
|
335
|
+
type index_ParsedArtifactDid = ParsedArtifactDid;
|
|
336
|
+
type index_ParsedCaip10 = ParsedCaip10;
|
|
337
|
+
type index_ParsedCaip2 = ParsedCaip2;
|
|
338
|
+
type index_ParsedDidUrl = ParsedDidUrl;
|
|
339
|
+
type index_PrivateKeyDidValidation = PrivateKeyDidValidation;
|
|
340
|
+
declare const index_PublicJwk: typeof PublicJwk;
|
|
341
|
+
declare const index_PublicKeySource: typeof PublicKeySource;
|
|
342
|
+
declare const index_ResolveKeyOptions: typeof ResolveKeyOptions;
|
|
343
|
+
declare const index_ResolvedControllerDid: typeof ResolvedControllerDid;
|
|
344
|
+
declare const index_ResolvedPublicKey: typeof ResolvedPublicKey;
|
|
345
|
+
declare const index_VerificationResultInput: typeof VerificationResultInput;
|
|
346
|
+
declare const index_artifactDidFromBytes: typeof artifactDidFromBytes;
|
|
347
|
+
declare const index_artifactDidFromJson: typeof artifactDidFromJson;
|
|
348
|
+
declare const index_assertBareDid: typeof assertBareDid;
|
|
349
|
+
declare const index_assertJsonSafe: typeof assertJsonSafe;
|
|
350
|
+
declare const index_buildCaip10: typeof buildCaip10;
|
|
351
|
+
declare const index_buildCaip2: typeof buildCaip2;
|
|
352
|
+
declare const index_buildDidPkh: typeof buildDidPkh;
|
|
353
|
+
declare const index_buildDidPkhFromCaip10: typeof buildDidPkhFromCaip10;
|
|
354
|
+
declare const index_buildDidWeb: typeof buildDidWeb;
|
|
355
|
+
declare const index_buildEvmDidPkh: typeof buildEvmDidPkh;
|
|
356
|
+
declare const index_canonicalizeAndKeccak256: typeof canonicalizeAndKeccak256;
|
|
357
|
+
declare const index_canonicalizeForHash: typeof canonicalizeForHash;
|
|
358
|
+
declare const index_canonicalizeJson: typeof canonicalizeJson;
|
|
359
|
+
declare const index_computeDidAddress: typeof computeDidAddress;
|
|
360
|
+
declare const index_computeDidHash: typeof computeDidHash;
|
|
361
|
+
declare const index_computeJwkThumbprint: typeof computeJwkThumbprint;
|
|
362
|
+
declare const index_didEthrToDidPkh: typeof didEthrToDidPkh;
|
|
363
|
+
declare const index_didJwkToJwk: typeof didJwkToJwk;
|
|
364
|
+
declare const index_didKeyToDidJwk: typeof didKeyToDidJwk;
|
|
365
|
+
declare const index_didToAddress: typeof didToAddress;
|
|
366
|
+
declare const index_extractAddressFromDid: typeof extractAddressFromDid;
|
|
367
|
+
declare const index_extractAuthorizationMetadata: typeof extractAuthorizationMetadata;
|
|
368
|
+
declare const index_extractControllerEvmAddress: typeof extractControllerEvmAddress;
|
|
369
|
+
declare const index_extractDidIdentifier: typeof extractDidIdentifier;
|
|
370
|
+
declare const index_extractDidMethod: typeof extractDidMethod;
|
|
371
|
+
declare const index_formatJktValue: typeof formatJktValue;
|
|
372
|
+
declare const index_getAddressFromDidPkh: typeof getAddressFromDidPkh;
|
|
373
|
+
declare const index_getChainIdFromDidPkh: typeof getChainIdFromDidPkh;
|
|
374
|
+
declare const index_getDomainFromDidWeb: typeof getDomainFromDidWeb;
|
|
375
|
+
declare const index_getNamespaceFromDidPkh: typeof getNamespaceFromDidPkh;
|
|
376
|
+
declare const index_hashCanonicalizedJson: typeof hashCanonicalizedJson;
|
|
377
|
+
declare const index_isDidUrl: typeof isDidUrl;
|
|
378
|
+
declare const index_isEvmDidPkh: typeof isEvmDidPkh;
|
|
379
|
+
declare const index_isPrivateKeyDid: typeof isPrivateKeyDid;
|
|
380
|
+
declare const index_isSameControllerId: typeof isSameControllerId;
|
|
381
|
+
declare const index_isValidDid: typeof isValidDid;
|
|
382
|
+
declare const index_jwkToDidJwk: typeof jwkToDidJwk;
|
|
383
|
+
declare const index_normalizeCaip10: typeof normalizeCaip10;
|
|
384
|
+
declare const index_normalizeDid: typeof normalizeDid;
|
|
385
|
+
declare const index_normalizeDidHandle: typeof normalizeDidHandle;
|
|
386
|
+
declare const index_normalizeDidJwk: typeof normalizeDidJwk;
|
|
387
|
+
declare const index_normalizeDidKey: typeof normalizeDidKey;
|
|
388
|
+
declare const index_normalizeDidPkh: typeof normalizeDidPkh;
|
|
389
|
+
declare const index_normalizeDidWeb: typeof normalizeDidWeb;
|
|
390
|
+
declare const index_normalizeDomain: typeof normalizeDomain;
|
|
391
|
+
declare const index_parseArtifactDid: typeof parseArtifactDid;
|
|
392
|
+
declare const index_parseCaip10: typeof parseCaip10;
|
|
393
|
+
declare const index_parseCaip2: typeof parseCaip2;
|
|
394
|
+
declare const index_parseDidUrl: typeof parseDidUrl;
|
|
395
|
+
declare const index_parseJsonStrict: typeof parseJsonStrict;
|
|
396
|
+
declare const index_publicJwkEquals: typeof publicJwkEquals;
|
|
397
|
+
declare const index_resolveDidUrlToControllerDid: typeof resolveDidUrlToControllerDid;
|
|
398
|
+
declare const index_resolveDidUrlToPublicKey: typeof resolveDidUrlToPublicKey;
|
|
399
|
+
declare const index_validateDidAddress: typeof validateDidAddress;
|
|
400
|
+
declare const index_validatePrivateKeyDid: typeof validatePrivateKeyDid;
|
|
401
|
+
declare const index_validatePublicJwk: typeof validatePublicJwk;
|
|
402
|
+
declare const index_verifyDidArtifact: typeof verifyDidArtifact;
|
|
403
|
+
declare namespace index {
|
|
404
|
+
export { type index_ArtifactVerificationResult as ArtifactVerificationResult, index_AuthorizationMetadata as AuthorizationMetadata, type index_Caip10 as Caip10, type index_Did as Did, type Hex$1 as Hex, index_JwkValidationResult as JwkValidationResult, index_JwsVerificationError as JwsVerificationError, index_JwsVerificationFailure as JwsVerificationFailure, index_JwsVerificationResult as JwsVerificationResult, type index_ParsedArtifactDid as ParsedArtifactDid, type index_ParsedCaip10 as ParsedCaip10, type index_ParsedCaip2 as ParsedCaip2, type index_ParsedDidUrl as ParsedDidUrl, type index_PrivateKeyDidValidation as PrivateKeyDidValidation, index_PublicJwk as PublicJwk, index_PublicKeySource as PublicKeySource, index_ResolveKeyOptions as ResolveKeyOptions, index_ResolvedControllerDid as ResolvedControllerDid, index_ResolvedPublicKey as ResolvedPublicKey, index_VerificationResultInput as VerificationResultInput, index_artifactDidFromBytes as artifactDidFromBytes, index_artifactDidFromJson as artifactDidFromJson, index_assertBareDid as assertBareDid, index_assertJsonSafe as assertJsonSafe, index_buildCaip10 as buildCaip10, index_buildCaip2 as buildCaip2, index_buildDidPkh as buildDidPkh, index_buildDidPkhFromCaip10 as buildDidPkhFromCaip10, index_buildDidWeb as buildDidWeb, index_buildEvmDidPkh as buildEvmDidPkh, index_canonicalizeAndKeccak256 as canonicalizeAndKeccak256, index_canonicalizeForHash as canonicalizeForHash, index_canonicalizeJson as canonicalizeJson, index_computeDidAddress as computeDidAddress, index_computeDidHash as computeDidHash, index_computeJwkThumbprint as computeJwkThumbprint, index_didEthrToDidPkh as didEthrToDidPkh, index_didJwkToJwk as didJwkToJwk, index_didKeyToDidJwk as didKeyToDidJwk, index_didToAddress as didToAddress, index_extractAddressFromDid as extractAddressFromDid, index_extractAuthorizationMetadata as extractAuthorizationMetadata, index_extractControllerEvmAddress as extractControllerEvmAddress, index_extractDidIdentifier as extractDidIdentifier, index_extractDidMethod as extractDidMethod, index_formatJktValue as formatJktValue, index_getAddressFromDidPkh as getAddressFromDidPkh, index_getChainIdFromDidPkh as getChainIdFromDidPkh, index_getDomainFromDidWeb as getDomainFromDidWeb, index_getNamespaceFromDidPkh as getNamespaceFromDidPkh, index_hashCanonicalizedJson as hashCanonicalizedJson, index_isDidUrl as isDidUrl, index_isEvmDidPkh as isEvmDidPkh, index_isPrivateKeyDid as isPrivateKeyDid, index_isSameControllerId as isSameControllerId, index_isValidDid as isValidDid, index_jwkToDidJwk as jwkToDidJwk, index_normalizeCaip10 as normalizeCaip10, index_normalizeDid as normalizeDid, index_normalizeDidHandle as normalizeDidHandle, index_normalizeDidJwk as normalizeDidJwk, index_normalizeDidKey as normalizeDidKey, index_normalizeDidPkh as normalizeDidPkh, index_normalizeDidWeb as normalizeDidWeb, index_normalizeDomain as normalizeDomain, index_parseArtifactDid as parseArtifactDid, index_parseCaip10 as parseCaip10, index_parseCaip2 as parseCaip2, index_parseDidUrl as parseDidUrl, index_parseJsonStrict as parseJsonStrict, index_publicJwkEquals as publicJwkEquals, index_resolveDidUrlToControllerDid as resolveDidUrlToControllerDid, index_resolveDidUrlToPublicKey as resolveDidUrlToPublicKey, index_validateDidAddress as validateDidAddress, index_validatePrivateKeyDid as validatePrivateKeyDid, index_validatePublicJwk as validatePublicJwk, index_verifyDidArtifact as verifyDidArtifact };
|
|
405
|
+
}
|
|
406
|
+
|
|
407
|
+
export { parseDidUrl as $, type ArtifactVerificationResult as A, extractDidMethod as B, type Caip10 as C, type Did as D, getAddressFromDidPkh as E, getChainIdFromDidPkh as F, getDomainFromDidWeb as G, type Hex$1 as H, getNamespaceFromDidPkh as I, hashCanonicalizedJson as J, isDidUrl as K, isEvmDidPkh as L, isPrivateKeyDid as M, isSameControllerId as N, isValidDid as O, type ParsedArtifactDid as P, normalizeCaip10 as Q, normalizeDid as R, normalizeDidHandle as S, normalizeDidJwk as T, normalizeDidKey as U, normalizeDidPkh as V, normalizeDidWeb as W, normalizeDomain as X, parseArtifactDid as Y, parseCaip10 as Z, parseCaip2 as _, type ParsedCaip10 as a, parseJsonStrict as a0, validateDidAddress as a1, validatePrivateKeyDid as a2, verifyDidArtifact as a3, type ParsedCaip2 as b, type ParsedDidUrl as c, type PrivateKeyDidValidation as d, artifactDidFromBytes as e, artifactDidFromJson as f, assertBareDid as g, assertJsonSafe as h, index as i, buildCaip10 as j, buildCaip2 as k, buildDidPkh as l, buildDidPkhFromCaip10 as m, buildDidWeb as n, buildEvmDidPkh as o, canonicalizeAndKeccak256 as p, canonicalizeForHash as q, canonicalizeJson as r, computeDidAddress as s, computeDidHash as t, didEthrToDidPkh as u, didKeyToDidJwk as v, didToAddress as w, extractAddressFromDid as x, extractControllerEvmAddress as y, extractDidIdentifier as z };
|