@fedify/fedify 2.4.0-dev.2212 → 2.4.0-dev.2219
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{builder-CKAVFvcH.mjs → builder-C5rYBZ16.mjs} +10 -2
- package/dist/compat/mod.d.cts +1 -1
- package/dist/compat/mod.d.ts +1 -1
- package/dist/compat/transformers.test.mjs +1 -1
- package/dist/{compound-proof-BP5SOdXv.mjs → compound-proof-D0xY7MBs.mjs} +2 -2
- package/dist/{context-Bl_Y7T_3.d.cts → context-B6X-t8gI.d.cts} +1 -1
- package/dist/{context-DMd11IAu.d.ts → context-CtI307_A.d.ts} +1 -1
- package/dist/{deno-BKp9fYB3.mjs → deno-Dj1TFhf4.mjs} +1 -1
- package/dist/{docloader-BjJreYQU.mjs → docloader-CzyJe90o.mjs} +2 -2
- package/dist/federation/builder.test.mjs +37 -1
- package/dist/federation/compound-fanout.test.mjs +3 -3
- package/dist/federation/handler-compound-proof.test.mjs +3 -3
- package/dist/federation/handler.test.mjs +5 -5
- package/dist/federation/hashlink-media.test.mjs +2 -2
- package/dist/federation/idempotency.test.mjs +2 -2
- package/dist/federation/metrics.test.mjs +1 -1
- package/dist/federation/middleware.test.mjs +123 -7
- package/dist/federation/mod.cjs +1 -1
- package/dist/federation/mod.d.cts +3 -3
- package/dist/federation/mod.d.ts +3 -3
- package/dist/federation/mod.js +1 -1
- package/dist/federation/outgoing-proof.test.mjs +5 -5
- package/dist/federation/portable-actor.test.mjs +3 -3
- package/dist/federation/portable-chain.test.mjs +3 -3
- package/dist/federation/portable-collection.test.mjs +4 -4
- package/dist/federation/portable-delivery.test.mjs +2 -2
- package/dist/federation/portable-gateway-keys.test.mjs +4 -4
- package/dist/federation/portable-inbox.test.mjs +4 -4
- package/dist/federation/portable-parse-uri.test.mjs +1 -1
- package/dist/federation/portable-route-activity.test.mjs +2 -2
- package/dist/federation/portable.test.mjs +3 -3
- package/dist/federation/send.test.mjs +3 -3
- package/dist/federation/tasks/enqueue.test.mjs +1 -1
- package/dist/federation/tasks/tasks.test.mjs +2 -2
- package/dist/federation/temporal.test.mjs +1 -1
- package/dist/federation/webfinger.test.mjs +1 -1
- package/dist/{federation-B-0EXZPH.cjs → federation-DC1yfb-8.cjs} +20 -9
- package/dist/{http-ByBlnY3D.cjs → http-Cuk0w0rp.cjs} +1 -1
- package/dist/{http--IGUT1mg.mjs → http-D-DpP4sd.mjs} +4 -4
- package/dist/{http-Di8yiDMY.js → http-Dx7yMmfw.js} +1 -1
- package/dist/{key-ChfV9C3v.mjs → key-Djyt1BFx.mjs} +2 -2
- package/dist/{kv-BhNbN8Ed.d.cts → kv-B2mzK5tl.d.cts} +3 -2
- package/dist/{kv-BhNbN8Ed.d.ts → kv-B2mzK5tl.d.ts} +3 -2
- package/dist/{kv-cache-BDwUzxBJ.cjs → kv-cache-BmLTVLXc.cjs} +1 -1
- package/dist/{kv-cache-DpwDPt9V.js → kv-cache-CUZOCSKZ.js} +1 -1
- package/dist/{kv-cache-DFIUR-E5.mjs → kv-cache-ecUXfCqW.mjs} +1 -1
- package/dist/{ld-DBBVabBC.mjs → ld-CNVWdooi.mjs} +3 -3
- package/dist/{metrics-DPQKFkiJ.mjs → metrics-BnYleVpg.mjs} +1 -1
- package/dist/{middleware-VXGLiHtY.js → middleware-BdzcazaN.js} +20 -9
- package/dist/{middleware-G9zpxUsD.mjs → middleware-Bh592bk8.mjs} +1 -1
- package/dist/{middleware-BW7-tHAG.mjs → middleware-C2_LcbL3.mjs} +23 -20
- package/dist/{mod-C5Mwx5ty.d.ts → mod-B8MI1mpi.d.ts} +1 -1
- package/dist/{mod-BVNGHgVr.d.ts → mod-BhTaDR5H.d.ts} +1 -1
- package/dist/{mod-Cyy1Wahy.d.cts → mod-C7_2j7VT.d.cts} +1 -1
- package/dist/{mod-Dp3Ij7sw.d.cts → mod-DFL6IxYQ.d.cts} +1 -1
- package/dist/mod.cjs +4 -4
- package/dist/mod.d.cts +4 -4
- package/dist/mod.d.ts +4 -4
- package/dist/mod.js +4 -4
- package/dist/nodeinfo/handler.test.mjs +1 -1
- package/dist/otel/mod.d.cts +1 -1
- package/dist/otel/mod.d.ts +1 -1
- package/dist/{owner-BW5VsXG3.mjs → owner-D_BDPwm2.mjs} +3 -3
- package/dist/{portable-collection-FTPa5D91.js → portable-collection-C0c0rUN9.js} +1 -1
- package/dist/{portable-collection-CXcAlwei.cjs → portable-collection-DwJ8YJP2.cjs} +1 -1
- package/dist/{portable-collection-Ct99JsBe.mjs → portable-collection-hcONGyUs.mjs} +2 -2
- package/dist/{portable-key-U3lW06QJ.mjs → portable-key-B880yVlC.mjs} +1 -1
- package/dist/{proof-MFz2960e.mjs → proof-z6Prgi5I.mjs} +4 -4
- package/dist/{send-Duj8xys1.mjs → send-Cw545L_2.mjs} +3 -3
- package/dist/sig/compound-proof-discovery.test.mjs +1 -1
- package/dist/sig/compound-proof-producer.test.mjs +1 -1
- package/dist/sig/compound-proof-verification.test.mjs +2 -2
- package/dist/sig/compound-proof.test.mjs +2 -2
- package/dist/sig/http.test.mjs +2 -2
- package/dist/sig/key.test.mjs +1 -1
- package/dist/sig/ld.test.mjs +2 -2
- package/dist/sig/mod.cjs +2 -2
- package/dist/sig/mod.js +2 -2
- package/dist/sig/owner.test.mjs +1 -1
- package/dist/sig/portable-collection.test.mjs +1 -1
- package/dist/sig/portable-key.test.mjs +6 -6
- package/dist/sig/proof.test.mjs +3 -3
- package/dist/{temporal-CVcPKB1N.mjs → temporal-Cy-8WCod.mjs} +1 -1
- package/dist/testing/kv.test.mjs +1 -1
- package/dist/testing/mod.d.mts +3 -2
- package/dist/utils/docloader.test.mjs +2 -2
- package/dist/utils/kv-cache.test.mjs +1 -1
- package/dist/utils/mod.cjs +1 -1
- package/dist/utils/mod.d.cts +1 -1
- package/dist/utils/mod.d.ts +1 -1
- package/dist/utils/mod.js +1 -1
- package/package.json +7 -7
|
@@ -2,7 +2,7 @@ import "temporal-polyfill";
|
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
4
|
import { i as getPortableDid, l as isPortableId, n as getCanonicalPortableId } from "./portable-key-id-Ca30-hOa.mjs";
|
|
5
|
-
import { n as version, t as name } from "./deno-
|
|
5
|
+
import { n as version, t as name } from "./deno-Dj1TFhf4.mjs";
|
|
6
6
|
import { t as ActivityListenerSet } from "./activity-listener-C-BSbKI7.mjs";
|
|
7
7
|
import { getLogger } from "@logtape/logtape";
|
|
8
8
|
import { Router, RouterError, assertPath } from "@fedify/uri-template";
|
|
@@ -73,6 +73,7 @@ var FederationBuilderImpl = class {
|
|
|
73
73
|
* Symbol registry for unique identification of unnamed symbols.
|
|
74
74
|
*/
|
|
75
75
|
#symbolRegistry = /* @__PURE__ */ new Map();
|
|
76
|
+
#collectionNames = /* @__PURE__ */ new Map();
|
|
76
77
|
constructor() {
|
|
77
78
|
this.router = new Router();
|
|
78
79
|
this.objectCallbacks = {};
|
|
@@ -89,7 +90,7 @@ var FederationBuilderImpl = class {
|
|
|
89
90
|
* specified.
|
|
90
91
|
*/
|
|
91
92
|
async build(options) {
|
|
92
|
-
const { FederationImpl } = await import("./middleware-
|
|
93
|
+
const { FederationImpl } = await import("./middleware-Bh592bk8.mjs");
|
|
93
94
|
const f = new FederationImpl(options);
|
|
94
95
|
const trailingSlashInsensitiveValue = f.router.trailingSlashInsensitive;
|
|
95
96
|
f.router = this.router.clone();
|
|
@@ -102,6 +103,8 @@ var FederationBuilderImpl = class {
|
|
|
102
103
|
f.objectTypeIds = { ...this.objectTypeIds };
|
|
103
104
|
f.collectionCallbacks = { ...this.collectionCallbacks };
|
|
104
105
|
f.collectionTypeIds = { ...this.collectionTypeIds };
|
|
106
|
+
f.#symbolRegistry = new Map(this.#symbolRegistry);
|
|
107
|
+
f.#collectionNames = new Map(this.#collectionNames);
|
|
105
108
|
f.inboxPath = this.inboxPath;
|
|
106
109
|
f.outboxPath = this.outboxPath;
|
|
107
110
|
f.inboxCallbacks = this.inboxCallbacks == null ? void 0 : { ...this.inboxCallbacks };
|
|
@@ -633,6 +636,7 @@ var FederationBuilderImpl = class {
|
|
|
633
636
|
if (this.collectionCallbacks[name] != null) throw new RouterError(`Collection dispatcher for ${strName} already set.`);
|
|
634
637
|
assertPath(path);
|
|
635
638
|
if (Router.variables(path).size < 1) throw new RouterError("Path for collection dispatcher must have at least one variable.");
|
|
639
|
+
this.#collectionNames.set(routeName, name);
|
|
636
640
|
this.router.add(path, routeName);
|
|
637
641
|
const callbacks = { dispatcher };
|
|
638
642
|
this.collectionCallbacks[name] = callbacks;
|
|
@@ -674,6 +678,10 @@ var FederationBuilderImpl = class {
|
|
|
674
678
|
const routeName = this.#uniqueCollectionId(name);
|
|
675
679
|
return this.router.build(`collection:${routeName}`, values) ?? this.router.build(`orderedCollection:${routeName}`, values);
|
|
676
680
|
}
|
|
681
|
+
/** Resolves a custom collection route to its original name. */
|
|
682
|
+
getCollectionName(routeName) {
|
|
683
|
+
return this.#collectionNames.get(routeName) ?? routeName.replace(/^(collection|orderedCollection):/, "");
|
|
684
|
+
}
|
|
677
685
|
setOutboxPermanentFailureHandler(handler) {
|
|
678
686
|
this.outboxPermanentFailureHandler = handler;
|
|
679
687
|
}
|
package/dist/compat/mod.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference lib="esnext.temporal" />
|
|
2
|
-
import { en as ActivityTransformer, n as Context } from "../context-
|
|
2
|
+
import { en as ActivityTransformer, n as Context } from "../context-B6X-t8gI.cjs";
|
|
3
3
|
import { Activity } from "@fedify/vocab";
|
|
4
4
|
|
|
5
5
|
//#region src/compat/transformers.d.ts
|
package/dist/compat/mod.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference lib="esnext.temporal" />
|
|
2
|
-
import { en as ActivityTransformer, n as Context } from "../context-
|
|
2
|
+
import { en as ActivityTransformer, n as Context } from "../context-CtI307_A.js";
|
|
3
3
|
import { Activity } from "@fedify/vocab";
|
|
4
4
|
|
|
5
5
|
//#region src/compat/transformers.d.ts
|
|
@@ -5,7 +5,7 @@ import { t as MemoryKvStore } from "../kv-DCHkaJ9-.mjs";
|
|
|
5
5
|
import { t as assertEquals } from "../assert_equals-Z6IcEbWU.mjs";
|
|
6
6
|
import { t as assertInstanceOf } from "../assert_instance_of-mrXWWNY-.mjs";
|
|
7
7
|
import { t as assert } from "../assert-D1Eafmd_.mjs";
|
|
8
|
-
import { E as autoIdAssigner, T as actorDehydrator, n as FederationImpl } from "../middleware-
|
|
8
|
+
import { E as autoIdAssigner, T as actorDehydrator, n as FederationImpl } from "../middleware-C2_LcbL3.mjs";
|
|
9
9
|
import { Follow, Person } from "@fedify/vocab";
|
|
10
10
|
import { test } from "@fedify/fixture";
|
|
11
11
|
//#region src/compat/transformers.test.ts
|
|
@@ -3,8 +3,8 @@ import "urlpattern-polyfill";
|
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
4
|
import { a as getRawCanonicalPortableId, l as isPortableId, n as getCanonicalPortableId } from "./portable-key-id-Ca30-hOa.mjs";
|
|
5
5
|
import { n as preloadedOnlyDocumentLoader } from "./public-audience--klBIOk1.mjs";
|
|
6
|
-
import { c as getNormalizationContextLoader } from "./ld-
|
|
7
|
-
import { l as verifyPortableObjectProofPolicy, n as classifyFep2277CoreType, o as verifyMapLocalProof } from "./proof-
|
|
6
|
+
import { c as getNormalizationContextLoader } from "./ld-CNVWdooi.mjs";
|
|
7
|
+
import { l as verifyPortableObjectProofPolicy, n as classifyFep2277CoreType, o as verifyMapLocalProof } from "./proof-z6Prgi5I.mjs";
|
|
8
8
|
import { parseIri, preloadedContexts } from "@fedify/vocab-runtime";
|
|
9
9
|
import jsonld from "@fedify/vocab-runtime/jsonld";
|
|
10
10
|
//#region src/sig/compound-proof.ts
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import { o as JsonValue, s as NodeInfo, t as GetNodeInfoOptions } from "./client-D-XP_Ccb.cjs";
|
|
3
3
|
import { o as VerifyRequestFailureReason, t as HttpMessageSignaturesSpec } from "./http-BrwKINQn.cjs";
|
|
4
4
|
import { n as GetKeyOwnerOptions } from "./owner-BF0L9cMt.cjs";
|
|
5
|
-
import { n as KvStore, t as KvKey } from "./kv-
|
|
5
|
+
import { n as KvStore, t as KvKey } from "./kv-B2mzK5tl.cjs";
|
|
6
6
|
import { Activity, Actor, Collection, CryptographicKey, Hashtag, Link, LookupObjectOptions, Multikey, Object as Object$1, Recipient, Tombstone, TraverseCollectionOptions } from "@fedify/vocab";
|
|
7
7
|
import { AuthenticatedDocumentLoaderFactory, DocumentLoader, DocumentLoaderFactory, GetUserAgentOptions, PortableObjectVerifier } from "@fedify/vocab-runtime";
|
|
8
8
|
import { Link as Link$1, LookupWebFingerOptions, ResourceDescriptor } from "@fedify/webfinger";
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import { o as JsonValue, s as NodeInfo, t as GetNodeInfoOptions } from "./client-D-XP_Ccb.js";
|
|
3
3
|
import { o as VerifyRequestFailureReason, t as HttpMessageSignaturesSpec } from "./http-DGx0KOws.js";
|
|
4
4
|
import { n as GetKeyOwnerOptions } from "./owner-BSzr5-I8.js";
|
|
5
|
-
import { n as KvStore, t as KvKey } from "./kv-
|
|
5
|
+
import { n as KvStore, t as KvKey } from "./kv-B2mzK5tl.js";
|
|
6
6
|
import { Router } from "@fedify/uri-template";
|
|
7
7
|
import { Activity, Actor, Collection, CryptographicKey, Hashtag, Link, LookupObjectOptions, Multikey, Object as Object$1, Recipient, Tombstone, TraverseCollectionOptions } from "@fedify/vocab";
|
|
8
8
|
import { MeterProvider, Span, Tracer, TracerProvider } from "@opentelemetry/api";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import "temporal-polyfill";
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
|
-
import { c as validateCryptoKey } from "./key-
|
|
5
|
-
import { n as doubleKnock } from "./http
|
|
4
|
+
import { c as validateCryptoKey } from "./key-Djyt1BFx.mjs";
|
|
5
|
+
import { n as doubleKnock } from "./http-D-DpP4sd.mjs";
|
|
6
6
|
import { getLogger } from "@logtape/logtape";
|
|
7
7
|
import { FetchError, UrlError, createActivityPubRequest, getRemoteDocument, logRequest, resolveDocumentLoaderTimeout, validatePublicUrl, withDocumentLoaderTimeout } from "@fedify/vocab-runtime";
|
|
8
8
|
import { curry } from "es-toolkit";
|
|
@@ -6,7 +6,8 @@ import { t as assertEquals } from "../assert_equals-Z6IcEbWU.mjs";
|
|
|
6
6
|
import { t as assertExists } from "../assert_exists-cffSpJ7X.mjs";
|
|
7
7
|
import { t as assertThrows } from "../assert_throws-BYITOvPO.mjs";
|
|
8
8
|
import "../std__assert-DvMDRPes.mjs";
|
|
9
|
-
import {
|
|
9
|
+
import { t as assertStrictEquals } from "../assert_strict_equals-CYvBmkpC.mjs";
|
|
10
|
+
import { r as createFederationBuilder } from "../builder-C5rYBZ16.mjs";
|
|
10
11
|
import { DisallowedOperatorError, DisallowedVarSpecModifierError, DuplicateRouteVariableError, RouteTemplateOptionsNotMatchedError, RouterError } from "@fedify/uri-template";
|
|
11
12
|
import { Activity, Note, Person } from "@fedify/vocab";
|
|
12
13
|
import { test } from "@fedify/fixture";
|
|
@@ -355,6 +356,41 @@ test("FederationBuilder", async (t) => {
|
|
|
355
356
|
assertEquals(impl.collectionTypeIds["test"], Note);
|
|
356
357
|
assertEquals((await impl.fetch(new Request("https://example.com/c/x", { headers: { accept: "application/activity+json" } }), { contextData: void 0 })).status, 200);
|
|
357
358
|
});
|
|
359
|
+
await t.step("preserves symbol-named collections through build()", async () => {
|
|
360
|
+
const builder = createFederationBuilder();
|
|
361
|
+
const collection = Symbol("saved");
|
|
362
|
+
const ordered = Symbol("saved");
|
|
363
|
+
builder.setCollectionDispatcher(collection, Note, "/users/{identifier}/saved", () => ({ items: [] }));
|
|
364
|
+
builder.setOrderedCollectionDispatcher(ordered, Note, "/users/{identifier}/ordered-saved", () => ({ items: [] }));
|
|
365
|
+
for (let build = 0; build < 2; build++) {
|
|
366
|
+
const federation = await builder.build({ kv: new MemoryKvStore() });
|
|
367
|
+
const ctx = federation.createContext(new URL("https://example.com/"));
|
|
368
|
+
for (const [name, path, type] of [[
|
|
369
|
+
collection,
|
|
370
|
+
"/users/alice/saved",
|
|
371
|
+
"collection"
|
|
372
|
+
], [
|
|
373
|
+
ordered,
|
|
374
|
+
"/users/alice/ordered-saved",
|
|
375
|
+
"orderedCollection"
|
|
376
|
+
]]) {
|
|
377
|
+
const uri = ctx.getCollectionUri(name, { identifier: "alice" });
|
|
378
|
+
assertEquals(uri.pathname, path);
|
|
379
|
+
const parsed = ctx.parseUri(uri);
|
|
380
|
+
assertEquals(parsed?.type, type);
|
|
381
|
+
if (parsed?.type !== "collection" && parsed?.type !== "orderedCollection") throw new Error("Expected a custom collection URI");
|
|
382
|
+
assertStrictEquals(parsed.name, name);
|
|
383
|
+
assertStrictEquals(parsed.class, Note);
|
|
384
|
+
assertEquals(parsed.values, { identifier: "alice" });
|
|
385
|
+
for (const cursor of [null, "next"]) {
|
|
386
|
+
const pageUri = new URL(uri);
|
|
387
|
+
if (cursor != null) pageUri.searchParams.set("cursor", cursor);
|
|
388
|
+
assertEquals((await federation.fetch(new Request(pageUri, { headers: { accept: "application/activity+json" } }), { contextData: void 0 })).status, 200);
|
|
389
|
+
}
|
|
390
|
+
}
|
|
391
|
+
assertThrows(() => federation.setCollectionDispatcher(collection, Note, "/users/{identifier}/duplicate", () => ({ items: [] })));
|
|
392
|
+
}
|
|
393
|
+
});
|
|
358
394
|
});
|
|
359
395
|
//#endregion
|
|
360
396
|
export {};
|
|
@@ -6,11 +6,11 @@ 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
8
|
import { t as assert } from "../assert-D1Eafmd_.mjs";
|
|
9
|
-
import { n as exportJwk } from "../key-
|
|
9
|
+
import { n as exportJwk } from "../key-Djyt1BFx.mjs";
|
|
10
10
|
import { r as normalizeOutgoingActivityJsonLd } from "../outgoing-jsonld-4IJqPYos.mjs";
|
|
11
|
-
import { a as signObject, d as verifyProof } from "../proof-
|
|
11
|
+
import { a as signObject, d as verifyProof } from "../proof-z6Prgi5I.mjs";
|
|
12
12
|
import { i as rsaPrivateKey2, n as ed25519PrivateKey, r as ed25519PublicKey, s as rsaPublicKey2 } from "../keys-DIJNHW-Y.mjs";
|
|
13
|
-
import { n as FederationImpl } from "../middleware-
|
|
13
|
+
import { n as FederationImpl } from "../middleware-C2_LcbL3.mjs";
|
|
14
14
|
import { Create, DataIntegrityProof, Note } from "@fedify/vocab";
|
|
15
15
|
import { exportDidKey, parseIri } from "@fedify/vocab-runtime";
|
|
16
16
|
import { mockDocumentLoader, test } from "@fedify/fixture";
|
|
@@ -5,10 +5,10 @@ import { r as createRequestContext, t as createInboxContext } from "../context-8
|
|
|
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 { a as compactJsonLd, m as verifyCompactJsonLd, p as signJsonLd } from "../ld-
|
|
9
|
-
import { l as signRequest } from "../http
|
|
8
|
+
import { a as compactJsonLd, m as verifyCompactJsonLd, p as signJsonLd } from "../ld-CNVWdooi.mjs";
|
|
9
|
+
import { l as signRequest } from "../http-D-DpP4sd.mjs";
|
|
10
10
|
import { a as rsaPrivateKey3, c as rsaPublicKey3, n as ed25519PrivateKey, r as ed25519PublicKey, s as rsaPublicKey2 } from "../keys-DIJNHW-Y.mjs";
|
|
11
|
-
import { f as handleInbox, o as createFederation } from "../middleware-
|
|
11
|
+
import { f as handleInbox, o as createFederation } from "../middleware-C2_LcbL3.mjs";
|
|
12
12
|
import { t as ActivityListenerSet } from "../activity-listener-C-BSbKI7.mjs";
|
|
13
13
|
import { t as map_local_create_note_default } from "../map-local-create-note-B0SeXJms.mjs";
|
|
14
14
|
import { Create, CryptographicKey, Multikey, Person, Update } from "@fedify/vocab";
|
|
@@ -10,12 +10,12 @@ import "../std__assert-DvMDRPes.mjs";
|
|
|
10
10
|
import { t as assertRejects } from "../assert_rejects-CTptdYck.mjs";
|
|
11
11
|
import { t as assert } from "../assert-D1Eafmd_.mjs";
|
|
12
12
|
import { r as parseAcceptSignature } from "../accept-CPVqki78.mjs";
|
|
13
|
-
import { o as generateCryptoKeyPair } from "../key-
|
|
14
|
-
import { a as compactJsonLd, p as signJsonLd } from "../ld-
|
|
15
|
-
import { a as signObject } from "../proof-
|
|
16
|
-
import { l as signRequest } from "../http
|
|
13
|
+
import { o as generateCryptoKeyPair } from "../key-Djyt1BFx.mjs";
|
|
14
|
+
import { a as compactJsonLd, p as signJsonLd } from "../ld-CNVWdooi.mjs";
|
|
15
|
+
import { a as signObject } from "../proof-z6Prgi5I.mjs";
|
|
16
|
+
import { l as signRequest } from "../http-D-DpP4sd.mjs";
|
|
17
17
|
import { a as rsaPrivateKey3, c as rsaPublicKey3, s as rsaPublicKey2 } from "../keys-DIJNHW-Y.mjs";
|
|
18
|
-
import { d as handleCustomCollection, f as handleInbox, g as respondWithObjectIfAcceptable, h as respondWithObject, l as handleActor, m as handleOutbox, o as createFederation, p as handleObject, u as handleCollection } from "../middleware-
|
|
18
|
+
import { d as handleCustomCollection, f as handleInbox, g as respondWithObjectIfAcceptable, h as respondWithObject, l as handleActor, m as handleOutbox, o as createFederation, p as handleObject, u as handleCollection } from "../middleware-C2_LcbL3.mjs";
|
|
19
19
|
import { t as ActivityListenerSet } from "../activity-listener-C-BSbKI7.mjs";
|
|
20
20
|
import { Activity, Create, CryptographicKey, Multikey, Note, Person, Tombstone } from "@fedify/vocab";
|
|
21
21
|
import { FetchError } from "@fedify/vocab-runtime";
|
|
@@ -10,8 +10,8 @@ import "../std__assert-DvMDRPes.mjs";
|
|
|
10
10
|
import { t as assertStrictEquals } from "../assert_strict_equals-CYvBmkpC.mjs";
|
|
11
11
|
import { t as assert } from "../assert-D1Eafmd_.mjs";
|
|
12
12
|
import { r as ed25519PublicKey } from "../keys-DIJNHW-Y.mjs";
|
|
13
|
-
import { o as createFederation, x as parseHashlinkGatewayRequest } from "../middleware-
|
|
14
|
-
import { r as createFederationBuilder } from "../builder-
|
|
13
|
+
import { o as createFederation, x as parseHashlinkGatewayRequest } from "../middleware-C2_LcbL3.mjs";
|
|
14
|
+
import { r as createFederationBuilder } from "../builder-C5rYBZ16.mjs";
|
|
15
15
|
import { n as RouterError } from "../router-u5O5KCQr.mjs";
|
|
16
16
|
import { Note } from "@fedify/vocab";
|
|
17
17
|
import { computeDigestMultibase, encodeMultibase, exportDidKey } from "@fedify/vocab-runtime";
|
|
@@ -4,9 +4,9 @@ globalThis.addEventListener = () => {};
|
|
|
4
4
|
import { t as MemoryKvStore } from "../kv-DCHkaJ9-.mjs";
|
|
5
5
|
import { t as assertEquals } from "../assert_equals-Z6IcEbWU.mjs";
|
|
6
6
|
import "../std__assert-DvMDRPes.mjs";
|
|
7
|
-
import { a as signObject } from "../proof-
|
|
7
|
+
import { a as signObject } from "../proof-z6Prgi5I.mjs";
|
|
8
8
|
import { n as ed25519PrivateKey, r as ed25519PublicKey, t as ed25519Multikey } from "../keys-DIJNHW-Y.mjs";
|
|
9
|
-
import { o as createFederation } from "../middleware-
|
|
9
|
+
import { o as createFederation } from "../middleware-C2_LcbL3.mjs";
|
|
10
10
|
import { Create, Follow, Person } from "@fedify/vocab";
|
|
11
11
|
import { mockDocumentLoader, test } from "@fedify/fixture";
|
|
12
12
|
//#region src/federation/idempotency.test.ts
|
|
@@ -4,7 +4,7 @@ globalThis.addEventListener = () => {};
|
|
|
4
4
|
import { t as assertEquals } from "../assert_equals-Z6IcEbWU.mjs";
|
|
5
5
|
import "../std__assert-DvMDRPes.mjs";
|
|
6
6
|
import { t as assertRejects } from "../assert_rejects-CTptdYck.mjs";
|
|
7
|
-
import { _ as recordKeyLookup, a as instrumentDocumentLoader, b as recordWebFingerHandle, c as recordCircuitBreakerStateChange, d as recordCollectionRequest, f as recordCollectionTotalItems, g as recordInboxActivity, h as recordFanoutRecipients, i as getRemoteHost, l as recordCollectionDispatchDuration, m as recordDocumentFetch, p as recordDocumentCache, r as getFederationMetrics, t as classifyFetchError, u as recordCollectionPageItems, v as recordOutboxActivity, x as registerQueueDepthGauge, y as recordOutboxEnqueue } from "../metrics-
|
|
7
|
+
import { _ as recordKeyLookup, a as instrumentDocumentLoader, b as recordWebFingerHandle, c as recordCircuitBreakerStateChange, d as recordCollectionRequest, f as recordCollectionTotalItems, g as recordInboxActivity, h as recordFanoutRecipients, i as getRemoteHost, l as recordCollectionDispatchDuration, m as recordDocumentFetch, p as recordDocumentCache, r as getFederationMetrics, t as classifyFetchError, u as recordCollectionPageItems, v as recordOutboxActivity, x as registerQueueDepthGauge, y as recordOutboxEnqueue } from "../metrics-BnYleVpg.mjs";
|
|
8
8
|
import { FetchError } from "@fedify/vocab-runtime";
|
|
9
9
|
import { createTestMeterProvider, test } from "@fedify/fixture";
|
|
10
10
|
import { DataPointType, MeterProvider, MetricReader } from "@opentelemetry/sdk-metrics";
|
|
@@ -16,14 +16,14 @@ import "../std__assert-DvMDRPes.mjs";
|
|
|
16
16
|
import { t as assertRejects } from "../assert_rejects-CTptdYck.mjs";
|
|
17
17
|
import { t as assertStrictEquals } from "../assert_strict_equals-CYvBmkpC.mjs";
|
|
18
18
|
import { t as assert } from "../assert-D1Eafmd_.mjs";
|
|
19
|
-
import { g as recordInboxActivity } from "../metrics-
|
|
20
|
-
import { a as compactJsonLd, h as verifyJsonLd, p as signJsonLd, s as detachSignature } from "../ld-
|
|
21
|
-
import { a as signObject, s as verifyObject } from "../proof-
|
|
22
|
-
import { f as verifyRequest, l as signRequest } from "../http
|
|
19
|
+
import { g as recordInboxActivity } from "../metrics-BnYleVpg.mjs";
|
|
20
|
+
import { a as compactJsonLd, h as verifyJsonLd, p as signJsonLd, s as detachSignature } from "../ld-CNVWdooi.mjs";
|
|
21
|
+
import { a as signObject, s as verifyObject } from "../proof-z6Prgi5I.mjs";
|
|
22
|
+
import { f as verifyRequest, l as signRequest } from "../http-D-DpP4sd.mjs";
|
|
23
23
|
import { a as rsaPrivateKey3, c as rsaPublicKey3, i as rsaPrivateKey2, n as ed25519PrivateKey, r as ed25519PublicKey, s as rsaPublicKey2, t as ed25519Multikey } from "../keys-DIJNHW-Y.mjs";
|
|
24
|
-
import { t as getAuthenticatedDocumentLoader } from "../docloader-
|
|
25
|
-
import { S as handleBenchmarkTrigger, i as KvSpecDeterminer, n as FederationImpl, o as createFederation, r as InboxContextImpl, t as ContextImpl } from "../middleware-
|
|
26
|
-
import { t as doesActorOwnKey } from "../owner-
|
|
24
|
+
import { t as getAuthenticatedDocumentLoader } from "../docloader-CzyJe90o.mjs";
|
|
25
|
+
import { S as handleBenchmarkTrigger, i as KvSpecDeterminer, n as FederationImpl, o as createFederation, r as InboxContextImpl, t as ContextImpl } from "../middleware-C2_LcbL3.mjs";
|
|
26
|
+
import { t as doesActorOwnKey } from "../owner-D_BDPwm2.mjs";
|
|
27
27
|
import { t as CircuitBreaker } from "../circuit-breaker-XJ53md4S.mjs";
|
|
28
28
|
import { t as TaskCodec } from "../codec-C6rTrpIp.mjs";
|
|
29
29
|
import { t as markCircuitBreakerLegacySweepDone } from "../circuit-breaker-test-utils-DW6YC_Pe.mjs";
|
|
@@ -7396,6 +7396,81 @@ test({
|
|
|
7396
7396
|
assertEquals(rejected[1].attributes["activitypub.activity.type"], "https://www.w3.org/ns/activitystreams#Offer");
|
|
7397
7397
|
}
|
|
7398
7398
|
});
|
|
7399
|
+
for (const queued of [false, true]) test(`ContextImpl.routeActivity() routes the fetched document (queued: ${queued})`, async () => {
|
|
7400
|
+
const id = new URL("https://example.com/verified-create");
|
|
7401
|
+
const genuine = new Create({
|
|
7402
|
+
id,
|
|
7403
|
+
actor: new URL("https://example.com/person"),
|
|
7404
|
+
object: new vocab.Note({ content: "Genuine content" }),
|
|
7405
|
+
to: new URL("https://example.com/recipient")
|
|
7406
|
+
});
|
|
7407
|
+
const genuineJson = await genuine.toJsonLd({ contextLoader: mockDocumentLoader });
|
|
7408
|
+
const forged = new Create({
|
|
7409
|
+
id,
|
|
7410
|
+
actor: new URL("https://victim.example/actor"),
|
|
7411
|
+
object: new vocab.Note({ content: "Forged content" }),
|
|
7412
|
+
to: new URL("https://attacker.example/recipient")
|
|
7413
|
+
});
|
|
7414
|
+
const messages = [];
|
|
7415
|
+
const queue = {
|
|
7416
|
+
enqueue(message) {
|
|
7417
|
+
messages.push(message);
|
|
7418
|
+
return Promise.resolve();
|
|
7419
|
+
},
|
|
7420
|
+
async listen() {}
|
|
7421
|
+
};
|
|
7422
|
+
const federation = createFederation({
|
|
7423
|
+
kv: new MemoryKvStore(),
|
|
7424
|
+
documentLoaderFactory: () => async (url, options) => url === id.href ? {
|
|
7425
|
+
document: genuineJson,
|
|
7426
|
+
documentUrl: id.href,
|
|
7427
|
+
contextUrl: null
|
|
7428
|
+
} : await mockDocumentLoader(url, options),
|
|
7429
|
+
contextLoaderFactory: () => mockDocumentLoader,
|
|
7430
|
+
queue: {
|
|
7431
|
+
inbox: queued ? queue : void 0,
|
|
7432
|
+
outbox: queue
|
|
7433
|
+
},
|
|
7434
|
+
manuallyStartQueue: true
|
|
7435
|
+
});
|
|
7436
|
+
const received = [];
|
|
7437
|
+
const contextDocuments = [];
|
|
7438
|
+
federation.setInboxListeners("/users/{identifier}/inbox", "/inbox").on(Create, async (ctx, activity) => {
|
|
7439
|
+
received.push(await activity.toJsonLd({ contextLoader: mockDocumentLoader }));
|
|
7440
|
+
assertInstanceOf(ctx, InboxContextImpl);
|
|
7441
|
+
contextDocuments.push(ctx.activity);
|
|
7442
|
+
await ctx.forwardActivity({
|
|
7443
|
+
privateKey: ed25519PrivateKey,
|
|
7444
|
+
keyId: ed25519Multikey.id
|
|
7445
|
+
}, {
|
|
7446
|
+
id: new URL("https://example.com/recipient"),
|
|
7447
|
+
inboxId: new URL("https://example.com/inbox")
|
|
7448
|
+
});
|
|
7449
|
+
});
|
|
7450
|
+
const ctx = federation.createContext(new URL("https://local.example/"));
|
|
7451
|
+
async function processInbox() {
|
|
7452
|
+
const inboxMessages = messages.filter((message) => message.type === "inbox");
|
|
7453
|
+
for (const message of inboxMessages) await federation.processQueuedTask(void 0, message);
|
|
7454
|
+
}
|
|
7455
|
+
assert(await ctx.routeActivity(null, forged));
|
|
7456
|
+
if (queued) {
|
|
7457
|
+
assertEquals(received, []);
|
|
7458
|
+
assertEquals(messages.length, 1);
|
|
7459
|
+
assert(messages[0].type === "inbox");
|
|
7460
|
+
assertEquals(messages[0].activity, genuineJson);
|
|
7461
|
+
await processInbox();
|
|
7462
|
+
}
|
|
7463
|
+
assertEquals(received, [genuineJson]);
|
|
7464
|
+
assertEquals(contextDocuments, [genuineJson]);
|
|
7465
|
+
const forwarded = messages.filter((message) => message.type === "outbox");
|
|
7466
|
+
assertEquals(forwarded.length, 1);
|
|
7467
|
+
assertEquals(forwarded[0].activity, genuineJson);
|
|
7468
|
+
assert(await ctx.routeActivity(null, genuine));
|
|
7469
|
+
if (queued) await processInbox();
|
|
7470
|
+
assertEquals(received, [genuineJson]);
|
|
7471
|
+
assertEquals(contextDocuments, [genuineJson]);
|
|
7472
|
+
assertEquals(messages.filter((message) => message.type === "outbox").length, 1);
|
|
7473
|
+
});
|
|
7399
7474
|
test("ContextImpl.routeActivity() marks queued signed activities as non-LDS", async () => {
|
|
7400
7475
|
let queuedMessage = null;
|
|
7401
7476
|
const federation = new FederationImpl({
|
|
@@ -7455,6 +7530,47 @@ test("ContextImpl.getCollectionUri()", () => {
|
|
|
7455
7530
|
assertThrows(() => ctx.getCollectionUri(Symbol(notReg), values));
|
|
7456
7531
|
assertThrows(() => ctx.getCollectionUri(Symbol.for(notReg), values));
|
|
7457
7532
|
});
|
|
7533
|
+
test("symbol-named custom collections are served and parsed", async () => {
|
|
7534
|
+
const federation = createFederation({ kv: new MemoryKvStore() });
|
|
7535
|
+
const names = [Symbol("bookmarks"), Symbol("bookmarks")];
|
|
7536
|
+
const paths = ["bookmarks", "ordered-bookmarks"];
|
|
7537
|
+
const calls = [];
|
|
7538
|
+
federation.setCollectionDispatcher(names[0], vocab.Object, "/users/{identifier}/bookmarks", (_ctx, _values, cursor) => {
|
|
7539
|
+
calls.push([0, cursor]);
|
|
7540
|
+
return { items: [] };
|
|
7541
|
+
});
|
|
7542
|
+
federation.setOrderedCollectionDispatcher(names[1], vocab.Object, "/users/{identifier}/ordered-bookmarks", (_ctx, _values, cursor) => {
|
|
7543
|
+
calls.push([1, cursor]);
|
|
7544
|
+
return { items: [] };
|
|
7545
|
+
});
|
|
7546
|
+
const ctx = federation.createContext(new URL("https://example.com/"));
|
|
7547
|
+
for (const [index, name] of names.entries()) {
|
|
7548
|
+
const uri = ctx.getCollectionUri(name, { identifier: "alice" });
|
|
7549
|
+
assertEquals(uri.pathname, `/users/alice/${paths[index]}`);
|
|
7550
|
+
const parsed = ctx.parseUri(uri);
|
|
7551
|
+
assertEquals(parsed?.type, index === 0 ? "collection" : "orderedCollection");
|
|
7552
|
+
if (parsed?.type !== "collection" && parsed?.type !== "orderedCollection") throw new Error("Expected a custom collection URI");
|
|
7553
|
+
assertStrictEquals(parsed.name, name);
|
|
7554
|
+
assertStrictEquals(parsed.class, vocab.Object);
|
|
7555
|
+
assertEquals(parsed.typeId, vocab.Object.typeId);
|
|
7556
|
+
assertEquals(parsed.values, { identifier: "alice" });
|
|
7557
|
+
for (const cursor of [null, "next"]) {
|
|
7558
|
+
const pageUri = new URL(uri);
|
|
7559
|
+
if (cursor != null) pageUri.searchParams.set("cursor", cursor);
|
|
7560
|
+
const response = await federation.fetch(new Request(pageUri, { headers: { accept: "application/activity+json" } }), { contextData: void 0 });
|
|
7561
|
+
assertEquals(response.status, 200);
|
|
7562
|
+
const body = await response.json();
|
|
7563
|
+
assert(body !== null && typeof body === "object" && "type" in body);
|
|
7564
|
+
assertEquals(body.type, `${index === 0 ? "Collection" : "OrderedCollection"}${cursor == null ? "" : "Page"}`);
|
|
7565
|
+
}
|
|
7566
|
+
}
|
|
7567
|
+
assertEquals(calls, [
|
|
7568
|
+
[0, null],
|
|
7569
|
+
[0, "next"],
|
|
7570
|
+
[1, null],
|
|
7571
|
+
[1, "next"]
|
|
7572
|
+
]);
|
|
7573
|
+
});
|
|
7458
7574
|
test("InboxContextImpl.forwardActivity()", async (t) => {
|
|
7459
7575
|
esm_default.spyGlobal();
|
|
7460
7576
|
let verified = null;
|
package/dist/federation/mod.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
const { URLPattern } = require("urlpattern-polyfill");
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const require_federation = require("../federation-
|
|
3
|
+
const require_federation = require("../federation-DC1yfb-8.cjs");
|
|
4
4
|
exports.CircuitBreaker = require_federation.CircuitBreaker;
|
|
5
5
|
exports.InProcessMessageQueue = require_federation.InProcessMessageQueue;
|
|
6
6
|
exports.MemoryKvStore = require_federation.MemoryKvStore;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference lib="esnext.temporal" />
|
|
2
|
-
import { $ as respondWithObject, $t as digest, A as InboxChallengePolicy, At as CustomCollectionDispatcher, B as createFederation, Bt as OutboxListener, C as FederationBenchmarkOptions, Ct as ActorKeyPairsDispatcher, D as FederationStartQueueOptions, Dt as CollectionDispatcher, E as FederationOptions, Et as CollectionCursor, F as PortableInboxForwardingOptions, Ft as MediaUploaderCallback, G as TaskEnqueueOptions, Gt as SharedInboxKeyDispatcher, H as createFederationBuilder, Ht as OutboxPermanentFailureHandler, I as Rfc6570Expression, It as NodeInfoDispatcher, J as CreateExponentialBackoffPolicyOptions, Jt as WebFingerLinksDispatcher, K as TaskHandler, Kt as UnverifiedActivityHandler, L as FederationKvPrefixes, Lt as ObjectAuthorizePredicate, M as MediaUploaderSetters, Mt as HashlinkMediaRequest, N as ObjectCallbackSetters, Nt as InboxErrorHandler, O as IdempotencyKeyCallback, Ot as CustomCollectionCounter, P as OutboxListenerSetters, Pt as InboxListener, Q as RespondWithObjectOptions, Qt as buildCollectionSynchronizationHeader, R as FederationOrigin, Rt as ObjectDispatcher, S as Federation, St as ActorHandleMapper, T as FederationFetchOptions, Tt as CollectionCounter, U as TaskDefinition, Ut as PortableActorIdMapper, V as Message, Vt as OutboxListenerErrorHandler, W as TaskDefinitionOptions, Wt as PortableCollectionOwnerMapper, X as RetryPolicy, Xt as SenderKeyPair, Y as RetryContext, Yt as SendActivityError, Z as createExponentialBackoffPolicy, Zt as PageItems, _ as ActorCallbackSetters, _t as NormalizedCircuitBreakerOptions, a as GetObjectOptions, at as MessageQueueEnqueueOptions, b as CustomCollectionCallbackSetters, bt as ActorAliasMapper, c as IsSignedByAudienceOptions, ct as CircuitBreaker, d as ParseUriResult, dt as CircuitBreakerCreateOptions, et as respondWithObjectIfAcceptable, f as PortableRequest, ft as CircuitBreakerFailurePolicy, g as SendActivityOptionsForCollection, gt as CircuitBreakerStateChange, h as SendActivityOptions, ht as CircuitBreakerState, i as GetActorOptions, it as MessageQueueDepth, j as InboxListenerSetters, jt as HashlinkMediaDispatcher, k as IdempotencyStrategy, kt as CustomCollectionCursor, l as OutboxContext, lt as CircuitBreakerActivityDrop, m as RouteActivityOptions, mt as CircuitBreakerOptions, n as Context, nt as InProcessMessageQueueOptions, o as GetSignedKeyOptions, ot as MessageQueueListenOptions, p as RequestContext, pt as CircuitBreakerKvState, q as TaskRegistry, qt as UnverifiedActivityReason, r as ForwardActivityOptions, rt as MessageQueue, s as InboxContext, st as ParallelMessageQueue, t as ActorKeyPair, tt as InProcessMessageQueue, u as ParseUriOptions, ut as CircuitBreakerBeforeSendDecision, v as CollectionCallbackSetters, vt as normalizeCircuitBreakerOptions, w as FederationBuilder, wt as AuthorizePredicate, x as Federatable, xt as ActorDispatcher, y as ConstructorWithTypeId, yt as parseCircuitBreakerKvState, z as FederationQueueOptions, zt as OutboxErrorHandler } from "../context-
|
|
3
|
-
import { a as MemoryKvStore, i as KvStoreSetOptions, n as KvStore, r as KvStoreListEntry, t as KvKey } from "../kv-
|
|
4
|
-
import { a as RouterOptions, i as RouterError, n as handleWebFinger, o as RouterRouteResult, r as Router, t as WebFingerHandlerParameters } from "../mod-
|
|
2
|
+
import { $ as respondWithObject, $t as digest, A as InboxChallengePolicy, At as CustomCollectionDispatcher, B as createFederation, Bt as OutboxListener, C as FederationBenchmarkOptions, Ct as ActorKeyPairsDispatcher, D as FederationStartQueueOptions, Dt as CollectionDispatcher, E as FederationOptions, Et as CollectionCursor, F as PortableInboxForwardingOptions, Ft as MediaUploaderCallback, G as TaskEnqueueOptions, Gt as SharedInboxKeyDispatcher, H as createFederationBuilder, Ht as OutboxPermanentFailureHandler, I as Rfc6570Expression, It as NodeInfoDispatcher, J as CreateExponentialBackoffPolicyOptions, Jt as WebFingerLinksDispatcher, K as TaskHandler, Kt as UnverifiedActivityHandler, L as FederationKvPrefixes, Lt as ObjectAuthorizePredicate, M as MediaUploaderSetters, Mt as HashlinkMediaRequest, N as ObjectCallbackSetters, Nt as InboxErrorHandler, O as IdempotencyKeyCallback, Ot as CustomCollectionCounter, P as OutboxListenerSetters, Pt as InboxListener, Q as RespondWithObjectOptions, Qt as buildCollectionSynchronizationHeader, R as FederationOrigin, Rt as ObjectDispatcher, S as Federation, St as ActorHandleMapper, T as FederationFetchOptions, Tt as CollectionCounter, U as TaskDefinition, Ut as PortableActorIdMapper, V as Message, Vt as OutboxListenerErrorHandler, W as TaskDefinitionOptions, Wt as PortableCollectionOwnerMapper, X as RetryPolicy, Xt as SenderKeyPair, Y as RetryContext, Yt as SendActivityError, Z as createExponentialBackoffPolicy, Zt as PageItems, _ as ActorCallbackSetters, _t as NormalizedCircuitBreakerOptions, a as GetObjectOptions, at as MessageQueueEnqueueOptions, b as CustomCollectionCallbackSetters, bt as ActorAliasMapper, c as IsSignedByAudienceOptions, ct as CircuitBreaker, d as ParseUriResult, dt as CircuitBreakerCreateOptions, et as respondWithObjectIfAcceptable, f as PortableRequest, ft as CircuitBreakerFailurePolicy, g as SendActivityOptionsForCollection, gt as CircuitBreakerStateChange, h as SendActivityOptions, ht as CircuitBreakerState, i as GetActorOptions, it as MessageQueueDepth, j as InboxListenerSetters, jt as HashlinkMediaDispatcher, k as IdempotencyStrategy, kt as CustomCollectionCursor, l as OutboxContext, lt as CircuitBreakerActivityDrop, m as RouteActivityOptions, mt as CircuitBreakerOptions, n as Context, nt as InProcessMessageQueueOptions, o as GetSignedKeyOptions, ot as MessageQueueListenOptions, p as RequestContext, pt as CircuitBreakerKvState, q as TaskRegistry, qt as UnverifiedActivityReason, r as ForwardActivityOptions, rt as MessageQueue, s as InboxContext, st as ParallelMessageQueue, t as ActorKeyPair, tt as InProcessMessageQueue, u as ParseUriOptions, ut as CircuitBreakerBeforeSendDecision, v as CollectionCallbackSetters, vt as normalizeCircuitBreakerOptions, w as FederationBuilder, wt as AuthorizePredicate, x as Federatable, xt as ActorDispatcher, y as ConstructorWithTypeId, yt as parseCircuitBreakerKvState, z as FederationQueueOptions, zt as OutboxErrorHandler } from "../context-B6X-t8gI.cjs";
|
|
3
|
+
import { a as MemoryKvStore, i as KvStoreSetOptions, n as KvStore, r as KvStoreListEntry, t as KvKey } from "../kv-B2mzK5tl.cjs";
|
|
4
|
+
import { a as RouterOptions, i as RouterError, n as handleWebFinger, o as RouterRouteResult, r as Router, t as WebFingerHandlerParameters } from "../mod-C7_2j7VT.cjs";
|
|
5
5
|
export { ActorAliasMapper, ActorCallbackSetters, ActorDispatcher, ActorHandleMapper, ActorKeyPair, ActorKeyPairsDispatcher, AuthorizePredicate, CircuitBreaker, CircuitBreakerActivityDrop, CircuitBreakerBeforeSendDecision, CircuitBreakerCreateOptions, CircuitBreakerFailurePolicy, CircuitBreakerKvState, CircuitBreakerOptions, CircuitBreakerState, CircuitBreakerStateChange, CollectionCallbackSetters, CollectionCounter, CollectionCursor, CollectionDispatcher, ConstructorWithTypeId, Context, CreateExponentialBackoffPolicyOptions, CustomCollectionCallbackSetters, CustomCollectionCounter, CustomCollectionCursor, CustomCollectionDispatcher, Federatable, Federation, FederationBenchmarkOptions, FederationBuilder, FederationFetchOptions, FederationKvPrefixes, FederationOptions, FederationOrigin, FederationQueueOptions, FederationStartQueueOptions, ForwardActivityOptions, GetActorOptions, GetObjectOptions, GetSignedKeyOptions, HashlinkMediaDispatcher, HashlinkMediaRequest, IdempotencyKeyCallback, IdempotencyStrategy, InProcessMessageQueue, InProcessMessageQueueOptions, InboxChallengePolicy, InboxContext, InboxErrorHandler, InboxListener, InboxListenerSetters, IsSignedByAudienceOptions, KvKey, KvStore, KvStoreListEntry, KvStoreSetOptions, MediaUploaderCallback, MediaUploaderSetters, MemoryKvStore, Message, MessageQueue, MessageQueueDepth, MessageQueueEnqueueOptions, MessageQueueListenOptions, NodeInfoDispatcher, NormalizedCircuitBreakerOptions, ObjectAuthorizePredicate, ObjectCallbackSetters, ObjectDispatcher, OutboxContext, OutboxErrorHandler, OutboxListener, OutboxListenerErrorHandler, OutboxListenerSetters, OutboxPermanentFailureHandler, PageItems, ParallelMessageQueue, ParseUriOptions, ParseUriResult, PortableActorIdMapper, PortableCollectionOwnerMapper, PortableInboxForwardingOptions, PortableRequest, RequestContext, RespondWithObjectOptions, RetryContext, RetryPolicy, Rfc6570Expression, RouteActivityOptions, Router, RouterError, RouterOptions, RouterRouteResult, SendActivityError, SendActivityOptions, SendActivityOptionsForCollection, SenderKeyPair, SharedInboxKeyDispatcher, TaskDefinition, TaskDefinitionOptions, TaskEnqueueOptions, TaskHandler, TaskRegistry, UnverifiedActivityHandler, UnverifiedActivityReason, WebFingerHandlerParameters, WebFingerLinksDispatcher, buildCollectionSynchronizationHeader, createExponentialBackoffPolicy, createFederation, createFederationBuilder, digest, handleWebFinger, normalizeCircuitBreakerOptions, parseCircuitBreakerKvState, respondWithObject, respondWithObjectIfAcceptable };
|
package/dist/federation/mod.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference lib="esnext.temporal" />
|
|
2
|
-
import { $ as respondWithObject, $t as digest, A as InboxChallengePolicy, At as CustomCollectionDispatcher, B as createFederation, Bt as OutboxListener, C as FederationBenchmarkOptions, Ct as ActorKeyPairsDispatcher, D as FederationStartQueueOptions, Dt as CollectionDispatcher, E as FederationOptions, Et as CollectionCursor, F as PortableInboxForwardingOptions, Ft as MediaUploaderCallback, G as TaskEnqueueOptions, Gt as SharedInboxKeyDispatcher, H as createFederationBuilder, Ht as OutboxPermanentFailureHandler, I as Rfc6570Expression, It as NodeInfoDispatcher, J as CreateExponentialBackoffPolicyOptions, Jt as WebFingerLinksDispatcher, K as TaskHandler, Kt as UnverifiedActivityHandler, L as FederationKvPrefixes, Lt as ObjectAuthorizePredicate, M as MediaUploaderSetters, Mt as HashlinkMediaRequest, N as ObjectCallbackSetters, Nt as InboxErrorHandler, O as IdempotencyKeyCallback, Ot as CustomCollectionCounter, P as OutboxListenerSetters, Pt as InboxListener, Q as RespondWithObjectOptions, Qt as buildCollectionSynchronizationHeader, R as FederationOrigin, Rt as ObjectDispatcher, S as Federation, St as ActorHandleMapper, T as FederationFetchOptions, Tt as CollectionCounter, U as TaskDefinition, Ut as PortableActorIdMapper, V as Message, Vt as OutboxListenerErrorHandler, W as TaskDefinitionOptions, Wt as PortableCollectionOwnerMapper, X as RetryPolicy, Xt as SenderKeyPair, Y as RetryContext, Yt as SendActivityError, Z as createExponentialBackoffPolicy, Zt as PageItems, _ as ActorCallbackSetters, _t as NormalizedCircuitBreakerOptions, a as GetObjectOptions, at as MessageQueueEnqueueOptions, b as CustomCollectionCallbackSetters, bt as ActorAliasMapper, c as IsSignedByAudienceOptions, ct as CircuitBreaker, d as ParseUriResult, dt as CircuitBreakerCreateOptions, et as respondWithObjectIfAcceptable, f as PortableRequest, ft as CircuitBreakerFailurePolicy, g as SendActivityOptionsForCollection, gt as CircuitBreakerStateChange, h as SendActivityOptions, ht as CircuitBreakerState, i as GetActorOptions, it as MessageQueueDepth, j as InboxListenerSetters, jt as HashlinkMediaDispatcher, k as IdempotencyStrategy, kt as CustomCollectionCursor, l as OutboxContext, lt as CircuitBreakerActivityDrop, m as RouteActivityOptions, mt as CircuitBreakerOptions, n as Context, nt as InProcessMessageQueueOptions, o as GetSignedKeyOptions, ot as MessageQueueListenOptions, p as RequestContext, pt as CircuitBreakerKvState, q as TaskRegistry, qt as UnverifiedActivityReason, r as ForwardActivityOptions, rt as MessageQueue, s as InboxContext, st as ParallelMessageQueue, t as ActorKeyPair, tt as InProcessMessageQueue, u as ParseUriOptions, ut as CircuitBreakerBeforeSendDecision, v as CollectionCallbackSetters, vt as normalizeCircuitBreakerOptions, w as FederationBuilder, wt as AuthorizePredicate, x as Federatable, xt as ActorDispatcher, y as ConstructorWithTypeId, yt as parseCircuitBreakerKvState, z as FederationQueueOptions, zt as OutboxErrorHandler } from "../context-
|
|
3
|
-
import { a as MemoryKvStore, i as KvStoreSetOptions, n as KvStore, r as KvStoreListEntry, t as KvKey } from "../kv-
|
|
4
|
-
import { a as RouterOptions, i as RouterError, n as handleWebFinger, o as RouterRouteResult, r as Router, t as WebFingerHandlerParameters } from "../mod-
|
|
2
|
+
import { $ as respondWithObject, $t as digest, A as InboxChallengePolicy, At as CustomCollectionDispatcher, B as createFederation, Bt as OutboxListener, C as FederationBenchmarkOptions, Ct as ActorKeyPairsDispatcher, D as FederationStartQueueOptions, Dt as CollectionDispatcher, E as FederationOptions, Et as CollectionCursor, F as PortableInboxForwardingOptions, Ft as MediaUploaderCallback, G as TaskEnqueueOptions, Gt as SharedInboxKeyDispatcher, H as createFederationBuilder, Ht as OutboxPermanentFailureHandler, I as Rfc6570Expression, It as NodeInfoDispatcher, J as CreateExponentialBackoffPolicyOptions, Jt as WebFingerLinksDispatcher, K as TaskHandler, Kt as UnverifiedActivityHandler, L as FederationKvPrefixes, Lt as ObjectAuthorizePredicate, M as MediaUploaderSetters, Mt as HashlinkMediaRequest, N as ObjectCallbackSetters, Nt as InboxErrorHandler, O as IdempotencyKeyCallback, Ot as CustomCollectionCounter, P as OutboxListenerSetters, Pt as InboxListener, Q as RespondWithObjectOptions, Qt as buildCollectionSynchronizationHeader, R as FederationOrigin, Rt as ObjectDispatcher, S as Federation, St as ActorHandleMapper, T as FederationFetchOptions, Tt as CollectionCounter, U as TaskDefinition, Ut as PortableActorIdMapper, V as Message, Vt as OutboxListenerErrorHandler, W as TaskDefinitionOptions, Wt as PortableCollectionOwnerMapper, X as RetryPolicy, Xt as SenderKeyPair, Y as RetryContext, Yt as SendActivityError, Z as createExponentialBackoffPolicy, Zt as PageItems, _ as ActorCallbackSetters, _t as NormalizedCircuitBreakerOptions, a as GetObjectOptions, at as MessageQueueEnqueueOptions, b as CustomCollectionCallbackSetters, bt as ActorAliasMapper, c as IsSignedByAudienceOptions, ct as CircuitBreaker, d as ParseUriResult, dt as CircuitBreakerCreateOptions, et as respondWithObjectIfAcceptable, f as PortableRequest, ft as CircuitBreakerFailurePolicy, g as SendActivityOptionsForCollection, gt as CircuitBreakerStateChange, h as SendActivityOptions, ht as CircuitBreakerState, i as GetActorOptions, it as MessageQueueDepth, j as InboxListenerSetters, jt as HashlinkMediaDispatcher, k as IdempotencyStrategy, kt as CustomCollectionCursor, l as OutboxContext, lt as CircuitBreakerActivityDrop, m as RouteActivityOptions, mt as CircuitBreakerOptions, n as Context, nt as InProcessMessageQueueOptions, o as GetSignedKeyOptions, ot as MessageQueueListenOptions, p as RequestContext, pt as CircuitBreakerKvState, q as TaskRegistry, qt as UnverifiedActivityReason, r as ForwardActivityOptions, rt as MessageQueue, s as InboxContext, st as ParallelMessageQueue, t as ActorKeyPair, tt as InProcessMessageQueue, u as ParseUriOptions, ut as CircuitBreakerBeforeSendDecision, v as CollectionCallbackSetters, vt as normalizeCircuitBreakerOptions, w as FederationBuilder, wt as AuthorizePredicate, x as Federatable, xt as ActorDispatcher, y as ConstructorWithTypeId, yt as parseCircuitBreakerKvState, z as FederationQueueOptions, zt as OutboxErrorHandler } from "../context-CtI307_A.js";
|
|
3
|
+
import { a as MemoryKvStore, i as KvStoreSetOptions, n as KvStore, r as KvStoreListEntry, t as KvKey } from "../kv-B2mzK5tl.js";
|
|
4
|
+
import { a as RouterOptions, i as RouterError, n as handleWebFinger, o as RouterRouteResult, r as Router, t as WebFingerHandlerParameters } from "../mod-BhTaDR5H.js";
|
|
5
5
|
export { ActorAliasMapper, ActorCallbackSetters, ActorDispatcher, ActorHandleMapper, ActorKeyPair, ActorKeyPairsDispatcher, AuthorizePredicate, CircuitBreaker, CircuitBreakerActivityDrop, CircuitBreakerBeforeSendDecision, CircuitBreakerCreateOptions, CircuitBreakerFailurePolicy, CircuitBreakerKvState, CircuitBreakerOptions, CircuitBreakerState, CircuitBreakerStateChange, CollectionCallbackSetters, CollectionCounter, CollectionCursor, CollectionDispatcher, ConstructorWithTypeId, Context, CreateExponentialBackoffPolicyOptions, CustomCollectionCallbackSetters, CustomCollectionCounter, CustomCollectionCursor, CustomCollectionDispatcher, Federatable, Federation, FederationBenchmarkOptions, FederationBuilder, FederationFetchOptions, FederationKvPrefixes, FederationOptions, FederationOrigin, FederationQueueOptions, FederationStartQueueOptions, ForwardActivityOptions, GetActorOptions, GetObjectOptions, GetSignedKeyOptions, HashlinkMediaDispatcher, HashlinkMediaRequest, IdempotencyKeyCallback, IdempotencyStrategy, InProcessMessageQueue, InProcessMessageQueueOptions, InboxChallengePolicy, InboxContext, InboxErrorHandler, InboxListener, InboxListenerSetters, IsSignedByAudienceOptions, KvKey, KvStore, KvStoreListEntry, KvStoreSetOptions, MediaUploaderCallback, MediaUploaderSetters, MemoryKvStore, Message, MessageQueue, MessageQueueDepth, MessageQueueEnqueueOptions, MessageQueueListenOptions, NodeInfoDispatcher, NormalizedCircuitBreakerOptions, ObjectAuthorizePredicate, ObjectCallbackSetters, ObjectDispatcher, OutboxContext, OutboxErrorHandler, OutboxListener, OutboxListenerErrorHandler, OutboxListenerSetters, OutboxPermanentFailureHandler, PageItems, ParallelMessageQueue, ParseUriOptions, ParseUriResult, PortableActorIdMapper, PortableCollectionOwnerMapper, PortableInboxForwardingOptions, PortableRequest, RequestContext, RespondWithObjectOptions, RetryContext, RetryPolicy, Rfc6570Expression, RouteActivityOptions, Router, RouterError, RouterOptions, RouterRouteResult, SendActivityError, SendActivityOptions, SendActivityOptionsForCollection, SenderKeyPair, SharedInboxKeyDispatcher, TaskDefinition, TaskDefinitionOptions, TaskEnqueueOptions, TaskHandler, TaskRegistry, UnverifiedActivityHandler, UnverifiedActivityReason, WebFingerHandlerParameters, WebFingerLinksDispatcher, buildCollectionSynchronizationHeader, createExponentialBackoffPolicy, createFederation, createFederationBuilder, digest, handleWebFinger, normalizeCircuitBreakerOptions, parseCircuitBreakerKvState, respondWithObject, respondWithObjectIfAcceptable };
|
package/dist/federation/mod.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Temporal } from "temporal-polyfill";
|
|
2
2
|
import { URLPattern } from "urlpattern-polyfill";
|
|
3
|
-
import { a as respondWithObjectIfAcceptable, c as digest, d as parseCircuitBreakerKvState, f as createFederationBuilder, i as respondWithObject, l as CircuitBreaker, n as handleWebFinger, o as SendActivityError, r as createExponentialBackoffPolicy, s as buildCollectionSynchronizationHeader, t as createFederation, u as normalizeCircuitBreakerOptions } from "../middleware-
|
|
3
|
+
import { a as respondWithObjectIfAcceptable, c as digest, d as parseCircuitBreakerKvState, f as createFederationBuilder, i as respondWithObject, l as CircuitBreaker, n as handleWebFinger, o as SendActivityError, r as createExponentialBackoffPolicy, s as buildCollectionSynchronizationHeader, t as createFederation, u as normalizeCircuitBreakerOptions } from "../middleware-BdzcazaN.js";
|
|
4
4
|
import { getLogger } from "@logtape/logtape";
|
|
5
5
|
import { Router as Router$1, RouterError as RouterError$1, assertPath, isPath } from "@fedify/uri-template";
|
|
6
6
|
import { isEqual } from "es-toolkit";
|
|
@@ -7,12 +7,12 @@ import { t as assertEquals } from "../assert_equals-Z6IcEbWU.mjs";
|
|
|
7
7
|
import "../std__assert-DvMDRPes.mjs";
|
|
8
8
|
import { t as assertRejects } from "../assert_rejects-CTptdYck.mjs";
|
|
9
9
|
import { t as assert } from "../assert-D1Eafmd_.mjs";
|
|
10
|
-
import { n as exportJwk } from "../key-
|
|
11
|
-
import { s as detachSignature } from "../ld-
|
|
12
|
-
import { a as signObject } from "../proof-
|
|
10
|
+
import { n as exportJwk } from "../key-Djyt1BFx.mjs";
|
|
11
|
+
import { s as detachSignature } from "../ld-CNVWdooi.mjs";
|
|
12
|
+
import { a as signObject } from "../proof-z6Prgi5I.mjs";
|
|
13
13
|
import { i as rsaPrivateKey2, n as ed25519PrivateKey, r as ed25519PublicKey, s as rsaPublicKey2 } from "../keys-DIJNHW-Y.mjs";
|
|
14
|
-
import { c as assertPortableActorActivity, n as FederationImpl, o as createFederation } from "../middleware-
|
|
15
|
-
import { a as verifyCompoundPortableObjectProofs } from "../compound-proof-
|
|
14
|
+
import { c as assertPortableActorActivity, n as FederationImpl, o as createFederation } from "../middleware-C2_LcbL3.mjs";
|
|
15
|
+
import { a as verifyCompoundPortableObjectProofs } from "../compound-proof-D0xY7MBs.mjs";
|
|
16
16
|
import { configure, reset } from "@logtape/logtape";
|
|
17
17
|
import { Create, Note, Person } from "@fedify/vocab";
|
|
18
18
|
import { exportDidKey, parseIri } from "@fedify/vocab-runtime";
|
|
@@ -8,10 +8,10 @@ import { t as assertInstanceOf } from "../assert_instance_of-mrXWWNY-.mjs";
|
|
|
8
8
|
import { t as assertThrows } from "../assert_throws-BYITOvPO.mjs";
|
|
9
9
|
import "../std__assert-DvMDRPes.mjs";
|
|
10
10
|
import { t as assert } from "../assert-D1Eafmd_.mjs";
|
|
11
|
-
import { a as signObject, c as verifyPortableObjectProof } from "../proof-
|
|
12
|
-
import { f as verifyRequest, l as signRequest } from "../http
|
|
11
|
+
import { a as signObject, c as verifyPortableObjectProof } from "../proof-z6Prgi5I.mjs";
|
|
12
|
+
import { f as verifyRequest, l as signRequest } from "../http-D-DpP4sd.mjs";
|
|
13
13
|
import { a as rsaPrivateKey3, c as rsaPublicKey3, i as rsaPrivateKey2, n as ed25519PrivateKey, r as ed25519PublicKey, s as rsaPublicKey2 } from "../keys-DIJNHW-Y.mjs";
|
|
14
|
-
import { b as PORTABLE_OBJECT_CONTENT_TYPE, o as createFederation } from "../middleware-
|
|
14
|
+
import { b as PORTABLE_OBJECT_CONTENT_TYPE, o as createFederation } from "../middleware-C2_LcbL3.mjs";
|
|
15
15
|
import { n as RouterError } from "../router-u5O5KCQr.mjs";
|
|
16
16
|
import { configure, reset } from "@logtape/logtape";
|
|
17
17
|
import { Note, Person, Tombstone, lookupObject } from "@fedify/vocab";
|
|
@@ -7,10 +7,10 @@ import { t as assertEquals } from "../assert_equals-Z6IcEbWU.mjs";
|
|
|
7
7
|
import { t as assertInstanceOf } from "../assert_instance_of-mrXWWNY-.mjs";
|
|
8
8
|
import "../std__assert-DvMDRPes.mjs";
|
|
9
9
|
import { t as assert } from "../assert-D1Eafmd_.mjs";
|
|
10
|
-
import { n as exportJwk } from "../key-
|
|
11
|
-
import { c as verifyPortableObjectProof, s as verifyObject } from "../proof-
|
|
10
|
+
import { n as exportJwk } from "../key-Djyt1BFx.mjs";
|
|
11
|
+
import { c as verifyPortableObjectProof, s as verifyObject } from "../proof-z6Prgi5I.mjs";
|
|
12
12
|
import { i as rsaPrivateKey2, n as ed25519PrivateKey, r as ed25519PublicKey, s as rsaPublicKey2 } from "../keys-DIJNHW-Y.mjs";
|
|
13
|
-
import { n as FederationImpl } from "../middleware-
|
|
13
|
+
import { n as FederationImpl } from "../middleware-C2_LcbL3.mjs";
|
|
14
14
|
import { Create, DataIntegrityProof, Note, OrderedCollection, Person, traverseCollection } from "@fedify/vocab";
|
|
15
15
|
import { FetchError, encodeMultibase, exportDidKey } from "@fedify/vocab-runtime";
|
|
16
16
|
import { mockDocumentLoader, test } from "@fedify/fixture";
|
|
@@ -7,11 +7,11 @@ import { t as assertFalse } from "../assert_false-CPdRnc3E.mjs";
|
|
|
7
7
|
import { t as assertThrows } from "../assert_throws-BYITOvPO.mjs";
|
|
8
8
|
import "../std__assert-DvMDRPes.mjs";
|
|
9
9
|
import { t as assert } from "../assert-D1Eafmd_.mjs";
|
|
10
|
-
import { a as signObject } from "../proof-
|
|
10
|
+
import { a as signObject } from "../proof-z6Prgi5I.mjs";
|
|
11
11
|
import { n as ed25519PrivateKey, r as ed25519PublicKey } from "../keys-DIJNHW-Y.mjs";
|
|
12
|
-
import { b as PORTABLE_OBJECT_CONTENT_TYPE, o as createFederation } from "../middleware-
|
|
13
|
-
import { t as verifyPortableObject } from "../portable-collection-
|
|
14
|
-
import { s as verifyServedPortableObjects } from "../compound-proof-
|
|
12
|
+
import { b as PORTABLE_OBJECT_CONTENT_TYPE, o as createFederation } from "../middleware-C2_LcbL3.mjs";
|
|
13
|
+
import { t as verifyPortableObject } from "../portable-collection-hcONGyUs.mjs";
|
|
14
|
+
import { s as verifyServedPortableObjects } from "../compound-proof-D0xY7MBs.mjs";
|
|
15
15
|
import { n as RouterError } from "../router-u5O5KCQr.mjs";
|
|
16
16
|
import { configure, reset } from "@logtape/logtape";
|
|
17
17
|
import { Create, Note, Object as Object$1, OrderedCollection, PUBLIC_COLLECTION, Person, Tombstone, lookupObject, traverseCollection } from "@fedify/vocab";
|
|
@@ -4,8 +4,8 @@ globalThis.addEventListener = () => {};
|
|
|
4
4
|
import { t as esm_default } from "../esm-BHXXx4Wx.mjs";
|
|
5
5
|
import { t as MemoryKvStore } from "../kv-DCHkaJ9-.mjs";
|
|
6
6
|
import { i as rsaPrivateKey2, s as rsaPublicKey2 } from "../keys-DIJNHW-Y.mjs";
|
|
7
|
-
import { n as FederationImpl, r as InboxContextImpl } from "../middleware-
|
|
8
|
-
import { n as extractInboxes, t as SendActivityError } from "../send-
|
|
7
|
+
import { n as FederationImpl, r as InboxContextImpl } from "../middleware-C2_LcbL3.mjs";
|
|
8
|
+
import { n as extractInboxes, t as SendActivityError } from "../send-Cw545L_2.mjs";
|
|
9
9
|
import { Create, Endpoints, Note, Person } from "@fedify/vocab";
|
|
10
10
|
import { parseIri } from "@fedify/vocab-runtime";
|
|
11
11
|
import { mockDocumentLoader, test } from "@fedify/fixture";
|
|
@@ -8,11 +8,11 @@ import { t as assertEquals } from "../assert_equals-Z6IcEbWU.mjs";
|
|
|
8
8
|
import "../std__assert-DvMDRPes.mjs";
|
|
9
9
|
import { t as assertRejects } from "../assert_rejects-CTptdYck.mjs";
|
|
10
10
|
import { r as getVerifiedKeyOwnerEvidence } from "../key-owner-evidence-APB6NpSk.mjs";
|
|
11
|
-
import { p as signJsonLd } from "../ld-
|
|
12
|
-
import { f as verifyRequest, l as signRequest, p as verifyRequestDetailed } from "../http
|
|
11
|
+
import { p as signJsonLd } from "../ld-CNVWdooi.mjs";
|
|
12
|
+
import { f as verifyRequest, l as signRequest, p as verifyRequestDetailed } from "../http-D-DpP4sd.mjs";
|
|
13
13
|
import { a as rsaPrivateKey3, i as rsaPrivateKey2, n as ed25519PrivateKey, r as ed25519PublicKey, s as rsaPublicKey2 } from "../keys-DIJNHW-Y.mjs";
|
|
14
|
-
import { f as handleInbox, n as FederationImpl, o as createFederation } from "../middleware-
|
|
15
|
-
import { n as getKeyOwner, t as doesActorOwnKey } from "../owner-
|
|
14
|
+
import { f as handleInbox, n as FederationImpl, o as createFederation } from "../middleware-C2_LcbL3.mjs";
|
|
15
|
+
import { n as getKeyOwner, t as doesActorOwnKey } from "../owner-D_BDPwm2.mjs";
|
|
16
16
|
import { t as ActivityListenerSet } from "../activity-listener-C-BSbKI7.mjs";
|
|
17
17
|
import { t as KvKeyCache } from "../keycache-Da8A8mZa.mjs";
|
|
18
18
|
import { Create, CryptographicKey, Person } from "@fedify/vocab";
|