@fedify/fedify 2.4.0-dev.2159 → 2.4.0-dev.2169
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-D89oOfHC.mjs → builder-B2d_Pt0j.mjs} +2 -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-B02Os8h2.mjs → compound-proof-D28gMFqP.mjs} +2 -2
- package/dist/{context-JDNkUtnu.d.ts → context-BykNUf04.d.ts} +1 -1
- package/dist/{context-DpsaHkk1.d.cts → context-L0Fnib9j.d.cts} +1 -1
- package/dist/{deno-CE_s0yQb.mjs → deno-DU8dvnWk.mjs} +1 -1
- package/dist/{docloader-C5p26tpa.mjs → docloader-CghLH7Zi.mjs} +2 -2
- package/dist/federation/builder.test.mjs +1 -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/keycache.test.mjs +67 -1
- package/dist/federation/metrics.test.mjs +1 -1
- package/dist/federation/middleware.test.mjs +7 -7
- package/dist/federation/mod.cjs +1 -1
- package/dist/federation/mod.d.cts +2 -2
- package/dist/federation/mod.d.ts +2 -2
- 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-gateway-keys.test.mjs +180 -6
- package/dist/federation/portable-inbox.test.mjs +4 -4
- package/dist/federation/portable-parse-uri.test.mjs +1 -1
- 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-dBOqmJcA.cjs → federation-DrNgkLfJ.cjs} +48 -24
- package/dist/{http-wdsia0-O.cjs → http-5CJBdU8n.cjs} +392 -65
- package/dist/{http-nTZuTacw.js → http-BGpexPO7.js} +368 -61
- package/dist/{http-DV_yW4dv.mjs → http-Bd6rZlJX.mjs} +7 -5
- package/dist/{http-C-x_OLSp.d.ts → http-Cok5-vIC.d.ts} +5 -0
- package/dist/{http-CjezPjFX.d.cts → http-DC1cqAQ2.d.cts} +5 -0
- package/dist/{key-C6jnekFI.mjs → key-gIhVZO3p.mjs} +58 -7
- package/dist/key-owner-evidence-Bo3yaeL5.mjs +108 -0
- package/dist/{keycache-BInaECGj.mjs → keycache-PiOM9pM0.mjs} +46 -21
- package/dist/{kv-cache-Bxm0a0Ww.mjs → kv-cache-D0qjSeWY.mjs} +1 -1
- package/dist/{kv-cache-BHNtQi9e.cjs → kv-cache-YRi_g8GB.cjs} +1 -1
- package/dist/{kv-cache-DhIl9YlV.js → kv-cache-iR55fqlk.js} +1 -1
- package/dist/{ld-ya2C1Xip.mjs → ld-BsTkRrwF.mjs} +3 -3
- package/dist/{metrics-ByOQOHHS.mjs → metrics-jUDFfVgi.mjs} +1 -1
- package/dist/{middleware-Bdwd_Gg8.mjs → middleware-Coqgp-K0.mjs} +15 -15
- package/dist/{middleware-WiaN4RS3.js → middleware-DlxMxVp5.js} +48 -24
- package/dist/{middleware-DoVWq8mE.mjs → middleware-Dq-OCmb6.mjs} +1 -1
- package/dist/{mod-Bz9tFXI2.d.ts → mod--jv6vyrP.d.ts} +1 -1
- package/dist/{mod-DaiBrWDW.d.ts → mod-B5z_q9TH.d.ts} +1 -1
- package/dist/{mod-Mt4aO3DX.d.cts → mod-BA_F2x53.d.cts} +1 -1
- package/dist/{mod-DSKkTwH2.d.cts → mod-BLOXGs6m.d.cts} +1 -1
- package/dist/{mod-S--JxYjo.d.cts → mod-CPPqkyV_.d.cts} +1 -1
- package/dist/{mod-_4K05HZF.d.ts → mod-DK0y9fd-.d.ts} +1 -1
- package/dist/mod.cjs +4 -4
- package/dist/mod.d.cts +5 -5
- package/dist/mod.d.ts +5 -5
- package/dist/mod.js +4 -4
- package/dist/nodeinfo/handler.test.mjs +1 -1
- package/dist/{owner-C6Nv5yyw.mjs → owner-D3GoetXS.mjs} +18 -3
- package/dist/{portable-collection-B-mU1F1-.js → portable-collection-Bkdh_WpL.js} +15 -1
- package/dist/{portable-collection-uWj3hfzv.mjs → portable-collection-C60_acmx.mjs} +2 -2
- package/dist/{portable-collection-C65SwL2l.cjs → portable-collection-CnlCamup.cjs} +15 -1
- package/dist/{portable-key-BXsVLSMa.mjs → portable-key-DyF5AnZo.mjs} +209 -55
- package/dist/{proof-BdO3BbLh.mjs → proof-CQAYqWdj.mjs} +4 -4
- package/dist/{send-BwANxryy.mjs → send-DjkQrxt5.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-owner-evidence.test.d.mts +2 -0
- package/dist/sig/key-owner-evidence.test.mjs +100 -0
- 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.d.cts +2 -2
- package/dist/sig/mod.d.ts +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 +253 -7
- package/dist/sig/proof.test.mjs +3 -3
- package/dist/{temporal-CbPfRGZq.mjs → temporal-oRKP803M.mjs} +1 -1
- package/dist/testing/kv.test.mjs +1 -1
- 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
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import "temporal-polyfill";
|
|
1
|
+
import { Temporal } from "temporal-polyfill";
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
|
-
import { n as version, t as name } from "./deno-
|
|
5
|
-
import { _ as recordKeyLookup, n as getDurationMs, t as classifyFetchError } from "./metrics-
|
|
4
|
+
import { n as version, t as name } from "./deno-DU8dvnWk.mjs";
|
|
5
|
+
import { _ as recordKeyLookup, n as getDurationMs, t as classifyFetchError } from "./metrics-jUDFfVgi.mjs";
|
|
6
6
|
import { c as isPortableId, f as parseKeyIdString, o as isCompatibleKeyId, s as isPortableActorDocument, u as isPortableUri } from "./portable-key-id-Bg259c4Z.mjs";
|
|
7
|
+
import { n as attachKeyOwnerEvidence, t as MAX_PORTABLE_KEY_TTL } from "./key-owner-evidence-Bo3yaeL5.mjs";
|
|
7
8
|
import { getLogger } from "@logtape/logtape";
|
|
8
9
|
import { CryptographicKey, Multikey, Object as Object$1, isActor } from "@fedify/vocab";
|
|
9
10
|
import { SpanKind, SpanStatusCode, trace } from "@opentelemetry/api";
|
|
@@ -230,6 +231,7 @@ function bypassKeyCacheReads(keyCache) {
|
|
|
230
231
|
const scoped = cache.compatibleKeyScope(scope);
|
|
231
232
|
return {
|
|
232
233
|
get: () => Promise.resolve(void 0),
|
|
234
|
+
getEntry: () => Promise.resolve(void 0),
|
|
233
235
|
set: async (keyId, key, options) => await scoped.set(keyId, key, options),
|
|
234
236
|
delete: async (keyId) => await scoped.delete(keyId)
|
|
235
237
|
};
|
|
@@ -397,6 +399,49 @@ function checkCachedKeyHit(cachedKey, keyId, cls, logger) {
|
|
|
397
399
|
}
|
|
398
400
|
return null;
|
|
399
401
|
}
|
|
402
|
+
/**
|
|
403
|
+
* Looks up a key at a compatible identifier, or at an `ap:` or `ap+ef61:`
|
|
404
|
+
* URI, in the cache namespace of a purpose, like {@link getCachedFetchKey}.
|
|
405
|
+
* A key that the verified document of its portable actor was cached with
|
|
406
|
+
* gets the actor's evidence attached from the same entry; see
|
|
407
|
+
* {@link attachKeyOwnerEvidence}.
|
|
408
|
+
*/
|
|
409
|
+
async function getCachedCompatibleKey(cacheKey, keyId, cls, scopedCache, logger) {
|
|
410
|
+
if (scopedCache?.getEntry == null) return await getCachedFetchKey(cacheKey, keyId, cls, scopedCache, logger);
|
|
411
|
+
const entry = await scopedCache.getEntry(cacheKey);
|
|
412
|
+
if (entry === void 0) return null;
|
|
413
|
+
if (entry === null) {
|
|
414
|
+
logger.debug("Entry {keyId} found in cache, but it is unavailable.", { keyId });
|
|
415
|
+
return {
|
|
416
|
+
key: null,
|
|
417
|
+
cached: true
|
|
418
|
+
};
|
|
419
|
+
}
|
|
420
|
+
const hit = checkCachedKeyHit(entry.key, keyId, cls, logger);
|
|
421
|
+
if (hit?.key instanceof CryptographicKey && entry.owner != null) attachKeyOwnerEvidence(hit.key, entry.owner, entry.expires);
|
|
422
|
+
return hit;
|
|
423
|
+
}
|
|
424
|
+
/**
|
|
425
|
+
* Attaches the evidence of the portable actor whose document has just
|
|
426
|
+
* vouched for a key to the key. The evidence expires with the cache entry
|
|
427
|
+
* of the key, so that it is never trusted longer than the key is cached.
|
|
428
|
+
* Without a cache, it expires with the proof of the document, but no later
|
|
429
|
+
* than {@link MAX_PORTABLE_KEY_TTL}, as a cache entry would.
|
|
430
|
+
* @param resolution The resolution of the key.
|
|
431
|
+
* @param scopedCache The cache namespace the key was stored in, if any.
|
|
432
|
+
* @param cached When the cache entry expires, if the cache stored one.
|
|
433
|
+
*/
|
|
434
|
+
function attachResolvedKeyOwnerEvidence(resolution, scopedCache, cached) {
|
|
435
|
+
let expires;
|
|
436
|
+
if (scopedCache != null) {
|
|
437
|
+
if (cached == null) return;
|
|
438
|
+
expires = cached;
|
|
439
|
+
} else {
|
|
440
|
+
expires = Temporal.Now.instant().add(MAX_PORTABLE_KEY_TTL);
|
|
441
|
+
if (resolution.expires != null && Temporal.Instant.compare(resolution.expires, expires) < 0) expires = resolution.expires;
|
|
442
|
+
}
|
|
443
|
+
attachKeyOwnerEvidence(resolution.key, resolution.document, expires);
|
|
444
|
+
}
|
|
400
445
|
async function clearFetchErrorMetadata(keyId, keyCache) {
|
|
401
446
|
await keyCache?.setFetchError?.(keyId, null);
|
|
402
447
|
}
|
|
@@ -521,7 +566,10 @@ async function resolveFetchedKey(document, cacheKey, documentUrl, keyId, cls, {
|
|
|
521
566
|
cached: false
|
|
522
567
|
};
|
|
523
568
|
}
|
|
524
|
-
await scopedCache?.set(cacheKey, resolution.key, {
|
|
569
|
+
attachResolvedKeyOwnerEvidence(resolution, scopedCache, await scopedCache?.set(cacheKey, resolution.key, {
|
|
570
|
+
expires: resolution.expires,
|
|
571
|
+
owner: resolution.document
|
|
572
|
+
}));
|
|
525
573
|
return {
|
|
526
574
|
key: resolution.key,
|
|
527
575
|
cached: false
|
|
@@ -742,7 +790,7 @@ async function fetchCompatibleKey(cacheKey, cls, options, onCachedUnavailable, o
|
|
|
742
790
|
const keyId = cacheKey.href;
|
|
743
791
|
const sharedCache = options.keyCache;
|
|
744
792
|
const scopedCache = sharedCache?.compatibleKeyScope?.(getCompatibleKeyScope(cls, options));
|
|
745
|
-
const cached = await
|
|
793
|
+
const cached = await getCachedCompatibleKey(cacheKey, keyId, cls, scopedCache, logger);
|
|
746
794
|
if (cached != null) return {
|
|
747
795
|
result: cached,
|
|
748
796
|
outcome: { result: "hit" }
|
|
@@ -806,7 +854,7 @@ async function fetchPortableActorKey(cacheKey, cls, options, onCachedUnavailable
|
|
|
806
854
|
}
|
|
807
855
|
const sharedCache = options.keyCache;
|
|
808
856
|
const scopedCache = sharedCache?.compatibleKeyScope?.("httpSignature");
|
|
809
|
-
const cached = await
|
|
857
|
+
const cached = await getCachedCompatibleKey(cacheKey, keyId, cls, scopedCache, logger);
|
|
810
858
|
if (cached != null) return {
|
|
811
859
|
result: cached,
|
|
812
860
|
outcome: { result: "hit" }
|
|
@@ -821,7 +869,10 @@ async function fetchPortableActorKey(cacheKey, cls, options, onCachedUnavailable
|
|
|
821
869
|
logger.debug("Resolving key {keyId} to verify signature...", { keyId });
|
|
822
870
|
const resolution = await resolvers.actorKey(cacheKey);
|
|
823
871
|
if (resolution.type === "verified") {
|
|
824
|
-
await scopedCache?.set(cacheKey, resolution.key, {
|
|
872
|
+
attachResolvedKeyOwnerEvidence(resolution, scopedCache, await scopedCache?.set(cacheKey, resolution.key, {
|
|
873
|
+
expires: resolution.expires,
|
|
874
|
+
owner: resolution.document
|
|
875
|
+
}));
|
|
825
876
|
return {
|
|
826
877
|
result: {
|
|
827
878
|
key: resolution.key,
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
import { Temporal } from "temporal-polyfill";
|
|
2
|
+
import "urlpattern-polyfill";
|
|
3
|
+
globalThis.addEventListener = () => {};
|
|
4
|
+
import { i as getRawCanonicalPortableId, s as isPortableActorDocument, t as getCanonicalPortableId } from "./portable-key-id-Bg259c4Z.mjs";
|
|
5
|
+
import { CryptographicKey, Object as Object$1 } from "@fedify/vocab";
|
|
6
|
+
//#region src/sig/key-owner-evidence.ts
|
|
7
|
+
/**
|
|
8
|
+
* How long a key of an [FEP-ef61] portable actor is trusted after its actor's
|
|
9
|
+
* signed document vouched for it, however long the proof of the document is
|
|
10
|
+
* valid. The actor can drop the key or the gateway from its document at any
|
|
11
|
+
* time, so the key is looked up again at least this often.
|
|
12
|
+
*
|
|
13
|
+
* [FEP-ef61]: https://w3id.org/fep/ef61
|
|
14
|
+
* @internal
|
|
15
|
+
*/
|
|
16
|
+
const MAX_PORTABLE_KEY_TTL = Temporal.Duration.from({ hours: 1 });
|
|
17
|
+
const candidates = /* @__PURE__ */ new WeakMap();
|
|
18
|
+
const verified = /* @__PURE__ */ new WeakMap();
|
|
19
|
+
/**
|
|
20
|
+
* Attaches to a key that was just resolved the evidence of the portable actor
|
|
21
|
+
* that owns it. The evidence is not used until the key verifies
|
|
22
|
+
* a signature; see {@link promoteKeyOwnerEvidence}.
|
|
23
|
+
*
|
|
24
|
+
* Nothing is attached unless the document, the key's owner, and the actor
|
|
25
|
+
* the key ID belongs to agree on the actor's canonical portable ID.
|
|
26
|
+
* @param key The key, whose owner the document vouched for.
|
|
27
|
+
* @param document The expanded root node of the actor's verified document.
|
|
28
|
+
* @param expires When the evidence must not be used anymore.
|
|
29
|
+
* @returns Whether the evidence was attached.
|
|
30
|
+
* @internal
|
|
31
|
+
*/
|
|
32
|
+
function attachKeyOwnerEvidence(key, document, expires) {
|
|
33
|
+
if (!(key instanceof CryptographicKey) || key.id == null || key.ownerId == null || key.publicKey == null || document == null || typeof document !== "object" || Array.isArray(document)) return false;
|
|
34
|
+
const rawId = document["@id"];
|
|
35
|
+
if (typeof rawId !== "string") return false;
|
|
36
|
+
const keyBase = new URL(key.id.href);
|
|
37
|
+
keyBase.hash = "";
|
|
38
|
+
const ownerId = getCanonicalPortableId(key.ownerId);
|
|
39
|
+
if (ownerId == null || getRawCanonicalPortableId(rawId) !== ownerId || getCanonicalPortableId(keyBase) !== ownerId) return false;
|
|
40
|
+
candidates.set(key, {
|
|
41
|
+
keyId: key.id.href,
|
|
42
|
+
keyOwner: key.ownerId.href,
|
|
43
|
+
publicKey: key.publicKey,
|
|
44
|
+
ownerId,
|
|
45
|
+
document: structuredClone(document),
|
|
46
|
+
expires
|
|
47
|
+
});
|
|
48
|
+
return true;
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* Makes the evidence attached to a key usable, as the key has just verified
|
|
52
|
+
* an HTTP Signature. Nothing happens if the key has no evidence.
|
|
53
|
+
* @param key The key that verified a signature.
|
|
54
|
+
* @internal
|
|
55
|
+
*/
|
|
56
|
+
function promoteKeyOwnerEvidence(key) {
|
|
57
|
+
const evidence = candidates.get(key);
|
|
58
|
+
if (evidence == null) return;
|
|
59
|
+
candidates.delete(key);
|
|
60
|
+
verified.set(key, evidence);
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* Gets the evidence of the portable actor that owns a key HTTP Signature
|
|
64
|
+
* verification returned.
|
|
65
|
+
* @param key The key.
|
|
66
|
+
* @param now The current time.
|
|
67
|
+
* @returns The evidence, or `undefined` if the key was not returned by HTTP
|
|
68
|
+
* Signature verification, if it has no evidence, if the evidence
|
|
69
|
+
* expired, or if the key has been changed since.
|
|
70
|
+
* @internal
|
|
71
|
+
*/
|
|
72
|
+
function getVerifiedKeyOwnerEvidence(key, now = Temporal.Now.instant()) {
|
|
73
|
+
const evidence = verified.get(key);
|
|
74
|
+
if (evidence == null) return void 0;
|
|
75
|
+
if (Temporal.Instant.compare(now, evidence.expires) >= 0) {
|
|
76
|
+
verified.delete(key);
|
|
77
|
+
return;
|
|
78
|
+
}
|
|
79
|
+
if (key.id?.href !== evidence.keyId || key.ownerId?.href !== evidence.keyOwner || key.publicKey !== evidence.publicKey) return;
|
|
80
|
+
return evidence;
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* Parses the actor from the evidence, i.e., from the expansion of its
|
|
84
|
+
* document whose proof was verified. Every call returns a new object.
|
|
85
|
+
* @param evidence The evidence.
|
|
86
|
+
* @param options Options for parsing the document.
|
|
87
|
+
* @returns The actor, or `null` if the document is not the actor that
|
|
88
|
+
* the evidence is about, or the evidence expired meanwhile.
|
|
89
|
+
* @internal
|
|
90
|
+
*/
|
|
91
|
+
async function parseKeyOwnerEvidence(evidence, options = {}) {
|
|
92
|
+
const refuse = (url) => Promise.reject(/* @__PURE__ */ new Error(`Refusing to fetch ${url}.`));
|
|
93
|
+
let actor;
|
|
94
|
+
try {
|
|
95
|
+
actor = await Object$1.fromJsonLd(structuredClone(evidence.document), {
|
|
96
|
+
documentLoader: refuse,
|
|
97
|
+
contextLoader: options.contextLoader,
|
|
98
|
+
tracerProvider: options.tracerProvider
|
|
99
|
+
});
|
|
100
|
+
} catch (error) {
|
|
101
|
+
if (!(error instanceof TypeError)) throw error;
|
|
102
|
+
return null;
|
|
103
|
+
}
|
|
104
|
+
if (!isPortableActorDocument(actor) || getCanonicalPortableId(actor.id) !== evidence.ownerId || Temporal.Instant.compare(Temporal.Now.instant(), evidence.expires) >= 0) return null;
|
|
105
|
+
return actor;
|
|
106
|
+
}
|
|
107
|
+
//#endregion
|
|
108
|
+
export { promoteKeyOwnerEvidence as a, parseKeyOwnerEvidence as i, attachKeyOwnerEvidence as n, getVerifiedKeyOwnerEvidence as r, MAX_PORTABLE_KEY_TTL as t };
|
|
@@ -1,14 +1,18 @@
|
|
|
1
1
|
import { Temporal } from "temporal-polyfill";
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
|
+
import { t as MAX_PORTABLE_KEY_TTL } from "./key-owner-evidence-Bo3yaeL5.mjs";
|
|
4
5
|
import { CryptographicKey, Multikey } from "@fedify/vocab";
|
|
5
6
|
//#region src/federation/keycache.ts
|
|
6
7
|
const KEY_CACHE_GENERATION = "2";
|
|
7
8
|
const COMPATIBLE_KEY_SEGMENT = "__compatible";
|
|
8
|
-
const
|
|
9
|
+
const MAX_OWNER_BYTES = 32 * 1024;
|
|
9
10
|
function isCompatibleKeyEntry(value) {
|
|
10
11
|
return value != null && typeof value === "object" && "key" in value && "expires" in value && typeof value.expires === "number";
|
|
11
12
|
}
|
|
13
|
+
function isJsonObject(value) {
|
|
14
|
+
return value != null && typeof value === "object" && !Array.isArray(value);
|
|
15
|
+
}
|
|
12
16
|
var KvKeyCache = class {
|
|
13
17
|
kv;
|
|
14
18
|
prefix;
|
|
@@ -90,30 +94,48 @@ var KvKeyCache = class {
|
|
|
90
94
|
keyId.href
|
|
91
95
|
];
|
|
92
96
|
const isExpired = (entry) => entry.expires <= now().epochMilliseconds;
|
|
93
|
-
const keyTtl = Math.min(this.keyTtl.total("millisecond"),
|
|
97
|
+
const keyTtl = Math.min(this.keyTtl.total("millisecond"), MAX_PORTABLE_KEY_TTL.total("millisecond"));
|
|
94
98
|
const unavailableKeyTtl = this.unavailableKeyTtl.total("millisecond");
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
99
|
+
const getEntry = async (keyId) => {
|
|
100
|
+
const entry = await this.kv.get(entryKey(keyId));
|
|
101
|
+
if (entry === void 0) return void 0;
|
|
102
|
+
if (!isCompatibleKeyEntry(entry) || isExpired(entry)) {
|
|
103
|
+
await this.kv.delete(entryKey(keyId));
|
|
104
|
+
return;
|
|
105
|
+
}
|
|
106
|
+
if (entry.key === null) return null;
|
|
107
|
+
let expires;
|
|
108
|
+
try {
|
|
109
|
+
expires = Temporal.Instant.fromEpochMilliseconds(entry.expires);
|
|
110
|
+
} catch (error) {
|
|
111
|
+
if (!(error instanceof RangeError)) throw error;
|
|
112
|
+
await this.kv.delete(entryKey(keyId));
|
|
113
|
+
return;
|
|
114
|
+
}
|
|
115
|
+
let key;
|
|
116
|
+
try {
|
|
117
|
+
key = await CryptographicKey.fromJsonLd(entry.key, this.options);
|
|
118
|
+
} catch {
|
|
105
119
|
try {
|
|
106
|
-
key = await
|
|
120
|
+
key = await Multikey.fromJsonLd(entry.key, this.options);
|
|
107
121
|
} catch {
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
} catch {
|
|
111
|
-
await this.kv.delete(entryKey(keyId));
|
|
112
|
-
return;
|
|
113
|
-
}
|
|
122
|
+
await this.kv.delete(entryKey(keyId));
|
|
123
|
+
return;
|
|
114
124
|
}
|
|
115
|
-
|
|
125
|
+
}
|
|
126
|
+
if (isExpired(entry)) return void 0;
|
|
127
|
+
return {
|
|
128
|
+
key,
|
|
129
|
+
...isJsonObject(entry.owner) ? { owner: entry.owner } : {},
|
|
130
|
+
expires
|
|
131
|
+
};
|
|
132
|
+
};
|
|
133
|
+
return {
|
|
134
|
+
get: async (keyId) => {
|
|
135
|
+
const entry = await getEntry(keyId);
|
|
136
|
+
return entry == null ? entry : entry.key;
|
|
116
137
|
},
|
|
138
|
+
getEntry,
|
|
117
139
|
set: async (keyId, key, options) => {
|
|
118
140
|
const serialized = key == null ? null : await key.toJsonLd(this.options);
|
|
119
141
|
const current = now();
|
|
@@ -124,10 +146,13 @@ var KvKeyCache = class {
|
|
|
124
146
|
await this.kv.delete(entryKey(keyId));
|
|
125
147
|
return;
|
|
126
148
|
}
|
|
149
|
+
const owner = key == null || options?.owner == null || new TextEncoder().encode(JSON.stringify(options.owner)).length > MAX_OWNER_BYTES ? void 0 : options.owner;
|
|
127
150
|
await this.kv.set(entryKey(keyId), {
|
|
128
151
|
key: serialized,
|
|
129
|
-
expires
|
|
152
|
+
expires,
|
|
153
|
+
...owner == null ? {} : { owner }
|
|
130
154
|
}, { ttl: Temporal.Duration.from({ milliseconds: ttl }) });
|
|
155
|
+
return key == null ? void 0 : Temporal.Instant.fromEpochMilliseconds(expires);
|
|
131
156
|
},
|
|
132
157
|
delete: async (keyId) => {
|
|
133
158
|
await this.kv.delete(entryKey(keyId));
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Temporal } from "temporal-polyfill";
|
|
2
2
|
import { URLPattern } from "urlpattern-polyfill";
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
|
-
import { p as recordDocumentCache } from "./metrics-
|
|
4
|
+
import { p as recordDocumentCache } from "./metrics-jUDFfVgi.mjs";
|
|
5
5
|
import { getLogger } from "@logtape/logtape";
|
|
6
6
|
import { preloadedContexts } from "@fedify/vocab-runtime";
|
|
7
7
|
//#region src/utils/kv-cache.ts
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
const { URLPattern } = require("urlpattern-polyfill");
|
|
2
|
-
const require_http = require("./http-
|
|
2
|
+
const require_http = require("./http-5CJBdU8n.cjs");
|
|
3
3
|
let _logtape_logtape = require("@logtape/logtape");
|
|
4
4
|
let _fedify_vocab_runtime = require("@fedify/vocab-runtime");
|
|
5
5
|
let es_toolkit = require("es-toolkit");
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Temporal } from "temporal-polyfill";
|
|
2
2
|
import { URLPattern } from "urlpattern-polyfill";
|
|
3
|
-
import { W as validateCryptoKey,
|
|
3
|
+
import { W as validateCryptoKey, at as recordDocumentCache, t as doubleKnock } from "./http-BGpexPO7.js";
|
|
4
4
|
import { getLogger } from "@logtape/logtape";
|
|
5
5
|
import { FetchError, UrlError, createActivityPubRequest, getRemoteDocument, logRequest, preloadedContexts, validatePublicUrl } from "@fedify/vocab-runtime";
|
|
6
6
|
import { curry } from "es-toolkit";
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import "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 getDurationMs, r as getFederationMetrics, s as measureSignatureKeyFetch } from "./metrics-
|
|
6
|
-
import { c as validateCryptoKey, i as fetchKey, t as bypassKeyCacheReads } from "./key-
|
|
4
|
+
import { n as version, t as name } from "./deno-DU8dvnWk.mjs";
|
|
5
|
+
import { n as getDurationMs, r as getFederationMetrics, s as measureSignatureKeyFetch } from "./metrics-jUDFfVgi.mjs";
|
|
6
|
+
import { c as validateCryptoKey, i as fetchKey, t as bypassKeyCacheReads } from "./key-gIhVZO3p.mjs";
|
|
7
7
|
import { getLogger } from "@logtape/logtape";
|
|
8
8
|
import { Activity, CryptographicKey, Object as Object$1, getTypeId } from "@fedify/vocab";
|
|
9
9
|
import { SpanStatusCode, trace } from "@opentelemetry/api";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "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-DU8dvnWk.mjs";
|
|
5
5
|
import { metrics } from "@opentelemetry/api";
|
|
6
6
|
import { FetchError } from "@fedify/vocab-runtime";
|
|
7
7
|
//#region src/federation/metrics.ts
|
|
@@ -1,29 +1,29 @@
|
|
|
1
1
|
import { Temporal } from "temporal-polyfill";
|
|
2
2
|
import "urlpattern-polyfill";
|
|
3
3
|
globalThis.addEventListener = () => {};
|
|
4
|
-
import { n as version, t as name } from "./deno-
|
|
5
|
-
import { 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, n as getDurationMs, o as isAbortError, r as getFederationMetrics, u as recordCollectionPageItems, v as recordOutboxActivity, x as registerQueueDepthGauge, y as recordOutboxEnqueue } from "./metrics-
|
|
4
|
+
import { n as version, t as name } from "./deno-DU8dvnWk.mjs";
|
|
5
|
+
import { 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, n as getDurationMs, o as isAbortError, r as getFederationMetrics, u as recordCollectionPageItems, v as recordOutboxActivity, x as registerQueueDepthGauge, y as recordOutboxEnqueue } from "./metrics-jUDFfVgi.mjs";
|
|
6
6
|
import { t as formatAcceptSignature } from "./accept-CPVqki78.mjs";
|
|
7
7
|
import { a as hasPortableActor, c as isPortableId, l as isPortableKeyId, n as getGatewayKeyBase, o as isCompatibleKeyId, r as getPortableDid, t as getCanonicalPortableId, u as isPortableUri } from "./portable-key-id-Bg259c4Z.mjs";
|
|
8
|
-
import { c as validateCryptoKey, n as exportJwk, s as importJwk } from "./key-
|
|
8
|
+
import { c as validateCryptoKey, n as exportJwk, s as importJwk } from "./key-gIhVZO3p.mjs";
|
|
9
9
|
import { r as normalizeOutgoingActivityJsonLd } from "./outgoing-jsonld-4IJqPYos.mjs";
|
|
10
|
-
import { _ as wrapContextLoaderForJsonLd, a as compactJsonLd, c as getNormalizationContextLoader, d as isClearlyMalformedContextReference, f as isInvalidUrlTypeError, l as hasSignature, m as verifyCompactJsonLd, p as signJsonLd, r as assertSafeJsonLd, s as detachSignature, t as InvalidContextReferenceError, u as hasSignatureLike } from "./ld-
|
|
11
|
-
import { a as signObject, c as verifyPortableObjectProof, i as hasProofLike, s as verifyObject, t as InvalidPortableObjectIdError, u as verifyPortableObjectProofWithRoot } from "./proof-
|
|
12
|
-
import { a as listRequestSignatures, c as selectRequestSignature, d as verifyRequest, f as verifyRequestDetailed, s as parseRfc9421SignatureInput } from "./http-
|
|
13
|
-
import { t as getAuthenticatedDocumentLoader } from "./docloader-
|
|
14
|
-
import { n as kvCache } from "./kv-cache-
|
|
10
|
+
import { _ as wrapContextLoaderForJsonLd, a as compactJsonLd, c as getNormalizationContextLoader, d as isClearlyMalformedContextReference, f as isInvalidUrlTypeError, l as hasSignature, m as verifyCompactJsonLd, p as signJsonLd, r as assertSafeJsonLd, s as detachSignature, t as InvalidContextReferenceError, u as hasSignatureLike } from "./ld-BsTkRrwF.mjs";
|
|
11
|
+
import { a as signObject, c as verifyPortableObjectProof, i as hasProofLike, s as verifyObject, t as InvalidPortableObjectIdError, u as verifyPortableObjectProofWithRoot } from "./proof-CQAYqWdj.mjs";
|
|
12
|
+
import { a as listRequestSignatures, c as selectRequestSignature, d as verifyRequest, f as verifyRequestDetailed, s as parseRfc9421SignatureInput } from "./http-Bd6rZlJX.mjs";
|
|
13
|
+
import { t as getAuthenticatedDocumentLoader } from "./docloader-CghLH7Zi.mjs";
|
|
14
|
+
import { n as kvCache } from "./kv-cache-D0qjSeWY.mjs";
|
|
15
15
|
import { d as readBoundedText, l as BodyTooLargeError, t as getNodeInfo, u as MAX_BODY_SIZE } from "./client-CEnNz8O7.mjs";
|
|
16
16
|
import { t as nodeInfoToJson } from "./types-DE_LV1JB.mjs";
|
|
17
|
-
import { n as getKeyOwner, t as doesActorOwnKey } from "./owner-
|
|
18
|
-
import { t as verifyPortableObject } from "./portable-collection-
|
|
19
|
-
import { n as extractInboxes, r as sendActivity, t as SendActivityError } from "./send-
|
|
20
|
-
import { n as FederationBuilderImpl, t as ACTOR_ALIAS_PREFIX } from "./builder-
|
|
17
|
+
import { n as getKeyOwner, t as doesActorOwnKey } from "./owner-D3GoetXS.mjs";
|
|
18
|
+
import { t as verifyPortableObject } from "./portable-collection-C60_acmx.mjs";
|
|
19
|
+
import { n as extractInboxes, r as sendActivity, t as SendActivityError } from "./send-DjkQrxt5.mjs";
|
|
20
|
+
import { n as FederationBuilderImpl, t as ACTOR_ALIAS_PREFIX } from "./builder-B2d_Pt0j.mjs";
|
|
21
21
|
import { t as CircuitBreaker } from "./circuit-breaker-C5NqoLBJ.mjs";
|
|
22
22
|
import { t as buildCollectionSynchronizationHeader } from "./collection-CnnP1UAv.mjs";
|
|
23
|
-
import { a as verifyCompoundPortableObjectProofs, i as inspectCompoundPortableObjectApplicability, r as findUnsupportedCompoundProofShape, s as verifyServedPortableObjects, t as containsCompoundPortableObject } from "./compound-proof-
|
|
24
|
-
import { t as KvKeyCache } from "./keycache-
|
|
23
|
+
import { a as verifyCompoundPortableObjectProofs, i as inspectCompoundPortableObjectApplicability, r as findUnsupportedCompoundProofShape, s as verifyServedPortableObjects, t as containsCompoundPortableObject } from "./compound-proof-D28gMFqP.mjs";
|
|
24
|
+
import { t as KvKeyCache } from "./keycache-PiOM9pM0.mjs";
|
|
25
25
|
import { t as acceptsJsonLd } from "./negotiation-CCocWT_N.mjs";
|
|
26
|
-
import { t as hasMalformedKnownTemporalLiteral } from "./temporal-
|
|
26
|
+
import { t as hasMalformedKnownTemporalLiteral } from "./temporal-oRKP803M.mjs";
|
|
27
27
|
import { t as createExponentialBackoffPolicy } from "./retry-zX5xw5e0.mjs";
|
|
28
28
|
import { t as TaskCodec } from "./codec-C6rTrpIp.mjs";
|
|
29
29
|
import { getLogger, withContext } from "@logtape/logtape";
|
|
@@ -2,10 +2,10 @@ import { Temporal } from "temporal-polyfill";
|
|
|
2
2
|
import { URLPattern } from "urlpattern-polyfill";
|
|
3
3
|
import { t as __exportAll } from "./rolldown-runtime-BC-Eo5Mj.js";
|
|
4
4
|
import { r as getDefaultActivityTransformers } from "./transformers-DAtXl_Kc.js";
|
|
5
|
-
import { $ as
|
|
5
|
+
import { $ as isAbortError, A as hasSignatureLike, C as assertSafeJsonLd, Ct as isPortableId, D as detachSignature, Dt as name, K as MAX_PORTABLE_KEY_TTL, L as wrapContextLoaderForJsonLd, M as isInvalidUrlTypeError, N as signJsonLd, O as getNormalizationContextLoader, Ot as version, P as verifyCompactJsonLd, Q as instrumentDocumentLoader, R as exportJwk, S as InvalidContextReferenceError, St as isCompatibleKeyId, T as compactJsonLd, Tt as isPortableUri, U as importJwk, W as validateCryptoKey, X as getFederationMetrics, Y as getDurationMs, Z as getRemoteHost, _ as verifyPortableObjectProof, _t as getCanonicalPortableId, bt as getRawCanonicalPortableId, ct as recordOutboxActivity, d as classifyFep2277CoreType, dt as registerQueueDepthGauge, et as recordCircuitBreakerStateChange, ft as preloadedOnlyDocumentLoader, g as verifyObject, h as verifyMapLocalProof, i as selectRequestSignature, it as recordCollectionTotalItems, j as isClearlyMalformedContextReference, k as hasSignature, lt as recordOutboxEnqueue, m as signObject, n as listRequestSignatures, nt as recordCollectionPageItems, o as verifyRequest, ot as recordFanoutRecipients, p as hasProofLike, pt as formatAcceptSignature, r as parseRfc9421SignatureInput, rt as recordCollectionRequest, s as verifyRequestDetailed, st as recordInboxActivity, t as doubleKnock, tt as recordCollectionDispatchDuration, u as InvalidPortableObjectIdError, ut as recordWebFingerHandle, v as verifyPortableObjectProofPolicy, vt as getGatewayKeyBase, wt as isPortableKeyId, x as normalizeOutgoingActivityJsonLd, xt as hasPortableActor, y as verifyPortableObjectProofWithRoot, yt as getPortableDid } from "./http-BGpexPO7.js";
|
|
6
6
|
import { a as MAX_BODY_SIZE, i as BodyTooLargeError, n as getNodeInfo, o as readBoundedText, t as nodeInfoToJson } from "./types-_S2_MeLF.js";
|
|
7
|
-
import { n as doesActorOwnKey, r as getKeyOwner, t as verifyPortableObject } from "./portable-collection-
|
|
8
|
-
import { n as getAuthenticatedDocumentLoader, t as kvCache } from "./kv-cache-
|
|
7
|
+
import { n as doesActorOwnKey, r as getKeyOwner, t as verifyPortableObject } from "./portable-collection-Bkdh_WpL.js";
|
|
8
|
+
import { n as getAuthenticatedDocumentLoader, t as kvCache } from "./kv-cache-iR55fqlk.js";
|
|
9
9
|
import { getLogger, withContext } from "@logtape/logtape";
|
|
10
10
|
import { Router, RouterError, assertPath } from "@fedify/uri-template";
|
|
11
11
|
import { Activity, Collection, CollectionPage, CryptographicKey, Link, Multikey, Object as Object$1, OrderedCollection, OrderedCollectionPage, Tombstone, getTypeId, isActor, lookupObject, traverseCollection } from "@fedify/vocab";
|
|
@@ -2494,10 +2494,13 @@ async function routeActivity({ context: ctx, json, originalJson, normalizedActiv
|
|
|
2494
2494
|
//#region src/federation/keycache.ts
|
|
2495
2495
|
const KEY_CACHE_GENERATION = "2";
|
|
2496
2496
|
const COMPATIBLE_KEY_SEGMENT = "__compatible";
|
|
2497
|
-
const
|
|
2497
|
+
const MAX_OWNER_BYTES = 32 * 1024;
|
|
2498
2498
|
function isCompatibleKeyEntry(value) {
|
|
2499
2499
|
return value != null && typeof value === "object" && "key" in value && "expires" in value && typeof value.expires === "number";
|
|
2500
2500
|
}
|
|
2501
|
+
function isJsonObject(value) {
|
|
2502
|
+
return value != null && typeof value === "object" && !Array.isArray(value);
|
|
2503
|
+
}
|
|
2501
2504
|
var KvKeyCache = class {
|
|
2502
2505
|
kv;
|
|
2503
2506
|
prefix;
|
|
@@ -2579,30 +2582,48 @@ var KvKeyCache = class {
|
|
|
2579
2582
|
keyId.href
|
|
2580
2583
|
];
|
|
2581
2584
|
const isExpired = (entry) => entry.expires <= now().epochMilliseconds;
|
|
2582
|
-
const keyTtl = Math.min(this.keyTtl.total("millisecond"),
|
|
2585
|
+
const keyTtl = Math.min(this.keyTtl.total("millisecond"), MAX_PORTABLE_KEY_TTL.total("millisecond"));
|
|
2583
2586
|
const unavailableKeyTtl = this.unavailableKeyTtl.total("millisecond");
|
|
2584
|
-
|
|
2585
|
-
|
|
2586
|
-
|
|
2587
|
-
|
|
2588
|
-
|
|
2589
|
-
|
|
2590
|
-
|
|
2591
|
-
|
|
2592
|
-
|
|
2593
|
-
|
|
2587
|
+
const getEntry = async (keyId) => {
|
|
2588
|
+
const entry = await this.kv.get(entryKey(keyId));
|
|
2589
|
+
if (entry === void 0) return void 0;
|
|
2590
|
+
if (!isCompatibleKeyEntry(entry) || isExpired(entry)) {
|
|
2591
|
+
await this.kv.delete(entryKey(keyId));
|
|
2592
|
+
return;
|
|
2593
|
+
}
|
|
2594
|
+
if (entry.key === null) return null;
|
|
2595
|
+
let expires;
|
|
2596
|
+
try {
|
|
2597
|
+
expires = Temporal.Instant.fromEpochMilliseconds(entry.expires);
|
|
2598
|
+
} catch (error) {
|
|
2599
|
+
if (!(error instanceof RangeError)) throw error;
|
|
2600
|
+
await this.kv.delete(entryKey(keyId));
|
|
2601
|
+
return;
|
|
2602
|
+
}
|
|
2603
|
+
let key;
|
|
2604
|
+
try {
|
|
2605
|
+
key = await CryptographicKey.fromJsonLd(entry.key, this.options);
|
|
2606
|
+
} catch {
|
|
2594
2607
|
try {
|
|
2595
|
-
key = await
|
|
2608
|
+
key = await Multikey.fromJsonLd(entry.key, this.options);
|
|
2596
2609
|
} catch {
|
|
2597
|
-
|
|
2598
|
-
|
|
2599
|
-
} catch {
|
|
2600
|
-
await this.kv.delete(entryKey(keyId));
|
|
2601
|
-
return;
|
|
2602
|
-
}
|
|
2610
|
+
await this.kv.delete(entryKey(keyId));
|
|
2611
|
+
return;
|
|
2603
2612
|
}
|
|
2604
|
-
|
|
2613
|
+
}
|
|
2614
|
+
if (isExpired(entry)) return void 0;
|
|
2615
|
+
return {
|
|
2616
|
+
key,
|
|
2617
|
+
...isJsonObject(entry.owner) ? { owner: entry.owner } : {},
|
|
2618
|
+
expires
|
|
2619
|
+
};
|
|
2620
|
+
};
|
|
2621
|
+
return {
|
|
2622
|
+
get: async (keyId) => {
|
|
2623
|
+
const entry = await getEntry(keyId);
|
|
2624
|
+
return entry == null ? entry : entry.key;
|
|
2605
2625
|
},
|
|
2626
|
+
getEntry,
|
|
2606
2627
|
set: async (keyId, key, options) => {
|
|
2607
2628
|
const serialized = key == null ? null : await key.toJsonLd(this.options);
|
|
2608
2629
|
const current = now();
|
|
@@ -2613,10 +2634,13 @@ var KvKeyCache = class {
|
|
|
2613
2634
|
await this.kv.delete(entryKey(keyId));
|
|
2614
2635
|
return;
|
|
2615
2636
|
}
|
|
2637
|
+
const owner = key == null || options?.owner == null || new TextEncoder().encode(JSON.stringify(options.owner)).length > MAX_OWNER_BYTES ? void 0 : options.owner;
|
|
2616
2638
|
await this.kv.set(entryKey(keyId), {
|
|
2617
2639
|
key: serialized,
|
|
2618
|
-
expires
|
|
2640
|
+
expires,
|
|
2641
|
+
...owner == null ? {} : { owner }
|
|
2619
2642
|
}, { ttl: Temporal.Duration.from({ milliseconds: ttl }) });
|
|
2643
|
+
return key == null ? void 0 : Temporal.Instant.fromEpochMilliseconds(expires);
|
|
2620
2644
|
},
|
|
2621
2645
|
delete: async (keyId) => {
|
|
2622
2646
|
await this.kv.delete(entryKey(keyId));
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference lib="esnext.temporal" />
|
|
2
|
-
import { S as KeyCache } from "./http-
|
|
2
|
+
import { S as KeyCache } from "./http-Cok5-vIC.js";
|
|
3
3
|
import { CryptographicKey, DataIntegrityProof, Multikey, Object as Object$1 } from "@fedify/vocab";
|
|
4
4
|
import { MeterProvider, TracerProvider } from "@opentelemetry/api";
|
|
5
5
|
import { DocumentLoader, PortableObjectVerifier, PortableObjectVerifierOptions } from "@fedify/vocab-runtime";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference lib="esnext.temporal" />
|
|
2
|
-
import { n as HttpMessageSignaturesSpecDeterminer } from "./http-
|
|
2
|
+
import { n as HttpMessageSignaturesSpecDeterminer } from "./http-Cok5-vIC.js";
|
|
3
3
|
import { n as KvStore, t as KvKey } from "./kv-BhNbN8Ed.js";
|
|
4
4
|
import { t as DocumentFetchKind } from "./metrics-DoRtI0qU.js";
|
|
5
5
|
import { MeterProvider, TracerProvider } from "@opentelemetry/api";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference lib="esnext.temporal" />
|
|
2
|
-
import { n as HttpMessageSignaturesSpecDeterminer } from "./http-
|
|
2
|
+
import { n as HttpMessageSignaturesSpecDeterminer } from "./http-DC1cqAQ2.cjs";
|
|
3
3
|
import { n as KvStore, t as KvKey } from "./kv-BhNbN8Ed.cjs";
|
|
4
4
|
import { t as DocumentFetchKind } from "./metrics-DVKYY6K1.cjs";
|
|
5
5
|
import { DocumentLoader, DocumentLoaderFactoryOptions } from "@fedify/vocab-runtime";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference lib="esnext.temporal" />
|
|
2
|
-
import { bt as ActorDispatcher, f as RequestContext, qt as WebFingerLinksDispatcher, xt as ActorHandleMapper, yt as ActorAliasMapper } from "./context-
|
|
2
|
+
import { bt as ActorDispatcher, f as RequestContext, qt as WebFingerLinksDispatcher, xt as ActorHandleMapper, yt as ActorAliasMapper } from "./context-L0Fnib9j.cjs";
|
|
3
3
|
import { MeterProvider, Span, Tracer } from "@opentelemetry/api";
|
|
4
4
|
import { RouterError, RouterOptions, RouterRouteResult } from "@fedify/uri-template";
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference lib="esnext.temporal" />
|
|
2
|
-
import { S as KeyCache } from "./http-
|
|
2
|
+
import { S as KeyCache } from "./http-DC1cqAQ2.cjs";
|
|
3
3
|
import { CryptographicKey, DataIntegrityProof, Multikey, Object as Object$1 } from "@fedify/vocab";
|
|
4
4
|
import { DocumentLoader, PortableObjectVerifier, PortableObjectVerifierOptions } from "@fedify/vocab-runtime";
|
|
5
5
|
import { MeterProvider, TracerProvider } from "@opentelemetry/api";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference lib="esnext.temporal" />
|
|
2
|
-
import { bt as ActorDispatcher, f as RequestContext, qt as WebFingerLinksDispatcher, xt as ActorHandleMapper, yt as ActorAliasMapper } from "./context-
|
|
2
|
+
import { bt as ActorDispatcher, f as RequestContext, qt as WebFingerLinksDispatcher, xt as ActorHandleMapper, yt as ActorAliasMapper } from "./context-BykNUf04.js";
|
|
3
3
|
import { RouterError, RouterOptions, RouterRouteResult } from "@fedify/uri-template";
|
|
4
4
|
import { MeterProvider, Span, Tracer } from "@opentelemetry/api";
|
|
5
5
|
|
package/dist/mod.cjs
CHANGED
|
@@ -3,11 +3,11 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
|
3
3
|
require("./rolldown-runtime-Dmm3t92W.cjs");
|
|
4
4
|
const require_transformers = require("./transformers-BalCrSsr.cjs");
|
|
5
5
|
require("./compat/mod.cjs");
|
|
6
|
-
const require_http = require("./http-
|
|
7
|
-
const require_federation = require("./federation-
|
|
6
|
+
const require_http = require("./http-5CJBdU8n.cjs");
|
|
7
|
+
const require_federation = require("./federation-DrNgkLfJ.cjs");
|
|
8
8
|
const require_types = require("./types-poIao40f.cjs");
|
|
9
|
-
const require_portable_collection = require("./portable-collection-
|
|
10
|
-
const require_kv_cache = require("./kv-cache-
|
|
9
|
+
const require_portable_collection = require("./portable-collection-CnlCamup.cjs");
|
|
10
|
+
const require_kv_cache = require("./kv-cache-YRi_g8GB.cjs");
|
|
11
11
|
require("./nodeinfo/mod.cjs");
|
|
12
12
|
require("./runtime/mod.cjs");
|
|
13
13
|
require("./sig/mod.cjs");
|