@fedify/fedify 2.2.0-pr.708.19 → 2.2.0-pr.710.22
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-_Q1P6V24.mjs → builder-bnytmADH.mjs} +3 -3
- package/dist/compat/public-audience.test.d.mts +2 -0
- package/dist/compat/public-audience.test.mjs +162 -0
- package/dist/compat/transformers.test.mjs +2 -2
- package/dist/{deno-D544KGtd.mjs → deno-sxAmy69e.mjs} +1 -1
- package/dist/{docloader-CXAw1Ofx.mjs → docloader-CAcGw6pQ.mjs} +2 -2
- package/dist/federation/builder.test.mjs +2 -2
- package/dist/federation/collection.test.mjs +1 -1
- package/dist/federation/handler.test.mjs +4 -4
- package/dist/federation/idempotency.test.mjs +3 -3
- package/dist/federation/inbox.test.mjs +1 -1
- package/dist/federation/keycache.test.mjs +2 -2
- package/dist/federation/kv.test.mjs +1 -1
- package/dist/federation/middleware.test.mjs +17 -7
- package/dist/federation/mod.cjs +1 -1
- package/dist/federation/mod.js +1 -1
- package/dist/federation/negotiation.test.mjs +1 -1
- package/dist/federation/retry.test.mjs +1 -1
- package/dist/federation/send.test.mjs +3 -3
- package/dist/federation/webfinger.test.mjs +2 -2
- package/dist/{http-6m2N3LCD.mjs → http-BKrXOLjL.mjs} +2 -2
- package/dist/{http-BMsHAyvq.cjs → http-C1BAaJ_m.cjs} +1 -1
- package/dist/{http-CxVGLNoz.js → http-DI4R9CTK.js} +1 -1
- package/dist/{key-CCuaH5jy.mjs → key-CwG1d1a2.mjs} +1 -1
- package/dist/{kv-cache-CBQPqEDj.js → kv-cache-BQS2P8gv.js} +1 -1
- package/dist/{kv-cache-D0srbjWc.cjs → kv-cache-p33MTfBu.cjs} +1 -1
- package/dist/{ld-DN2lsaG8.mjs → ld-t2WD3nYp.mjs} +2 -2
- package/dist/{middleware-Ddf57ad_.cjs → middleware-C4JOTHSG.cjs} +1 -1
- package/dist/{middleware-Djy1WhXC.mjs → middleware-D545J7x8.mjs} +1 -1
- package/dist/{middleware-CDNoFhdO.mjs → middleware-D8r5yKV-.mjs} +17 -15
- package/dist/{middleware-C7DGuOYc.js → middleware-RhsXBX0y.js} +4 -3
- package/dist/{middleware-DmwNARrQ.cjs → middleware-cGUpoNb_.cjs} +5 -4
- package/dist/mod.cjs +4 -4
- package/dist/mod.js +4 -4
- package/dist/nodeinfo/client.test.mjs +1 -1
- package/dist/nodeinfo/handler.test.mjs +2 -2
- package/dist/nodeinfo/types.test.mjs +1 -1
- package/dist/otel/exporter.test.mjs +1 -1
- package/dist/{owner-B34dTvD2.mjs → owner-J1wYUBAp.mjs} +2 -2
- package/dist/{proof-3RKiVMZP.cjs → proof-0fe_hpBU.cjs} +221 -38
- package/dist/{proof-0cJIZBgO.js → proof-DJiXN7Qc.js} +218 -41
- package/dist/{proof-grJLXdIM.mjs → proof-DngAmXc3.mjs} +36 -31
- package/dist/public-audience-5WWE-JTr.mjs +181 -0
- package/dist/{send-Cqy2NRSV.mjs → send-CCwbKHXy.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/proof.test.mjs +60 -2
- package/dist/utils/docloader.test.mjs +2 -2
- package/dist/utils/mod.cjs +1 -1
- package/dist/utils/mod.js +1 -1
- package/package.json +5 -5
- /package/dist/{activity-listener-Ck3JZ_hR.mjs → activity-listener-CFzUqoCS.mjs} +0 -0
- /package/dist/{client-DEpOVgY1.mjs → client-DVu6Fmom.mjs} +0 -0
- /package/dist/{collection-BD6-SZ6O.mjs → collection-BQRKGS7L.mjs} +0 -0
- /package/dist/{keycache-CCSwkQcY.mjs → keycache-C2t1kvP5.mjs} +0 -0
- /package/dist/{kv-tL2TOE9X.mjs → kv-C-TG81Sv.mjs} +0 -0
- /package/dist/{negotiation-DnsfFF8I.mjs → negotiation-xb0QR3u_.mjs} +0 -0
- /package/dist/{retry-B_E3V_Dx.mjs → retry-CJL0poaU.mjs} +0 -0
- /package/dist/{types-DCP0WLdt.mjs → types-CGUnLkU3.mjs} +0 -0
|
@@ -2,8 +2,8 @@ import "@js-temporal/polyfill";
|
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
4
|
import { n as RouterError, t as Router } from "./router-CrMLXoOr.mjs";
|
|
5
|
-
import { n as version, t as name } from "./deno-
|
|
6
|
-
import { t as ActivityListenerSet } from "./activity-listener-
|
|
5
|
+
import { n as version, t as name } from "./deno-sxAmy69e.mjs";
|
|
6
|
+
import { t as ActivityListenerSet } from "./activity-listener-CFzUqoCS.mjs";
|
|
7
7
|
import { Tombstone, getTypeId } from "@fedify/vocab";
|
|
8
8
|
import { SpanKind, SpanStatusCode, trace } from "@opentelemetry/api";
|
|
9
9
|
import { getLogger } from "@logtape/logtape";
|
|
@@ -58,7 +58,7 @@ var FederationBuilderImpl = class {
|
|
|
58
58
|
this.collectionTypeIds = {};
|
|
59
59
|
}
|
|
60
60
|
async build(options) {
|
|
61
|
-
const { FederationImpl } = await import("./middleware-
|
|
61
|
+
const { FederationImpl } = await import("./middleware-D545J7x8.mjs");
|
|
62
62
|
const f = new FederationImpl(options);
|
|
63
63
|
const trailingSlashInsensitiveValue = f.router.trailingSlashInsensitive;
|
|
64
64
|
f.router = this.router.clone();
|
|
@@ -0,0 +1,162 @@
|
|
|
1
|
+
import "@js-temporal/polyfill";
|
|
2
|
+
import "urlpattern-polyfill";
|
|
3
|
+
globalThis.addEventListener = () => {};
|
|
4
|
+
import { t as assertEquals } from "../assert_equals-Ew3jOFa3.mjs";
|
|
5
|
+
import { t as assertNotEquals } from "../assert_not_equals--wG9hV7u.mjs";
|
|
6
|
+
import { t as normalizePublicAudience } from "../public-audience-5WWE-JTr.mjs";
|
|
7
|
+
import { test } from "@fedify/fixture";
|
|
8
|
+
import { Create, Note, PUBLIC_COLLECTION } from "@fedify/vocab";
|
|
9
|
+
import { getDocumentLoader, preloadedContexts } from "@fedify/vocab-runtime";
|
|
10
|
+
//#region src/compat/public-audience.test.ts
|
|
11
|
+
const PUBLIC_URI = PUBLIC_COLLECTION.href;
|
|
12
|
+
const AS_CONTEXT = "https://www.w3.org/ns/activitystreams";
|
|
13
|
+
test("normalizePublicAudience() rewrites as:Public in addressing fields", async () => {
|
|
14
|
+
const output = await normalizePublicAudience({
|
|
15
|
+
"@context": AS_CONTEXT,
|
|
16
|
+
type: "Note",
|
|
17
|
+
id: "https://example.com/notes/1",
|
|
18
|
+
to: "as:Public",
|
|
19
|
+
cc: ["as:Public", "https://example.com/bob"]
|
|
20
|
+
});
|
|
21
|
+
assertEquals(output.to, PUBLIC_URI);
|
|
22
|
+
assertEquals(output.cc, [PUBLIC_URI, "https://example.com/bob"]);
|
|
23
|
+
});
|
|
24
|
+
test("normalizePublicAudience() normalises activities serialized by @fedify/vocab", async () => {
|
|
25
|
+
const compact = await new Create({
|
|
26
|
+
id: new URL("https://example.com/activities/1"),
|
|
27
|
+
actor: new URL("https://example.com/alice"),
|
|
28
|
+
object: new Note({
|
|
29
|
+
id: new URL("https://example.com/notes/1"),
|
|
30
|
+
content: "Hello, world!",
|
|
31
|
+
tos: [PUBLIC_COLLECTION]
|
|
32
|
+
}),
|
|
33
|
+
tos: [PUBLIC_COLLECTION],
|
|
34
|
+
ccs: [new URL("https://example.com/followers")]
|
|
35
|
+
}).toJsonLd({ format: "compact" });
|
|
36
|
+
assertEquals(compact.to, "as:Public");
|
|
37
|
+
const normalized = await normalizePublicAudience(compact, getDocumentLoader());
|
|
38
|
+
assertEquals(normalized.to, PUBLIC_URI);
|
|
39
|
+
const nestedObject = normalized.object;
|
|
40
|
+
assertEquals(nestedObject.to, PUBLIC_URI);
|
|
41
|
+
});
|
|
42
|
+
test("normalizePublicAudience() is a no-op without the CURIE", async () => {
|
|
43
|
+
const input = {
|
|
44
|
+
"@context": AS_CONTEXT,
|
|
45
|
+
type: "Note",
|
|
46
|
+
id: "https://example.com/notes/3",
|
|
47
|
+
to: PUBLIC_URI
|
|
48
|
+
};
|
|
49
|
+
assertEquals(await normalizePublicAudience(input), input);
|
|
50
|
+
});
|
|
51
|
+
test("normalizePublicAudience() leaves non-addressing fields untouched", async () => {
|
|
52
|
+
const output = await normalizePublicAudience({
|
|
53
|
+
"@context": AS_CONTEXT,
|
|
54
|
+
type: "Note",
|
|
55
|
+
id: "https://example.com/notes/4",
|
|
56
|
+
name: "as:Public",
|
|
57
|
+
to: "as:Public"
|
|
58
|
+
});
|
|
59
|
+
assertEquals(output.name, "as:Public");
|
|
60
|
+
assertEquals(output.to, PUBLIC_URI);
|
|
61
|
+
});
|
|
62
|
+
test("normalizePublicAudience() rewrites without canonicalization for known-safe contexts", async () => {
|
|
63
|
+
const rejecting = () => {
|
|
64
|
+
throw new Error("contextLoader should not be called for a known-safe @context");
|
|
65
|
+
};
|
|
66
|
+
assertEquals((await normalizePublicAudience({
|
|
67
|
+
"@context": AS_CONTEXT,
|
|
68
|
+
type: "Note",
|
|
69
|
+
id: "https://example.com/notes/fast1",
|
|
70
|
+
to: "as:Public"
|
|
71
|
+
}, rejecting)).to, PUBLIC_URI);
|
|
72
|
+
assertEquals((await normalizePublicAudience({
|
|
73
|
+
"@context": [AS_CONTEXT, "https://w3id.org/security/data-integrity/v1"],
|
|
74
|
+
type: "Note",
|
|
75
|
+
id: "https://example.com/notes/fast2",
|
|
76
|
+
to: "as:Public"
|
|
77
|
+
}, rejecting)).to, PUBLIC_URI);
|
|
78
|
+
});
|
|
79
|
+
test("normalizePublicAudience() falls back to canonicalization for unknown-URL contexts", async () => {
|
|
80
|
+
let loaderCalls = 0;
|
|
81
|
+
const loader = (url) => {
|
|
82
|
+
loaderCalls++;
|
|
83
|
+
return Promise.resolve({
|
|
84
|
+
contextUrl: null,
|
|
85
|
+
documentUrl: url,
|
|
86
|
+
document: preloadedContexts[AS_CONTEXT]
|
|
87
|
+
});
|
|
88
|
+
};
|
|
89
|
+
assertEquals((await normalizePublicAudience({
|
|
90
|
+
"@context": [AS_CONTEXT, "https://custom.example/ctx"],
|
|
91
|
+
type: "Note",
|
|
92
|
+
id: "https://example.com/notes/unknown",
|
|
93
|
+
to: "as:Public"
|
|
94
|
+
}, loader)).to, PUBLIC_URI);
|
|
95
|
+
assertEquals(loaderCalls > 0, true);
|
|
96
|
+
});
|
|
97
|
+
test("normalizePublicAudience() leaves @context subtrees untouched", async () => {
|
|
98
|
+
const inlineCtx = (await normalizePublicAudience({
|
|
99
|
+
"@context": [AS_CONTEXT, { "customTerm": "as:Public" }],
|
|
100
|
+
type: "Note",
|
|
101
|
+
id: "https://example.com/notes/context",
|
|
102
|
+
to: PUBLIC_URI
|
|
103
|
+
}))["@context"][1];
|
|
104
|
+
assertEquals(inlineCtx.customTerm, "as:Public");
|
|
105
|
+
});
|
|
106
|
+
test("normalizePublicAudience() does not traverse prototype-polluted keys", async () => {
|
|
107
|
+
const polluted = Object.create({ to: "as:Public" });
|
|
108
|
+
polluted["@context"] = AS_CONTEXT;
|
|
109
|
+
polluted.type = "Note";
|
|
110
|
+
polluted.id = "https://example.com/notes/proto";
|
|
111
|
+
const output = await normalizePublicAudience(polluted);
|
|
112
|
+
assertEquals(Object.hasOwn(output, "to"), false);
|
|
113
|
+
});
|
|
114
|
+
test("normalizePublicAudience() stops before blowing the stack on pathological nesting", async () => {
|
|
115
|
+
let deep = { to: "as:Public" };
|
|
116
|
+
for (let i = 0; i < 256; i++) deep = { nested: deep };
|
|
117
|
+
assertEquals(typeof await normalizePublicAudience({
|
|
118
|
+
"@context": AS_CONTEXT,
|
|
119
|
+
type: "Note",
|
|
120
|
+
id: "https://example.com/notes/deep",
|
|
121
|
+
to: "as:Public",
|
|
122
|
+
object: deep
|
|
123
|
+
}), "object");
|
|
124
|
+
});
|
|
125
|
+
test("normalizePublicAudience() bails out on nested @context that redefines as:", async () => {
|
|
126
|
+
const output = await normalizePublicAudience({
|
|
127
|
+
"@context": AS_CONTEXT,
|
|
128
|
+
type: "Create",
|
|
129
|
+
id: "https://example.com/activities/nested",
|
|
130
|
+
actor: "https://example.com/alice",
|
|
131
|
+
to: "as:Public",
|
|
132
|
+
object: {
|
|
133
|
+
"@context": { "as": "https://not-activitystreams.example/" },
|
|
134
|
+
type: "https://www.w3.org/ns/activitystreams#Note",
|
|
135
|
+
id: "https://example.com/objects/nested",
|
|
136
|
+
to: "as:Public"
|
|
137
|
+
}
|
|
138
|
+
});
|
|
139
|
+
assertEquals(output.to, "as:Public");
|
|
140
|
+
const nested = output.object;
|
|
141
|
+
assertEquals(nested.to, "as:Public");
|
|
142
|
+
});
|
|
143
|
+
test("normalizePublicAudience() bails out when the rewrite changes semantics", async () => {
|
|
144
|
+
const output = await normalizePublicAudience({
|
|
145
|
+
"@context": {
|
|
146
|
+
"as": "https://not-activitystreams.example/",
|
|
147
|
+
"to": {
|
|
148
|
+
"@id": "https://www.w3.org/ns/activitystreams#to",
|
|
149
|
+
"@type": "@id"
|
|
150
|
+
},
|
|
151
|
+
"type": "@type",
|
|
152
|
+
"id": "@id"
|
|
153
|
+
},
|
|
154
|
+
type: "https://www.w3.org/ns/activitystreams#Note",
|
|
155
|
+
id: "https://example.com/notes/5",
|
|
156
|
+
to: "as:Public"
|
|
157
|
+
});
|
|
158
|
+
assertEquals(output.to, "as:Public");
|
|
159
|
+
assertNotEquals(output.to, PUBLIC_URI);
|
|
160
|
+
});
|
|
161
|
+
//#endregion
|
|
162
|
+
export {};
|
|
@@ -4,8 +4,8 @@ globalThis.addEventListener = () => {};
|
|
|
4
4
|
import { t as assertEquals } from "../assert_equals-Ew3jOFa3.mjs";
|
|
5
5
|
import { t as assertInstanceOf } from "../assert_instance_of-C4Ri6VuN.mjs";
|
|
6
6
|
import { t as assert } from "../assert-ddO5KLpe.mjs";
|
|
7
|
-
import { t as MemoryKvStore } from "../kv-
|
|
8
|
-
import { n as FederationImpl, v as actorDehydrator, y as autoIdAssigner } from "../middleware-
|
|
7
|
+
import { t as MemoryKvStore } from "../kv-C-TG81Sv.mjs";
|
|
8
|
+
import { n as FederationImpl, v as actorDehydrator, y as autoIdAssigner } from "../middleware-D8r5yKV-.mjs";
|
|
9
9
|
import { test } from "@fedify/fixture";
|
|
10
10
|
import { Follow, Person } from "@fedify/vocab";
|
|
11
11
|
//#region src/compat/transformers.test.ts
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import "@js-temporal/polyfill";
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
|
-
import { o as validateCryptoKey } from "./key-
|
|
5
|
-
import { n as doubleKnock } from "./http-
|
|
4
|
+
import { o as validateCryptoKey } from "./key-CwG1d1a2.mjs";
|
|
5
|
+
import { n as doubleKnock } from "./http-BKrXOLjL.mjs";
|
|
6
6
|
import { curry } from "es-toolkit";
|
|
7
7
|
import { UrlError, createActivityPubRequest, getRemoteDocument, logRequest, validatePublicUrl } from "@fedify/vocab-runtime";
|
|
8
8
|
import { getLogger } from "@logtape/logtape";
|
|
@@ -5,8 +5,8 @@ import { n as RouterError } from "../router-CrMLXoOr.mjs";
|
|
|
5
5
|
import { t as assertEquals } from "../assert_equals-Ew3jOFa3.mjs";
|
|
6
6
|
import { a as assertExists } from "../std__assert-Duiq_YC9.mjs";
|
|
7
7
|
import { t as assertThrows } from "../assert_throws-4NwKEy2q.mjs";
|
|
8
|
-
import { t as MemoryKvStore } from "../kv-
|
|
9
|
-
import { n as createFederationBuilder } from "../builder-
|
|
8
|
+
import { t as MemoryKvStore } from "../kv-C-TG81Sv.mjs";
|
|
9
|
+
import { n as createFederationBuilder } from "../builder-bnytmADH.mjs";
|
|
10
10
|
import { test } from "@fedify/fixture";
|
|
11
11
|
import { Activity, Note, Person } from "@fedify/vocab";
|
|
12
12
|
//#region src/federation/builder.test.ts
|
|
@@ -3,7 +3,7 @@ import "urlpattern-polyfill";
|
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
4
|
import { t as assertEquals } from "../assert_equals-Ew3jOFa3.mjs";
|
|
5
5
|
import "../std__assert-Duiq_YC9.mjs";
|
|
6
|
-
import { n as digest, t as buildCollectionSynchronizationHeader } from "../collection-
|
|
6
|
+
import { n as digest, t as buildCollectionSynchronizationHeader } from "../collection-BQRKGS7L.mjs";
|
|
7
7
|
import { test } from "@fedify/fixture";
|
|
8
8
|
import { decodeHex } from "byte-encodings/hex";
|
|
9
9
|
//#region src/federation/collection.test.ts
|
|
@@ -7,11 +7,11 @@ import "../std__assert-Duiq_YC9.mjs";
|
|
|
7
7
|
import { t as assertInstanceOf } from "../assert_instance_of-C4Ri6VuN.mjs";
|
|
8
8
|
import { t as assert } from "../assert-ddO5KLpe.mjs";
|
|
9
9
|
import { r as parseAcceptSignature } from "../accept-Dd__NiUL.mjs";
|
|
10
|
-
import { s as signRequest } from "../http-
|
|
10
|
+
import { s as signRequest } from "../http-BKrXOLjL.mjs";
|
|
11
11
|
import { a as rsaPrivateKey3, c as rsaPublicKey3, s as rsaPublicKey2 } from "../keys-BAK-tUlf.mjs";
|
|
12
|
-
import { t as MemoryKvStore } from "../kv-
|
|
13
|
-
import { c as handleActor, d as handleInbox, f as handleObject, h as respondWithObjectIfAcceptable, l as handleCollection, m as respondWithObject, o as createFederation, p as handleOutbox, u as handleCustomCollection } from "../middleware-
|
|
14
|
-
import { t as ActivityListenerSet } from "../activity-listener-
|
|
12
|
+
import { t as MemoryKvStore } from "../kv-C-TG81Sv.mjs";
|
|
13
|
+
import { c as handleActor, d as handleInbox, f as handleObject, h as respondWithObjectIfAcceptable, l as handleCollection, m as respondWithObject, o as createFederation, p as handleOutbox, u as handleCustomCollection } from "../middleware-D8r5yKV-.mjs";
|
|
14
|
+
import { t as ActivityListenerSet } from "../activity-listener-CFzUqoCS.mjs";
|
|
15
15
|
import { createTestTracerProvider, mockDocumentLoader, test } from "@fedify/fixture";
|
|
16
16
|
import { Activity, Create, Note, Person, Tombstone } from "@fedify/vocab";
|
|
17
17
|
import { FetchError } from "@fedify/vocab-runtime";
|
|
@@ -4,9 +4,9 @@ globalThis.addEventListener = () => {};
|
|
|
4
4
|
import { t as assertEquals } from "../assert_equals-Ew3jOFa3.mjs";
|
|
5
5
|
import "../std__assert-Duiq_YC9.mjs";
|
|
6
6
|
import { n as ed25519PrivateKey, r as ed25519PublicKey, t as ed25519Multikey } from "../keys-BAK-tUlf.mjs";
|
|
7
|
-
import { r as signObject } from "../proof-
|
|
8
|
-
import { t as MemoryKvStore } from "../kv-
|
|
9
|
-
import { o as createFederation } from "../middleware-
|
|
7
|
+
import { r as signObject } from "../proof-DngAmXc3.mjs";
|
|
8
|
+
import { t as MemoryKvStore } from "../kv-C-TG81Sv.mjs";
|
|
9
|
+
import { o as createFederation } from "../middleware-D8r5yKV-.mjs";
|
|
10
10
|
import { mockDocumentLoader, test } from "@fedify/fixture";
|
|
11
11
|
import { Create, Follow, Person } from "@fedify/vocab";
|
|
12
12
|
//#region src/federation/idempotency.test.ts
|
|
@@ -3,7 +3,7 @@ import "urlpattern-polyfill";
|
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
4
|
import { t as assertEquals } from "../assert_equals-Ew3jOFa3.mjs";
|
|
5
5
|
import { t as assertThrows } from "../assert_throws-4NwKEy2q.mjs";
|
|
6
|
-
import { t as ActivityListenerSet } from "../activity-listener-
|
|
6
|
+
import { t as ActivityListenerSet } from "../activity-listener-CFzUqoCS.mjs";
|
|
7
7
|
import { test } from "@fedify/fixture";
|
|
8
8
|
import { Activity, Create, Invite, Offer, Update } from "@fedify/vocab";
|
|
9
9
|
//#region src/federation/inbox.test.ts
|
|
@@ -4,8 +4,8 @@ globalThis.addEventListener = () => {};
|
|
|
4
4
|
import { t as assertEquals } from "../assert_equals-Ew3jOFa3.mjs";
|
|
5
5
|
import { t as assertInstanceOf } from "../assert_instance_of-C4Ri6VuN.mjs";
|
|
6
6
|
import { t as assert } from "../assert-ddO5KLpe.mjs";
|
|
7
|
-
import { t as MemoryKvStore } from "../kv-
|
|
8
|
-
import { t as KvKeyCache } from "../keycache-
|
|
7
|
+
import { t as MemoryKvStore } from "../kv-C-TG81Sv.mjs";
|
|
8
|
+
import { t as KvKeyCache } from "../keycache-C2t1kvP5.mjs";
|
|
9
9
|
import { test } from "@fedify/fixture";
|
|
10
10
|
import { CryptographicKey, Multikey } from "@fedify/vocab";
|
|
11
11
|
//#region src/federation/keycache.test.ts
|
|
@@ -3,7 +3,7 @@ import "urlpattern-polyfill";
|
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
4
|
import { t as assertEquals } from "../assert_equals-Ew3jOFa3.mjs";
|
|
5
5
|
import "../std__assert-Duiq_YC9.mjs";
|
|
6
|
-
import { t as MemoryKvStore } from "../kv-
|
|
6
|
+
import { t as MemoryKvStore } from "../kv-C-TG81Sv.mjs";
|
|
7
7
|
import { test } from "@fedify/fixture";
|
|
8
8
|
//#region src/federation/kv.test.ts
|
|
9
9
|
test("MemoryKvStore", async (t) => {
|
|
@@ -10,14 +10,14 @@ import { t as assertInstanceOf } from "../assert_instance_of-C4Ri6VuN.mjs";
|
|
|
10
10
|
import { t as assertThrows } from "../assert_throws-4NwKEy2q.mjs";
|
|
11
11
|
import { t as assertNotEquals } from "../assert_not_equals--wG9hV7u.mjs";
|
|
12
12
|
import { t as assert } from "../assert-ddO5KLpe.mjs";
|
|
13
|
-
import { l as verifyRequest, s as signRequest } from "../http-
|
|
13
|
+
import { l as verifyRequest, s as signRequest } from "../http-BKrXOLjL.mjs";
|
|
14
14
|
import { a as rsaPrivateKey3, c as rsaPublicKey3, i as rsaPrivateKey2, n as ed25519PrivateKey, r as ed25519PublicKey, s as rsaPublicKey2, t as ed25519Multikey } from "../keys-BAK-tUlf.mjs";
|
|
15
|
-
import { t as getAuthenticatedDocumentLoader } from "../docloader-
|
|
16
|
-
import { a as signJsonLd, o as verifyJsonLd, r as detachSignature } from "../ld-
|
|
17
|
-
import { t as doesActorOwnKey } from "../owner-
|
|
18
|
-
import { i as verifyObject, r as signObject } from "../proof-
|
|
19
|
-
import { t as MemoryKvStore } from "../kv-
|
|
20
|
-
import { i as KvSpecDeterminer, n as FederationImpl, o as createFederation, r as InboxContextImpl, t as ContextImpl } from "../middleware-
|
|
15
|
+
import { t as getAuthenticatedDocumentLoader } from "../docloader-CAcGw6pQ.mjs";
|
|
16
|
+
import { a as signJsonLd, o as verifyJsonLd, r as detachSignature } from "../ld-t2WD3nYp.mjs";
|
|
17
|
+
import { t as doesActorOwnKey } from "../owner-J1wYUBAp.mjs";
|
|
18
|
+
import { i as verifyObject, r as signObject } from "../proof-DngAmXc3.mjs";
|
|
19
|
+
import { t as MemoryKvStore } from "../kv-C-TG81Sv.mjs";
|
|
20
|
+
import { i as KvSpecDeterminer, n as FederationImpl, o as createFederation, r as InboxContextImpl, t as ContextImpl } from "../middleware-D8r5yKV-.mjs";
|
|
21
21
|
import { createTestTracerProvider, mockDocumentLoader, test } from "@fedify/fixture";
|
|
22
22
|
import * as vocab from "@fedify/vocab";
|
|
23
23
|
import { getTypeId, lookupObject } from "@fedify/vocab";
|
|
@@ -1805,6 +1805,16 @@ test("FederationImpl.sendActivity()", async (t) => {
|
|
|
1805
1805
|
assertEquals(request?.url, "https://example.com/inbox");
|
|
1806
1806
|
assertEquals(request?.headers.get("Content-Type"), "application/activity+json");
|
|
1807
1807
|
verified = null;
|
|
1808
|
+
await federation.sendActivity([{
|
|
1809
|
+
privateKey: rsaPrivateKey3,
|
|
1810
|
+
keyId: rsaPublicKey3.id
|
|
1811
|
+
}], inboxes, activity.clone({
|
|
1812
|
+
actor: new URL("https://example.com/person2"),
|
|
1813
|
+
tos: [vocab.PUBLIC_COLLECTION]
|
|
1814
|
+
}), { context });
|
|
1815
|
+
assertEquals(verified, ["ld", "http"]);
|
|
1816
|
+
assertEquals((await request?.json())?.to, vocab.PUBLIC_COLLECTION.href);
|
|
1817
|
+
verified = null;
|
|
1808
1818
|
await federation.sendActivity([{
|
|
1809
1819
|
privateKey: rsaPrivateKey3,
|
|
1810
1820
|
keyId: rsaPublicKey3.id
|
package/dist/federation/mod.cjs
CHANGED
|
@@ -2,7 +2,7 @@ const { Temporal } = require("@js-temporal/polyfill");
|
|
|
2
2
|
const { URLPattern } = require("urlpattern-polyfill");
|
|
3
3
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
4
4
|
require("../chunk-DDcVe30Y.cjs");
|
|
5
|
-
const require_middleware = require("../middleware-
|
|
5
|
+
const require_middleware = require("../middleware-cGUpoNb_.cjs");
|
|
6
6
|
let es_toolkit = require("es-toolkit");
|
|
7
7
|
//#region src/federation/kv.ts
|
|
8
8
|
/**
|
package/dist/federation/mod.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Temporal } from "@js-temporal/polyfill";
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
|
-
import { a as createExponentialBackoffPolicy, c as buildCollectionSynchronizationHeader, d as Router, f as RouterError, i as SendActivityError, l as digest, o as respondWithObject, r as handleWebFinger, s as respondWithObjectIfAcceptable, t as createFederation, u as createFederationBuilder } from "../middleware-
|
|
3
|
+
import { a as createExponentialBackoffPolicy, c as buildCollectionSynchronizationHeader, d as Router, f as RouterError, i as SendActivityError, l as digest, o as respondWithObject, r as handleWebFinger, s as respondWithObjectIfAcceptable, t as createFederation, u as createFederationBuilder } from "../middleware-RhsXBX0y.js";
|
|
4
4
|
import { isEqual } from "es-toolkit";
|
|
5
5
|
//#region src/federation/kv.ts
|
|
6
6
|
/**
|
|
@@ -4,7 +4,7 @@ globalThis.addEventListener = () => {};
|
|
|
4
4
|
import "../std__assert-Duiq_YC9.mjs";
|
|
5
5
|
import { n as assertFalse } from "../assert_rejects-B-qJtC9Z.mjs";
|
|
6
6
|
import { t as assert } from "../assert-ddO5KLpe.mjs";
|
|
7
|
-
import { t as acceptsJsonLd } from "../negotiation-
|
|
7
|
+
import { t as acceptsJsonLd } from "../negotiation-xb0QR3u_.mjs";
|
|
8
8
|
import { test } from "@fedify/fixture";
|
|
9
9
|
//#region src/federation/negotiation.test.ts
|
|
10
10
|
test("acceptsJsonLd()", () => {
|
|
@@ -3,7 +3,7 @@ import "urlpattern-polyfill";
|
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
4
|
import { l as AssertionError, t as assertEquals } from "../assert_equals-Ew3jOFa3.mjs";
|
|
5
5
|
import { t as assertNotEquals } from "../assert_not_equals--wG9hV7u.mjs";
|
|
6
|
-
import { t as createExponentialBackoffPolicy } from "../retry-
|
|
6
|
+
import { t as createExponentialBackoffPolicy } from "../retry-CJL0poaU.mjs";
|
|
7
7
|
import { test } from "@fedify/fixture";
|
|
8
8
|
//#region src/federation/retry.test.ts
|
|
9
9
|
test("createExponentialBackoffPolicy()", () => {
|
|
@@ -8,10 +8,10 @@ import { n as assertFalse, t as assertRejects } from "../assert_rejects-B-qJtC9Z
|
|
|
8
8
|
import { t as assertInstanceOf } from "../assert_instance_of-C4Ri6VuN.mjs";
|
|
9
9
|
import { t as assertNotEquals } from "../assert_not_equals--wG9hV7u.mjs";
|
|
10
10
|
import { t as assert } from "../assert-ddO5KLpe.mjs";
|
|
11
|
-
import { l as verifyRequest } from "../http-
|
|
11
|
+
import { l as verifyRequest } from "../http-BKrXOLjL.mjs";
|
|
12
12
|
import { i as rsaPrivateKey2, n as ed25519PrivateKey, s as rsaPublicKey2, t as ed25519Multikey } from "../keys-BAK-tUlf.mjs";
|
|
13
|
-
import { t as doesActorOwnKey } from "../owner-
|
|
14
|
-
import { n as extractInboxes, r as sendActivity, t as SendActivityError } from "../send-
|
|
13
|
+
import { t as doesActorOwnKey } from "../owner-J1wYUBAp.mjs";
|
|
14
|
+
import { n as extractInboxes, r as sendActivity, t as SendActivityError } from "../send-CCwbKHXy.mjs";
|
|
15
15
|
import { createTestTracerProvider, mockDocumentLoader, test } from "@fedify/fixture";
|
|
16
16
|
import { Activity, Application, Endpoints, Group, Person, Service } from "@fedify/vocab";
|
|
17
17
|
//#region src/federation/send.test.ts
|
|
@@ -4,8 +4,8 @@ globalThis.addEventListener = () => {};
|
|
|
4
4
|
import { r as createRequestContext } from "../context-Dk_tacqz.mjs";
|
|
5
5
|
import { t as assertEquals } from "../assert_equals-Ew3jOFa3.mjs";
|
|
6
6
|
import "../std__assert-Duiq_YC9.mjs";
|
|
7
|
-
import { t as MemoryKvStore } from "../kv-
|
|
8
|
-
import { o as createFederation, s as handleWebFinger } from "../middleware-
|
|
7
|
+
import { t as MemoryKvStore } from "../kv-C-TG81Sv.mjs";
|
|
8
|
+
import { o as createFederation, s as handleWebFinger } from "../middleware-D8r5yKV-.mjs";
|
|
9
9
|
import { test } from "@fedify/fixture";
|
|
10
10
|
import { Image, Link, Person, Tombstone } from "@fedify/vocab";
|
|
11
11
|
//#region src/federation/webfinger.test.ts
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { Temporal } from "@js-temporal/polyfill";
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
|
-
import { n as version, t as name } from "./deno-
|
|
4
|
+
import { n as version, t as name } from "./deno-sxAmy69e.mjs";
|
|
5
5
|
import { i as validateAcceptSignature, n as fulfillAcceptSignature, r as parseAcceptSignature } from "./accept-Dd__NiUL.mjs";
|
|
6
|
-
import { o as validateCryptoKey, r as fetchKeyDetailed } from "./key-
|
|
6
|
+
import { o as validateCryptoKey, r as fetchKeyDetailed } from "./key-CwG1d1a2.mjs";
|
|
7
7
|
import { CryptographicKey } from "@fedify/vocab";
|
|
8
8
|
import { SpanStatusCode, trace } from "@opentelemetry/api";
|
|
9
9
|
import { FetchError } from "@fedify/vocab-runtime";
|
|
@@ -11,7 +11,7 @@ let _opentelemetry_semantic_conventions = require("@opentelemetry/semantic-conve
|
|
|
11
11
|
let byte_encodings_base64 = require("byte-encodings/base64");
|
|
12
12
|
//#region deno.json
|
|
13
13
|
var name = "@fedify/fedify";
|
|
14
|
-
var version = "2.2.0-pr.
|
|
14
|
+
var version = "2.2.0-pr.710.22+527afb16";
|
|
15
15
|
//#endregion
|
|
16
16
|
//#region src/sig/accept.ts
|
|
17
17
|
/**
|
|
@@ -10,7 +10,7 @@ import { ATTR_HTTP_REQUEST_HEADER, ATTR_HTTP_REQUEST_METHOD, ATTR_URL_FULL } fro
|
|
|
10
10
|
import { decodeBase64, encodeBase64 } from "byte-encodings/base64";
|
|
11
11
|
//#region deno.json
|
|
12
12
|
var name = "@fedify/fedify";
|
|
13
|
-
var version = "2.2.0-pr.
|
|
13
|
+
var version = "2.2.0-pr.710.22+527afb16";
|
|
14
14
|
//#endregion
|
|
15
15
|
//#region src/sig/accept.ts
|
|
16
16
|
/**
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "@js-temporal/polyfill";
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
|
-
import { n as version, t as name } from "./deno-
|
|
4
|
+
import { n as version, t as name } from "./deno-sxAmy69e.mjs";
|
|
5
5
|
import { CryptographicKey, Object as Object$1, isActor } from "@fedify/vocab";
|
|
6
6
|
import { SpanKind, SpanStatusCode, trace } from "@opentelemetry/api";
|
|
7
7
|
import { FetchError, getDocumentLoader } from "@fedify/vocab-runtime";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Temporal } from "@js-temporal/polyfill";
|
|
2
2
|
import { URLPattern } from "urlpattern-polyfill";
|
|
3
|
-
import { d as validateCryptoKey, t as doubleKnock } from "./http-
|
|
3
|
+
import { d as validateCryptoKey, t as doubleKnock } from "./http-DI4R9CTK.js";
|
|
4
4
|
import { getLogger } from "@logtape/logtape";
|
|
5
5
|
import { curry } from "es-toolkit";
|
|
6
6
|
import { UrlError, createActivityPubRequest, getRemoteDocument, logRequest, preloadedContexts, validatePublicUrl } from "@fedify/vocab-runtime";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
const { Temporal } = require("@js-temporal/polyfill");
|
|
2
2
|
const { URLPattern } = require("urlpattern-polyfill");
|
|
3
3
|
require("./chunk-DDcVe30Y.cjs");
|
|
4
|
-
const require_http = require("./http-
|
|
4
|
+
const require_http = require("./http-C1BAaJ_m.cjs");
|
|
5
5
|
let _logtape_logtape = require("@logtape/logtape");
|
|
6
6
|
let es_toolkit = require("es-toolkit");
|
|
7
7
|
let _fedify_vocab_runtime = require("@fedify/vocab-runtime");
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import "@js-temporal/polyfill";
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
|
-
import { n as version, t as name } from "./deno-
|
|
5
|
-
import { n as fetchKey, o as validateCryptoKey } from "./key-
|
|
4
|
+
import { n as version, t as name } from "./deno-sxAmy69e.mjs";
|
|
5
|
+
import { n as fetchKey, o as validateCryptoKey } from "./key-CwG1d1a2.mjs";
|
|
6
6
|
import { Activity, CryptographicKey, Object as Object$1, getTypeId } from "@fedify/vocab";
|
|
7
7
|
import { SpanStatusCode, trace } from "@opentelemetry/api";
|
|
8
8
|
import { getDocumentLoader } from "@fedify/vocab-runtime";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
const { Temporal } = require("@js-temporal/polyfill");
|
|
2
2
|
const { URLPattern } = require("urlpattern-polyfill");
|
|
3
|
-
const require_middleware = require("./middleware-
|
|
3
|
+
const require_middleware = require("./middleware-cGUpoNb_.cjs");
|
|
4
4
|
exports.FederationImpl = require_middleware.FederationImpl;
|
|
@@ -2,23 +2,24 @@ import { Temporal } from "@js-temporal/polyfill";
|
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
4
|
import { n as RouterError } from "./router-CrMLXoOr.mjs";
|
|
5
|
-
import { n as version, t as name } from "./deno-
|
|
5
|
+
import { n as version, t as name } from "./deno-sxAmy69e.mjs";
|
|
6
6
|
import { t as formatAcceptSignature } from "./accept-Dd__NiUL.mjs";
|
|
7
|
-
import { a as importJwk, o as validateCryptoKey, t as exportJwk } from "./key-
|
|
8
|
-
import { l as verifyRequest, o as parseRfc9421SignatureInput, u as verifyRequestDetailed } from "./http-
|
|
9
|
-
import { t as getAuthenticatedDocumentLoader } from "./docloader-
|
|
7
|
+
import { a as importJwk, o as validateCryptoKey, t as exportJwk } from "./key-CwG1d1a2.mjs";
|
|
8
|
+
import { l as verifyRequest, o as parseRfc9421SignatureInput, u as verifyRequestDetailed } from "./http-BKrXOLjL.mjs";
|
|
9
|
+
import { t as getAuthenticatedDocumentLoader } from "./docloader-CAcGw6pQ.mjs";
|
|
10
10
|
import { n as kvCache } from "./kv-cache-B01V7s3h.mjs";
|
|
11
|
-
import { a as signJsonLd, i as hasSignatureLike, o as verifyJsonLd, r as detachSignature } from "./ld-
|
|
12
|
-
import { n as getKeyOwner, t as doesActorOwnKey } from "./owner-
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import { t as
|
|
16
|
-
import { t as
|
|
17
|
-
import { t as
|
|
18
|
-
import { t as
|
|
19
|
-
import { t as
|
|
20
|
-
import { t as
|
|
21
|
-
import {
|
|
11
|
+
import { a as signJsonLd, i as hasSignatureLike, o as verifyJsonLd, r as detachSignature } from "./ld-t2WD3nYp.mjs";
|
|
12
|
+
import { n as getKeyOwner, t as doesActorOwnKey } from "./owner-J1wYUBAp.mjs";
|
|
13
|
+
import { t as normalizePublicAudience } from "./public-audience-5WWE-JTr.mjs";
|
|
14
|
+
import { i as verifyObject, n as hasProofLike, r as signObject } from "./proof-DngAmXc3.mjs";
|
|
15
|
+
import { t as getNodeInfo } from "./client-DVu6Fmom.mjs";
|
|
16
|
+
import { t as nodeInfoToJson } from "./types-CGUnLkU3.mjs";
|
|
17
|
+
import { t as FederationBuilderImpl } from "./builder-bnytmADH.mjs";
|
|
18
|
+
import { t as buildCollectionSynchronizationHeader } from "./collection-BQRKGS7L.mjs";
|
|
19
|
+
import { t as KvKeyCache } from "./keycache-C2t1kvP5.mjs";
|
|
20
|
+
import { t as acceptsJsonLd } from "./negotiation-xb0QR3u_.mjs";
|
|
21
|
+
import { t as createExponentialBackoffPolicy } from "./retry-CJL0poaU.mjs";
|
|
22
|
+
import { n as extractInboxes, r as sendActivity, t as SendActivityError } from "./send-CCwbKHXy.mjs";
|
|
22
23
|
import { Activity, Collection, CollectionPage, CryptographicKey, Link, Multikey, Object as Object$1, OrderedCollection, OrderedCollectionPage, Tombstone, getTypeId, lookupObject, traverseCollection } from "@fedify/vocab";
|
|
23
24
|
import { lookupWebFinger } from "@fedify/webfinger";
|
|
24
25
|
import { SpanKind, SpanStatusCode, context, propagation, trace } from "@opentelemetry/api";
|
|
@@ -2261,6 +2262,7 @@ var FederationImpl = class extends FederationBuilderImpl {
|
|
|
2261
2262
|
format: "compact",
|
|
2262
2263
|
contextLoader
|
|
2263
2264
|
});
|
|
2265
|
+
jsonLd = await normalizePublicAudience(jsonLd, contextLoader);
|
|
2264
2266
|
if (rsaKey == null) logger.warn("No supported key found to create a Linked Data signature for the activity {activityId}. The activity will be sent without a Linked Data signature. In order to create a Linked Data signature, at least one RSASSA-PKCS1-v1_5 key must be provided.", {
|
|
2265
2267
|
activityId,
|
|
2266
2268
|
keys: keys.map((pair) => ({
|
|
@@ -2,10 +2,10 @@ import { Temporal } from "@js-temporal/polyfill";
|
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
3
|
import { t as __exportAll } from "./chunk-nlSIicah.js";
|
|
4
4
|
import { r as getDefaultActivityTransformers } from "./transformers-ve6e2xcg.js";
|
|
5
|
-
import { _ as version, a as verifyRequestDetailed, d as validateCryptoKey, f as formatAcceptSignature, g as name, i as verifyRequest, n as parseRfc9421SignatureInput, o as exportJwk, t as doubleKnock, u as importJwk } from "./http-
|
|
6
|
-
import { d as
|
|
5
|
+
import { _ as version, a as verifyRequestDetailed, d as validateCryptoKey, f as formatAcceptSignature, g as name, i as verifyRequest, n as parseRfc9421SignatureInput, o as exportJwk, t as doubleKnock, u as importJwk } from "./http-DI4R9CTK.js";
|
|
6
|
+
import { c as getKeyOwner, d as detachSignature, f as hasSignatureLike, i as verifyObject, m as verifyJsonLd, n as hasProofLike, o as normalizePublicAudience, p as signJsonLd, r as signObject, s as doesActorOwnKey } from "./proof-DJiXN7Qc.js";
|
|
7
7
|
import { n as getNodeInfo, t as nodeInfoToJson } from "./types-hvL8ElAs.js";
|
|
8
|
-
import { n as getAuthenticatedDocumentLoader, t as kvCache } from "./kv-cache-
|
|
8
|
+
import { n as getAuthenticatedDocumentLoader, t as kvCache } from "./kv-cache-BQS2P8gv.js";
|
|
9
9
|
import { getLogger, withContext } from "@logtape/logtape";
|
|
10
10
|
import { Activity, Collection, CollectionPage, CryptographicKey, Link, Multikey, Object as Object$1, OrderedCollection, OrderedCollectionPage, Tombstone, getTypeId, lookupObject, traverseCollection } from "@fedify/vocab";
|
|
11
11
|
import { SpanKind, SpanStatusCode, context, propagation, trace } from "@opentelemetry/api";
|
|
@@ -3291,6 +3291,7 @@ var FederationImpl = class extends FederationBuilderImpl {
|
|
|
3291
3291
|
format: "compact",
|
|
3292
3292
|
contextLoader
|
|
3293
3293
|
});
|
|
3294
|
+
jsonLd = await normalizePublicAudience(jsonLd, contextLoader);
|
|
3294
3295
|
if (rsaKey == null) logger.warn("No supported key found to create a Linked Data signature for the activity {activityId}. The activity will be sent without a Linked Data signature. In order to create a Linked Data signature, at least one RSASSA-PKCS1-v1_5 key must be provided.", {
|
|
3295
3296
|
activityId,
|
|
3296
3297
|
keys: keys.map((pair) => ({
|
|
@@ -2,10 +2,10 @@ const { Temporal } = require("@js-temporal/polyfill");
|
|
|
2
2
|
const { URLPattern } = require("urlpattern-polyfill");
|
|
3
3
|
require("./chunk-DDcVe30Y.cjs");
|
|
4
4
|
const require_transformers = require("./transformers-NeAONrAq.cjs");
|
|
5
|
-
const require_http = require("./http-
|
|
6
|
-
const require_proof = require("./proof-
|
|
5
|
+
const require_http = require("./http-C1BAaJ_m.cjs");
|
|
6
|
+
const require_proof = require("./proof-0fe_hpBU.cjs");
|
|
7
7
|
const require_types = require("./types-KC4QAoxe.cjs");
|
|
8
|
-
const require_kv_cache = require("./kv-cache-
|
|
8
|
+
const require_kv_cache = require("./kv-cache-p33MTfBu.cjs");
|
|
9
9
|
let _logtape_logtape = require("@logtape/logtape");
|
|
10
10
|
let _fedify_vocab = require("@fedify/vocab");
|
|
11
11
|
let _opentelemetry_api = require("@opentelemetry/api");
|
|
@@ -210,7 +210,7 @@ var FederationBuilderImpl = class {
|
|
|
210
210
|
this.collectionTypeIds = {};
|
|
211
211
|
}
|
|
212
212
|
async build(options) {
|
|
213
|
-
const { FederationImpl } = await Promise.resolve().then(() => require("./middleware-
|
|
213
|
+
const { FederationImpl } = await Promise.resolve().then(() => require("./middleware-C4JOTHSG.cjs"));
|
|
214
214
|
const f = new FederationImpl(options);
|
|
215
215
|
const trailingSlashInsensitiveValue = f.router.trailingSlashInsensitive;
|
|
216
216
|
f.router = this.router.clone();
|
|
@@ -3283,6 +3283,7 @@ var FederationImpl = class extends FederationBuilderImpl {
|
|
|
3283
3283
|
format: "compact",
|
|
3284
3284
|
contextLoader
|
|
3285
3285
|
});
|
|
3286
|
+
jsonLd = await require_proof.normalizePublicAudience(jsonLd, contextLoader);
|
|
3286
3287
|
if (rsaKey == null) logger.warn("No supported key found to create a Linked Data signature for the activity {activityId}. The activity will be sent without a Linked Data signature. In order to create a Linked Data signature, at least one RSASSA-PKCS1-v1_5 key must be provided.", {
|
|
3287
3288
|
activityId,
|
|
3288
3289
|
keys: keys.map((pair) => ({
|