@fedify/fedify 2.5.0-dev.2618 → 2.5.0-dev.2664
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/{builder-C-zhu1PC.mjs → builder-CGJ-NXcZ.mjs} +2 -2
- package/dist/compat/transformers.test.mjs +1 -1
- package/dist/{compound-proof-B6Mz3pzt.mjs → compound-proof-CnzwOddk.mjs} +2 -2
- package/dist/{context-A-Nde3u-.mjs → context-LgGFFSz7.mjs} +1 -1
- package/dist/{deno-CaPDSXDl.mjs → deno-eoFpPk7W.mjs} +1 -1
- package/dist/{dist-DJQM4u7i.mjs → dist-_geWsuaI.mjs} +1 -1
- package/dist/{docloader-kYMkiXaB.mjs → docloader-DwkipyL1.mjs} +2 -2
- package/dist/federation/builder.test.mjs +1 -1
- package/dist/federation/compound-fanout.test.mjs +5 -5
- package/dist/federation/handler-compound-proof.test.mjs +4 -4
- 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/inbox-actorless.test.mjs +5 -5
- package/dist/federation/inbox-report.test.mjs +5 -5
- package/dist/federation/inbox-view.test.mjs +1 -1
- package/dist/federation/inbox.test.mjs +1 -1
- package/dist/federation/metrics.test.mjs +1 -1
- package/dist/federation/middleware.test.mjs +16 -13
- package/dist/federation/mod.cjs +1 -1
- package/dist/federation/mod.js +1 -1
- package/dist/federation/mq.test.mjs +1 -1
- package/dist/federation/negotiation.test.mjs +1 -1
- package/dist/federation/outbound-capture.test.mjs +1 -1
- package/dist/federation/outbound-dispatch.test.mjs +1 -1
- package/dist/federation/outbound-document.test.mjs +1 -1
- package/dist/federation/outbound-provenance.test.mjs +2 -2
- package/dist/federation/outbound-report.test.mjs +5 -5
- package/dist/federation/outbound-workflow.test.mjs +1 -1
- package/dist/federation/outgoing-proof.test.mjs +7 -7
- 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 +5 -5
- package/dist/federation/portable-delivery.test.mjs +2 -2
- package/dist/federation/portable-gateway-keys.test.mjs +6 -6
- 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 +4 -4
- package/dist/federation/tasks/enqueue.test.mjs +3 -3
- package/dist/federation/tasks/tasks.test.mjs +4 -4
- package/dist/federation/temporal.test.mjs +1 -1
- package/dist/federation/webfinger.test.mjs +2 -2
- package/dist/{federation-c-ulWHXG.cjs → federation-FbwcnRHg.cjs} +13 -9
- package/dist/{http-C12QVNZt.js → http-CWn0K5jD.js} +2 -2
- package/dist/{http-DwL_g670.cjs → http-DbvOPsFZ.cjs} +2 -2
- package/dist/{http-NYqvoigN.mjs → http-l1zKGCll.mjs} +4 -4
- package/dist/{inbox-CkL5YgHZ.mjs → inbox-CWX3EBTO.mjs} +2 -2
- package/dist/{inbox-view-IJCZG0_b.mjs → inbox-view-DkPCF71K.mjs} +1 -1
- package/dist/{kv-cache-BdFnnrOU.mjs → kv-cache-8eJh4Xum.mjs} +1 -1
- package/dist/{kv-cache-CcGUsFoZ.cjs → kv-cache-B-fOrhb-.cjs} +1 -1
- package/dist/{kv-cache-1BO1Deou.js → kv-cache-BC837EqC.js} +1 -1
- package/dist/{ld-CEOS8Pho.mjs → ld-Cdt8qD-r.mjs} +3 -3
- package/dist/{metrics-CvuJeWaJ.mjs → metrics-BnfvSPj9.mjs} +1 -1
- package/dist/{middleware-BPZ9KhAd.mjs → middleware-CwnXJze2.mjs} +1 -1
- package/dist/{middleware-DMrpt2wD.mjs → middleware-D_W_LdJN.mjs} +25 -21
- package/dist/{middleware-CzcR7pNr.js → middleware-n2UrG62B.js} +13 -9
- package/dist/mod.cjs +4 -4
- package/dist/mod.js +4 -4
- package/dist/{negotiation-CCocWT_N.mjs → negotiation-BAKO9nih.mjs} +1 -1
- package/dist/nodeinfo/handler.test.mjs +2 -2
- package/dist/{owner-BOyHaAlU.mjs → owner-DukEQnv3.mjs} +3 -3
- package/dist/{portable-collection-B4HFXlgN.js → portable-collection-DQhIkX5a.js} +1 -1
- package/dist/{portable-collection-D_zZTK4C.cjs → portable-collection-DseoiPPj.cjs} +1 -1
- package/dist/{portable-collection-BBSMcaDY.mjs → portable-collection-OHaqa11n.mjs} +2 -2
- package/dist/{portable-key-CF8xK_lj.mjs → portable-key-BkOLJxVz.mjs} +1 -1
- package/dist/{proof-VrE-GaGv.mjs → proof-Y7omSVvc.mjs} +3 -3
- package/dist/{send-CY6agn9T.mjs → send-ccQynabr.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 +3 -3
- package/dist/sig/key.test.mjs +1 -1
- package/dist/sig/ld.test.mjs +1 -1
- package/dist/sig/mitra-receive-interop.test.mjs +4 -4
- package/dist/sig/mitra-send-interop.test.mjs +3 -3
- 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-interop.test.mjs +3 -3
- package/dist/sig/portable-key.test.mjs +5 -5
- package/dist/sig/proof.test.mjs +3 -3
- package/dist/sig/tootik-request-interop.test.mjs +4 -4
- package/dist/sig/tootik-send-interop.test.mjs +3 -3
- package/dist/sig/verification.test.mjs +3 -3
- package/dist/{tasks-IG3pHfvZ.mjs → tasks-BCUmQbbz.mjs} +1 -1
- package/dist/{temporal-QO2pe6W4.mjs → temporal-f_K4lAVR.mjs} +1 -1
- package/dist/testing/context.test.mjs +1 -1
- package/dist/testing/kv.test.mjs +3 -3
- package/dist/testing/mod.mjs +4 -4
- package/dist/{testing-_9kJHvqh.mjs → testing-vrnD5Uaa.mjs} +3 -3
- package/dist/utils/docloader.test.mjs +3 -3
- package/dist/utils/kv-cache.test.mjs +1 -1
- package/dist/utils/mod.cjs +1 -1
- package/dist/utils/mod.js +1 -1
- package/package.json +8 -8
package/README.md
CHANGED
|
@@ -232,8 +232,8 @@ financial contributors:[^2]
|
|
|
232
232
|
|
|
233
233
|
### Supporters
|
|
234
234
|
|
|
235
|
-
- [Blaine](https://opencollective.com/blaine)
|
|
236
235
|
- [tkgka](https://opencollective.com/tkgka)
|
|
236
|
+
- [Blaine](https://opencollective.com/blaine)
|
|
237
237
|
- [Erick González Aguilar](https://opencollective.com/erick-gonzalez-aguilar)
|
|
238
238
|
- [Daniel Supernault](https://pixelfed.org/)
|
|
239
239
|
|
|
@@ -243,7 +243,7 @@ Encyclia, Robin Riley, box464, Evan Prodromou, taye, okin, yamanoku, malte, Rafa
|
|
|
243
243
|
|
|
244
244
|
### One-time donations
|
|
245
245
|
|
|
246
|
-
Robin Riley, malte, Nils Bergmann, Markus P, Rameez, Guest, Guest, 1, Guest, Guest, Guest, Guest, Guest, Guest, Guest, Guest, Guest, 1, 1, Wil
|
|
246
|
+
Robin Riley, malte, Nils Bergmann, Markus P, Rameez, nyanrus, Guest, Guest, 1, Guest, Guest, Guest, Guest, Guest, Guest, Guest, Guest, Guest, 1, 1, Wil
|
|
247
247
|
|
|
248
248
|
<!-- /DO NOT EDIT -->
|
|
249
249
|
|
|
@@ -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-eoFpPk7W.mjs";
|
|
6
6
|
import { n as snapshotSenderPayloadOption } from "./outbound-document-BMgwLXTY.mjs";
|
|
7
7
|
import { n as snapshotBodyCapture } from "./outbound-capture-DVgnRzlf.mjs";
|
|
8
8
|
import { t as ActivityListenerSet } from "./activity-listener-CELFAodc.mjs";
|
|
@@ -156,7 +156,7 @@ var FederationBuilderImpl = class {
|
|
|
156
156
|
* specified.
|
|
157
157
|
*/
|
|
158
158
|
async build(options) {
|
|
159
|
-
const { FederationImpl } = await import("./middleware-
|
|
159
|
+
const { FederationImpl } = await import("./middleware-CwnXJze2.mjs");
|
|
160
160
|
const f = new FederationImpl(options);
|
|
161
161
|
const trailingSlashInsensitiveValue = f.router.trailingSlashInsensitive;
|
|
162
162
|
f.router = this.router.clone();
|
|
@@ -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 { O as actorDehydrator, k as autoIdAssigner, n as FederationImpl } from "../middleware-
|
|
8
|
+
import { O as actorDehydrator, k as autoIdAssigner, n as FederationImpl } from "../middleware-D_W_LdJN.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,9 +3,9 @@ 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 { a as verificationObservation, t as observeAttempt } from "./verification-Dpfcw8ml.mjs";
|
|
6
|
-
import { c as getNormalizationContextLoader } from "./ld-
|
|
6
|
+
import { c as getNormalizationContextLoader } from "./ld-Cdt8qD-r.mjs";
|
|
7
7
|
import { n as preloadedOnlyDocumentLoader } from "./public-audience--klBIOk1.mjs";
|
|
8
|
-
import { c as verifyMapLocalProof, f as verifyPortableObjectProofPolicy, m as verifyPreparedPortableObjectProofPolicy, n as classifyFep2277CoreType, o as preparePortableObjectProofPolicy } from "./proof-
|
|
8
|
+
import { c as verifyMapLocalProof, f as verifyPortableObjectProofPolicy, m as verifyPreparedPortableObjectProofPolicy, n as classifyFep2277CoreType, o as preparePortableObjectProofPolicy } from "./proof-Y7omSVvc.mjs";
|
|
9
9
|
import { parseIri, preloadedContexts } from "@fedify/vocab-runtime";
|
|
10
10
|
import jsonld from "@fedify/vocab-runtime/jsonld";
|
|
11
11
|
//#region src/sig/compound-proof.ts
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "temporal-polyfill";
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
|
-
import { t as mockDocumentLoader } from "./dist-
|
|
4
|
+
import { t as mockDocumentLoader } from "./dist-_geWsuaI.mjs";
|
|
5
5
|
import { t as isInAudience } from "./audience-CHQ-FlLD.mjs";
|
|
6
6
|
import { i as getEmptyAuthenticationEvidence } from "./inbox-authentication-CgonVRkg.mjs";
|
|
7
7
|
import { RouterError } from "@fedify/uri-template";
|
|
@@ -181,7 +181,7 @@ function caller() {
|
|
|
181
181
|
const Trace = Error;
|
|
182
182
|
const _ = Trace.prepareStackTrace;
|
|
183
183
|
Trace.prepareStackTrace = (_, stack) => stack;
|
|
184
|
-
const { stack } = /* @__PURE__ */ new Error();
|
|
184
|
+
const { stack } = /* @__PURE__ */ new Error("capture stack");
|
|
185
185
|
Trace.prepareStackTrace = _;
|
|
186
186
|
return stack[2].getFileName().replaceAll("\\", "/");
|
|
187
187
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import "temporal-polyfill";
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
|
-
import { D as validateCryptoKey } from "./ld-
|
|
5
|
-
import { r as doubleKnockScoped } from "./http-
|
|
4
|
+
import { D as validateCryptoKey } from "./ld-Cdt8qD-r.mjs";
|
|
5
|
+
import { r as doubleKnockScoped } from "./http-l1zKGCll.mjs";
|
|
6
6
|
import { getLogger } from "@logtape/logtape";
|
|
7
7
|
import { FetchError, UrlError, createActivityPubRequest, getRemoteDocument, logRequest, resolveDocumentLoaderTimeout, withDocumentLoaderTimeout } from "@fedify/vocab-runtime";
|
|
8
8
|
import { curry } from "es-toolkit";
|
|
@@ -7,7 +7,7 @@ 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
9
|
import { t as assertStrictEquals } from "../assert_strict_equals-CYvBmkpC.mjs";
|
|
10
|
-
import { r as createFederationBuilder } from "../builder-
|
|
10
|
+
import { r as createFederationBuilder } from "../builder-CGJ-NXcZ.mjs";
|
|
11
11
|
import { DisallowedOperatorError, DisallowedVarSpecModifierError, DuplicateRouteVariableError, RouteTemplateOptionsNotMatchedError, RouterError } from "@fedify/uri-template";
|
|
12
12
|
import { Activity, Note, Person } from "@fedify/vocab";
|
|
13
13
|
import { test } from "@fedify/fixture";
|
|
@@ -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 { x as exportJwk } from "../ld-
|
|
9
|
+
import { x as exportJwk } from "../ld-Cdt8qD-r.mjs";
|
|
10
10
|
import { r as normalizeOutgoingActivityJsonLd } from "../outgoing-jsonld-4IJqPYos.mjs";
|
|
11
|
-
import { h as verifyProof, s as signObject } from "../proof-
|
|
11
|
+
import { h as verifyProof, s as signObject } from "../proof-Y7omSVvc.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-D_W_LdJN.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";
|
|
@@ -150,7 +150,7 @@ test("forced fanout signs before serializing so the child survives", async () =>
|
|
|
150
150
|
inboxId: new URL("https://example.com/inbox")
|
|
151
151
|
}, activity, { fanout: "force" });
|
|
152
152
|
assertEquals(queued.length, 1);
|
|
153
|
-
for (
|
|
153
|
+
for (const message of queued) await federation.processQueuedTask(void 0, message);
|
|
154
154
|
assert(delivered != null);
|
|
155
155
|
const body = delivered;
|
|
156
156
|
delete body.signature;
|
|
@@ -214,7 +214,7 @@ test("an already signed activity keeps its single proof through fanout", async (
|
|
|
214
214
|
id: new URL("https://example.com/users/bob"),
|
|
215
215
|
inboxId: new URL("https://example.com/inbox")
|
|
216
216
|
}, activity, { fanout: "force" });
|
|
217
|
-
for (
|
|
217
|
+
for (const message of queued) await federation.processQueuedTask(void 0, message);
|
|
218
218
|
assert(delivered != null);
|
|
219
219
|
const body = delivered;
|
|
220
220
|
delete body.signature;
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import "temporal-polyfill";
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
|
-
import { r as createRequestContext, t as createInboxContext } from "../context-
|
|
4
|
+
import { r as createRequestContext, t as createInboxContext } from "../context-LgGFFSz7.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 { a as compactJsonLd, h as verifyCompactJsonLd, m as signJsonLd } from "../ld-
|
|
9
|
-
import { u as signRequest } from "../http-
|
|
8
|
+
import { a as compactJsonLd, h as verifyCompactJsonLd, m as signJsonLd } from "../ld-Cdt8qD-r.mjs";
|
|
9
|
+
import { u as signRequest } from "../http-l1zKGCll.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-D_W_LdJN.mjs";
|
|
12
12
|
import { t as ActivityListenerSet } from "../activity-listener-CELFAodc.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";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Temporal } from "temporal-polyfill";
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
|
-
import { n as createOutboxContext, r as createRequestContext, t as createInboxContext } from "../context-
|
|
4
|
+
import { n as createOutboxContext, r as createRequestContext, t as createInboxContext } from "../context-LgGFFSz7.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 { t as assertGreaterOrEqual } from "../assert_greater_or_equal-BlafOF4-.mjs";
|
|
@@ -11,11 +11,11 @@ import "../std__assert-DvMDRPes.mjs";
|
|
|
11
11
|
import { t as assertRejects } from "../assert_rejects-CTptdYck.mjs";
|
|
12
12
|
import { t as assert } from "../assert-D1Eafmd_.mjs";
|
|
13
13
|
import { r as parseAcceptSignature } from "../accept-CPVqki78.mjs";
|
|
14
|
-
import { T as generateCryptoKeyPair, a as compactJsonLd, m as signJsonLd } from "../ld-
|
|
15
|
-
import { s as signObject } from "../proof-
|
|
16
|
-
import { u as signRequest } from "../http-
|
|
14
|
+
import { T as generateCryptoKeyPair, a as compactJsonLd, m as signJsonLd } from "../ld-Cdt8qD-r.mjs";
|
|
15
|
+
import { s as signObject } from "../proof-Y7omSVvc.mjs";
|
|
16
|
+
import { u as signRequest } from "../http-l1zKGCll.mjs";
|
|
17
17
|
import { a as rsaPrivateKey3, c as rsaPublicKey3, n as ed25519PrivateKey, s as rsaPublicKey2, t as ed25519Multikey } 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-D_W_LdJN.mjs";
|
|
19
19
|
import { t as ActivityListenerSet } from "../activity-listener-CELFAodc.mjs";
|
|
20
20
|
import { t as FedifySpanExporter } from "../exporter-DVG68ozH.mjs";
|
|
21
21
|
import { configure, getLogger, reset, withContext } from "@logtape/logtape";
|
|
@@ -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 { r as createFederationBuilder } from "../builder-
|
|
14
|
-
import { o as createFederation, x as parseHashlinkGatewayRequest } from "../middleware-
|
|
13
|
+
import { r as createFederationBuilder } from "../builder-CGJ-NXcZ.mjs";
|
|
14
|
+
import { o as createFederation, x as parseHashlinkGatewayRequest } from "../middleware-D_W_LdJN.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 { s as signObject } from "../proof-
|
|
7
|
+
import { s as signObject } from "../proof-Y7omSVvc.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-D_W_LdJN.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
|
|
@@ -7,12 +7,12 @@ import { t as assertEquals } from "../assert_equals-Z6IcEbWU.mjs";
|
|
|
7
7
|
import { t as assertFalse } from "../assert_false-CPdRnc3E.mjs";
|
|
8
8
|
import "../std__assert-DvMDRPes.mjs";
|
|
9
9
|
import { t as assert } from "../assert-D1Eafmd_.mjs";
|
|
10
|
-
import { m as signJsonLd } from "../ld-
|
|
11
|
-
import { s as signObject } from "../proof-
|
|
12
|
-
import { u as signRequest } from "../http-
|
|
10
|
+
import { m as signJsonLd } from "../ld-Cdt8qD-r.mjs";
|
|
11
|
+
import { s as signObject } from "../proof-Y7omSVvc.mjs";
|
|
12
|
+
import { u as signRequest } from "../http-l1zKGCll.mjs";
|
|
13
13
|
import { a as rsaPrivateKey3, c as rsaPublicKey3, i as rsaPrivateKey2, n as ed25519PrivateKey, s as rsaPublicKey2 } from "../keys-DIJNHW-Y.mjs";
|
|
14
|
-
import { o as createFederation } from "../middleware-
|
|
15
|
-
import { c as expandDocument } from "../inbox-view-
|
|
14
|
+
import { o as createFederation } from "../middleware-D_W_LdJN.mjs";
|
|
15
|
+
import { c as expandDocument } from "../inbox-view-DkPCF71K.mjs";
|
|
16
16
|
import { t as KvKeyCache } from "../keycache-N2opu4-3.mjs";
|
|
17
17
|
import { Create, CryptographicKey, FeatureRequest, Person } from "@fedify/vocab";
|
|
18
18
|
import { FetchError, encodeMultibase, preloadedContexts } from "@fedify/vocab-runtime";
|
|
@@ -2,12 +2,12 @@ import "temporal-polyfill";
|
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
4
|
import { t as MemoryKvStore } from "../kv-DCHkaJ9-.mjs";
|
|
5
|
-
import { m as signJsonLd } from "../ld-
|
|
6
|
-
import { s as signObject } from "../proof-
|
|
7
|
-
import { u as signRequest } from "../http-
|
|
5
|
+
import { m as signJsonLd } from "../ld-Cdt8qD-r.mjs";
|
|
6
|
+
import { s as signObject } from "../proof-Y7omSVvc.mjs";
|
|
7
|
+
import { u as signRequest } from "../http-l1zKGCll.mjs";
|
|
8
8
|
import { a as rsaPrivateKey3, c as rsaPublicKey3, i as rsaPrivateKey2, n as ed25519PrivateKey, s as rsaPublicKey2, t as ed25519Multikey } from "../keys-DIJNHW-Y.mjs";
|
|
9
|
-
import { r as createFederationBuilder } from "../builder-
|
|
10
|
-
import { o as createFederation, t as ContextImpl } from "../middleware-
|
|
9
|
+
import { r as createFederationBuilder } from "../builder-CGJ-NXcZ.mjs";
|
|
10
|
+
import { o as createFederation, t as ContextImpl } from "../middleware-D_W_LdJN.mjs";
|
|
11
11
|
import { Create, Person } from "@fedify/vocab";
|
|
12
12
|
import { exportDidKey, parseIri } from "@fedify/vocab-runtime";
|
|
13
13
|
import { createTestTracerProvider, mockDocumentLoader, test } from "@fedify/fixture";
|
|
@@ -6,7 +6,7 @@ import { t as assertFalse } from "../assert_false-CPdRnc3E.mjs";
|
|
|
6
6
|
import "../std__assert-DvMDRPes.mjs";
|
|
7
7
|
import { t as assertRejects } from "../assert_rejects-CTptdYck.mjs";
|
|
8
8
|
import { t as assert } from "../assert-D1Eafmd_.mjs";
|
|
9
|
-
import { a as createSnapshotOnlyLoader, c as expandDocument, f as restoreVerifiedActivityView, i as createReleasableLoader, l as getActorPresence, n as buildVerifiedActivityView, p as serializeContextSnapshot, r as createContextSnapshot, s as deserializeContextSnapshot, t as ContextSnapshotMissError, u as getPropertyValues } from "../inbox-view-
|
|
9
|
+
import { a as createSnapshotOnlyLoader, c as expandDocument, f as restoreVerifiedActivityView, i as createReleasableLoader, l as getActorPresence, n as buildVerifiedActivityView, p as serializeContextSnapshot, r as createContextSnapshot, s as deserializeContextSnapshot, t as ContextSnapshotMissError, u as getPropertyValues } from "../inbox-view-DkPCF71K.mjs";
|
|
10
10
|
import { getDocumentLoader, preloadedContexts } from "@fedify/vocab-runtime";
|
|
11
11
|
import { test } from "@fedify/fixture";
|
|
12
12
|
//#region src/federation/inbox-view.test.ts
|
|
@@ -4,7 +4,7 @@ globalThis.addEventListener = () => {};
|
|
|
4
4
|
import { t as assertEquals } from "../assert_equals-Z6IcEbWU.mjs";
|
|
5
5
|
import { t as assertFalse } from "../assert_false-CPdRnc3E.mjs";
|
|
6
6
|
import { t as assertThrows } from "../assert_throws-BYITOvPO.mjs";
|
|
7
|
-
import { t as actorsHaveSameOrigin } from "../inbox-
|
|
7
|
+
import { t as actorsHaveSameOrigin } from "../inbox-CWX3EBTO.mjs";
|
|
8
8
|
import { t as ActivityListenerSet } from "../activity-listener-CELFAodc.mjs";
|
|
9
9
|
import { Activity, Create, Invite, Offer, Update } from "@fedify/vocab";
|
|
10
10
|
import { parseIri } from "@fedify/vocab-runtime";
|
|
@@ -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-BnfvSPj9.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";
|
|
@@ -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 { t as ManualClockKvStore } from "../kv-DBRWVx3Q.mjs";
|
|
7
|
-
import { a as numberSchema, r as envelopeSchema, t as MockQueue } from "../tasks-
|
|
8
|
-
import "../testing-
|
|
7
|
+
import { a as numberSchema, r as envelopeSchema, t as MockQueue } from "../tasks-BCUmQbbz.mjs";
|
|
8
|
+
import "../testing-vrnD5Uaa.mjs";
|
|
9
9
|
import { t as assertEquals } from "../assert_equals-Z6IcEbWU.mjs";
|
|
10
10
|
import { t as assertExists } from "../assert_exists-cffSpJ7X.mjs";
|
|
11
11
|
import { t as assertFalse } from "../assert_false-CPdRnc3E.mjs";
|
|
@@ -16,18 +16,18 @@ 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 { _ as verifyJsonLd, a as compactJsonLd, m as signJsonLd, s as detachSignature } from "../ld-
|
|
21
|
-
import { l as verifyObject, s as signObject } from "../proof-
|
|
22
|
-
import { p as verifyRequest, u as signRequest } from "../http-
|
|
19
|
+
import { g as recordInboxActivity } from "../metrics-BnfvSPj9.mjs";
|
|
20
|
+
import { _ as verifyJsonLd, a as compactJsonLd, m as signJsonLd, s as detachSignature } from "../ld-Cdt8qD-r.mjs";
|
|
21
|
+
import { l as verifyObject, s as signObject } from "../proof-Y7omSVvc.mjs";
|
|
22
|
+
import { p as verifyRequest, u as signRequest } from "../http-l1zKGCll.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 { n as getAuthenticatedDocumentLoader } from "../docloader-
|
|
25
|
-
import { T 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 { n as getAuthenticatedDocumentLoader } from "../docloader-DwkipyL1.mjs";
|
|
25
|
+
import { T as handleBenchmarkTrigger, i as KvSpecDeterminer, n as FederationImpl, o as createFederation, r as InboxContextImpl, t as ContextImpl } from "../middleware-D_W_LdJN.mjs";
|
|
26
|
+
import { t as doesActorOwnKey } from "../owner-DukEQnv3.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";
|
|
30
|
-
import { configure, reset, withContext } from "@logtape/logtape";
|
|
30
|
+
import { configure, getTextFormatter, reset, withContext } from "@logtape/logtape";
|
|
31
31
|
import { RouterError } from "@fedify/uri-template";
|
|
32
32
|
import * as vocab from "@fedify/vocab";
|
|
33
33
|
import { Create, CryptographicKey, Note, Offer, Person, getTypeId, lookupObject } from "@fedify/vocab";
|
|
@@ -213,7 +213,10 @@ test("createFederation()", async (t) => {
|
|
|
213
213
|
});
|
|
214
214
|
assertEquals(records.length, 1);
|
|
215
215
|
assertEquals(records[0].level, "warning");
|
|
216
|
-
assertEquals(records[0].rawMessage, "Fedify benchmarkMode is enabled;
|
|
216
|
+
assertEquals(records[0].rawMessage, "Fedify benchmarkMode is enabled; {relaxationSummary}. Benchmark endpoints are active and must not be used in production.");
|
|
217
|
+
assertEquals(records[0].properties.relaxationSummary, "private address checks disabled (allowPrivateAddress=true); HTTP Signature time window disabled (signatureTimeWindow=false)");
|
|
218
|
+
const formatted = getTextFormatter({ timestamp: "disabled" })(records[0]);
|
|
219
|
+
assert(formatted.includes("private address checks disabled (allowPrivateAddress=true); HTTP Signature time window disabled (signatureTimeWindow=false)"), formatted);
|
|
217
220
|
assertEquals(records[0].properties.relaxations, [{
|
|
218
221
|
protection: "private_address_checks",
|
|
219
222
|
effect: "disabled",
|
|
@@ -6154,7 +6157,7 @@ test("FederationImpl.processQueuedTask() circuit breaker", async (t) => {
|
|
|
6154
6157
|
]);
|
|
6155
6158
|
assertEquals(state?.state, "open");
|
|
6156
6159
|
assertEquals(Array.isArray(state?.failures), true);
|
|
6157
|
-
assertEquals((state?.failures)
|
|
6160
|
+
assertEquals((state?.failures)?.length, 1);
|
|
6158
6161
|
assertExists(state?.opened);
|
|
6159
6162
|
});
|
|
6160
6163
|
await t.step("open circuit requeues without sending", async () => {
|
|
@@ -6488,7 +6491,7 @@ test("FederationImpl.processQueuedTask() circuit breaker", async (t) => {
|
|
|
6488
6491
|
"unavailable.example"
|
|
6489
6492
|
]);
|
|
6490
6493
|
assertEquals(state?.state, "closed");
|
|
6491
|
-
assertEquals((state?.failures)
|
|
6494
|
+
assertEquals((state?.failures)?.length, 1);
|
|
6492
6495
|
});
|
|
6493
6496
|
await t.step("503 Retry-After delays newly opened circuit hold", async () => {
|
|
6494
6497
|
esm_default.hardReset();
|
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-FbwcnRHg.cjs");
|
|
4
4
|
exports.CircuitBreaker = require_federation.CircuitBreaker;
|
|
5
5
|
exports.InProcessMessageQueue = require_federation.InProcessMessageQueue;
|
|
6
6
|
exports.MemoryKvStore = require_federation.MemoryKvStore;
|
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 buildCollectionSynchronizationHeader, d as normalizeCircuitBreakerOptions, f as parseCircuitBreakerKvState, i as respondWithObject, l as digest, n as handleWebFinger, o as SendActivityError, p as createFederationBuilder, r as createExponentialBackoffPolicy, s as isActorAuthenticated, t as createFederation, u as CircuitBreaker } from "../middleware-
|
|
3
|
+
import { a as respondWithObjectIfAcceptable, c as buildCollectionSynchronizationHeader, d as normalizeCircuitBreakerOptions, f as parseCircuitBreakerKvState, i as respondWithObject, l as digest, n as handleWebFinger, o as SendActivityError, p as createFederationBuilder, r as createExponentialBackoffPolicy, s as isActorAuthenticated, t as createFederation, u as CircuitBreaker } from "../middleware-n2UrG62B.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,7 +7,7 @@ import { t as assertGreaterOrEqual } from "../assert_greater_or_equal-BlafOF4-.m
|
|
|
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 { r as estimateQueuedMessageSize } from "../inbox-
|
|
10
|
+
import { r as estimateQueuedMessageSize } from "../inbox-CWX3EBTO.mjs";
|
|
11
11
|
import { n as ParallelMessageQueue, t as InProcessMessageQueue } from "../mq-eF96QxUT.mjs";
|
|
12
12
|
import { delay } from "es-toolkit";
|
|
13
13
|
import { test } from "@fedify/fixture";
|
|
@@ -4,7 +4,7 @@ globalThis.addEventListener = () => {};
|
|
|
4
4
|
import { t as assertFalse } from "../assert_false-CPdRnc3E.mjs";
|
|
5
5
|
import "../std__assert-DvMDRPes.mjs";
|
|
6
6
|
import { t as assert } from "../assert-D1Eafmd_.mjs";
|
|
7
|
-
import { t as acceptsJsonLd } from "../negotiation-
|
|
7
|
+
import { t as acceptsJsonLd } from "../negotiation-BAKO9nih.mjs";
|
|
8
8
|
import { test } from "@fedify/fixture";
|
|
9
9
|
//#region src/federation/negotiation.test.ts
|
|
10
10
|
test("acceptsJsonLd()", () => {
|
|
@@ -2,7 +2,7 @@ import "temporal-polyfill";
|
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
4
|
import { n as snapshotBodyCapture, r as takeCapturedDiagnostic, t as captureResponseBody } from "../outbound-capture-DVgnRzlf.mjs";
|
|
5
|
-
import { n as FederationBuilderImpl, r as createFederationBuilder } from "../builder-
|
|
5
|
+
import { n as FederationBuilderImpl, r as createFederationBuilder } from "../builder-CGJ-NXcZ.mjs";
|
|
6
6
|
import { test } from "@fedify/fixture";
|
|
7
7
|
import { deepStrictEqual, ok, rejects, strictEqual, throws } from "node:assert/strict";
|
|
8
8
|
//#region src/federation/outbound-capture.test.ts
|
|
@@ -4,7 +4,7 @@ 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 { o as createFederation, t as ContextImpl } from "../middleware-
|
|
7
|
+
import { o as createFederation, t as ContextImpl } from "../middleware-D_W_LdJN.mjs";
|
|
8
8
|
import { configure, getLogger, reset, withContext } from "@logtape/logtape";
|
|
9
9
|
import { Create, Person } from "@fedify/vocab";
|
|
10
10
|
import { mockDocumentLoader, test } from "@fedify/fixture";
|
|
@@ -2,7 +2,7 @@ import "temporal-polyfill";
|
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
4
|
import { t as projectSenderPayload } from "../outbound-document-BMgwLXTY.mjs";
|
|
5
|
-
import { n as FederationBuilderImpl, r as createFederationBuilder } from "../builder-
|
|
5
|
+
import { n as FederationBuilderImpl, r as createFederationBuilder } from "../builder-CGJ-NXcZ.mjs";
|
|
6
6
|
import { test } from "@fedify/fixture";
|
|
7
7
|
import { deepStrictEqual, ok, strictEqual, throws } from "node:assert/strict";
|
|
8
8
|
//#region src/federation/outbound-document.test.ts
|
|
@@ -3,9 +3,9 @@ import "urlpattern-polyfill";
|
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
4
|
import { t as esm_default } from "../esm-BHXXx4Wx.mjs";
|
|
5
5
|
import { t as MemoryKvStore } from "../kv-DCHkaJ9-.mjs";
|
|
6
|
-
import { s as signObject } from "../proof-
|
|
6
|
+
import { s as signObject } from "../proof-Y7omSVvc.mjs";
|
|
7
7
|
import { i as rsaPrivateKey2, n as ed25519PrivateKey, r as ed25519PublicKey, s as rsaPublicKey2, t as ed25519Multikey } from "../keys-DIJNHW-Y.mjs";
|
|
8
|
-
import { o as createFederation, t as ContextImpl } from "../middleware-
|
|
8
|
+
import { o as createFederation, t as ContextImpl } from "../middleware-D_W_LdJN.mjs";
|
|
9
9
|
import { configure, getLogger, reset, withContext } from "@logtape/logtape";
|
|
10
10
|
import { Create, Note, Person } from "@fedify/vocab";
|
|
11
11
|
import { computeDigestMultibase, exportDidKey, parseIri } from "@fedify/vocab-runtime";
|
|
@@ -3,11 +3,11 @@ import "urlpattern-polyfill";
|
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
4
|
import { t as esm_default } from "../esm-BHXXx4Wx.mjs";
|
|
5
5
|
import { t as MemoryKvStore } from "../kv-DCHkaJ9-.mjs";
|
|
6
|
-
import { x as exportJwk } from "../ld-
|
|
6
|
+
import { x as exportJwk } from "../ld-Cdt8qD-r.mjs";
|
|
7
7
|
import { i as rsaPrivateKey2, s as rsaPublicKey2 } from "../keys-DIJNHW-Y.mjs";
|
|
8
|
-
import { a as snapshotHeaders, i as snapshotHeaderPolicy, n as FederationBuilderImpl, r as createFederationBuilder } from "../builder-
|
|
9
|
-
import { A as OutboundAttemptObservation, a as OutboxContextImpl, j as OutboundBroadcastObservation, n as FederationImpl, o as createFederation, r as InboxContextImpl, t as ContextImpl } from "../middleware-
|
|
10
|
-
import { i as sendActivity, t as SendActivityError } from "../send-
|
|
8
|
+
import { a as snapshotHeaders, i as snapshotHeaderPolicy, n as FederationBuilderImpl, r as createFederationBuilder } from "../builder-CGJ-NXcZ.mjs";
|
|
9
|
+
import { A as OutboundAttemptObservation, a as OutboxContextImpl, j as OutboundBroadcastObservation, n as FederationImpl, o as createFederation, r as InboxContextImpl, t as ContextImpl } from "../middleware-D_W_LdJN.mjs";
|
|
10
|
+
import { i as sendActivity, t as SendActivityError } from "../send-ccQynabr.mjs";
|
|
11
11
|
import { configure, reset } from "@logtape/logtape";
|
|
12
12
|
import { Create, Follow, Person } from "@fedify/vocab";
|
|
13
13
|
import { SpanKind, SpanStatusCode, TraceFlags, isSpanContextValid, propagation, trace } from "@opentelemetry/api";
|
|
@@ -1202,7 +1202,7 @@ test("outbound observers isolate callback and logging errors from success and or
|
|
|
1202
1202
|
});
|
|
1203
1203
|
federation.setOutboundObservers({ onBroadcast() {
|
|
1204
1204
|
calls++;
|
|
1205
|
-
throw "observer failed";
|
|
1205
|
+
throw new Error("observer failed");
|
|
1206
1206
|
} });
|
|
1207
1207
|
const ctx = federation.createContext(new URL("https://example.com"), void 0);
|
|
1208
1208
|
await ctx.sendActivity(sender, [], activity);
|
|
@@ -3,7 +3,7 @@ import "urlpattern-polyfill";
|
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
4
|
import { t as MemoryKvStore } from "../kv-DCHkaJ9-.mjs";
|
|
5
5
|
import { i as rsaPrivateKey2, s as rsaPublicKey2 } from "../keys-DIJNHW-Y.mjs";
|
|
6
|
-
import { o as createFederation } from "../middleware-
|
|
6
|
+
import { o as createFederation } from "../middleware-D_W_LdJN.mjs";
|
|
7
7
|
import { Create, Person } from "@fedify/vocab";
|
|
8
8
|
import { test } from "@fedify/fixture";
|
|
9
9
|
import { deepStrictEqual, ok, strictEqual } from "node:assert/strict";
|
|
@@ -7,11 +7,11 @@ 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 { s as detachSignature, x as exportJwk } from "../ld-
|
|
11
|
-
import { s as signObject } from "../proof-
|
|
10
|
+
import { s as detachSignature, x as exportJwk } from "../ld-Cdt8qD-r.mjs";
|
|
11
|
+
import { s as signObject } from "../proof-Y7omSVvc.mjs";
|
|
12
12
|
import { i as rsaPrivateKey2, n as ed25519PrivateKey, r as ed25519PublicKey, s as rsaPublicKey2 } from "../keys-DIJNHW-Y.mjs";
|
|
13
|
-
import { C as getEmbeddedFirstGateway, S as getCompactRootId, c as assertPortableActorActivity, n as FederationImpl, o as createFederation, w as warnCompatibleIdsInJson } from "../middleware-
|
|
14
|
-
import { o as verifyCompoundPortableObjectProofs } from "../compound-proof-
|
|
13
|
+
import { C as getEmbeddedFirstGateway, S as getCompactRootId, c as assertPortableActorActivity, n as FederationImpl, o as createFederation, w as warnCompatibleIdsInJson } from "../middleware-D_W_LdJN.mjs";
|
|
14
|
+
import { o as verifyCompoundPortableObjectProofs } from "../compound-proof-CnzwOddk.mjs";
|
|
15
15
|
import { configure, reset } from "@logtape/logtape";
|
|
16
16
|
import { Accept, Announce, Create, Follow, Note, Person } from "@fedify/vocab";
|
|
17
17
|
import { exportDidKey, parseIri } from "@fedify/vocab-runtime";
|
|
@@ -352,7 +352,7 @@ test("forced fanout selects the DID-matching key before enqueueing", async () =>
|
|
|
352
352
|
assertEquals(message.type, "fanout");
|
|
353
353
|
assertEquals(message.keys.length, 3);
|
|
354
354
|
assertEquals(message.keys[0].keyId, rsaKey.keyId.href);
|
|
355
|
-
for (
|
|
355
|
+
for (const message of queued) await federation.processQueuedTask(void 0, message);
|
|
356
356
|
});
|
|
357
357
|
assertEquals(bodies.length, 1);
|
|
358
358
|
assertEquals(proofOf(bodies[0]).verificationMethod, owner.keyId.href);
|
|
@@ -609,7 +609,7 @@ test("forced fanout selects the DID-matching key for a compatible-ID activity",
|
|
|
609
609
|
sender(owner)
|
|
610
610
|
], recipient, compatibleCreate(owner, await signedChild(await didKey())), { fanout: "force" });
|
|
611
611
|
assertEquals(queued.length, 1);
|
|
612
|
-
for (
|
|
612
|
+
for (const message of queued) await federation.processQueuedTask(void 0, message);
|
|
613
613
|
});
|
|
614
614
|
assertEquals(bodies.length, 1);
|
|
615
615
|
assertEquals(proofOf(bodies[0]).verificationMethod, owner.keyId.href);
|
|
@@ -735,7 +735,7 @@ test("fanout warns once before enqueueing a compatible activity", async () => {
|
|
|
735
735
|
actor: ownerId
|
|
736
736
|
}), { fanout: "force" });
|
|
737
737
|
assertEquals(queued.length, 1);
|
|
738
|
-
for (
|
|
738
|
+
for (const message of queued) await federation.processQueuedTask(void 0, message);
|
|
739
739
|
}))).filter((r) => r.properties.kind === "activity").length, 1);
|
|
740
740
|
});
|
|
741
741
|
test("an embedded actor supplies gateways to a plain send context", async () => {
|
|
@@ -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 { d as verifyPortableObjectProof, s as signObject } from "../proof-
|
|
12
|
-
import { p as verifyRequest, u as signRequest } from "../http-
|
|
11
|
+
import { d as verifyPortableObjectProof, s as signObject } from "../proof-Y7omSVvc.mjs";
|
|
12
|
+
import { p as verifyRequest, u as signRequest } from "../http-l1zKGCll.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-D_W_LdJN.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 { x as exportJwk } from "../ld-
|
|
11
|
-
import { d as verifyPortableObjectProof, l as verifyObject } from "../proof-
|
|
10
|
+
import { x as exportJwk } from "../ld-Cdt8qD-r.mjs";
|
|
11
|
+
import { d as verifyPortableObjectProof, l as verifyObject } from "../proof-Y7omSVvc.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-D_W_LdJN.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 { d as verifyPortableObjectProof, s as signObject } from "../proof-
|
|
10
|
+
import { d as verifyPortableObjectProof, s as signObject } from "../proof-Y7omSVvc.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 { c as verifyServedPortableObjects } from "../compound-proof-
|
|
12
|
+
import { b as PORTABLE_OBJECT_CONTENT_TYPE, o as createFederation } from "../middleware-D_W_LdJN.mjs";
|
|
13
|
+
import { t as verifyPortableObject } from "../portable-collection-OHaqa11n.mjs";
|
|
14
|
+
import { c as verifyServedPortableObjects } from "../compound-proof-CnzwOddk.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";
|
|
@@ -378,7 +378,7 @@ test("Federation.fetch() serves portable custom collections", async (t) => {
|
|
|
378
378
|
assertEquals(json?.id, portableId("/users/alice/bookmarks?tag=fedify&cursor=0"));
|
|
379
379
|
assertEquals(json?.partOf, portableId("/users/alice/bookmarks?tag=fedify"));
|
|
380
380
|
assertEquals(json?.next, portableId("/users/alice/bookmarks?tag=fedify&cursor=1"));
|
|
381
|
-
assertEquals((json?.orderedItems)[0]
|
|
381
|
+
assertEquals((json?.orderedItems)?.[0]?.id, portableId("/notes/fedify-0"));
|
|
382
382
|
});
|
|
383
383
|
await t.step("compatible identifiers", async () => {
|
|
384
384
|
const [response, json] = await fetchJson(federation, gatewayUrl("/users/compatible/bookmarks"));
|
|
@@ -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, t as ContextImpl } from "../middleware-
|
|
8
|
-
import { n as extractInboxes, t as SendActivityError } from "../send-
|
|
7
|
+
import { n as FederationImpl, r as InboxContextImpl, t as ContextImpl } from "../middleware-D_W_LdJN.mjs";
|
|
8
|
+
import { n as extractInboxes, t as SendActivityError } from "../send-ccQynabr.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";
|