@fedify/fedify 2.4.0-dev.2056 → 2.4.0-dev.2063

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 (71) hide show
  1. package/dist/{builder-D_XU_Fw2.mjs → builder-BzS4brdy.mjs} +2 -2
  2. package/dist/compat/transformers.test.mjs +1 -1
  3. package/dist/{compound-proof-CwTySDnn.mjs → compound-proof-BrSXP5so.mjs} +1 -1
  4. package/dist/{deno-BtpLWN2L.mjs → deno-CVZgG4sc.mjs} +1 -1
  5. package/dist/{docloader-CJADEtqb.mjs → docloader-DBb8z7_l.mjs} +2 -2
  6. package/dist/federation/builder.test.mjs +1 -1
  7. package/dist/federation/compound-fanout.test.mjs +3 -3
  8. package/dist/federation/handler-compound-proof.test.mjs +3 -3
  9. package/dist/federation/handler.test.mjs +5 -5
  10. package/dist/federation/hashlink-media.test.mjs +2 -2
  11. package/dist/federation/idempotency.test.mjs +2 -2
  12. package/dist/federation/metrics.test.mjs +1 -1
  13. package/dist/federation/middleware.test.mjs +7 -7
  14. package/dist/federation/mod.cjs +1 -1
  15. package/dist/federation/mod.js +1 -1
  16. package/dist/federation/outgoing-proof.test.mjs +5 -5
  17. package/dist/federation/portable.test.mjs +3 -3
  18. package/dist/federation/send.test.mjs +3 -3
  19. package/dist/federation/tasks/enqueue.test.mjs +1 -1
  20. package/dist/federation/tasks/tasks.test.mjs +2 -2
  21. package/dist/federation/temporal.test.mjs +1 -1
  22. package/dist/federation/webfinger.test.mjs +1 -1
  23. package/dist/{federation-DDwszIrk.cjs → federation-BrsIzNK5.cjs} +3 -3
  24. package/dist/{http-iLCx9vk-.js → http-99KVDtMr.js} +1 -1
  25. package/dist/{http-DW5mt8FG.cjs → http-CVjwUCCu.cjs} +1 -1
  26. package/dist/{http-CotELN-4.mjs → http-znjq5j6a.mjs} +3 -3
  27. package/dist/{key-DrCNkH3Y.mjs → key-BnMA6vpl.mjs} +2 -2
  28. package/dist/{kv-cache-a1ghEA4h.mjs → kv-cache--REpvHgG.mjs} +1 -1
  29. package/dist/{kv-cache-LOyq_Ty6.cjs → kv-cache-D2O0JspA.cjs} +1 -1
  30. package/dist/{kv-cache-bXLDSaRu.js → kv-cache-aijDx_jN.js} +1 -1
  31. package/dist/{ld-BPG92sC0.mjs → ld-BBVP8ock.mjs} +3 -3
  32. package/dist/{metrics-DxVi0UJD.mjs → metrics-B5spFq82.mjs} +1 -1
  33. package/dist/{middleware-BIPftTly.mjs → middleware-ClrGS1xy.mjs} +1 -1
  34. package/dist/{middleware-DohUu-Tz.mjs → middleware-Cw8EWwAT.mjs} +13 -13
  35. package/dist/{middleware-1nes8_U-.js → middleware-CzYM4cJI.js} +3 -3
  36. package/dist/{mod-CNRAxXEb.d.ts → mod-Dhm7SqyE.d.ts} +150 -2
  37. package/dist/{mod-CVQFWefn.d.cts → mod-pLbeNwcC.d.cts} +150 -2
  38. package/dist/mod.cjs +6 -5
  39. package/dist/mod.d.cts +3 -3
  40. package/dist/mod.d.ts +3 -3
  41. package/dist/mod.js +6 -6
  42. package/dist/nodeinfo/handler.test.mjs +1 -1
  43. package/dist/{owner-C2ER4VD7.cjs → owner-CHBQ0sSj.cjs} +34 -2
  44. package/dist/{owner-SBgt2USF.js → owner-Cu_KMvQN.js} +29 -3
  45. package/dist/{owner-BN7Mqjso.mjs → owner-Hc0hvbbX.mjs} +2 -2
  46. package/dist/{proof-BigVZwkl.mjs → proof-B69bJaSn.mjs} +32 -6
  47. package/dist/{send-CvatEhyY.mjs → send-BB5rBhvN.mjs} +3 -3
  48. package/dist/sig/compound-proof-discovery.test.mjs +1 -1
  49. package/dist/sig/compound-proof-producer.test.mjs +1 -1
  50. package/dist/sig/compound-proof-verification.test.mjs +2 -2
  51. package/dist/sig/compound-proof.test.mjs +2 -2
  52. package/dist/sig/http.test.mjs +2 -2
  53. package/dist/sig/key.test.mjs +1 -1
  54. package/dist/sig/ld.test.mjs +2 -2
  55. package/dist/sig/mod.cjs +4 -2
  56. package/dist/sig/mod.d.cts +2 -2
  57. package/dist/sig/mod.d.ts +2 -2
  58. package/dist/sig/mod.js +4 -3
  59. package/dist/sig/owner.test.mjs +1 -1
  60. package/dist/sig/portable-collection.test.d.mts +2 -0
  61. package/dist/sig/portable-collection.test.mjs +971 -0
  62. package/dist/sig/proof.test.mjs +3 -3
  63. package/dist/sig-B8WDBV-h.js +401 -0
  64. package/dist/sig-dut4BzEW.cjs +405 -0
  65. package/dist/{temporal-DV5jeBbR.mjs → temporal-CcRkOx3C.mjs} +1 -1
  66. package/dist/testing/kv.test.mjs +1 -1
  67. package/dist/utils/docloader.test.mjs +2 -2
  68. package/dist/utils/kv-cache.test.mjs +1 -1
  69. package/dist/utils/mod.cjs +1 -1
  70. package/dist/utils/mod.js +1 -1
  71. package/package.json +7 -7
@@ -2,7 +2,7 @@
2
2
  import { S as KeyCache } from "./http-65PYi9jY.js";
3
3
  import { CryptographicKey, DataIntegrityProof, Multikey, Object as Object$1 } from "@fedify/vocab";
4
4
  import { MeterProvider, TracerProvider } from "@opentelemetry/api";
5
- import { DocumentLoader } from "@fedify/vocab-runtime";
5
+ import { DocumentLoader, PortableObjectVerifierOptions } from "@fedify/vocab-runtime";
6
6
 
7
7
  //#region src/sig/ld.d.ts
8
8
  /**
@@ -382,4 +382,152 @@ declare function verifyObject<T extends Object$1>(cls: (new (...args: any[]) =>
382
382
  fromJsonLd(jsonLd: unknown, options: VerifyObjectOptions): Promise<T>;
383
383
  }, jsonLd: unknown, options?: VerifyObjectOptions): Promise<T | null>;
384
384
  //#endregion
385
- export { verifyJsonLd as C, signJsonLd as S, VerifySignatureOptions as _, VerifyPortableObjectProofOptions as a, detachSignature as b, createProof as c, verifyObject as d, verifyPortableObjectProof as f, VerifyJsonLdOptions as g, SignJsonLdOptions as h, VerifyPortableObjectProofFailureReason as i, hasProofLike as l, CreateSignatureOptions as m, SignObjectOptions as n, VerifyPortableObjectProofResult as o, verifyProof as p, VerifyObjectOptions as r, VerifyProofOptions as s, CreateProofOptions as t, signObject as u, attachSignature as v, verifySignature as w, hasSignatureLike as x, createSignature as y };
385
+ //#region src/sig/portable-collection.d.ts
386
+ /**
387
+ * Options for {@link verifyPortableObject}.
388
+ *
389
+ * Besides the options for {@link verifyPortableObjectProof}, it takes where
390
+ * the document came from, which property accessors pass automatically when
391
+ * `verifyPortableObject()` is used as their `verifyPortableObject` option.
392
+ * @since 2.4.0
393
+ */
394
+ interface VerifyPortableObjectOptions extends VerifyPortableObjectProofOptions, Omit<PortableObjectVerifierOptions, "documentLoader" | "contextLoader" | "tracerProvider"> {}
395
+ /**
396
+ * The reason why {@link verifyPortableObject} did not accept a document.
397
+ *
398
+ * Besides the reasons of {@link verifyPortableObjectProof}, it describes why
399
+ * an unsecured portable collection was not trusted. The
400
+ * `unsecuredCollection` reason itself never appears, since such collections
401
+ * are judged by the gateway trust policy instead.
402
+ * @since 2.4.0
403
+ */
404
+ type VerifyPortableObjectFailureReason = Exclude<VerifyPortableObjectProofFailureReason, {
405
+ readonly type: "unsecuredCollection";
406
+ }> | {
407
+ /**
408
+ * The unsecured collection was not retrieved from a gateway, i.e., the
409
+ * document's final URL is missing or is not a compatible identifier for
410
+ * the same portable collection.
411
+ */
412
+ readonly type: "unknownCollectionSource"; /** The final URL of the document, if known. */
413
+ readonly documentUrl: URL | null;
414
+ } | {
415
+ /**
416
+ * The actor that owns the unsecured collection cannot be determined
417
+ * unambiguously.
418
+ */
419
+ readonly type: "unknownCollectionOwner";
420
+ } | {
421
+ /** The collection, its pages, or its referrer disagree on its owner. */readonly type: "conflictingCollectionOwners"; /** The owner candidates that disagree. */
422
+ readonly candidates: readonly URL[];
423
+ } | {
424
+ /**
425
+ * A collection page does not belong to the collection it was reached
426
+ * from: its `partOf` names another collection, or its cryptographic
427
+ * origin differs.
428
+ */
429
+ readonly type: "collectionPageMismatch"; /** The page. */
430
+ readonly pageId: URL; /** The collection that the page was reached from. */
431
+ readonly collectionId: URL; /** The mismatching `partOf`, or `null` if the origin differs. */
432
+ readonly partOf: URL | null;
433
+ } | {
434
+ /**
435
+ * The owner's actor document could not be retrieved or verified, or it
436
+ * lists no gateways.
437
+ */
438
+ readonly type: "collectionOwnerUnavailable"; /** The owner candidate. */
439
+ readonly owner: URL;
440
+ } | {
441
+ /**
442
+ * The owner's actor document does not list the collection as its
443
+ * `inbox`, `outbox`, `followers`, `following`, or `liked`.
444
+ */
445
+ readonly type: "collectionNotListedByOwner"; /** The owner. */
446
+ readonly owner: URL; /** The collection. */
447
+ readonly collectionId: URL;
448
+ } | {
449
+ /**
450
+ * The unsecured collection was retrieved from a gateway that its owner
451
+ * does not list in its `gateways`.
452
+ */
453
+ readonly type: "untrustedGateway"; /** The owner. */
454
+ readonly owner: URL; /** The gateway that served the collection. */
455
+ readonly gateway: URL; /** The owner's gateways. */
456
+ readonly gateways: readonly URL[];
457
+ };
458
+ /**
459
+ * The result of {@link verifyPortableObject}.
460
+ * @since 2.4.0
461
+ */
462
+ type VerifyPortableObjectResult = {
463
+ /** Whether the document is accepted. */readonly verified: true; /** The document carries valid Object Integrity Proofs. */
464
+ readonly method: "proof"; /** The public keys used by the verified proofs, in proof order. */
465
+ readonly keys: readonly Multikey[];
466
+ /**
467
+ * Opaque state for verifying the pages of a portable collection. Do not
468
+ * inspect it; property accessors pass it back automatically.
469
+ */
470
+ readonly collectionContext?: unknown;
471
+ } | {
472
+ /** Whether the document is accepted. */readonly verified: true;
473
+ /**
474
+ * The document is an unsecured portable collection served by a gateway
475
+ * that its owner lists.
476
+ */
477
+ readonly method: "gateway"; /** The document has no integrity proof. */
478
+ readonly unsecured: true; /** The actor that owns the collection. */
479
+ readonly owner: URL; /** The gateway that served the collection. */
480
+ readonly gateway: URL;
481
+ /**
482
+ * Opaque state for verifying the pages of a portable collection. Do not
483
+ * inspect it; property accessors pass it back automatically.
484
+ */
485
+ readonly collectionContext: unknown;
486
+ } | {
487
+ /** Whether the document is accepted. */readonly verified: false; /** Why the document was not accepted. */
488
+ readonly reason: VerifyPortableObjectFailureReason;
489
+ };
490
+ /**
491
+ * Applies the [FEP-ef61] trust policy to a portable object fetched through
492
+ * a gateway.
493
+ *
494
+ * Portable actors, activities, objects, and collections with proofs are
495
+ * verified by {@link verifyPortableObjectProof}. A portable collection or
496
+ * collection page without a proof is accepted only if all of the following
497
+ * hold:
498
+ *
499
+ * - It was retrieved from a gateway: its final URL (`documentUrl`) is
500
+ * a compatible identifier for the same portable collection.
501
+ * - Its owner is determined unambiguously: the actor whose `inbox`,
502
+ * `outbox`, `followers`, `following`, or `liked` property referred to
503
+ * the collection, or the single actor in its `attributedTo`. A page
504
+ * inherits the owner of the collection it was reached from through
505
+ * `first`, `last`, `current`, `next`, or `prev`, and must not name
506
+ * another collection in `partOf`.
507
+ * - The owner's actor document is verified by its proof and lists the
508
+ * collection as its `inbox`, `outbox`, `followers`, `following`, or
509
+ * `liked`.
510
+ * - The gateway that served the collection is in the owner's `gateways`.
511
+ *
512
+ * Where the document came from and which object referred to it are passed
513
+ * by property accessors when this function is used as their
514
+ * `verifyPortableObject` option. Objects embedded in an unsecured
515
+ * collection accepted this way are not trusted: accessors dereference and
516
+ * verify them one by one.
517
+ *
518
+ * Note that acceptance through the gateway policy does not verify anything
519
+ * cryptographically; it only means that the owner trusts the gateway.
520
+ *
521
+ * [FEP-ef61]: https://w3id.org/fep/ef61
522
+ *
523
+ * @param jsonLd The JSON-LD document to verify.
524
+ * @param options Additional options. See also
525
+ * {@link VerifyPortableObjectOptions}.
526
+ * @returns The detailed result.
527
+ * @throws {TypeError} If the input is not a single JSON-LD object or has a
528
+ * malformed portable ID.
529
+ * @since 2.4.0
530
+ */
531
+ declare function verifyPortableObject(jsonLd: unknown, options?: VerifyPortableObjectOptions): Promise<VerifyPortableObjectResult>;
532
+ //#endregion
533
+ export { createSignature as C, verifyJsonLd as D, signJsonLd as E, verifySignature as O, attachSignature as S, hasSignatureLike as T, verifyProof as _, CreateProofOptions as a, VerifyJsonLdOptions as b, VerifyPortableObjectProofFailureReason as c, VerifyProofOptions as d, createProof as f, verifyPortableObjectProof as g, verifyObject as h, verifyPortableObject as i, VerifyPortableObjectProofOptions as l, signObject as m, VerifyPortableObjectOptions as n, SignObjectOptions as o, hasProofLike as p, VerifyPortableObjectResult as r, VerifyObjectOptions as s, VerifyPortableObjectFailureReason as t, VerifyPortableObjectProofResult as u, CreateSignatureOptions as v, detachSignature as w, VerifySignatureOptions as x, SignJsonLdOptions as y };
@@ -1,7 +1,7 @@
1
1
  /// <reference lib="esnext.temporal" />
2
2
  import { S as KeyCache } from "./http-CP-7OdSq.cjs";
3
3
  import { CryptographicKey, DataIntegrityProof, Multikey, Object as Object$1 } from "@fedify/vocab";
4
- import { DocumentLoader } from "@fedify/vocab-runtime";
4
+ import { DocumentLoader, PortableObjectVerifierOptions } from "@fedify/vocab-runtime";
5
5
  import { MeterProvider, TracerProvider } from "@opentelemetry/api";
6
6
 
7
7
  //#region src/sig/ld.d.ts
@@ -382,4 +382,152 @@ declare function verifyObject<T extends Object$1>(cls: (new (...args: any[]) =>
382
382
  fromJsonLd(jsonLd: unknown, options: VerifyObjectOptions): Promise<T>;
383
383
  }, jsonLd: unknown, options?: VerifyObjectOptions): Promise<T | null>;
384
384
  //#endregion
385
- export { verifyJsonLd as C, signJsonLd as S, VerifySignatureOptions as _, VerifyPortableObjectProofOptions as a, detachSignature as b, createProof as c, verifyObject as d, verifyPortableObjectProof as f, VerifyJsonLdOptions as g, SignJsonLdOptions as h, VerifyPortableObjectProofFailureReason as i, hasProofLike as l, CreateSignatureOptions as m, SignObjectOptions as n, VerifyPortableObjectProofResult as o, verifyProof as p, VerifyObjectOptions as r, VerifyProofOptions as s, CreateProofOptions as t, signObject as u, attachSignature as v, verifySignature as w, hasSignatureLike as x, createSignature as y };
385
+ //#region src/sig/portable-collection.d.ts
386
+ /**
387
+ * Options for {@link verifyPortableObject}.
388
+ *
389
+ * Besides the options for {@link verifyPortableObjectProof}, it takes where
390
+ * the document came from, which property accessors pass automatically when
391
+ * `verifyPortableObject()` is used as their `verifyPortableObject` option.
392
+ * @since 2.4.0
393
+ */
394
+ interface VerifyPortableObjectOptions extends VerifyPortableObjectProofOptions, Omit<PortableObjectVerifierOptions, "documentLoader" | "contextLoader" | "tracerProvider"> {}
395
+ /**
396
+ * The reason why {@link verifyPortableObject} did not accept a document.
397
+ *
398
+ * Besides the reasons of {@link verifyPortableObjectProof}, it describes why
399
+ * an unsecured portable collection was not trusted. The
400
+ * `unsecuredCollection` reason itself never appears, since such collections
401
+ * are judged by the gateway trust policy instead.
402
+ * @since 2.4.0
403
+ */
404
+ type VerifyPortableObjectFailureReason = Exclude<VerifyPortableObjectProofFailureReason, {
405
+ readonly type: "unsecuredCollection";
406
+ }> | {
407
+ /**
408
+ * The unsecured collection was not retrieved from a gateway, i.e., the
409
+ * document's final URL is missing or is not a compatible identifier for
410
+ * the same portable collection.
411
+ */
412
+ readonly type: "unknownCollectionSource"; /** The final URL of the document, if known. */
413
+ readonly documentUrl: URL | null;
414
+ } | {
415
+ /**
416
+ * The actor that owns the unsecured collection cannot be determined
417
+ * unambiguously.
418
+ */
419
+ readonly type: "unknownCollectionOwner";
420
+ } | {
421
+ /** The collection, its pages, or its referrer disagree on its owner. */readonly type: "conflictingCollectionOwners"; /** The owner candidates that disagree. */
422
+ readonly candidates: readonly URL[];
423
+ } | {
424
+ /**
425
+ * A collection page does not belong to the collection it was reached
426
+ * from: its `partOf` names another collection, or its cryptographic
427
+ * origin differs.
428
+ */
429
+ readonly type: "collectionPageMismatch"; /** The page. */
430
+ readonly pageId: URL; /** The collection that the page was reached from. */
431
+ readonly collectionId: URL; /** The mismatching `partOf`, or `null` if the origin differs. */
432
+ readonly partOf: URL | null;
433
+ } | {
434
+ /**
435
+ * The owner's actor document could not be retrieved or verified, or it
436
+ * lists no gateways.
437
+ */
438
+ readonly type: "collectionOwnerUnavailable"; /** The owner candidate. */
439
+ readonly owner: URL;
440
+ } | {
441
+ /**
442
+ * The owner's actor document does not list the collection as its
443
+ * `inbox`, `outbox`, `followers`, `following`, or `liked`.
444
+ */
445
+ readonly type: "collectionNotListedByOwner"; /** The owner. */
446
+ readonly owner: URL; /** The collection. */
447
+ readonly collectionId: URL;
448
+ } | {
449
+ /**
450
+ * The unsecured collection was retrieved from a gateway that its owner
451
+ * does not list in its `gateways`.
452
+ */
453
+ readonly type: "untrustedGateway"; /** The owner. */
454
+ readonly owner: URL; /** The gateway that served the collection. */
455
+ readonly gateway: URL; /** The owner's gateways. */
456
+ readonly gateways: readonly URL[];
457
+ };
458
+ /**
459
+ * The result of {@link verifyPortableObject}.
460
+ * @since 2.4.0
461
+ */
462
+ type VerifyPortableObjectResult = {
463
+ /** Whether the document is accepted. */readonly verified: true; /** The document carries valid Object Integrity Proofs. */
464
+ readonly method: "proof"; /** The public keys used by the verified proofs, in proof order. */
465
+ readonly keys: readonly Multikey[];
466
+ /**
467
+ * Opaque state for verifying the pages of a portable collection. Do not
468
+ * inspect it; property accessors pass it back automatically.
469
+ */
470
+ readonly collectionContext?: unknown;
471
+ } | {
472
+ /** Whether the document is accepted. */readonly verified: true;
473
+ /**
474
+ * The document is an unsecured portable collection served by a gateway
475
+ * that its owner lists.
476
+ */
477
+ readonly method: "gateway"; /** The document has no integrity proof. */
478
+ readonly unsecured: true; /** The actor that owns the collection. */
479
+ readonly owner: URL; /** The gateway that served the collection. */
480
+ readonly gateway: URL;
481
+ /**
482
+ * Opaque state for verifying the pages of a portable collection. Do not
483
+ * inspect it; property accessors pass it back automatically.
484
+ */
485
+ readonly collectionContext: unknown;
486
+ } | {
487
+ /** Whether the document is accepted. */readonly verified: false; /** Why the document was not accepted. */
488
+ readonly reason: VerifyPortableObjectFailureReason;
489
+ };
490
+ /**
491
+ * Applies the [FEP-ef61] trust policy to a portable object fetched through
492
+ * a gateway.
493
+ *
494
+ * Portable actors, activities, objects, and collections with proofs are
495
+ * verified by {@link verifyPortableObjectProof}. A portable collection or
496
+ * collection page without a proof is accepted only if all of the following
497
+ * hold:
498
+ *
499
+ * - It was retrieved from a gateway: its final URL (`documentUrl`) is
500
+ * a compatible identifier for the same portable collection.
501
+ * - Its owner is determined unambiguously: the actor whose `inbox`,
502
+ * `outbox`, `followers`, `following`, or `liked` property referred to
503
+ * the collection, or the single actor in its `attributedTo`. A page
504
+ * inherits the owner of the collection it was reached from through
505
+ * `first`, `last`, `current`, `next`, or `prev`, and must not name
506
+ * another collection in `partOf`.
507
+ * - The owner's actor document is verified by its proof and lists the
508
+ * collection as its `inbox`, `outbox`, `followers`, `following`, or
509
+ * `liked`.
510
+ * - The gateway that served the collection is in the owner's `gateways`.
511
+ *
512
+ * Where the document came from and which object referred to it are passed
513
+ * by property accessors when this function is used as their
514
+ * `verifyPortableObject` option. Objects embedded in an unsecured
515
+ * collection accepted this way are not trusted: accessors dereference and
516
+ * verify them one by one.
517
+ *
518
+ * Note that acceptance through the gateway policy does not verify anything
519
+ * cryptographically; it only means that the owner trusts the gateway.
520
+ *
521
+ * [FEP-ef61]: https://w3id.org/fep/ef61
522
+ *
523
+ * @param jsonLd The JSON-LD document to verify.
524
+ * @param options Additional options. See also
525
+ * {@link VerifyPortableObjectOptions}.
526
+ * @returns The detailed result.
527
+ * @throws {TypeError} If the input is not a single JSON-LD object or has a
528
+ * malformed portable ID.
529
+ * @since 2.4.0
530
+ */
531
+ declare function verifyPortableObject(jsonLd: unknown, options?: VerifyPortableObjectOptions): Promise<VerifyPortableObjectResult>;
532
+ //#endregion
533
+ export { createSignature as C, verifyJsonLd as D, signJsonLd as E, verifySignature as O, attachSignature as S, hasSignatureLike as T, verifyProof as _, CreateProofOptions as a, VerifyJsonLdOptions as b, VerifyPortableObjectProofFailureReason as c, VerifyProofOptions as d, createProof as f, verifyPortableObjectProof as g, verifyObject as h, verifyPortableObject as i, VerifyPortableObjectProofOptions as l, signObject as m, VerifyPortableObjectOptions as n, SignObjectOptions as o, hasProofLike as p, VerifyPortableObjectResult as r, VerifyObjectOptions as s, VerifyPortableObjectFailureReason as t, VerifyPortableObjectProofResult as u, CreateSignatureOptions as v, detachSignature as w, VerifySignatureOptions as x, SignJsonLdOptions as y };
package/dist/mod.cjs CHANGED
@@ -3,14 +3,14 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  require("./rolldown-runtime-Dmm3t92W.cjs");
4
4
  const require_transformers = require("./transformers-BalCrSsr.cjs");
5
5
  require("./compat/mod.cjs");
6
- const require_http = require("./http-DW5mt8FG.cjs");
7
- const require_federation = require("./federation-DDwszIrk.cjs");
6
+ const require_http = require("./http-CVjwUCCu.cjs");
7
+ const require_federation = require("./federation-BrsIzNK5.cjs");
8
8
  const require_types = require("./types-Be2zbyeG.cjs");
9
- const require_owner = require("./owner-C2ER4VD7.cjs");
10
- const require_kv_cache = require("./kv-cache-LOyq_Ty6.cjs");
9
+ const require_owner = require("./owner-CHBQ0sSj.cjs");
10
+ const require_kv_cache = require("./kv-cache-D2O0JspA.cjs");
11
11
  require("./nodeinfo/mod.cjs");
12
12
  require("./runtime/mod.cjs");
13
- require("./sig/mod.cjs");
13
+ const require_sig = require("./sig-dut4BzEW.cjs");
14
14
  require("./utils/mod.cjs");
15
15
  //#endregion
16
16
  exports.CircuitBreaker = require_federation.CircuitBreaker;
@@ -60,6 +60,7 @@ exports.signRequest = require_http.signRequest;
60
60
  exports.validateAcceptSignature = require_http.validateAcceptSignature;
61
61
  exports.verifyJsonLd = require_owner.verifyJsonLd;
62
62
  exports.verifyObject = require_owner.verifyObject;
63
+ exports.verifyPortableObject = require_sig.verifyPortableObject;
63
64
  exports.verifyPortableObjectProof = require_owner.verifyPortableObjectProof;
64
65
  exports.verifyProof = require_owner.verifyProof;
65
66
  exports.verifyRequest = require_http.verifyRequest;
package/dist/mod.d.cts CHANGED
@@ -6,13 +6,13 @@ import { $ as MessageQueue, A as ObjectCallbackSetters, At as InboxListener, B a
6
6
  import { a as MemoryKvStore, i as KvStoreSetOptions, n as KvStore, r as KvStoreListEntry, t as KvKey } from "./kv-BhNbN8Ed.cjs";
7
7
  import { actorDehydrator, autoIdAssigner, getDefaultActivityTransformers } from "./compat/mod.cjs";
8
8
  import { a as RouterOptions, i as RouterError, n as handleWebFinger, o as RouterRouteResult, r as Router, t as WebFingerHandlerParameters } from "./mod-Bfenkg_c.cjs";
9
- import { C as verifyJsonLd, S as signJsonLd, _ as VerifySignatureOptions, a as VerifyPortableObjectProofOptions, b as detachSignature, c as createProof, d as verifyObject, f as verifyPortableObjectProof, g as VerifyJsonLdOptions, h as SignJsonLdOptions, i as VerifyPortableObjectProofFailureReason, l as hasProofLike, m as CreateSignatureOptions, n as SignObjectOptions, o as VerifyPortableObjectProofResult, p as verifyProof, r as VerifyObjectOptions, s as VerifyProofOptions, t as CreateProofOptions, u as signObject, v as attachSignature, w as verifySignature, x as hasSignatureLike, y as createSignature } from "./mod-CVQFWefn.cjs";
9
+ import { C as createSignature, D as verifyJsonLd, E as signJsonLd, O as verifySignature, S as attachSignature, T as hasSignatureLike, _ as verifyProof, a as CreateProofOptions, b as VerifyJsonLdOptions, c as VerifyPortableObjectProofFailureReason, d as VerifyProofOptions, f as createProof, g as verifyPortableObjectProof, h as verifyObject, i as verifyPortableObject, l as VerifyPortableObjectProofOptions, m as signObject, n as VerifyPortableObjectOptions, o as SignObjectOptions, p as hasProofLike, r as VerifyPortableObjectResult, s as VerifyObjectOptions, t as VerifyPortableObjectFailureReason, u as VerifyPortableObjectProofResult, v as CreateSignatureOptions, w as detachSignature, x as VerifySignatureOptions, y as SignJsonLdOptions } from "./mod-pLbeNwcC.cjs";
10
10
  import { n as getAuthenticatedDocumentLoader, t as kvCache } from "./mod-CyiSjRkk.cjs";
11
11
  export * from "@fedify/vocab-runtime";
12
12
 
13
13
  //#region src/mod.d.ts
14
14
  declare namespace mod_d_exports {
15
- export { AcceptSignatureMember, AcceptSignatureParameters, ActivityTransformer, ActorAliasMapper, ActorCallbackSetters, ActorDispatcher, ActorHandleMapper, ActorKeyPair, ActorKeyPairsDispatcher, AuthorizePredicate, CircuitBreaker, CircuitBreakerActivityDrop, CircuitBreakerBeforeSendDecision, CircuitBreakerCreateOptions, CircuitBreakerFailurePolicy, CircuitBreakerKvState, CircuitBreakerOptions, CircuitBreakerState, CircuitBreakerStateChange, CollectionCallbackSetters, CollectionCounter, CollectionCursor, CollectionDispatcher, ConstructorWithTypeId, Context, CreateExponentialBackoffPolicyOptions, CreateProofOptions, CreateSignatureOptions, CustomCollectionCallbackSetters, CustomCollectionCounter, CustomCollectionCursor, CustomCollectionDispatcher, DoesActorOwnKeyOptions, Federatable, Federation, FederationBenchmarkOptions, FederationBuilder, FederationFetchOptions, FederationKvPrefixes, FederationOptions, FederationOrigin, FederationQueueOptions, FederationStartQueueOptions, FetchKeyDetailedResult, FetchKeyErrorResult, FetchKeyOptions, FetchKeyResult, ForwardActivityOptions, FulfillAcceptSignatureResult, GetActorOptions, GetKeyOwnerOptions, GetNodeInfoOptions, GetSignedKeyOptions, HashlinkMediaDispatcher, HashlinkMediaRequest, HttpMessageSignaturesSpec, HttpMessageSignaturesSpecDeterminer, IdempotencyKeyCallback, IdempotencyStrategy, InProcessMessageQueue, InProcessMessageQueueOptions, InboundService, InboxChallengePolicy, InboxContext, InboxErrorHandler, InboxListener, InboxListenerSetters, JsonValue, KeyCache, KvKey, KvStore, KvStoreListEntry, KvStoreSetOptions, MediaUploaderCallback, MediaUploaderSetters, MemoryKvStore, Message, MessageQueue, MessageQueueDepth, MessageQueueEnqueueOptions, MessageQueueListenOptions, NodeInfo, NodeInfoDispatcher, NormalizedCircuitBreakerOptions, ObjectAuthorizePredicate, ObjectCallbackSetters, ObjectDispatcher, OutboundService, OutboxContext, OutboxErrorHandler, OutboxListener, OutboxListenerErrorHandler, OutboxListenerSetters, OutboxPermanentFailureHandler, PageItems, ParallelMessageQueue, ParseNodeInfoOptions, ParseUriResult, PortableRequest, Protocol, RequestContext, RespondWithObjectOptions, RetryContext, RetryPolicy, Rfc6570Expression, Rfc9421SignRequestOptions, RouteActivityOptions, Router, RouterError, RouterOptions, RouterRouteResult, SendActivityError, SendActivityOptions, SendActivityOptionsForCollection, SenderKeyPair, Services, SharedInboxKeyDispatcher, SignJsonLdOptions, SignObjectOptions, SignRequestOptions, Software, TaskDefinition, TaskDefinitionOptions, TaskEnqueueOptions, TaskHandler, TaskRegistry, UnverifiedActivityHandler, UnverifiedActivityReason, Usage, VerifyJsonLdOptions, VerifyObjectOptions, VerifyPortableObjectProofFailureReason, VerifyPortableObjectProofOptions, VerifyPortableObjectProofResult, VerifyProofOptions, VerifyRequestDetailedResult, VerifyRequestFailureReason, VerifyRequestOptions, VerifySignatureOptions, WebFingerHandlerParameters, WebFingerLinksDispatcher, actorDehydrator, attachSignature, autoIdAssigner, buildCollectionSynchronizationHeader, createExponentialBackoffPolicy, createFederation, createFederationBuilder, createProof, createSignature, detachSignature, digest, doesActorOwnKey, exportJwk, fetchKey, fetchKeyDetailed, formatAcceptSignature, fulfillAcceptSignature, generateCryptoKeyPair, getAuthenticatedDocumentLoader, getDefaultActivityTransformers, getKeyOwner, getNodeInfo, handleWebFinger, hasProofLike, hasSignatureLike, importJwk, kvCache, nodeInfoToJson, normalizeCircuitBreakerOptions, parseAcceptSignature, parseCircuitBreakerKvState, parseNodeInfo, respondWithObject, respondWithObjectIfAcceptable, signJsonLd, signObject, signRequest, validateAcceptSignature, verifyJsonLd, verifyObject, verifyPortableObjectProof, verifyProof, verifyRequest, verifyRequestDetailed, verifySignature };
15
+ export { AcceptSignatureMember, AcceptSignatureParameters, ActivityTransformer, ActorAliasMapper, ActorCallbackSetters, ActorDispatcher, ActorHandleMapper, ActorKeyPair, ActorKeyPairsDispatcher, AuthorizePredicate, CircuitBreaker, CircuitBreakerActivityDrop, CircuitBreakerBeforeSendDecision, CircuitBreakerCreateOptions, CircuitBreakerFailurePolicy, CircuitBreakerKvState, CircuitBreakerOptions, CircuitBreakerState, CircuitBreakerStateChange, CollectionCallbackSetters, CollectionCounter, CollectionCursor, CollectionDispatcher, ConstructorWithTypeId, Context, CreateExponentialBackoffPolicyOptions, CreateProofOptions, CreateSignatureOptions, CustomCollectionCallbackSetters, CustomCollectionCounter, CustomCollectionCursor, CustomCollectionDispatcher, DoesActorOwnKeyOptions, Federatable, Federation, FederationBenchmarkOptions, FederationBuilder, FederationFetchOptions, FederationKvPrefixes, FederationOptions, FederationOrigin, FederationQueueOptions, FederationStartQueueOptions, FetchKeyDetailedResult, FetchKeyErrorResult, FetchKeyOptions, FetchKeyResult, ForwardActivityOptions, FulfillAcceptSignatureResult, GetActorOptions, GetKeyOwnerOptions, GetNodeInfoOptions, GetSignedKeyOptions, HashlinkMediaDispatcher, HashlinkMediaRequest, HttpMessageSignaturesSpec, HttpMessageSignaturesSpecDeterminer, IdempotencyKeyCallback, IdempotencyStrategy, InProcessMessageQueue, InProcessMessageQueueOptions, InboundService, InboxChallengePolicy, InboxContext, InboxErrorHandler, InboxListener, InboxListenerSetters, JsonValue, KeyCache, KvKey, KvStore, KvStoreListEntry, KvStoreSetOptions, MediaUploaderCallback, MediaUploaderSetters, MemoryKvStore, Message, MessageQueue, MessageQueueDepth, MessageQueueEnqueueOptions, MessageQueueListenOptions, NodeInfo, NodeInfoDispatcher, NormalizedCircuitBreakerOptions, ObjectAuthorizePredicate, ObjectCallbackSetters, ObjectDispatcher, OutboundService, OutboxContext, OutboxErrorHandler, OutboxListener, OutboxListenerErrorHandler, OutboxListenerSetters, OutboxPermanentFailureHandler, PageItems, ParallelMessageQueue, ParseNodeInfoOptions, ParseUriResult, PortableRequest, Protocol, RequestContext, RespondWithObjectOptions, RetryContext, RetryPolicy, Rfc6570Expression, Rfc9421SignRequestOptions, RouteActivityOptions, Router, RouterError, RouterOptions, RouterRouteResult, SendActivityError, SendActivityOptions, SendActivityOptionsForCollection, SenderKeyPair, Services, SharedInboxKeyDispatcher, SignJsonLdOptions, SignObjectOptions, SignRequestOptions, Software, TaskDefinition, TaskDefinitionOptions, TaskEnqueueOptions, TaskHandler, TaskRegistry, UnverifiedActivityHandler, UnverifiedActivityReason, Usage, VerifyJsonLdOptions, VerifyObjectOptions, VerifyPortableObjectFailureReason, VerifyPortableObjectOptions, VerifyPortableObjectProofFailureReason, VerifyPortableObjectProofOptions, VerifyPortableObjectProofResult, VerifyPortableObjectResult, VerifyProofOptions, VerifyRequestDetailedResult, VerifyRequestFailureReason, VerifyRequestOptions, VerifySignatureOptions, WebFingerHandlerParameters, WebFingerLinksDispatcher, actorDehydrator, attachSignature, autoIdAssigner, buildCollectionSynchronizationHeader, createExponentialBackoffPolicy, createFederation, createFederationBuilder, createProof, createSignature, detachSignature, digest, doesActorOwnKey, exportJwk, fetchKey, fetchKeyDetailed, formatAcceptSignature, fulfillAcceptSignature, generateCryptoKeyPair, getAuthenticatedDocumentLoader, getDefaultActivityTransformers, getKeyOwner, getNodeInfo, handleWebFinger, hasProofLike, hasSignatureLike, importJwk, kvCache, nodeInfoToJson, normalizeCircuitBreakerOptions, parseAcceptSignature, parseCircuitBreakerKvState, parseNodeInfo, respondWithObject, respondWithObjectIfAcceptable, signJsonLd, signObject, signRequest, validateAcceptSignature, verifyJsonLd, verifyObject, verifyPortableObject, verifyPortableObjectProof, verifyProof, verifyRequest, verifyRequestDetailed, verifySignature };
16
16
  }
17
17
  //#endregion
18
- export { AcceptSignatureMember, AcceptSignatureParameters, ActivityTransformer, ActorAliasMapper, ActorCallbackSetters, ActorDispatcher, ActorHandleMapper, ActorKeyPair, ActorKeyPairsDispatcher, AuthorizePredicate, CircuitBreaker, CircuitBreakerActivityDrop, CircuitBreakerBeforeSendDecision, CircuitBreakerCreateOptions, CircuitBreakerFailurePolicy, CircuitBreakerKvState, CircuitBreakerOptions, CircuitBreakerState, CircuitBreakerStateChange, CollectionCallbackSetters, CollectionCounter, CollectionCursor, CollectionDispatcher, ConstructorWithTypeId, Context, CreateExponentialBackoffPolicyOptions, CreateProofOptions, CreateSignatureOptions, CustomCollectionCallbackSetters, CustomCollectionCounter, CustomCollectionCursor, CustomCollectionDispatcher, DoesActorOwnKeyOptions, Federatable, Federation, FederationBenchmarkOptions, FederationBuilder, FederationFetchOptions, FederationKvPrefixes, FederationOptions, FederationOrigin, FederationQueueOptions, FederationStartQueueOptions, FetchKeyDetailedResult, FetchKeyErrorResult, FetchKeyOptions, FetchKeyResult, ForwardActivityOptions, FulfillAcceptSignatureResult, GetActorOptions, GetKeyOwnerOptions, GetNodeInfoOptions, GetSignedKeyOptions, HashlinkMediaDispatcher, HashlinkMediaRequest, HttpMessageSignaturesSpec, HttpMessageSignaturesSpecDeterminer, IdempotencyKeyCallback, IdempotencyStrategy, InProcessMessageQueue, InProcessMessageQueueOptions, InboundService, InboxChallengePolicy, InboxContext, InboxErrorHandler, InboxListener, InboxListenerSetters, JsonValue, KeyCache, KvKey, KvStore, KvStoreListEntry, KvStoreSetOptions, MediaUploaderCallback, MediaUploaderSetters, MemoryKvStore, Message, MessageQueue, MessageQueueDepth, MessageQueueEnqueueOptions, MessageQueueListenOptions, NodeInfo, NodeInfoDispatcher, NormalizedCircuitBreakerOptions, ObjectAuthorizePredicate, ObjectCallbackSetters, ObjectDispatcher, OutboundService, OutboxContext, OutboxErrorHandler, OutboxListener, OutboxListenerErrorHandler, OutboxListenerSetters, OutboxPermanentFailureHandler, PageItems, ParallelMessageQueue, ParseNodeInfoOptions, ParseUriResult, PortableRequest, Protocol, RequestContext, RespondWithObjectOptions, RetryContext, RetryPolicy, Rfc6570Expression, Rfc9421SignRequestOptions, RouteActivityOptions, Router, RouterError, RouterOptions, RouterRouteResult, SendActivityError, SendActivityOptions, SendActivityOptionsForCollection, SenderKeyPair, Services, SharedInboxKeyDispatcher, SignJsonLdOptions, SignObjectOptions, SignRequestOptions, Software, TaskDefinition, TaskDefinitionOptions, TaskEnqueueOptions, TaskHandler, TaskRegistry, UnverifiedActivityHandler, UnverifiedActivityReason, Usage, VerifyJsonLdOptions, VerifyObjectOptions, VerifyPortableObjectProofFailureReason, VerifyPortableObjectProofOptions, VerifyPortableObjectProofResult, VerifyProofOptions, VerifyRequestDetailedResult, VerifyRequestFailureReason, VerifyRequestOptions, VerifySignatureOptions, WebFingerHandlerParameters, WebFingerLinksDispatcher, actorDehydrator, attachSignature, autoIdAssigner, buildCollectionSynchronizationHeader, createExponentialBackoffPolicy, createFederation, createFederationBuilder, createProof, createSignature, detachSignature, digest, doesActorOwnKey, exportJwk, fetchKey, fetchKeyDetailed, formatAcceptSignature, fulfillAcceptSignature, generateCryptoKeyPair, getAuthenticatedDocumentLoader, getDefaultActivityTransformers, getKeyOwner, getNodeInfo, handleWebFinger, hasProofLike, hasSignatureLike, importJwk, kvCache, nodeInfoToJson, normalizeCircuitBreakerOptions, parseAcceptSignature, parseCircuitBreakerKvState, parseNodeInfo, respondWithObject, respondWithObjectIfAcceptable, signJsonLd, signObject, signRequest, validateAcceptSignature, verifyJsonLd, verifyObject, verifyPortableObjectProof, verifyProof, verifyRequest, verifyRequestDetailed, verifySignature };
18
+ export { AcceptSignatureMember, AcceptSignatureParameters, ActivityTransformer, ActorAliasMapper, ActorCallbackSetters, ActorDispatcher, ActorHandleMapper, ActorKeyPair, ActorKeyPairsDispatcher, AuthorizePredicate, CircuitBreaker, CircuitBreakerActivityDrop, CircuitBreakerBeforeSendDecision, CircuitBreakerCreateOptions, CircuitBreakerFailurePolicy, CircuitBreakerKvState, CircuitBreakerOptions, CircuitBreakerState, CircuitBreakerStateChange, CollectionCallbackSetters, CollectionCounter, CollectionCursor, CollectionDispatcher, ConstructorWithTypeId, Context, CreateExponentialBackoffPolicyOptions, CreateProofOptions, CreateSignatureOptions, CustomCollectionCallbackSetters, CustomCollectionCounter, CustomCollectionCursor, CustomCollectionDispatcher, DoesActorOwnKeyOptions, Federatable, Federation, FederationBenchmarkOptions, FederationBuilder, FederationFetchOptions, FederationKvPrefixes, FederationOptions, FederationOrigin, FederationQueueOptions, FederationStartQueueOptions, FetchKeyDetailedResult, FetchKeyErrorResult, FetchKeyOptions, FetchKeyResult, ForwardActivityOptions, FulfillAcceptSignatureResult, GetActorOptions, GetKeyOwnerOptions, GetNodeInfoOptions, GetSignedKeyOptions, HashlinkMediaDispatcher, HashlinkMediaRequest, HttpMessageSignaturesSpec, HttpMessageSignaturesSpecDeterminer, IdempotencyKeyCallback, IdempotencyStrategy, InProcessMessageQueue, InProcessMessageQueueOptions, InboundService, InboxChallengePolicy, InboxContext, InboxErrorHandler, InboxListener, InboxListenerSetters, JsonValue, KeyCache, KvKey, KvStore, KvStoreListEntry, KvStoreSetOptions, MediaUploaderCallback, MediaUploaderSetters, MemoryKvStore, Message, MessageQueue, MessageQueueDepth, MessageQueueEnqueueOptions, MessageQueueListenOptions, NodeInfo, NodeInfoDispatcher, NormalizedCircuitBreakerOptions, ObjectAuthorizePredicate, ObjectCallbackSetters, ObjectDispatcher, OutboundService, OutboxContext, OutboxErrorHandler, OutboxListener, OutboxListenerErrorHandler, OutboxListenerSetters, OutboxPermanentFailureHandler, PageItems, ParallelMessageQueue, ParseNodeInfoOptions, ParseUriResult, PortableRequest, Protocol, RequestContext, RespondWithObjectOptions, RetryContext, RetryPolicy, Rfc6570Expression, Rfc9421SignRequestOptions, RouteActivityOptions, Router, RouterError, RouterOptions, RouterRouteResult, SendActivityError, SendActivityOptions, SendActivityOptionsForCollection, SenderKeyPair, Services, SharedInboxKeyDispatcher, SignJsonLdOptions, SignObjectOptions, SignRequestOptions, Software, TaskDefinition, TaskDefinitionOptions, TaskEnqueueOptions, TaskHandler, TaskRegistry, UnverifiedActivityHandler, UnverifiedActivityReason, Usage, VerifyJsonLdOptions, VerifyObjectOptions, VerifyPortableObjectFailureReason, VerifyPortableObjectOptions, VerifyPortableObjectProofFailureReason, VerifyPortableObjectProofOptions, VerifyPortableObjectProofResult, VerifyPortableObjectResult, VerifyProofOptions, VerifyRequestDetailedResult, VerifyRequestFailureReason, VerifyRequestOptions, VerifySignatureOptions, WebFingerHandlerParameters, WebFingerLinksDispatcher, actorDehydrator, attachSignature, autoIdAssigner, buildCollectionSynchronizationHeader, createExponentialBackoffPolicy, createFederation, createFederationBuilder, createProof, createSignature, detachSignature, digest, doesActorOwnKey, exportJwk, fetchKey, fetchKeyDetailed, formatAcceptSignature, fulfillAcceptSignature, generateCryptoKeyPair, getAuthenticatedDocumentLoader, getDefaultActivityTransformers, getKeyOwner, getNodeInfo, handleWebFinger, hasProofLike, hasSignatureLike, importJwk, kvCache, nodeInfoToJson, normalizeCircuitBreakerOptions, parseAcceptSignature, parseCircuitBreakerKvState, parseNodeInfo, respondWithObject, respondWithObjectIfAcceptable, signJsonLd, signObject, signRequest, validateAcceptSignature, verifyJsonLd, verifyObject, verifyPortableObject, verifyPortableObjectProof, verifyProof, verifyRequest, verifyRequestDetailed, verifySignature };
package/dist/mod.d.ts CHANGED
@@ -6,13 +6,13 @@ import { $ as MessageQueue, A as ObjectCallbackSetters, At as InboxListener, B a
6
6
  import { a as MemoryKvStore, i as KvStoreSetOptions, n as KvStore, r as KvStoreListEntry, t as KvKey } from "./kv-BhNbN8Ed.js";
7
7
  import { actorDehydrator, autoIdAssigner, getDefaultActivityTransformers } from "./compat/mod.js";
8
8
  import { a as RouterOptions, i as RouterError, n as handleWebFinger, o as RouterRouteResult, r as Router, t as WebFingerHandlerParameters } from "./mod-BhMvsgdF.js";
9
- import { C as verifyJsonLd, S as signJsonLd, _ as VerifySignatureOptions, a as VerifyPortableObjectProofOptions, b as detachSignature, c as createProof, d as verifyObject, f as verifyPortableObjectProof, g as VerifyJsonLdOptions, h as SignJsonLdOptions, i as VerifyPortableObjectProofFailureReason, l as hasProofLike, m as CreateSignatureOptions, n as SignObjectOptions, o as VerifyPortableObjectProofResult, p as verifyProof, r as VerifyObjectOptions, s as VerifyProofOptions, t as CreateProofOptions, u as signObject, v as attachSignature, w as verifySignature, x as hasSignatureLike, y as createSignature } from "./mod-CNRAxXEb.js";
9
+ import { C as createSignature, D as verifyJsonLd, E as signJsonLd, O as verifySignature, S as attachSignature, T as hasSignatureLike, _ as verifyProof, a as CreateProofOptions, b as VerifyJsonLdOptions, c as VerifyPortableObjectProofFailureReason, d as VerifyProofOptions, f as createProof, g as verifyPortableObjectProof, h as verifyObject, i as verifyPortableObject, l as VerifyPortableObjectProofOptions, m as signObject, n as VerifyPortableObjectOptions, o as SignObjectOptions, p as hasProofLike, r as VerifyPortableObjectResult, s as VerifyObjectOptions, t as VerifyPortableObjectFailureReason, u as VerifyPortableObjectProofResult, v as CreateSignatureOptions, w as detachSignature, x as VerifySignatureOptions, y as SignJsonLdOptions } from "./mod-Dhm7SqyE.js";
10
10
  import { n as getAuthenticatedDocumentLoader, t as kvCache } from "./mod-C0BYc0OU.js";
11
11
  export * from "@fedify/vocab-runtime";
12
12
 
13
13
  //#region src/mod.d.ts
14
14
  declare namespace mod_d_exports {
15
- export { AcceptSignatureMember, AcceptSignatureParameters, ActivityTransformer, ActorAliasMapper, ActorCallbackSetters, ActorDispatcher, ActorHandleMapper, ActorKeyPair, ActorKeyPairsDispatcher, AuthorizePredicate, CircuitBreaker, CircuitBreakerActivityDrop, CircuitBreakerBeforeSendDecision, CircuitBreakerCreateOptions, CircuitBreakerFailurePolicy, CircuitBreakerKvState, CircuitBreakerOptions, CircuitBreakerState, CircuitBreakerStateChange, CollectionCallbackSetters, CollectionCounter, CollectionCursor, CollectionDispatcher, ConstructorWithTypeId, Context, CreateExponentialBackoffPolicyOptions, CreateProofOptions, CreateSignatureOptions, CustomCollectionCallbackSetters, CustomCollectionCounter, CustomCollectionCursor, CustomCollectionDispatcher, DoesActorOwnKeyOptions, Federatable, Federation, FederationBenchmarkOptions, FederationBuilder, FederationFetchOptions, FederationKvPrefixes, FederationOptions, FederationOrigin, FederationQueueOptions, FederationStartQueueOptions, FetchKeyDetailedResult, FetchKeyErrorResult, FetchKeyOptions, FetchKeyResult, ForwardActivityOptions, FulfillAcceptSignatureResult, GetActorOptions, GetKeyOwnerOptions, GetNodeInfoOptions, GetSignedKeyOptions, HashlinkMediaDispatcher, HashlinkMediaRequest, HttpMessageSignaturesSpec, HttpMessageSignaturesSpecDeterminer, IdempotencyKeyCallback, IdempotencyStrategy, InProcessMessageQueue, InProcessMessageQueueOptions, InboundService, InboxChallengePolicy, InboxContext, InboxErrorHandler, InboxListener, InboxListenerSetters, JsonValue, KeyCache, KvKey, KvStore, KvStoreListEntry, KvStoreSetOptions, MediaUploaderCallback, MediaUploaderSetters, MemoryKvStore, Message, MessageQueue, MessageQueueDepth, MessageQueueEnqueueOptions, MessageQueueListenOptions, NodeInfo, NodeInfoDispatcher, NormalizedCircuitBreakerOptions, ObjectAuthorizePredicate, ObjectCallbackSetters, ObjectDispatcher, OutboundService, OutboxContext, OutboxErrorHandler, OutboxListener, OutboxListenerErrorHandler, OutboxListenerSetters, OutboxPermanentFailureHandler, PageItems, ParallelMessageQueue, ParseNodeInfoOptions, ParseUriResult, PortableRequest, Protocol, RequestContext, RespondWithObjectOptions, RetryContext, RetryPolicy, Rfc6570Expression, Rfc9421SignRequestOptions, RouteActivityOptions, Router, RouterError, RouterOptions, RouterRouteResult, SendActivityError, SendActivityOptions, SendActivityOptionsForCollection, SenderKeyPair, Services, SharedInboxKeyDispatcher, SignJsonLdOptions, SignObjectOptions, SignRequestOptions, Software, TaskDefinition, TaskDefinitionOptions, TaskEnqueueOptions, TaskHandler, TaskRegistry, UnverifiedActivityHandler, UnverifiedActivityReason, Usage, VerifyJsonLdOptions, VerifyObjectOptions, VerifyPortableObjectProofFailureReason, VerifyPortableObjectProofOptions, VerifyPortableObjectProofResult, VerifyProofOptions, VerifyRequestDetailedResult, VerifyRequestFailureReason, VerifyRequestOptions, VerifySignatureOptions, WebFingerHandlerParameters, WebFingerLinksDispatcher, actorDehydrator, attachSignature, autoIdAssigner, buildCollectionSynchronizationHeader, createExponentialBackoffPolicy, createFederation, createFederationBuilder, createProof, createSignature, detachSignature, digest, doesActorOwnKey, exportJwk, fetchKey, fetchKeyDetailed, formatAcceptSignature, fulfillAcceptSignature, generateCryptoKeyPair, getAuthenticatedDocumentLoader, getDefaultActivityTransformers, getKeyOwner, getNodeInfo, handleWebFinger, hasProofLike, hasSignatureLike, importJwk, kvCache, nodeInfoToJson, normalizeCircuitBreakerOptions, parseAcceptSignature, parseCircuitBreakerKvState, parseNodeInfo, respondWithObject, respondWithObjectIfAcceptable, signJsonLd, signObject, signRequest, validateAcceptSignature, verifyJsonLd, verifyObject, verifyPortableObjectProof, verifyProof, verifyRequest, verifyRequestDetailed, verifySignature };
15
+ export { AcceptSignatureMember, AcceptSignatureParameters, ActivityTransformer, ActorAliasMapper, ActorCallbackSetters, ActorDispatcher, ActorHandleMapper, ActorKeyPair, ActorKeyPairsDispatcher, AuthorizePredicate, CircuitBreaker, CircuitBreakerActivityDrop, CircuitBreakerBeforeSendDecision, CircuitBreakerCreateOptions, CircuitBreakerFailurePolicy, CircuitBreakerKvState, CircuitBreakerOptions, CircuitBreakerState, CircuitBreakerStateChange, CollectionCallbackSetters, CollectionCounter, CollectionCursor, CollectionDispatcher, ConstructorWithTypeId, Context, CreateExponentialBackoffPolicyOptions, CreateProofOptions, CreateSignatureOptions, CustomCollectionCallbackSetters, CustomCollectionCounter, CustomCollectionCursor, CustomCollectionDispatcher, DoesActorOwnKeyOptions, Federatable, Federation, FederationBenchmarkOptions, FederationBuilder, FederationFetchOptions, FederationKvPrefixes, FederationOptions, FederationOrigin, FederationQueueOptions, FederationStartQueueOptions, FetchKeyDetailedResult, FetchKeyErrorResult, FetchKeyOptions, FetchKeyResult, ForwardActivityOptions, FulfillAcceptSignatureResult, GetActorOptions, GetKeyOwnerOptions, GetNodeInfoOptions, GetSignedKeyOptions, HashlinkMediaDispatcher, HashlinkMediaRequest, HttpMessageSignaturesSpec, HttpMessageSignaturesSpecDeterminer, IdempotencyKeyCallback, IdempotencyStrategy, InProcessMessageQueue, InProcessMessageQueueOptions, InboundService, InboxChallengePolicy, InboxContext, InboxErrorHandler, InboxListener, InboxListenerSetters, JsonValue, KeyCache, KvKey, KvStore, KvStoreListEntry, KvStoreSetOptions, MediaUploaderCallback, MediaUploaderSetters, MemoryKvStore, Message, MessageQueue, MessageQueueDepth, MessageQueueEnqueueOptions, MessageQueueListenOptions, NodeInfo, NodeInfoDispatcher, NormalizedCircuitBreakerOptions, ObjectAuthorizePredicate, ObjectCallbackSetters, ObjectDispatcher, OutboundService, OutboxContext, OutboxErrorHandler, OutboxListener, OutboxListenerErrorHandler, OutboxListenerSetters, OutboxPermanentFailureHandler, PageItems, ParallelMessageQueue, ParseNodeInfoOptions, ParseUriResult, PortableRequest, Protocol, RequestContext, RespondWithObjectOptions, RetryContext, RetryPolicy, Rfc6570Expression, Rfc9421SignRequestOptions, RouteActivityOptions, Router, RouterError, RouterOptions, RouterRouteResult, SendActivityError, SendActivityOptions, SendActivityOptionsForCollection, SenderKeyPair, Services, SharedInboxKeyDispatcher, SignJsonLdOptions, SignObjectOptions, SignRequestOptions, Software, TaskDefinition, TaskDefinitionOptions, TaskEnqueueOptions, TaskHandler, TaskRegistry, UnverifiedActivityHandler, UnverifiedActivityReason, Usage, VerifyJsonLdOptions, VerifyObjectOptions, VerifyPortableObjectFailureReason, VerifyPortableObjectOptions, VerifyPortableObjectProofFailureReason, VerifyPortableObjectProofOptions, VerifyPortableObjectProofResult, VerifyPortableObjectResult, VerifyProofOptions, VerifyRequestDetailedResult, VerifyRequestFailureReason, VerifyRequestOptions, VerifySignatureOptions, WebFingerHandlerParameters, WebFingerLinksDispatcher, actorDehydrator, attachSignature, autoIdAssigner, buildCollectionSynchronizationHeader, createExponentialBackoffPolicy, createFederation, createFederationBuilder, createProof, createSignature, detachSignature, digest, doesActorOwnKey, exportJwk, fetchKey, fetchKeyDetailed, formatAcceptSignature, fulfillAcceptSignature, generateCryptoKeyPair, getAuthenticatedDocumentLoader, getDefaultActivityTransformers, getKeyOwner, getNodeInfo, handleWebFinger, hasProofLike, hasSignatureLike, importJwk, kvCache, nodeInfoToJson, normalizeCircuitBreakerOptions, parseAcceptSignature, parseCircuitBreakerKvState, parseNodeInfo, respondWithObject, respondWithObjectIfAcceptable, signJsonLd, signObject, signRequest, validateAcceptSignature, verifyJsonLd, verifyObject, verifyPortableObject, verifyPortableObjectProof, verifyProof, verifyRequest, verifyRequestDetailed, verifySignature };
16
16
  }
17
17
  //#endregion
18
- export { AcceptSignatureMember, AcceptSignatureParameters, ActivityTransformer, ActorAliasMapper, ActorCallbackSetters, ActorDispatcher, ActorHandleMapper, ActorKeyPair, ActorKeyPairsDispatcher, AuthorizePredicate, CircuitBreaker, CircuitBreakerActivityDrop, CircuitBreakerBeforeSendDecision, CircuitBreakerCreateOptions, CircuitBreakerFailurePolicy, CircuitBreakerKvState, CircuitBreakerOptions, CircuitBreakerState, CircuitBreakerStateChange, CollectionCallbackSetters, CollectionCounter, CollectionCursor, CollectionDispatcher, ConstructorWithTypeId, Context, CreateExponentialBackoffPolicyOptions, CreateProofOptions, CreateSignatureOptions, CustomCollectionCallbackSetters, CustomCollectionCounter, CustomCollectionCursor, CustomCollectionDispatcher, DoesActorOwnKeyOptions, Federatable, Federation, FederationBenchmarkOptions, FederationBuilder, FederationFetchOptions, FederationKvPrefixes, FederationOptions, FederationOrigin, FederationQueueOptions, FederationStartQueueOptions, FetchKeyDetailedResult, FetchKeyErrorResult, FetchKeyOptions, FetchKeyResult, ForwardActivityOptions, FulfillAcceptSignatureResult, GetActorOptions, GetKeyOwnerOptions, GetNodeInfoOptions, GetSignedKeyOptions, HashlinkMediaDispatcher, HashlinkMediaRequest, HttpMessageSignaturesSpec, HttpMessageSignaturesSpecDeterminer, IdempotencyKeyCallback, IdempotencyStrategy, InProcessMessageQueue, InProcessMessageQueueOptions, InboundService, InboxChallengePolicy, InboxContext, InboxErrorHandler, InboxListener, InboxListenerSetters, JsonValue, KeyCache, KvKey, KvStore, KvStoreListEntry, KvStoreSetOptions, MediaUploaderCallback, MediaUploaderSetters, MemoryKvStore, Message, MessageQueue, MessageQueueDepth, MessageQueueEnqueueOptions, MessageQueueListenOptions, NodeInfo, NodeInfoDispatcher, NormalizedCircuitBreakerOptions, ObjectAuthorizePredicate, ObjectCallbackSetters, ObjectDispatcher, OutboundService, OutboxContext, OutboxErrorHandler, OutboxListener, OutboxListenerErrorHandler, OutboxListenerSetters, OutboxPermanentFailureHandler, PageItems, ParallelMessageQueue, ParseNodeInfoOptions, ParseUriResult, PortableRequest, Protocol, RequestContext, RespondWithObjectOptions, RetryContext, RetryPolicy, Rfc6570Expression, Rfc9421SignRequestOptions, RouteActivityOptions, Router, RouterError, RouterOptions, RouterRouteResult, SendActivityError, SendActivityOptions, SendActivityOptionsForCollection, SenderKeyPair, Services, SharedInboxKeyDispatcher, SignJsonLdOptions, SignObjectOptions, SignRequestOptions, Software, TaskDefinition, TaskDefinitionOptions, TaskEnqueueOptions, TaskHandler, TaskRegistry, UnverifiedActivityHandler, UnverifiedActivityReason, Usage, VerifyJsonLdOptions, VerifyObjectOptions, VerifyPortableObjectProofFailureReason, VerifyPortableObjectProofOptions, VerifyPortableObjectProofResult, VerifyProofOptions, VerifyRequestDetailedResult, VerifyRequestFailureReason, VerifyRequestOptions, VerifySignatureOptions, WebFingerHandlerParameters, WebFingerLinksDispatcher, actorDehydrator, attachSignature, autoIdAssigner, buildCollectionSynchronizationHeader, createExponentialBackoffPolicy, createFederation, createFederationBuilder, createProof, createSignature, detachSignature, digest, doesActorOwnKey, exportJwk, fetchKey, fetchKeyDetailed, formatAcceptSignature, fulfillAcceptSignature, generateCryptoKeyPair, getAuthenticatedDocumentLoader, getDefaultActivityTransformers, getKeyOwner, getNodeInfo, handleWebFinger, hasProofLike, hasSignatureLike, importJwk, kvCache, nodeInfoToJson, normalizeCircuitBreakerOptions, parseAcceptSignature, parseCircuitBreakerKvState, parseNodeInfo, respondWithObject, respondWithObjectIfAcceptable, signJsonLd, signObject, signRequest, validateAcceptSignature, verifyJsonLd, verifyObject, verifyPortableObjectProof, verifyProof, verifyRequest, verifyRequestDetailed, verifySignature };
18
+ export { AcceptSignatureMember, AcceptSignatureParameters, ActivityTransformer, ActorAliasMapper, ActorCallbackSetters, ActorDispatcher, ActorHandleMapper, ActorKeyPair, ActorKeyPairsDispatcher, AuthorizePredicate, CircuitBreaker, CircuitBreakerActivityDrop, CircuitBreakerBeforeSendDecision, CircuitBreakerCreateOptions, CircuitBreakerFailurePolicy, CircuitBreakerKvState, CircuitBreakerOptions, CircuitBreakerState, CircuitBreakerStateChange, CollectionCallbackSetters, CollectionCounter, CollectionCursor, CollectionDispatcher, ConstructorWithTypeId, Context, CreateExponentialBackoffPolicyOptions, CreateProofOptions, CreateSignatureOptions, CustomCollectionCallbackSetters, CustomCollectionCounter, CustomCollectionCursor, CustomCollectionDispatcher, DoesActorOwnKeyOptions, Federatable, Federation, FederationBenchmarkOptions, FederationBuilder, FederationFetchOptions, FederationKvPrefixes, FederationOptions, FederationOrigin, FederationQueueOptions, FederationStartQueueOptions, FetchKeyDetailedResult, FetchKeyErrorResult, FetchKeyOptions, FetchKeyResult, ForwardActivityOptions, FulfillAcceptSignatureResult, GetActorOptions, GetKeyOwnerOptions, GetNodeInfoOptions, GetSignedKeyOptions, HashlinkMediaDispatcher, HashlinkMediaRequest, HttpMessageSignaturesSpec, HttpMessageSignaturesSpecDeterminer, IdempotencyKeyCallback, IdempotencyStrategy, InProcessMessageQueue, InProcessMessageQueueOptions, InboundService, InboxChallengePolicy, InboxContext, InboxErrorHandler, InboxListener, InboxListenerSetters, JsonValue, KeyCache, KvKey, KvStore, KvStoreListEntry, KvStoreSetOptions, MediaUploaderCallback, MediaUploaderSetters, MemoryKvStore, Message, MessageQueue, MessageQueueDepth, MessageQueueEnqueueOptions, MessageQueueListenOptions, NodeInfo, NodeInfoDispatcher, NormalizedCircuitBreakerOptions, ObjectAuthorizePredicate, ObjectCallbackSetters, ObjectDispatcher, OutboundService, OutboxContext, OutboxErrorHandler, OutboxListener, OutboxListenerErrorHandler, OutboxListenerSetters, OutboxPermanentFailureHandler, PageItems, ParallelMessageQueue, ParseNodeInfoOptions, ParseUriResult, PortableRequest, Protocol, RequestContext, RespondWithObjectOptions, RetryContext, RetryPolicy, Rfc6570Expression, Rfc9421SignRequestOptions, RouteActivityOptions, Router, RouterError, RouterOptions, RouterRouteResult, SendActivityError, SendActivityOptions, SendActivityOptionsForCollection, SenderKeyPair, Services, SharedInboxKeyDispatcher, SignJsonLdOptions, SignObjectOptions, SignRequestOptions, Software, TaskDefinition, TaskDefinitionOptions, TaskEnqueueOptions, TaskHandler, TaskRegistry, UnverifiedActivityHandler, UnverifiedActivityReason, Usage, VerifyJsonLdOptions, VerifyObjectOptions, VerifyPortableObjectFailureReason, VerifyPortableObjectOptions, VerifyPortableObjectProofFailureReason, VerifyPortableObjectProofOptions, VerifyPortableObjectProofResult, VerifyPortableObjectResult, VerifyProofOptions, VerifyRequestDetailedResult, VerifyRequestFailureReason, VerifyRequestOptions, VerifySignatureOptions, WebFingerHandlerParameters, WebFingerLinksDispatcher, actorDehydrator, attachSignature, autoIdAssigner, buildCollectionSynchronizationHeader, createExponentialBackoffPolicy, createFederation, createFederationBuilder, createProof, createSignature, detachSignature, digest, doesActorOwnKey, exportJwk, fetchKey, fetchKeyDetailed, formatAcceptSignature, fulfillAcceptSignature, generateCryptoKeyPair, getAuthenticatedDocumentLoader, getDefaultActivityTransformers, getKeyOwner, getNodeInfo, handleWebFinger, hasProofLike, hasSignatureLike, importJwk, kvCache, nodeInfoToJson, normalizeCircuitBreakerOptions, parseAcceptSignature, parseCircuitBreakerKvState, parseNodeInfo, respondWithObject, respondWithObjectIfAcceptable, signJsonLd, signObject, signRequest, validateAcceptSignature, verifyJsonLd, verifyObject, verifyPortableObject, verifyPortableObjectProof, verifyProof, verifyRequest, verifyRequestDetailed, verifySignature };
package/dist/mod.js CHANGED
@@ -3,16 +3,16 @@ import { URLPattern } from "urlpattern-polyfill";
3
3
  import "./rolldown-runtime-BC-Eo5Mj.js";
4
4
  import { n as autoIdAssigner, r as getDefaultActivityTransformers, t as actorDehydrator } from "./transformers-DAtXl_Kc.js";
5
5
  import "./compat/mod.js";
6
- import { F as validateAcceptSignature, M as formatAcceptSignature, N as fulfillAcceptSignature, P as parseAcceptSignature, a as verifyRequestDetailed, c as fetchKey, d as importJwk, i as verifyRequest, l as fetchKeyDetailed, o as exportJwk, r as signRequest, u as generateCryptoKeyPair } from "./http-iLCx9vk-.js";
7
- import { a as respondWithObject, c as digest, d as parseCircuitBreakerKvState, f as createFederationBuilder, i as SendActivityError, l as CircuitBreaker, n as handleWebFinger, o as respondWithObjectIfAcceptable, r as createExponentialBackoffPolicy, s as buildCollectionSynchronizationHeader, t as createFederation, u as normalizeCircuitBreakerOptions } from "./middleware-1nes8_U-.js";
6
+ import { F as validateAcceptSignature, M as formatAcceptSignature, N as fulfillAcceptSignature, P as parseAcceptSignature, a as verifyRequestDetailed, c as fetchKey, d as importJwk, i as verifyRequest, l as fetchKeyDetailed, o as exportJwk, r as signRequest, u as generateCryptoKeyPair } from "./http-99KVDtMr.js";
7
+ import { a as respondWithObject, c as digest, d as parseCircuitBreakerKvState, f as createFederationBuilder, i as SendActivityError, l as CircuitBreaker, n as handleWebFinger, o as respondWithObjectIfAcceptable, r as createExponentialBackoffPolicy, s as buildCollectionSynchronizationHeader, t as createFederation, u as normalizeCircuitBreakerOptions } from "./middleware-CzYM4cJI.js";
8
8
  import { n as getNodeInfo, r as parseNodeInfo, t as nodeInfoToJson } from "./types-C_cNlNVK.js";
9
- import { S as signJsonLd, T as verifySignature, a as signObject, c as verifyPortableObjectProof, g as detachSignature, h as createSignature, i as hasProofLike, n as getKeyOwner, p as attachSignature, r as createProof, s as verifyObject, t as doesActorOwnKey, u as verifyProof, w as verifyJsonLd, y as hasSignatureLike } from "./owner-SBgt2USF.js";
10
- import { n as getAuthenticatedDocumentLoader, t as kvCache } from "./kv-cache-bXLDSaRu.js";
9
+ import { C as signJsonLd, E as verifySignature, T as verifyJsonLd, _ as detachSignature, a as signObject, b as hasSignatureLike, c as verifyPortableObjectProof, d as verifyProof, g as createSignature, i as hasProofLike, m as attachSignature, n as getKeyOwner, r as createProof, s as verifyObject, t as doesActorOwnKey } from "./owner-Cu_KMvQN.js";
10
+ import { n as getAuthenticatedDocumentLoader, t as kvCache } from "./kv-cache-aijDx_jN.js";
11
11
  import { InProcessMessageQueue, MemoryKvStore, ParallelMessageQueue, Router, RouterError } from "./federation/mod.js";
12
12
  import "./nodeinfo/mod.js";
13
13
  import "./runtime/mod.js";
14
- import "./sig/mod.js";
14
+ import { t as verifyPortableObject } from "./sig-B8WDBV-h.js";
15
15
  import "./utils/mod.js";
16
16
  export * from "@fedify/vocab-runtime";
17
17
  //#endregion
18
- export { CircuitBreaker, InProcessMessageQueue, MemoryKvStore, ParallelMessageQueue, Router, RouterError, SendActivityError, actorDehydrator, attachSignature, autoIdAssigner, buildCollectionSynchronizationHeader, createExponentialBackoffPolicy, createFederation, createFederationBuilder, createProof, createSignature, detachSignature, digest, doesActorOwnKey, exportJwk, fetchKey, fetchKeyDetailed, formatAcceptSignature, fulfillAcceptSignature, generateCryptoKeyPair, getAuthenticatedDocumentLoader, getDefaultActivityTransformers, getKeyOwner, getNodeInfo, handleWebFinger, hasProofLike, hasSignatureLike, importJwk, kvCache, nodeInfoToJson, normalizeCircuitBreakerOptions, parseAcceptSignature, parseCircuitBreakerKvState, parseNodeInfo, respondWithObject, respondWithObjectIfAcceptable, signJsonLd, signObject, signRequest, validateAcceptSignature, verifyJsonLd, verifyObject, verifyPortableObjectProof, verifyProof, verifyRequest, verifyRequestDetailed, verifySignature };
18
+ export { CircuitBreaker, InProcessMessageQueue, MemoryKvStore, ParallelMessageQueue, Router, RouterError, SendActivityError, actorDehydrator, attachSignature, autoIdAssigner, buildCollectionSynchronizationHeader, createExponentialBackoffPolicy, createFederation, createFederationBuilder, createProof, createSignature, detachSignature, digest, doesActorOwnKey, exportJwk, fetchKey, fetchKeyDetailed, formatAcceptSignature, fulfillAcceptSignature, generateCryptoKeyPair, getAuthenticatedDocumentLoader, getDefaultActivityTransformers, getKeyOwner, getNodeInfo, handleWebFinger, hasProofLike, hasSignatureLike, importJwk, kvCache, nodeInfoToJson, normalizeCircuitBreakerOptions, parseAcceptSignature, parseCircuitBreakerKvState, parseNodeInfo, respondWithObject, respondWithObjectIfAcceptable, signJsonLd, signObject, signRequest, validateAcceptSignature, verifyJsonLd, verifyObject, verifyPortableObject, verifyPortableObjectProof, verifyProof, verifyRequest, verifyRequestDetailed, verifySignature };
@@ -5,7 +5,7 @@ import { r as createRequestContext } from "../context-DG5QeQ8W.mjs";
5
5
  import { t as MemoryKvStore } from "../kv-DCHkaJ9-.mjs";
6
6
  import { t as assertEquals } from "../assert_equals-Z6IcEbWU.mjs";
7
7
  import "../std__assert-DvMDRPes.mjs";
8
- import { b as handleNodeInfoJrd, o as createFederation, y as handleNodeInfo } from "../middleware-DohUu-Tz.mjs";
8
+ import { b as handleNodeInfoJrd, o as createFederation, y as handleNodeInfo } from "../middleware-Cw8EWwAT.mjs";
9
9
  import { test } from "@fedify/fixture";
10
10
  //#region src/nodeinfo/handler.test.ts
11
11
  test("handleNodeInfo()", async () => {
@@ -1,6 +1,6 @@
1
1
  const { URLPattern } = require("urlpattern-polyfill");
2
2
  const require_rolldown_runtime = require("./rolldown-runtime-Dmm3t92W.cjs");
3
- const require_http = require("./http-DW5mt8FG.cjs");
3
+ const require_http = require("./http-CVjwUCCu.cjs");
4
4
  let _logtape_logtape = require("@logtape/logtape");
5
5
  let _fedify_vocab = require("@fedify/vocab");
6
6
  let _opentelemetry_api = require("@opentelemetry/api");
@@ -1794,6 +1794,8 @@ async function preparePortableObjectProof(jsonLd, options) {
1794
1794
  const proofValues = root[SECURITY_PROOF];
1795
1795
  if (proofValues == null || Array.isArray(proofValues) && proofValues.length < 1) return {
1796
1796
  prepared: false,
1797
+ root,
1798
+ objectType,
1797
1799
  result: objectType === "collection" ? {
1798
1800
  verified: false,
1799
1801
  reason: { type: "unsecuredCollection" }
@@ -1897,6 +1899,8 @@ async function preparePortableObjectProof(jsonLd, options) {
1897
1899
  }
1898
1900
  return {
1899
1901
  prepared: true,
1902
+ root,
1903
+ objectType,
1900
1904
  objectId,
1901
1905
  proofs,
1902
1906
  rawProofValues,
@@ -1951,8 +1955,30 @@ async function verifyPortableObjectProofPolicy(jsonLd, key, options = {}) {
1951
1955
  * @since 2.4.0
1952
1956
  */
1953
1957
  async function verifyPortableObjectProof(jsonLd, options = {}) {
1958
+ return (await verifyPortableObjectProofWithRoot(jsonLd, options)).result;
1959
+ }
1960
+ /**
1961
+ * Same as {@link verifyPortableObjectProof}, but also returns the expanded
1962
+ * root node and its FEP-2277 core type, so that a caller can apply further
1963
+ * policy, such as the gateway trust policy for unsecured collections, to the
1964
+ * same interpretation of the document.
1965
+ * @internal
1966
+ */
1967
+ async function verifyPortableObjectProofWithRoot(jsonLd, options = {}) {
1954
1968
  const prepared = await preparePortableObjectProof(jsonLd, options);
1955
- if (!prepared.prepared) return prepared.result;
1969
+ if (!prepared.prepared) return {
1970
+ result: prepared.result,
1971
+ ...prepared.root == null ? {} : { root: prepared.root },
1972
+ ...prepared.objectType == null ? {} : { objectType: prepared.objectType }
1973
+ };
1974
+ const { root, objectType } = prepared;
1975
+ return {
1976
+ result: await verifyPreparedPortableObjectProof(jsonLd, prepared, options),
1977
+ root,
1978
+ objectType
1979
+ };
1980
+ }
1981
+ async function verifyPreparedPortableObjectProof(jsonLd, prepared, options) {
1956
1982
  const { proofs, rawProofValues, proofContextLoader } = prepared;
1957
1983
  const keys = [];
1958
1984
  const rawProofCandidatePool = {
@@ -2394,6 +2420,12 @@ Object.defineProperty(exports, "verifyPortableObjectProofPolicy", {
2394
2420
  return verifyPortableObjectProofPolicy;
2395
2421
  }
2396
2422
  });
2423
+ Object.defineProperty(exports, "verifyPortableObjectProofWithRoot", {
2424
+ enumerable: true,
2425
+ get: function() {
2426
+ return verifyPortableObjectProofWithRoot;
2427
+ }
2428
+ });
2397
2429
  Object.defineProperty(exports, "verifyProof", {
2398
2430
  enumerable: true,
2399
2431
  get: function() {
@@ -1,6 +1,6 @@
1
1
  import { Temporal } from "temporal-polyfill";
2
2
  import { URLPattern } from "urlpattern-polyfill";
3
- import { I as name, L as version, c as fetchKey, f as validateCryptoKey, h as getFederationMetrics, m as getDurationMs, o as exportJwk, p as verifyKeyOwnership, s as fetchActorDocument, y as measureSignatureKeyFetch } from "./http-iLCx9vk-.js";
3
+ import { I as name, L as version, c as fetchKey, f as validateCryptoKey, h as getFederationMetrics, m as getDurationMs, o as exportJwk, p as verifyKeyOwnership, s as fetchActorDocument, y as measureSignatureKeyFetch } from "./http-99KVDtMr.js";
4
4
  import { getLogger } from "@logtape/logtape";
5
5
  import { Activity, CryptographicKey, DataIntegrityProof, Multikey, Object as Object$1, PUBLIC_COLLECTION, getTypeId, isActor } from "@fedify/vocab";
6
6
  import { SpanKind, SpanStatusCode, trace } from "@opentelemetry/api";
@@ -1791,6 +1791,8 @@ async function preparePortableObjectProof(jsonLd, options) {
1791
1791
  const proofValues = root[SECURITY_PROOF];
1792
1792
  if (proofValues == null || Array.isArray(proofValues) && proofValues.length < 1) return {
1793
1793
  prepared: false,
1794
+ root,
1795
+ objectType,
1794
1796
  result: objectType === "collection" ? {
1795
1797
  verified: false,
1796
1798
  reason: { type: "unsecuredCollection" }
@@ -1894,6 +1896,8 @@ async function preparePortableObjectProof(jsonLd, options) {
1894
1896
  }
1895
1897
  return {
1896
1898
  prepared: true,
1899
+ root,
1900
+ objectType,
1897
1901
  objectId,
1898
1902
  proofs,
1899
1903
  rawProofValues,
@@ -1948,8 +1952,30 @@ async function verifyPortableObjectProofPolicy(jsonLd, key, options = {}) {
1948
1952
  * @since 2.4.0
1949
1953
  */
1950
1954
  async function verifyPortableObjectProof(jsonLd, options = {}) {
1955
+ return (await verifyPortableObjectProofWithRoot(jsonLd, options)).result;
1956
+ }
1957
+ /**
1958
+ * Same as {@link verifyPortableObjectProof}, but also returns the expanded
1959
+ * root node and its FEP-2277 core type, so that a caller can apply further
1960
+ * policy, such as the gateway trust policy for unsecured collections, to the
1961
+ * same interpretation of the document.
1962
+ * @internal
1963
+ */
1964
+ async function verifyPortableObjectProofWithRoot(jsonLd, options = {}) {
1951
1965
  const prepared = await preparePortableObjectProof(jsonLd, options);
1952
- if (!prepared.prepared) return prepared.result;
1966
+ if (!prepared.prepared) return {
1967
+ result: prepared.result,
1968
+ ...prepared.root == null ? {} : { root: prepared.root },
1969
+ ...prepared.objectType == null ? {} : { objectType: prepared.objectType }
1970
+ };
1971
+ const { root, objectType } = prepared;
1972
+ return {
1973
+ result: await verifyPreparedPortableObjectProof(jsonLd, prepared, options),
1974
+ root,
1975
+ objectType
1976
+ };
1977
+ }
1978
+ async function verifyPreparedPortableObjectProof(jsonLd, prepared, options) {
1953
1979
  const { proofs, rawProofValues, proofContextLoader } = prepared;
1954
1980
  const keys = [];
1955
1981
  const rawProofCandidatePool = {
@@ -2247,4 +2273,4 @@ async function getKeyOwner(keyId, options) {
2247
2273
  return null;
2248
2274
  }
2249
2275
  //#endregion
2250
- export { verifyCompactJsonLd as C, normalizeOutgoingActivityJsonLd as D, wrapContextLoaderForJsonLd as E, signJsonLd as S, verifySignature as T, getNormalizationContextLoader as _, signObject as a, isClearlyMalformedContextReference as b, verifyPortableObjectProof as c, InvalidContextReferenceError as d, assertSafeJsonLd as f, detachSignature as g, createSignature as h, hasProofLike as i, verifyPortableObjectProofPolicy as l, compactJsonLd as m, getKeyOwner as n, verifyMapLocalProof as o, attachSignature as p, createProof as r, verifyObject as s, doesActorOwnKey as t, verifyProof as u, hasSignature as v, verifyJsonLd as w, isInvalidUrlTypeError as x, hasSignatureLike as y };
2276
+ export { signJsonLd as C, wrapContextLoaderForJsonLd as D, verifySignature as E, normalizeOutgoingActivityJsonLd as O, isInvalidUrlTypeError as S, verifyJsonLd as T, detachSignature as _, signObject as a, hasSignatureLike as b, verifyPortableObjectProof as c, verifyProof as d, InvalidContextReferenceError as f, createSignature as g, compactJsonLd as h, hasProofLike as i, verifyPortableObjectProofPolicy as l, attachSignature as m, getKeyOwner as n, verifyMapLocalProof as o, assertSafeJsonLd as p, createProof as r, verifyObject as s, doesActorOwnKey as t, verifyPortableObjectProofWithRoot as u, getNormalizationContextLoader as v, verifyCompactJsonLd as w, isClearlyMalformedContextReference as x, hasSignature as y };