@fedify/fedify 1.9.6 → 1.9.8
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/{actor-CEGEmRll.js → actor-BTA45fXF.js} +1205 -2768
- package/dist/{actor-Ydzhc8dj.d.cts → actor-Be-68iJP.d.cts} +3 -3
- package/dist/{actor-C1Euqngb.d.ts → actor-C5AY0Tno.d.ts} +3 -3
- package/dist/{actor-DbpZ6pzg.js → actor-DGa1EWaV.mjs} +8 -15
- package/dist/{actor-DlS-Q8hE.cjs → actor-DxfJk4lY.cjs} +3112 -4674
- package/dist/{assert-MZs1qjMx.js → assert-DikXweDx.mjs} +5 -9
- package/dist/{assert_equals-DSbWqCm3.js → assert_equals-Ew3jOFa3.mjs} +55 -69
- package/dist/{assert_instance_of-DHz7EHNU.js → assert_instance_of-C4Ri6VuN.mjs} +5 -9
- package/dist/{assert_is_error-BPGph1Jx.js → assert_is_error-C50x8tnw.mjs} +5 -9
- package/dist/{assert_not_equals-f3m3epl3.js → assert_not_equals--wG9hV7u.mjs} +6 -13
- package/dist/{assert_rejects-DiIiJbZn.js → assert_rejects-CJC9ThS-.mjs} +6 -11
- package/dist/{assert_throws-BOO88avQ.js → assert_throws-BIL7gChy.mjs} +6 -10
- package/dist/{authdocloader-DUQcOTRS.js → authdocloader-BC2rYCy1.mjs} +9 -14
- package/dist/{authdocloader-CT_V4Z7G.cjs → authdocloader-BrhFB421.cjs} +14 -22
- package/dist/{authdocloader-BLqMyboS.js → authdocloader-CqtNsX_N.js} +8 -15
- package/dist/{builder-BO61xeXE.js → builder-CIkAhIGC.mjs} +31 -40
- package/dist/{client-DF8anIB5.d.ts → client-D8OSiPBT.d.ts} +2 -2
- package/dist/{client-UG5wpNhG.js → client-MXqit6c-.mjs} +11 -15
- package/dist/{client-DjT_tegg.d.cts → client-T0VFOdMw.d.cts} +2 -2
- package/dist/{collection-CSzG2j1P.js → collection-BD6-SZ6O.mjs} +7 -12
- package/dist/compat/mod.cjs +5 -8
- package/dist/compat/mod.d.cts +78 -12
- package/dist/compat/mod.d.ts +78 -12
- package/dist/compat/mod.js +4 -8
- package/dist/compat/transformers.test.mjs +62 -0
- package/dist/{context-CwUAkopp.d.cts → context-CACMqDzl.d.cts} +33 -26
- package/dist/{context-CXUibY4L.d.ts → context-K4cCphQj.d.ts} +33 -26
- package/dist/{denokv-Bv33Xxea.js → denokv-CoSB_Eps.mjs} +22 -11
- package/dist/{docloader-BIFI3OS7.cjs → docloader-BVuUhBLI.cjs} +112 -212
- package/dist/{docloader-fJgJeqiX.js → docloader-BoXhusJ1.js} +17 -151
- package/dist/{docloader-CxWcuWqQ.d.ts → docloader-DSaLRXEA.d.ts} +2 -7
- package/dist/{docloader-D-MrRyHl.d.cts → docloader-DpGRDZrn.d.cts} +2 -7
- package/dist/{esm-C1EfGjSS.js → esm-BHJ7sdNg.mjs} +49 -85
- package/dist/federation/{builder.test.js → builder.test.mjs} +22 -41
- package/dist/federation/collection.test.d.mts +2 -0
- package/dist/federation/collection.test.mjs +21 -0
- package/dist/federation/handler.test.d.mts +2 -0
- package/dist/federation/{handler.test.js → handler.test.mjs} +22 -49
- package/dist/federation/idempotency.test.d.mts +2 -0
- package/dist/federation/{idempotency.test.js → idempotency.test.mjs} +29 -59
- package/dist/federation/inbox.test.d.mts +2 -0
- package/dist/federation/{inbox.test.js → inbox.test.mjs} +10 -15
- package/dist/federation/keycache.test.d.mts +2 -0
- package/dist/federation/{keycache.test.js → keycache.test.mjs} +13 -18
- package/dist/federation/kv.test.d.mts +2 -0
- package/dist/federation/{kv.test.js → kv.test.mjs} +9 -20
- package/dist/federation/middleware.test.d.mts +2 -0
- package/dist/federation/{middleware.test.js → middleware.test.mjs} +182 -197
- package/dist/federation/mod.cjs +223 -21
- package/dist/federation/mod.d.cts +4 -13
- package/dist/federation/mod.d.ts +4 -13
- package/dist/federation/mod.js +218 -18
- package/dist/federation/mq.test.d.mts +2 -0
- package/dist/federation/{mq.test.js → mq.test.mjs} +23 -38
- package/dist/federation/retry.test.d.mts +2 -0
- package/dist/federation/{retry.test.js → retry.test.mjs} +9 -14
- package/dist/federation/router.test.d.mts +2 -0
- package/dist/federation/{router.test.js → router.test.mjs} +12 -19
- package/dist/federation/send.test.d.mts +2 -0
- package/dist/federation/{send.test.js → send.test.mjs} +17 -26
- package/dist/{http-wsGR6KkT.d.ts → http-BZpls--H.d.ts} +5 -9
- package/dist/{http-CR-Eg1Uq.js → http-Bu5ZNlhZ.mjs} +16 -32
- package/dist/{http-B1_DzfAU.d.cts → http-C7WoprmE.d.cts} +5 -9
- package/dist/{http-BgopPF-8.cjs → http-DKw-O_VY.cjs} +51 -68
- package/dist/{http-05HxN-lp.js → http-VJbz6sKD.js} +17 -33
- package/dist/{inbox-DcJN1cxM.js → inbox-DkbTULXE.mjs} +17 -25
- package/dist/key-4fu6v0Jf.mjs +5 -0
- package/dist/{key-DjS1X9TG.cjs → key-B-wFdaPB.cjs} +42 -50
- package/dist/{key-ibMO03_0.js → key-BNMK_IVr.mjs} +12 -18
- package/dist/key-CancShOo.cjs +4 -0
- package/dist/{key-CPJcJjp-.js → key-DK3o0FEH.js} +19 -19
- package/dist/{keycache-CMUfqYqr.js → keycache-D-Vj8z88.mjs} +6 -10
- package/dist/{keys-IZ5050fT.js → keys-B27nVeIs.mjs} +6 -10
- package/dist/{kv-C7sopW2E.d.ts → kv-Bq9QLKm5.d.ts} +1 -1
- package/dist/{kv-CRZrzyXm.js → kv-DM1zFCtL.mjs} +6 -10
- package/dist/{kv-63Cil1MD.d.cts → kv-GIrOktyG.d.cts} +1 -1
- package/dist/{ld-DHNA2RSQ.js → ld-6jAVu3jV.mjs} +17 -31
- package/dist/{lookup-CKZfuyxA.js → lookup-BaU75j-d.js} +5 -11
- package/dist/{lookup-C4_dVYz7.cjs → lookup-BiIPmTwB.cjs} +16 -23
- package/dist/{lookup-BMAWLsP2.js → lookup-DmeJ8WUw.mjs} +8 -17
- package/dist/middleware-9ByEpBvV.cjs +4 -0
- package/dist/{middleware-CGbvIGvy.cjs → middleware-C188G4Go.cjs} +494 -547
- package/dist/{middleware-DrhEvfTo.js → middleware-Db1yZQaT.mjs} +276 -321
- package/dist/{middleware-ODfDRN3q.js → middleware-Do06X21v.js} +349 -393
- package/dist/middleware-DrfZEjyc.mjs +5 -0
- package/dist/{mod-CDObsV1d.d.ts → mod-BSwc3_rD.d.ts} +3 -3
- package/dist/{mod-DBzN0aCM.d.ts → mod-BTNpXcPj.d.ts} +2 -2
- package/dist/{mod-fjqfsrty.d.cts → mod-Chb_NKPp.d.cts} +4 -4
- package/dist/{mod-DgcYoyZK.d.ts → mod-DHoc3toL.d.ts} +4 -4
- package/dist/{mod-jQ4OODsl.d.cts → mod-DIMx6YjJ.d.cts} +2 -2
- package/dist/{mod-BUbqxBev.d.cts → mod-HElaq2UB.d.cts} +3 -3
- package/dist/mod.cjs +31 -33
- package/dist/mod.d.cts +15 -17
- package/dist/mod.d.ts +15 -17
- package/dist/mod.js +20 -23
- package/dist/{mq-B7R1Q-M5.d.cts → mq-CrItclRD.d.cts} +1 -1
- package/dist/{mq-CRGm1e_F.d.ts → mq-D_ZZRdby.d.ts} +1 -1
- package/dist/nodeinfo/client.test.d.mts +2 -0
- package/dist/nodeinfo/{client.test.js → client.test.mjs} +23 -45
- package/dist/nodeinfo/handler.test.d.mts +2 -0
- package/dist/nodeinfo/{handler.test.js → handler.test.mjs} +14 -43
- package/dist/nodeinfo/mod.cjs +5 -9
- package/dist/nodeinfo/mod.d.cts +2 -5
- package/dist/nodeinfo/mod.d.ts +2 -5
- package/dist/nodeinfo/mod.js +4 -9
- package/dist/nodeinfo/semver.test.d.mts +2 -0
- package/dist/nodeinfo/{semver.test.js → semver.test.mjs} +28 -51
- package/dist/nodeinfo/types.test.d.mts +2 -0
- package/dist/nodeinfo/{types.test.js → types.test.mjs} +10 -21
- package/dist/{owner-DDHsHYQO.js → owner-CKuGt_T9.mjs} +10 -13
- package/dist/{owner-BbeUDvOu.d.ts → owner-DPAPnB0R.d.ts} +4 -4
- package/dist/{owner-6KSEp9eV.d.cts → owner-_rFs0ik_.d.cts} +4 -4
- package/dist/{proof-V1uQaB2y.js → proof-CmTtG_t-.js} +33 -57
- package/dist/{proof-CX7ujFFX.cjs → proof-DLOy7HYU.cjs} +112 -135
- package/dist/{proof-exgGRW88.js → proof-mJLL2gSA.mjs} +20 -32
- package/dist/{retry-D4GJ670a.js → retry-Ddbq3AcK.mjs} +4 -7
- package/dist/rolldown-runtime-C7fyD9f2.js +15 -0
- package/dist/runtime/authdocloader.test.d.mts +2 -0
- package/dist/runtime/{authdocloader.test.js → authdocloader.test.mjs} +16 -28
- package/dist/runtime/docloader.test.d.mts +2 -0
- package/dist/runtime/{docloader.test.js → docloader.test.mjs} +52 -72
- package/dist/runtime/key.test.d.mts +2 -0
- package/dist/runtime/{key.test.js → key.test.mjs} +27 -57
- package/dist/runtime/langstr.test.d.mts +2 -0
- package/dist/runtime/{langstr.test.js → langstr.test.mjs} +9 -19
- package/dist/runtime/link.test.d.mts +2 -0
- package/dist/runtime/{link.test.js → link.test.mjs} +7 -11
- package/dist/runtime/mod.cjs +7 -13
- package/dist/runtime/mod.d.cts +103 -6
- package/dist/runtime/mod.d.ts +103 -6
- package/dist/runtime/mod.js +6 -13
- package/dist/runtime/multibase/multibase.test.d.mts +2 -0
- package/dist/runtime/multibase/{multibase.test.js → multibase.test.mjs} +16 -33
- package/dist/runtime/url.test.d.mts +2 -0
- package/dist/runtime/{url.test.js → url.test.mjs} +10 -15
- package/dist/{semver-dArNLkR9.js → semver-CgD82xxg.mjs} +13 -28
- package/dist/{send-BfMYakUE.js → send-BsQbGuw4.mjs} +7 -12
- package/dist/sig/http.test.d.mts +2 -0
- package/dist/sig/{http.test.js → http.test.mjs} +119 -203
- package/dist/sig/key.test.d.mts +2 -0
- package/dist/sig/{key.test.js → key.test.mjs} +13 -22
- package/dist/sig/ld.test.d.mts +2 -0
- package/dist/sig/{ld.test.js → ld.test.mjs} +24 -39
- package/dist/sig/mod.cjs +7 -13
- package/dist/sig/mod.d.cts +3 -7
- package/dist/sig/mod.d.ts +3 -7
- package/dist/sig/mod.js +6 -13
- package/dist/sig/owner.test.d.mts +2 -0
- package/dist/sig/owner.test.mjs +39 -0
- package/dist/sig/proof.test.d.mts +2 -0
- package/dist/sig/{proof.test.js → proof.test.mjs} +18 -31
- package/dist/{std__assert-X-_kMxKM.js → std__assert-2v7gYiZp.mjs} +13 -24
- package/dist/testing/docloader.test.d.mts +2 -0
- package/dist/testing/docloader.test.mjs +12 -0
- package/dist/testing/{mod.d.ts → mod.d.mts} +371 -541
- package/dist/testing/mod.mjs +5 -0
- package/dist/{testing-RPOc_gVG.js → testing-DS3gcq8V.mjs} +27 -35
- package/dist/{transformers-CoBS-oFG.cjs → transformers-BM0M8hnW.cjs} +20 -25
- package/dist/{transformers-BFT6d7J5.js → transformers-BV4OeK9o.js} +3 -7
- package/dist/{types-Cptev2nt.js → types-BXfL-dsX.js} +18 -36
- package/dist/{types-BIgY6c-l.js → types-CAnkAQGM.mjs} +5 -9
- package/dist/{types-CGnM1vft.cjs → types-DpM4FhjW.cjs} +45 -64
- package/dist/vocab/actor.test.d.mts +2 -0
- package/dist/vocab/{actor.test.js → actor.test.mjs} +308 -550
- package/dist/vocab/cjs.test.d.mts +2 -0
- package/dist/vocab/cjs.test.mjs +14 -0
- package/dist/vocab/lookup.test.d.mts +2 -0
- package/dist/vocab/{lookup.test.js → lookup.test.mjs} +29 -45
- package/dist/vocab/mod.cjs +251 -16
- package/dist/vocab/mod.d.cts +3 -5
- package/dist/vocab/mod.d.ts +3 -5
- package/dist/vocab/mod.js +244 -10
- package/dist/vocab/type.test.d.mts +2 -0
- package/dist/vocab/type.test.mjs +16 -0
- package/dist/vocab/vocab.test.d.mts +2 -0
- package/dist/vocab/{vocab.test.js → vocab.test.mjs} +178 -311
- package/dist/{vocab-CDHNj5zp.d.ts → vocab-BLvSEtuz.d.cts} +2 -4
- package/dist/{type-COPv6pMi.js → vocab-DuW9rL1h.mjs} +1177 -2871
- package/dist/{vocab-Cfs0937i.d.cts → vocab-lhCS9lzq.d.ts} +4 -2
- package/dist/webfinger/handler.test.d.mts +2 -0
- package/dist/webfinger/{handler.test.js → handler.test.mjs} +23 -56
- package/dist/webfinger/lookup.test.d.mts +2 -0
- package/dist/webfinger/{lookup.test.js → lookup.test.mjs} +13 -27
- package/dist/webfinger/mod.cjs +5 -9
- package/dist/webfinger/mod.d.cts +1 -3
- package/dist/webfinger/mod.d.ts +1 -3
- package/dist/webfinger/mod.js +4 -9
- package/dist/x/cfworkers.cjs +25 -14
- package/dist/x/cfworkers.d.cts +33 -6
- package/dist/x/cfworkers.d.ts +33 -6
- package/dist/x/cfworkers.js +22 -12
- package/dist/x/cfworkers.test.d.mts +2 -0
- package/dist/x/{cfworkers.test.js → cfworkers.test.mjs} +28 -26
- package/dist/x/hono.cjs +25 -14
- package/dist/x/hono.d.cts +1 -11
- package/dist/x/hono.d.ts +1 -11
- package/dist/x/hono.js +22 -12
- package/dist/x/sveltekit.cjs +23 -12
- package/dist/x/sveltekit.d.cts +1 -11
- package/dist/x/sveltekit.d.ts +1 -11
- package/dist/x/sveltekit.js +20 -10
- package/package.json +2 -2
- package/dist/chunk-DqRYRqnO.cjs +0 -34
- package/dist/compat/transformers.test.d.ts +0 -3
- package/dist/compat/transformers.test.js +0 -86
- package/dist/compat-DmDDELst.cjs +0 -4
- package/dist/compat-nxUqe4Z-.js +0 -4
- package/dist/federation/builder.test.d.ts +0 -3
- package/dist/federation/collection.test.d.ts +0 -3
- package/dist/federation/collection.test.js +0 -35
- package/dist/federation/handler.test.d.ts +0 -3
- package/dist/federation/idempotency.test.d.ts +0 -3
- package/dist/federation/inbox.test.d.ts +0 -3
- package/dist/federation/keycache.test.d.ts +0 -3
- package/dist/federation/kv.test.d.ts +0 -3
- package/dist/federation/middleware.test.d.ts +0 -3
- package/dist/federation/mq.test.d.ts +0 -3
- package/dist/federation/retry.test.d.ts +0 -3
- package/dist/federation/router.test.d.ts +0 -3
- package/dist/federation/send.test.d.ts +0 -3
- package/dist/federation-D1U8YY9t.js +0 -226
- package/dist/federation-H2_En3j5.cjs +0 -244
- package/dist/key-BCUd8FWp.js +0 -10
- package/dist/key-BUardnTH.cjs +0 -10
- package/dist/key-Dr6H_e3K.js +0 -10
- package/dist/middleware-BJ83veqi.js +0 -26
- package/dist/middleware-CJ4W2ir5.cjs +0 -17
- package/dist/middleware-Ve2mHJgo.js +0 -17
- package/dist/mod-BcObK1Lz.d.ts +0 -82
- package/dist/mod-C2tOeRkN.d.cts +0 -1
- package/dist/mod-CIbqfZW0.d.ts +0 -104
- package/dist/mod-Dt-G9ZOS.d.cts +0 -102
- package/dist/mod-FZd39qVq.d.cts +0 -1
- package/dist/mod-mXx9V0q5.d.cts +0 -80
- package/dist/nodeinfo/client.test.d.ts +0 -3
- package/dist/nodeinfo/handler.test.d.ts +0 -3
- package/dist/nodeinfo/semver.test.d.ts +0 -3
- package/dist/nodeinfo/types.test.d.ts +0 -3
- package/dist/nodeinfo-Co9lJrWl.cjs +0 -4
- package/dist/nodeinfo-DfycQ8Wf.js +0 -4
- package/dist/runtime/authdocloader.test.d.ts +0 -3
- package/dist/runtime/docloader.test.d.ts +0 -3
- package/dist/runtime/key.test.d.ts +0 -3
- package/dist/runtime/langstr.test.d.ts +0 -3
- package/dist/runtime/link.test.d.ts +0 -3
- package/dist/runtime/multibase/multibase.test.d.ts +0 -3
- package/dist/runtime/url.test.d.ts +0 -3
- package/dist/runtime-C58AJWSv.cjs +0 -4
- package/dist/runtime-DPYEDf-o.js +0 -4
- package/dist/sig/http.test.d.ts +0 -3
- package/dist/sig/key.test.d.ts +0 -3
- package/dist/sig/ld.test.d.ts +0 -3
- package/dist/sig/owner.test.d.ts +0 -3
- package/dist/sig/owner.test.js +0 -52
- package/dist/sig/proof.test.d.ts +0 -3
- package/dist/sig-ByHXzqUi.cjs +0 -4
- package/dist/sig-Cj3tk-ig.js +0 -4
- package/dist/testing/docloader.test.d.ts +0 -3
- package/dist/testing/docloader.test.js +0 -24
- package/dist/testing/mod.js +0 -10
- package/dist/vocab/actor.test.d.ts +0 -3
- package/dist/vocab/lookup.test.d.ts +0 -3
- package/dist/vocab/type.test.d.ts +0 -3
- package/dist/vocab/type.test.js +0 -25
- package/dist/vocab/vocab.test.d.ts +0 -3
- package/dist/vocab-BFy1CS5L.cjs +0 -289
- package/dist/vocab-BPFiQ650.js +0 -253
- package/dist/webfinger/handler.test.d.ts +0 -3
- package/dist/webfinger/lookup.test.d.ts +0 -3
- package/dist/webfinger-BjOEdFPs.cjs +0 -4
- package/dist/webfinger-De_bU0iE.js +0 -4
- package/dist/x/cfworkers.test.d.ts +0 -3
- /package/dist/{mod-1pDWKvUL.d.ts → compat/transformers.test.d.mts} +0 -0
- /package/dist/{mod-g0xFzAP9.d.ts → federation/builder.test.d.mts} +0 -0
|
@@ -1,137 +1,35 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
1
|
+
const { Temporal } = require("@js-temporal/polyfill");
|
|
2
|
+
const { URLPattern } = require("urlpattern-polyfill");
|
|
3
|
+
//#region \0rolldown/runtime.js
|
|
4
|
+
var __create = Object.create;
|
|
5
|
+
var __defProp = Object.defineProperty;
|
|
6
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
7
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
8
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
9
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
|
|
12
|
+
key = keys[i];
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
14
|
+
get: ((k) => from[k]).bind(null, key),
|
|
15
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
16
|
+
});
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
21
|
+
value: mod,
|
|
22
|
+
enumerable: true
|
|
23
|
+
}) : target, mod));
|
|
24
|
+
//#endregion
|
|
25
|
+
let _logtape_logtape = require("@logtape/logtape");
|
|
26
|
+
let node_process = require("node:process");
|
|
27
|
+
node_process = __toESM(node_process);
|
|
28
|
+
let node_dns_promises = require("node:dns/promises");
|
|
29
|
+
let node_net = require("node:net");
|
|
11
30
|
//#region deno.json
|
|
12
31
|
var name = "@fedify/fedify";
|
|
13
|
-
var version = "1.9.
|
|
14
|
-
var license = "MIT";
|
|
15
|
-
var exports$1 = {
|
|
16
|
-
".": "./src/mod.ts",
|
|
17
|
-
"./compat": "./src/compat/mod.ts",
|
|
18
|
-
"./federation": "./src/federation/mod.ts",
|
|
19
|
-
"./nodeinfo": "./src/nodeinfo/mod.ts",
|
|
20
|
-
"./runtime": "./src/runtime/mod.ts",
|
|
21
|
-
"./sig": "./src/sig/mod.ts",
|
|
22
|
-
"./testing": "./src/testing/mod.ts",
|
|
23
|
-
"./vocab": "./src/vocab/mod.ts",
|
|
24
|
-
"./webfinger": "./src/webfinger/mod.ts",
|
|
25
|
-
"./x/cfworkers": "./src/x/cfworkers.ts",
|
|
26
|
-
"./x/denokv": "./src/x/denokv.ts",
|
|
27
|
-
"./x/fresh": "./src/x/fresh.ts",
|
|
28
|
-
"./x/hono": "./src/x/hono.ts",
|
|
29
|
-
"./x/sveltekit": "./src/x/sveltekit.ts"
|
|
30
|
-
};
|
|
31
|
-
var imports = {
|
|
32
|
-
"@cfworker/json-schema": "npm:@cfworker/json-schema@^4.1.1",
|
|
33
|
-
"@multiformats/base-x": "npm:@multiformats/base-x@^4.0.1",
|
|
34
|
-
"@opentelemetry/api": "npm:@opentelemetry/api@^1.9.0",
|
|
35
|
-
"@opentelemetry/semantic-conventions": "npm:@opentelemetry/semantic-conventions@^1.27.0",
|
|
36
|
-
"@phensley/language-tag": "npm:@phensley/language-tag@^1.9.0",
|
|
37
|
-
"@std/assert": "jsr:@std/assert@^0.226.0",
|
|
38
|
-
"@std/testing": "jsr:@std/testing@^0.224.0",
|
|
39
|
-
"@std/url": "jsr:@std/url@^0.225.1",
|
|
40
|
-
"asn1js": "npm:asn1js@^3.0.5",
|
|
41
|
-
"byte-encodings": "npm:byte-encodings@^1.0.11",
|
|
42
|
-
"es-toolkit": "jsr:@es-toolkit/es-toolkit@^1.39.5",
|
|
43
|
-
"fast-check": "npm:fast-check@^3.22.0",
|
|
44
|
-
"fetch-mock": "npm:fetch-mock@^12.5.2",
|
|
45
|
-
"json-canon": "npm:json-canon@^1.0.1",
|
|
46
|
-
"jsonld": "npm:jsonld@^8.3.2",
|
|
47
|
-
"multicodec": "npm:multicodec@^3.2.1",
|
|
48
|
-
"pkijs": "npm:pkijs@^3.2.4",
|
|
49
|
-
"structured-field-values": "npm:structured-field-values@^2.0.4",
|
|
50
|
-
"uri-template-router": "npm:uri-template-router@^1.0.0",
|
|
51
|
-
"url-template": "npm:url-template@^3.1.1"
|
|
52
|
-
};
|
|
53
|
-
var include = ["src/vocab/vocab.ts"];
|
|
54
|
-
var exclude = [
|
|
55
|
-
".test-report.xml",
|
|
56
|
-
"apidoc/",
|
|
57
|
-
"dist/",
|
|
58
|
-
"node_modules/",
|
|
59
|
-
"npm/",
|
|
60
|
-
"pnpm-lock.yaml",
|
|
61
|
-
"src/cfworkers/dist/",
|
|
62
|
-
"src/cfworkers/fixtures/",
|
|
63
|
-
"src/cfworkers/imports.ts",
|
|
64
|
-
"src/cfworkers/README.md",
|
|
65
|
-
"src/cfworkers/server.ts",
|
|
66
|
-
"src/cfworkers/server.js",
|
|
67
|
-
"src/cfworkers/server.js.map",
|
|
68
|
-
"src/codegen/schema.yaml",
|
|
69
|
-
"src/vocab/*.yaml",
|
|
70
|
-
"!src/vocab/vocab.ts"
|
|
71
|
-
];
|
|
72
|
-
var tasks = {
|
|
73
|
-
"codegen": "GENPATH=vocab-$(deno eval \"console.log(crypto.randomUUID());\").ts && deno run --allow-read --allow-write --check src/codegen/main.ts src/vocab/ ../runtime/ src/vocab/$GENPATH && deno fmt src/vocab/$GENPATH && mv src/vocab/$GENPATH src/vocab/vocab.ts && deno cache src/vocab/vocab.ts && deno check src/vocab/vocab.ts",
|
|
74
|
-
"cache": {
|
|
75
|
-
"command": "deno cache src/mod.ts",
|
|
76
|
-
"dependencies": ["codegen"]
|
|
77
|
-
},
|
|
78
|
-
"check": {
|
|
79
|
-
"command": "deno fmt --check && deno lint && deno check src/**/*.ts",
|
|
80
|
-
"dependencies": ["codegen"]
|
|
81
|
-
},
|
|
82
|
-
"test": {
|
|
83
|
-
"command": "deno test --check --doc --allow-read --allow-write --allow-env --unstable-kv --trace-leaks --parallel",
|
|
84
|
-
"dependencies": ["codegen"]
|
|
85
|
-
},
|
|
86
|
-
"coverage": "deno task test --clean --coverage && deno coverage --html coverage",
|
|
87
|
-
"bench": {
|
|
88
|
-
"command": "deno bench --allow-read --allow-write --allow-net --allow-env --allow-run --unstable-kv",
|
|
89
|
-
"dependencies": ["codegen"]
|
|
90
|
-
},
|
|
91
|
-
"apidoc": {
|
|
92
|
-
"command": "deno doc --html --name=Fedify --output=apidoc/ src/mod.ts",
|
|
93
|
-
"dependencies": ["codegen"]
|
|
94
|
-
},
|
|
95
|
-
"publish": {
|
|
96
|
-
"command": "deno publish",
|
|
97
|
-
"dependencies": ["codegen"]
|
|
98
|
-
},
|
|
99
|
-
"pnpm:install": "pnpm install",
|
|
100
|
-
"pnpm:build": {
|
|
101
|
-
"command": "pnpm exec tsdown",
|
|
102
|
-
"dependencies": ["codegen", "pnpm:install"]
|
|
103
|
-
},
|
|
104
|
-
"test:node": {
|
|
105
|
-
"command": "cd dist/ && node --test",
|
|
106
|
-
"dependencies": ["pnpm:build"]
|
|
107
|
-
},
|
|
108
|
-
"test:bun": {
|
|
109
|
-
"command": "cd dist/ && bun test --timeout 60000",
|
|
110
|
-
"dependencies": ["pnpm:build"]
|
|
111
|
-
},
|
|
112
|
-
"test:cfworkers": {
|
|
113
|
-
"command": "pnpm exec wrangler deploy --dry-run --outdir src/cfworkers && node --import=tsx src/cfworkers/client.ts",
|
|
114
|
-
"dependencies": ["pnpm:build"]
|
|
115
|
-
},
|
|
116
|
-
"test-all": { "dependencies": [
|
|
117
|
-
"check",
|
|
118
|
-
"test",
|
|
119
|
-
"test:node",
|
|
120
|
-
"test:bun",
|
|
121
|
-
"test:cfworkers"
|
|
122
|
-
] }
|
|
123
|
-
};
|
|
124
|
-
var deno_default = {
|
|
125
|
-
name,
|
|
126
|
-
version,
|
|
127
|
-
license,
|
|
128
|
-
exports: exports$1,
|
|
129
|
-
imports,
|
|
130
|
-
include,
|
|
131
|
-
exclude,
|
|
132
|
-
tasks
|
|
133
|
-
};
|
|
134
|
-
|
|
32
|
+
var version = "1.9.8";
|
|
135
33
|
//#endregion
|
|
136
34
|
//#region src/runtime/contexts.ts
|
|
137
35
|
const preloadedContexts = {
|
|
@@ -4275,8 +4173,6 @@ const preloadedContexts = {
|
|
|
4275
4173
|
}
|
|
4276
4174
|
} }
|
|
4277
4175
|
};
|
|
4278
|
-
var contexts_default = preloadedContexts;
|
|
4279
|
-
|
|
4280
4176
|
//#endregion
|
|
4281
4177
|
//#region src/runtime/link.ts
|
|
4282
4178
|
const parametersNeedLowerCase = ["rel", "type"];
|
|
@@ -4458,7 +4354,6 @@ var HttpHeaderLink = class HttpHeaderLink {
|
|
|
4458
4354
|
return new this(...inputs).toString();
|
|
4459
4355
|
}
|
|
4460
4356
|
};
|
|
4461
|
-
|
|
4462
4357
|
//#endregion
|
|
4463
4358
|
//#region src/runtime/url.ts
|
|
4464
4359
|
var UrlError = class extends Error {
|
|
@@ -4477,8 +4372,7 @@ async function validatePublicUrl(url) {
|
|
|
4477
4372
|
if (hostname.startsWith("[") && hostname.endsWith("]")) hostname = hostname.substring(1, hostname.length - 2);
|
|
4478
4373
|
if (hostname === "localhost") throw new UrlError("Localhost is not allowed");
|
|
4479
4374
|
if ("Deno" in globalThis && !(0, node_net.isIP)(hostname)) {
|
|
4480
|
-
|
|
4481
|
-
if (netPermission.state !== "granted") return;
|
|
4375
|
+
if ((await Deno.permissions.query({ name: "net" })).state !== "granted") return;
|
|
4482
4376
|
}
|
|
4483
4377
|
if ("Bun" in globalThis) {
|
|
4484
4378
|
if (hostname === "example.com" || hostname.endsWith(".example.com")) return;
|
|
@@ -4514,13 +4408,11 @@ function expandIPv6Address(address) {
|
|
|
4514
4408
|
if (address.startsWith("::")) address = "0000" + address;
|
|
4515
4409
|
if (address.endsWith("::")) address = address + "0000";
|
|
4516
4410
|
address = address.replace("::", ":0000".repeat(8 - (address.match(/:/g) || []).length) + ":");
|
|
4517
|
-
|
|
4518
|
-
return parts.map((part) => part.padStart(4, "0")).join(":");
|
|
4411
|
+
return address.split(":").map((part) => part.padStart(4, "0")).join(":");
|
|
4519
4412
|
}
|
|
4520
|
-
|
|
4521
4413
|
//#endregion
|
|
4522
4414
|
//#region src/runtime/docloader.ts
|
|
4523
|
-
const logger = (0,
|
|
4415
|
+
const logger = (0, _logtape_logtape.getLogger)([
|
|
4524
4416
|
"fedify",
|
|
4525
4417
|
"runtime",
|
|
4526
4418
|
"docloader"
|
|
@@ -4583,7 +4475,7 @@ function logRequest(request) {
|
|
|
4583
4475
|
* @throws {FetchError} If the response is not OK.
|
|
4584
4476
|
* @internal
|
|
4585
4477
|
*/
|
|
4586
|
-
async function getRemoteDocument(url, response, fetch
|
|
4478
|
+
async function getRemoteDocument(url, response, fetch) {
|
|
4587
4479
|
const documentUrl = response.url === "" ? url : response.url;
|
|
4588
4480
|
const docUrl = new URL(documentUrl);
|
|
4589
4481
|
if (!response.ok) {
|
|
@@ -4621,7 +4513,7 @@ async function getRemoteDocument(url, response, fetch$1) {
|
|
|
4621
4513
|
alternateUrl: altUri.href,
|
|
4622
4514
|
url: documentUrl
|
|
4623
4515
|
});
|
|
4624
|
-
return await fetch
|
|
4516
|
+
return await fetch(altUri.href);
|
|
4625
4517
|
}
|
|
4626
4518
|
}
|
|
4627
4519
|
}
|
|
@@ -4647,15 +4539,14 @@ async function getRemoteDocument(url, response, fetch$1) {
|
|
|
4647
4539
|
attrPattern.lastIndex = 0;
|
|
4648
4540
|
while ((attrMatch = attrPattern.exec(tagContent)) !== null) {
|
|
4649
4541
|
const key = attrMatch[1].toLowerCase();
|
|
4650
|
-
|
|
4651
|
-
attribs[key] = value;
|
|
4542
|
+
attribs[key] = attrMatch[2] ?? attrMatch[3] ?? attrMatch[4] ?? "";
|
|
4652
4543
|
}
|
|
4653
4544
|
if (attribs.rel === "alternate" && "type" in attribs && (attribs.type === "application/activity+json" || attribs.type === "application/ld+json" || attribs.type.startsWith("application/ld+json;")) && "href" in attribs && new URL(attribs.href, docUrl).href !== docUrl.href) {
|
|
4654
4545
|
logger.debug("Found alternate document: {alternateUrl} from {url}", {
|
|
4655
4546
|
alternateUrl: attribs.href,
|
|
4656
4547
|
url: documentUrl
|
|
4657
4548
|
});
|
|
4658
|
-
return await fetch
|
|
4549
|
+
return await fetch(new URL(attribs.href, docUrl).href);
|
|
4659
4550
|
}
|
|
4660
4551
|
}
|
|
4661
4552
|
document = JSON.parse(html);
|
|
@@ -4693,11 +4584,11 @@ function getDocumentLoader({ allowPrivateAddress, skipPreloadedContexts, userAge
|
|
|
4693
4584
|
async function load(url, options, redirected = 0, visited = /* @__PURE__ */ new Set()) {
|
|
4694
4585
|
options?.signal?.throwIfAborted();
|
|
4695
4586
|
const currentUrl = new URL(url).href;
|
|
4696
|
-
if (!skipPreloadedContexts && currentUrl in
|
|
4587
|
+
if (!skipPreloadedContexts && currentUrl in preloadedContexts) {
|
|
4697
4588
|
logger.debug("Using preloaded context: {url}.", { url: currentUrl });
|
|
4698
4589
|
return {
|
|
4699
4590
|
contextUrl: null,
|
|
4700
|
-
document:
|
|
4591
|
+
document: preloadedContexts[currentUrl],
|
|
4701
4592
|
documentUrl: currentUrl
|
|
4702
4593
|
};
|
|
4703
4594
|
}
|
|
@@ -4744,8 +4635,7 @@ const _fetchDocumentLoader_allowPrivateAddress = getDocumentLoader({ allowPrivat
|
|
|
4744
4635
|
function fetchDocumentLoader(url, arg = false) {
|
|
4745
4636
|
const allowPrivateAddress = typeof arg === "boolean" ? arg : false;
|
|
4746
4637
|
logger.warn("fetchDocumentLoader() function is deprecated. Use getDocumentLoader() function instead.");
|
|
4747
|
-
|
|
4748
|
-
return loader(url);
|
|
4638
|
+
return (allowPrivateAddress ? _fetchDocumentLoader_allowPrivateAddress : _fetchDocumentLoader)(url);
|
|
4749
4639
|
}
|
|
4750
4640
|
/**
|
|
4751
4641
|
* Decorates a {@link DocumentLoader} with a cache backed by a {@link Deno.Kv}.
|
|
@@ -4771,11 +4661,11 @@ function kvCache({ loader, kv, prefix, rules }) {
|
|
|
4771
4661
|
return null;
|
|
4772
4662
|
}
|
|
4773
4663
|
return async (url, options) => {
|
|
4774
|
-
if (url in
|
|
4664
|
+
if (url in preloadedContexts) {
|
|
4775
4665
|
logger.debug("Using preloaded context: {url}.", { url });
|
|
4776
4666
|
return {
|
|
4777
4667
|
contextUrl: null,
|
|
4778
|
-
document:
|
|
4668
|
+
document: preloadedContexts[url],
|
|
4779
4669
|
documentUrl: url
|
|
4780
4670
|
};
|
|
4781
4671
|
}
|
|
@@ -4813,79 +4703,89 @@ function kvCache({ loader, kv, prefix, rules }) {
|
|
|
4813
4703
|
* @since 1.3.0
|
|
4814
4704
|
*/
|
|
4815
4705
|
function getUserAgent({ software, url } = {}) {
|
|
4816
|
-
const fedify = `Fedify/${
|
|
4706
|
+
const fedify = `Fedify/${version}`;
|
|
4817
4707
|
const runtime = globalThis.Deno?.version?.deno != null ? `Deno/${Deno.version.deno}` : globalThis.process?.versions?.bun != null ? `Bun/${node_process.default.versions.bun}` : "navigator" in globalThis && navigator.userAgent === "Cloudflare-Workers" ? navigator.userAgent : globalThis.process?.versions?.node != null ? `Node.js/${node_process.default.versions.node}` : null;
|
|
4818
4708
|
const userAgent = software == null ? [fedify] : [software, fedify];
|
|
4819
4709
|
if (runtime != null) userAgent.push(runtime);
|
|
4820
4710
|
if (url != null) userAgent.push(`+${url.toString()}`);
|
|
4821
|
-
|
|
4822
|
-
return `${first} (${userAgent.join("; ")})`;
|
|
4711
|
+
return `${userAgent.shift()} (${userAgent.join("; ")})`;
|
|
4823
4712
|
}
|
|
4824
|
-
|
|
4825
4713
|
//#endregion
|
|
4826
|
-
Object.defineProperty(exports,
|
|
4827
|
-
|
|
4828
|
-
|
|
4829
|
-
|
|
4830
|
-
|
|
4714
|
+
Object.defineProperty(exports, "FetchError", {
|
|
4715
|
+
enumerable: true,
|
|
4716
|
+
get: function() {
|
|
4717
|
+
return FetchError;
|
|
4718
|
+
}
|
|
4719
|
+
});
|
|
4720
|
+
Object.defineProperty(exports, "UrlError", {
|
|
4721
|
+
enumerable: true,
|
|
4722
|
+
get: function() {
|
|
4723
|
+
return UrlError;
|
|
4724
|
+
}
|
|
4725
|
+
});
|
|
4726
|
+
Object.defineProperty(exports, "__toESM", {
|
|
4727
|
+
enumerable: true,
|
|
4728
|
+
get: function() {
|
|
4729
|
+
return __toESM;
|
|
4730
|
+
}
|
|
4731
|
+
});
|
|
4732
|
+
Object.defineProperty(exports, "createRequest", {
|
|
4733
|
+
enumerable: true,
|
|
4734
|
+
get: function() {
|
|
4735
|
+
return createRequest;
|
|
4736
|
+
}
|
|
4831
4737
|
});
|
|
4832
|
-
Object.defineProperty(exports,
|
|
4833
|
-
|
|
4834
|
-
|
|
4835
|
-
|
|
4836
|
-
|
|
4738
|
+
Object.defineProperty(exports, "fetchDocumentLoader", {
|
|
4739
|
+
enumerable: true,
|
|
4740
|
+
get: function() {
|
|
4741
|
+
return fetchDocumentLoader;
|
|
4742
|
+
}
|
|
4837
4743
|
});
|
|
4838
|
-
Object.defineProperty(exports,
|
|
4839
|
-
|
|
4840
|
-
|
|
4841
|
-
|
|
4842
|
-
|
|
4744
|
+
Object.defineProperty(exports, "getDocumentLoader", {
|
|
4745
|
+
enumerable: true,
|
|
4746
|
+
get: function() {
|
|
4747
|
+
return getDocumentLoader;
|
|
4748
|
+
}
|
|
4843
4749
|
});
|
|
4844
|
-
Object.defineProperty(exports,
|
|
4845
|
-
|
|
4846
|
-
|
|
4847
|
-
|
|
4848
|
-
|
|
4750
|
+
Object.defineProperty(exports, "getRemoteDocument", {
|
|
4751
|
+
enumerable: true,
|
|
4752
|
+
get: function() {
|
|
4753
|
+
return getRemoteDocument;
|
|
4754
|
+
}
|
|
4849
4755
|
});
|
|
4850
|
-
Object.defineProperty(exports,
|
|
4851
|
-
|
|
4852
|
-
|
|
4853
|
-
|
|
4854
|
-
|
|
4756
|
+
Object.defineProperty(exports, "getUserAgent", {
|
|
4757
|
+
enumerable: true,
|
|
4758
|
+
get: function() {
|
|
4759
|
+
return getUserAgent;
|
|
4760
|
+
}
|
|
4855
4761
|
});
|
|
4856
|
-
Object.defineProperty(exports,
|
|
4857
|
-
|
|
4858
|
-
|
|
4859
|
-
|
|
4860
|
-
|
|
4762
|
+
Object.defineProperty(exports, "kvCache", {
|
|
4763
|
+
enumerable: true,
|
|
4764
|
+
get: function() {
|
|
4765
|
+
return kvCache;
|
|
4766
|
+
}
|
|
4861
4767
|
});
|
|
4862
|
-
Object.defineProperty(exports,
|
|
4863
|
-
|
|
4864
|
-
|
|
4865
|
-
|
|
4866
|
-
|
|
4768
|
+
Object.defineProperty(exports, "logRequest", {
|
|
4769
|
+
enumerable: true,
|
|
4770
|
+
get: function() {
|
|
4771
|
+
return logRequest;
|
|
4772
|
+
}
|
|
4867
4773
|
});
|
|
4868
|
-
Object.defineProperty(exports,
|
|
4869
|
-
|
|
4870
|
-
|
|
4871
|
-
|
|
4872
|
-
|
|
4774
|
+
Object.defineProperty(exports, "name", {
|
|
4775
|
+
enumerable: true,
|
|
4776
|
+
get: function() {
|
|
4777
|
+
return name;
|
|
4778
|
+
}
|
|
4873
4779
|
});
|
|
4874
|
-
Object.defineProperty(exports,
|
|
4875
|
-
|
|
4876
|
-
|
|
4877
|
-
|
|
4878
|
-
|
|
4780
|
+
Object.defineProperty(exports, "validatePublicUrl", {
|
|
4781
|
+
enumerable: true,
|
|
4782
|
+
get: function() {
|
|
4783
|
+
return validatePublicUrl;
|
|
4784
|
+
}
|
|
4879
4785
|
});
|
|
4880
|
-
Object.defineProperty(exports,
|
|
4881
|
-
|
|
4882
|
-
|
|
4883
|
-
|
|
4884
|
-
|
|
4786
|
+
Object.defineProperty(exports, "version", {
|
|
4787
|
+
enumerable: true,
|
|
4788
|
+
get: function() {
|
|
4789
|
+
return version;
|
|
4790
|
+
}
|
|
4885
4791
|
});
|
|
4886
|
-
Object.defineProperty(exports, 'validatePublicUrl', {
|
|
4887
|
-
enumerable: true,
|
|
4888
|
-
get: function () {
|
|
4889
|
-
return validatePublicUrl;
|
|
4890
|
-
}
|
|
4891
|
-
});
|