@fedify/fedify 2.5.0-dev.2364 → 2.5.0-dev.2378

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.
Files changed (101) hide show
  1. package/dist/{builder-ClDm_1c7.mjs → builder-J1K0IJj6.mjs} +2 -2
  2. package/dist/compat/mod.d.cts +1 -1
  3. package/dist/compat/mod.d.ts +1 -1
  4. package/dist/compat/transformers.test.mjs +1 -1
  5. package/dist/{compound-proof-D03g5HXz.mjs → compound-proof-DtmVrMV7.mjs} +47 -19
  6. package/dist/{context-tsYPJ2Ew.d.cts → context-BjD_CTxh.d.cts} +1 -1
  7. package/dist/{context-7NyiqIcg.d.ts → context-C2-UDo2c.d.ts} +1 -1
  8. package/dist/{deno-Bp8q024B.mjs → deno-Ci6tSK9-.mjs} +1 -1
  9. package/dist/{docloader-DarxdYmj.mjs → docloader-DZ9h6KJS.mjs} +2 -2
  10. package/dist/federation/builder.test.mjs +1 -1
  11. package/dist/federation/compound-fanout.test.mjs +3 -3
  12. package/dist/federation/handler-compound-proof.test.mjs +3 -3
  13. package/dist/federation/handler.test.mjs +4 -5
  14. package/dist/federation/hashlink-media.test.mjs +2 -2
  15. package/dist/federation/idempotency.test.mjs +2 -2
  16. package/dist/federation/inbox-report.test.mjs +5 -5
  17. package/dist/federation/metrics.test.mjs +1 -1
  18. package/dist/federation/middleware.test.mjs +7 -7
  19. package/dist/federation/mod.cjs +1 -1
  20. package/dist/federation/mod.d.cts +3 -3
  21. package/dist/federation/mod.d.ts +3 -3
  22. package/dist/federation/mod.js +1 -1
  23. package/dist/federation/outgoing-proof.test.mjs +4 -5
  24. package/dist/federation/portable-actor.test.mjs +3 -3
  25. package/dist/federation/portable-chain.test.mjs +3 -3
  26. package/dist/federation/portable-collection.test.mjs +4 -4
  27. package/dist/federation/portable-delivery.test.mjs +2 -2
  28. package/dist/federation/portable-gateway-keys.test.mjs +4 -4
  29. package/dist/federation/portable-inbox.test.mjs +4 -4
  30. package/dist/federation/portable-parse-uri.test.mjs +1 -1
  31. package/dist/federation/portable-route-activity.test.mjs +2 -2
  32. package/dist/federation/portable.test.mjs +3 -3
  33. package/dist/federation/send.test.mjs +3 -3
  34. package/dist/federation/tasks/enqueue.test.mjs +1 -1
  35. package/dist/federation/tasks/tasks.test.mjs +2 -2
  36. package/dist/federation/temporal.test.mjs +1 -1
  37. package/dist/federation/webfinger.test.mjs +1 -1
  38. package/dist/{federation-BW53Wxj7.cjs → federation-lzy7M3hT.cjs} +48 -20
  39. package/dist/{http-D6JDnBO1.mjs → http-CFyizTHa.mjs} +4 -4
  40. package/dist/{http-Cg5Yj_yk.js → http-Cmz7x6Iw.js} +151 -19
  41. package/dist/{http-Btzv2JZU.cjs → http-D1RPHoq3.cjs} +161 -17
  42. package/dist/{key-DYxuyd-s.d.cts → key-DhsBxxZN.d.ts} +6 -2
  43. package/dist/{key-C1nv7_jD.d.ts → key-nYGY4QB9.d.cts} +6 -2
  44. package/dist/{kv-cache-CamfvHLY.js → kv-cache-C0-HuvwP.js} +1 -1
  45. package/dist/{kv-cache-0qHe-sN1.cjs → kv-cache-Jym5nP3J.cjs} +1 -1
  46. package/dist/{kv-cache-BoekCvYF.mjs → kv-cache-rOQX3I3c.mjs} +1 -1
  47. package/dist/{key-R5cUSA6S.mjs → ld-DJ--ZUpr.mjs} +760 -16
  48. package/dist/{metrics-DUdlIyrB.mjs → metrics-Dwgav7s_.mjs} +1 -1
  49. package/dist/{middleware-Hl0lTClT.mjs → middleware-BbBsa5iR.mjs} +13 -14
  50. package/dist/{middleware-DLB1TqQ1.mjs → middleware-CJWxuUy5.mjs} +1 -1
  51. package/dist/{middleware-BYOXwJvI.js → middleware-CqgRIsWM.js} +48 -20
  52. package/dist/{mod-Dw-nPxQh.d.cts → mod-B5-wdzmJ.d.cts} +1 -1
  53. package/dist/{mod-BojP2Bw3.d.cts → mod-BBPd4M_0.d.cts} +1 -1
  54. package/dist/{mod-CtpF2BU5.d.ts → mod-BRpER-B0.d.ts} +1 -1
  55. package/dist/{mod-Xj5P4s4d.d.ts → mod-CUYBGKof.d.ts} +1 -1
  56. package/dist/{mod-DEZXwV6J.d.ts → mod-DkhfZC1u.d.ts} +1 -1
  57. package/dist/{mod-CavhAgLw.d.cts → mod-xAfaLS4T.d.cts} +1 -1
  58. package/dist/mod.cjs +4 -4
  59. package/dist/mod.d.cts +5 -5
  60. package/dist/mod.d.ts +5 -5
  61. package/dist/mod.js +4 -4
  62. package/dist/nodeinfo/handler.test.mjs +1 -1
  63. package/dist/{owner-CKHKMnp-.mjs → owner-Btd7SwMj.mjs} +3 -3
  64. package/dist/{portable-collection-CyTnj1m9.cjs → portable-collection-BvWxS1sL.cjs} +1 -1
  65. package/dist/{portable-collection-Dhg0By3t.js → portable-collection-DwQT28O2.js} +1 -1
  66. package/dist/{portable-collection-DxVKitQN.mjs → portable-collection-gb9V8XEO.mjs} +2 -2
  67. package/dist/{portable-key-BOBhrrKN.mjs → portable-key-Cwti99nP.mjs} +1 -1
  68. package/dist/{proof-BGyUYuOb.mjs → proof-Bwzv6mXZ.mjs} +44 -11
  69. package/dist/{send-DmlYxKmb.mjs → send-BrQYUSb4.mjs} +3 -3
  70. package/dist/sig/compound-proof-discovery.test.mjs +1 -1
  71. package/dist/sig/compound-proof-producer.test.mjs +1 -1
  72. package/dist/sig/compound-proof-verification.test.mjs +168 -2
  73. package/dist/sig/compound-proof.test.mjs +2 -2
  74. package/dist/sig/http.test.mjs +2 -2
  75. package/dist/sig/key.test.mjs +208 -3
  76. package/dist/sig/ld.test.mjs +1 -2
  77. package/dist/sig/mitra-receive-interop.test.mjs +4 -4
  78. package/dist/sig/mitra-send-interop.test.mjs +3 -3
  79. package/dist/sig/mod.cjs +2 -2
  80. package/dist/sig/mod.d.cts +2 -2
  81. package/dist/sig/mod.d.ts +2 -2
  82. package/dist/sig/mod.js +2 -2
  83. package/dist/sig/owner.test.mjs +1 -1
  84. package/dist/sig/portable-collection.test.mjs +1 -1
  85. package/dist/sig/portable-interop.test.mjs +3 -3
  86. package/dist/sig/portable-key.test.mjs +5 -6
  87. package/dist/sig/proof.test.mjs +3 -3
  88. package/dist/sig/tootik-request-interop.test.mjs +4 -4
  89. package/dist/sig/tootik-send-interop.test.mjs +3 -3
  90. package/dist/sig/verification.test.mjs +3 -3
  91. package/dist/{temporal-Bvota1RR.mjs → temporal-BRaCTxVe.mjs} +1 -1
  92. package/dist/testing/kv.test.mjs +1 -1
  93. package/dist/testing/mod.d.mts +5 -1
  94. package/dist/utils/docloader.test.mjs +2 -2
  95. package/dist/utils/kv-cache.test.mjs +1 -1
  96. package/dist/utils/mod.cjs +1 -1
  97. package/dist/utils/mod.d.cts +1 -1
  98. package/dist/utils/mod.d.ts +1 -1
  99. package/dist/utils/mod.js +1 -1
  100. package/package.json +6 -6
  101. package/dist/ld-B6RQHcnq.mjs +0 -658
@@ -17,7 +17,7 @@ json_canon = require_rolldown_runtime.__toESM(json_canon, 1);
17
17
  let _opentelemetry_semantic_conventions = require("@opentelemetry/semantic-conventions");
18
18
  //#region deno.json
19
19
  var name = "@fedify/fedify";
20
- var version = "2.5.0-dev.2364+4d9b5f4d";
20
+ var version = "2.5.0-dev.2378+fea9c751";
21
21
  //#endregion
22
22
  //#region src/sig/portable-key-id.ts
23
23
  const COMPATIBLE_KEY_ID_PATH_PATTERN = /^\/\.well-known\/apgateway\/did(?::|%3A)/i;
@@ -4998,6 +4998,65 @@ async function parseKeyOwnerEvidence(evidence, options = {}) {
4998
4998
  //#endregion
4999
4999
  //#region src/sig/key.ts
5000
5000
  const Temporal$2 = Temporal$4;
5001
+ /** Classifies decoding failures without hiding unexpected loader errors. */
5002
+ function classifyKeyJsonLdError(error, seen = /* @__PURE__ */ new Set()) {
5003
+ if (!(error instanceof Error) || !error.name.startsWith("jsonld.")) return null;
5004
+ if (seen.has(error)) throw error;
5005
+ seen.add(error);
5006
+ const details = error.details;
5007
+ if (typeof details?.code !== "string") return null;
5008
+ if (details.code !== "loading remote context failed" || !("cause" in details) && !("cause" in error)) return "invalid";
5009
+ const cause = "cause" in details ? details.cause : error.cause;
5010
+ const nestedFailure = classifyKeyJsonLdError(cause, seen);
5011
+ if (nestedFailure != null) return nestedFailure;
5012
+ if (cause instanceof SyntaxError) return "invalid";
5013
+ if (cause instanceof _fedify_vocab_runtime.FetchError || cause instanceof _fedify_vocab_runtime.UrlError) return "fetch";
5014
+ if (cause instanceof Error && [
5015
+ "AbortError",
5016
+ "TimeoutError",
5017
+ "NetworkError"
5018
+ ].includes(cause.name)) return "fetch";
5019
+ if (cause instanceof TypeError) {
5020
+ const urlCode = cause.code;
5021
+ if (cause.name === "InvalidContextReferenceError") return "invalid";
5022
+ if (urlCode === "ERR_INVALID_URL" || cause.message === "Invalid URL string." || /^Invalid URL(?::|$)/.test(cause.message) || / cannot be parsed as a URL\.?$/.test(cause.message)) return typeof details.url === "string" && /^[A-Za-z][A-Za-z0-9+.-]*:/.test(details.url) && !URL.canParse(details.url) ? "invalid" : "fetch";
5023
+ const networkCause = cause.cause;
5024
+ const code = cause.code ?? networkCause?.code;
5025
+ if (typeof code === "string" && [
5026
+ "ECONNREFUSED",
5027
+ "ECONNRESET",
5028
+ "ECONNABORTED",
5029
+ "ETIMEDOUT",
5030
+ "EHOSTUNREACH",
5031
+ "ENETUNREACH",
5032
+ "ENOTFOUND",
5033
+ "EAI_AGAIN",
5034
+ "UND_ERR_CONNECT_TIMEOUT",
5035
+ "UND_ERR_HEADERS_TIMEOUT",
5036
+ "UND_ERR_BODY_TIMEOUT",
5037
+ "UND_ERR_SOCKET"
5038
+ ].includes(code) || /^(fetch failed|Failed to fetch|error sending request|error reading a body from connection|Unable to connect|ConnectionRefused|Network connection lost|The socket connection was closed unexpectedly)/.test(cause.message)) return "fetch";
5039
+ }
5040
+ throw cause;
5041
+ }
5042
+ /** Carries a context transport failure through the key decoding boundary. */
5043
+ var KeyContextFetchError = class extends Error {
5044
+ error;
5045
+ constructor(error) {
5046
+ super("Failed to fetch a key's JSON-LD context.", { cause: error });
5047
+ this.error = error;
5048
+ }
5049
+ };
5050
+ function contextFetchError(error) {
5051
+ const seen = /* @__PURE__ */ new Set();
5052
+ while (error instanceof Error && !seen.has(error)) {
5053
+ seen.add(error);
5054
+ const details = error.details;
5055
+ if (!error.name.startsWith("jsonld.") || details?.code !== "loading remote context failed") break;
5056
+ error = "cause" in details ? details.cause : error.cause;
5057
+ }
5058
+ return new KeyContextFetchError(error);
5059
+ }
5001
5060
  /**
5002
5061
  * Checks if the given key is valid and supported. No-op if the key is valid,
5003
5062
  * otherwise throws an error.
@@ -5092,6 +5151,9 @@ async function importJwk(jwk, type) {
5092
5151
  * @internal
5093
5152
  */
5094
5153
  async function fetchActorDocument(actorId, options = {}) {
5154
+ return await fetchActorDocumentInternal(actorId, options, false);
5155
+ }
5156
+ async function fetchActorDocumentInternal(actorId, options, propagateContextFetchErrors) {
5095
5157
  const logger = (0, _logtape_logtape.getLogger)([
5096
5158
  "fedify",
5097
5159
  "sig",
@@ -5126,9 +5188,12 @@ async function fetchActorDocument(actorId, options = {}) {
5126
5188
  baseUrl: documentUrl
5127
5189
  });
5128
5190
  } catch (error) {
5129
- if (!(error instanceof TypeError)) throw error;
5130
- logger.debug("The document served at {documentUrl} is not a valid object: {error}", {
5191
+ const failure = classifyKeyJsonLdError(error);
5192
+ if (failure === "fetch" && propagateContextFetchErrors) throw contextFetchError(error);
5193
+ if (failure == null && !(error instanceof TypeError)) throw error;
5194
+ logger.debug("Failed to decode the actor document at {documentUrl}: {error}", {
5131
5195
  documentUrl: documentUrl.href,
5196
+ failure: failure ?? "invalid",
5132
5197
  error
5133
5198
  });
5134
5199
  return null;
@@ -5174,6 +5239,9 @@ async function fetchActorDocument(actorId, options = {}) {
5174
5239
  * @internal
5175
5240
  */
5176
5241
  async function verifyKeyOwnership(key, options = {}) {
5242
+ return await verifyKeyOwnershipInternal(key, options, false);
5243
+ }
5244
+ async function verifyKeyOwnershipInternal(key, options, propagateContextFetchErrors) {
5177
5245
  const logger = (0, _logtape_logtape.getLogger)([
5178
5246
  "fedify",
5179
5247
  "sig",
@@ -5183,7 +5251,7 @@ async function verifyKeyOwnership(key, options = {}) {
5183
5251
  if (keyId == null) return null;
5184
5252
  const claimedOwnerId = key instanceof _fedify_vocab.CryptographicKey ? key.ownerId : key.controllerId;
5185
5253
  if (claimedOwnerId == null) return null;
5186
- const owner = await fetchActorDocument(claimedOwnerId, options);
5254
+ const owner = await fetchActorDocumentInternal(claimedOwnerId, options, propagateContextFetchErrors);
5187
5255
  if (owner == null) {
5188
5256
  logger.debug("The owner ({claimedOwnerId}) that key {keyId} claims could not be resolved.", {
5189
5257
  keyId: keyId.href,
@@ -5509,6 +5577,21 @@ async function resolveFetchedKey(document, cacheKey, documentUrl, keyId, cls, {
5509
5577
  tracerProvider
5510
5578
  });
5511
5579
  } catch (e) {
5580
+ const failure = classifyKeyJsonLdError(e);
5581
+ if (failure === "fetch") throw contextFetchError(e);
5582
+ if (failure != null) {
5583
+ logger.debug("Failed to decode key {keyId}: {error}", {
5584
+ keyId,
5585
+ failure,
5586
+ error: e
5587
+ });
5588
+ await keyCache?.set(cacheKey, null);
5589
+ await clearFetchErrorMetadata(cacheKey, keyCache);
5590
+ return {
5591
+ key: null,
5592
+ cached: false
5593
+ };
5594
+ }
5512
5595
  if (!(e instanceof TypeError)) throw e;
5513
5596
  try {
5514
5597
  object = await cls.fromJsonLd(document, {
@@ -5517,8 +5600,14 @@ async function resolveFetchedKey(document, cacheKey, documentUrl, keyId, cls, {
5517
5600
  tracerProvider
5518
5601
  });
5519
5602
  } catch (e) {
5520
- if (e instanceof TypeError) {
5521
- logger.debug("Failed to verify; key {keyId} returned an invalid object.", { keyId });
5603
+ const failure = classifyKeyJsonLdError(e);
5604
+ if (failure === "fetch") throw contextFetchError(e);
5605
+ if (failure != null || e instanceof TypeError) {
5606
+ logger.debug("Failed to decode key {keyId}: {error}", {
5607
+ keyId,
5608
+ failure: failure ?? "invalid",
5609
+ error: e
5610
+ });
5522
5611
  await keyCache?.set(cacheKey, null);
5523
5612
  await clearFetchErrorMetadata(cacheKey, keyCache);
5524
5613
  return {
@@ -5657,16 +5746,17 @@ async function resolveFetchedKey(document, cacheKey, documentUrl, keyId, cls, {
5657
5746
  }
5658
5747
  if (ownerDocument != null && claimedOwnerId == null) key = key instanceof _fedify_vocab.CryptographicKey ? key.clone({ owner: ownerDocument.id }) : key.clone({ controller: ownerDocument.id });
5659
5748
  else if (claimedOwnerId != null && claimedOwnerId.href !== ownerDocument?.id?.href) {
5660
- if (await verifyKeyOwnership(key, {
5749
+ if (await verifyKeyOwnershipInternal(key, {
5661
5750
  documentLoader,
5662
5751
  contextLoader,
5663
5752
  tracerProvider
5664
- }) == null) {
5753
+ }, true) == null) {
5665
5754
  logger.debug("Failed to verify; the owner {claimedOwnerId} that key {keyId} claims does not list the key as its own.", {
5666
5755
  keyId,
5667
5756
  claimedOwnerId: claimedOwnerId.href
5668
5757
  });
5669
5758
  await keyCache?.set(cacheKey, null);
5759
+ await clearFetchErrorMetadata(cacheKey, keyCache);
5670
5760
  return {
5671
5761
  key: null,
5672
5762
  cached: false
@@ -5743,9 +5833,17 @@ async function fetchKeyWithResult(cacheKey, cls, options, onCachedUnavailable, o
5743
5833
  outcome = classified;
5744
5834
  return errored;
5745
5835
  }
5746
- const resolved = await resolveFetchedKey(document, cacheKey, documentUrl, keyId, cls, options, logger);
5747
- outcome = { result: resolved.key != null ? "fetched" : "invalid" };
5748
- return resolved;
5836
+ try {
5837
+ const resolved = await resolveFetchedKey(document, cacheKey, documentUrl, keyId, cls, options, logger);
5838
+ outcome = { result: resolved.key != null ? "fetched" : "invalid" };
5839
+ return resolved;
5840
+ } catch (error) {
5841
+ if (!(error instanceof KeyContextFetchError)) throw error;
5842
+ const classified = classifyFetchError(error.error);
5843
+ const errored = await onFetchError(error.error, cacheKey, keyId, keyCache, logger);
5844
+ outcome = classified;
5845
+ return errored;
5846
+ }
5749
5847
  } finally {
5750
5848
  recordKeyLookup(options.meterProvider, {
5751
5849
  durationMs: getDurationMs(start),
@@ -7989,34 +8087,68 @@ async function preparePortableObjectProof(jsonLd, options) {
7989
8087
  };
7990
8088
  }
7991
8089
  /**
7992
- * Applies portable-object proof policy to one map-local cryptographic result.
8090
+ * Checks portable-object policy without resolving keys or verifying signatures.
7993
8091
  *
7994
8092
  * @internal
7995
8093
  */
7996
- async function verifyPortableObjectProofPolicy(jsonLd, key, options = {}) {
8094
+ async function preparePortableObjectProofPolicy(jsonLd, options = {}) {
7997
8095
  const policyOptions = {
7998
8096
  ...options,
7999
8097
  contextLoader: preloadedOnlyDocumentLoader
8000
8098
  };
8001
8099
  const prepared = await preparePortableObjectProof(jsonLd, policyOptions);
8002
- if (!prepared.prepared) return prepared.result;
8100
+ if (!prepared.prepared) return {
8101
+ prepared: false,
8102
+ result: prepared.result
8103
+ };
8003
8104
  const policyProof = prepared.proofs[0];
8004
8105
  const literalProof = isJsonLdNode(jsonLd) && isJsonLdNode(jsonLd.proof) ? (await parseRawProofCandidates(jsonLd, [jsonLd.proof], policyOptions, prepared.proofContextLoader))[0]?.proof : null;
8005
8106
  const verificationMethod = policyProof?.verificationMethodId;
8006
- if (prepared.proofs.length !== 1 || key == null || policyProof == null || literalProof == null || !sameProof(policyProof, literalProof) || verificationMethod == null || key.id?.href !== verificationMethod.href) return {
8107
+ if (prepared.proofs.length !== 1 || policyProof == null || literalProof == null || !sameProof(policyProof, literalProof) || verificationMethod == null) return {
8108
+ prepared: false,
8109
+ result: {
8110
+ verified: false,
8111
+ reason: {
8112
+ type: "invalidProof",
8113
+ proofIndex: prepared.proofs.length > 1 ? 1 : 0
8114
+ }
8115
+ }
8116
+ };
8117
+ return {
8118
+ prepared: true,
8119
+ verificationMethod,
8120
+ objectId: (0, _fedify_vocab_runtime.formatIri)(prepared.objectId)
8121
+ };
8122
+ }
8123
+ /**
8124
+ * Binds prepared portable-object policy to the map-local verified key.
8125
+ *
8126
+ * @internal
8127
+ */
8128
+ function verifyPreparedPortableObjectProofPolicy(prepared, key) {
8129
+ if (key == null || key.id?.href !== prepared.verificationMethod.href) return {
8007
8130
  verified: false,
8008
8131
  reason: {
8009
8132
  type: "invalidProof",
8010
- proofIndex: prepared.proofs.length > 1 ? 1 : 0
8133
+ proofIndex: 0
8011
8134
  }
8012
8135
  };
8013
8136
  return {
8014
8137
  verified: true,
8015
8138
  keys: [key],
8016
- objectId: (0, _fedify_vocab_runtime.formatIri)(prepared.objectId)
8139
+ objectId: prepared.objectId
8017
8140
  };
8018
8141
  }
8019
8142
  /**
8143
+ * Applies portable-object proof policy to one map-local cryptographic result.
8144
+ *
8145
+ * @internal
8146
+ */
8147
+ async function verifyPortableObjectProofPolicy(jsonLd, key, options = {}) {
8148
+ const prepared = await preparePortableObjectProofPolicy(jsonLd, options);
8149
+ return prepared.prepared ? verifyPreparedPortableObjectProofPolicy(prepared, key) : prepared.result;
8150
+ }
8151
+ /**
8020
8152
  * Verifies the FEP-ef61 Object Integrity Proof policy for a portable object.
8021
8153
  *
8022
8154
  * This applies the FEP-2277 core-type classification to the top-level JSON-LD
@@ -10412,6 +10544,12 @@ Object.defineProperty(exports, "preloadedOnlyDocumentLoader", {
10412
10544
  return preloadedOnlyDocumentLoader;
10413
10545
  }
10414
10546
  });
10547
+ Object.defineProperty(exports, "preparePortableObjectProofPolicy", {
10548
+ enumerable: true,
10549
+ get: function() {
10550
+ return preparePortableObjectProofPolicy;
10551
+ }
10552
+ });
10415
10553
  Object.defineProperty(exports, "recordCircuitBreakerStateChange", {
10416
10554
  enumerable: true,
10417
10555
  get: function() {
@@ -10592,6 +10730,12 @@ Object.defineProperty(exports, "verifyPortableObjectProofWithRoot", {
10592
10730
  return verifyPortableObjectProofWithRoot;
10593
10731
  }
10594
10732
  });
10733
+ Object.defineProperty(exports, "verifyPreparedPortableObjectProofPolicy", {
10734
+ enumerable: true,
10735
+ get: function() {
10736
+ return verifyPreparedPortableObjectProofPolicy;
10737
+ }
10738
+ });
10595
10739
  Object.defineProperty(exports, "verifyProof", {
10596
10740
  enumerable: true,
10597
10741
  get: function() {
@@ -1,7 +1,7 @@
1
1
  /// <reference lib="esnext.temporal" />
2
2
  import { Actor, CryptographicKey, DataIntegrityProof, Multikey, Object as Object$1 } from "@fedify/vocab";
3
- import { DocumentLoader, PortableObjectVerifier } from "@fedify/vocab-runtime";
4
3
  import { MeterProvider, TracerProvider } from "@opentelemetry/api";
4
+ import { DocumentLoader, PortableObjectVerifier } from "@fedify/vocab-runtime";
5
5
 
6
6
  //#region src/sig/proof.d.ts
7
7
  /**
@@ -272,7 +272,11 @@ type CompoundProofDiscoveryFailureReason = {
272
272
  type CompoundProofVerificationFailureReason = {
273
273
  /** A nested secured map does not carry its own JSON-LD context. */readonly type: "missingContext";
274
274
  } | {
275
- /** The direct proof is malformed, unsupported, or invalid. */readonly type: "invalidProof";
275
+ /**
276
+ * The direct proof is malformed, unsupported, invalid, or left unverified
277
+ * because the portable-object policy rejects its map.
278
+ */
279
+ readonly type: "invalidProof";
276
280
  };
277
281
  /** Why one portable map did not pass compound proof policy. */
278
282
  type CompoundPortableObjectFailureReason = CompoundProofVerificationFailureReason | VerifyPortableObjectProofFailureReason | {
@@ -1,7 +1,7 @@
1
1
  /// <reference lib="esnext.temporal" />
2
2
  import { Actor, CryptographicKey, DataIntegrityProof, Multikey, Object as Object$1 } from "@fedify/vocab";
3
- import { MeterProvider, TracerProvider } from "@opentelemetry/api";
4
3
  import { DocumentLoader, PortableObjectVerifier } from "@fedify/vocab-runtime";
4
+ import { MeterProvider, TracerProvider } from "@opentelemetry/api";
5
5
 
6
6
  //#region src/sig/proof.d.ts
7
7
  /**
@@ -272,7 +272,11 @@ type CompoundProofDiscoveryFailureReason = {
272
272
  type CompoundProofVerificationFailureReason = {
273
273
  /** A nested secured map does not carry its own JSON-LD context. */readonly type: "missingContext";
274
274
  } | {
275
- /** The direct proof is malformed, unsupported, or invalid. */readonly type: "invalidProof";
275
+ /**
276
+ * The direct proof is malformed, unsupported, invalid, or left unverified
277
+ * because the portable-object policy rejects its map.
278
+ */
279
+ readonly type: "invalidProof";
276
280
  };
277
281
  /** Why one portable map did not pass compound proof policy. */
278
282
  type CompoundPortableObjectFailureReason = CompoundProofVerificationFailureReason | VerifyPortableObjectProofFailureReason | {
@@ -1,6 +1,6 @@
1
1
  import { Temporal } from "temporal-polyfill";
2
2
  import { URLPattern } from "urlpattern-polyfill";
3
- import { G as validateCryptoKey, ot as recordDocumentCache, t as doubleKnock } from "./http-Cg5Yj_yk.js";
3
+ import { ct as recordDocumentCache, q as validateCryptoKey, t as doubleKnock } from "./http-Cmz7x6Iw.js";
4
4
  import { getLogger } from "@logtape/logtape";
5
5
  import { FetchError, UrlError, createActivityPubRequest, getRemoteDocument, logRequest, preloadedContexts, resolveDocumentLoaderTimeout, validatePublicUrl, withDocumentLoaderTimeout } from "@fedify/vocab-runtime";
6
6
  import { curry } from "es-toolkit";
@@ -1,5 +1,5 @@
1
1
  const { URLPattern } = require("urlpattern-polyfill");
2
- const require_http = require("./http-Btzv2JZU.cjs");
2
+ const require_http = require("./http-D1RPHoq3.cjs");
3
3
  let _logtape_logtape = require("@logtape/logtape");
4
4
  let _fedify_vocab_runtime = require("@fedify/vocab-runtime");
5
5
  let es_toolkit = require("es-toolkit");
@@ -1,7 +1,7 @@
1
1
  import { Temporal } from "temporal-polyfill";
2
2
  import { URLPattern } from "urlpattern-polyfill";
3
3
  globalThis.addEventListener = () => {};
4
- import { p as recordDocumentCache } from "./metrics-DUdlIyrB.mjs";
4
+ import { p as recordDocumentCache } from "./metrics-Dwgav7s_.mjs";
5
5
  import { getLogger } from "@logtape/logtape";
6
6
  import { preloadedContexts } from "@fedify/vocab-runtime";
7
7
  //#region src/utils/kv-cache.ts