@fedify/fedify 1.6.1-dev.856 → 1.6.1-dev.871
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-CM3gfkH6.js +36173 -0
- package/dist/{vocab/actor.js → actor-D7NMuy45.js} +5 -4
- package/dist/{vocab/actor.d.ts → actor-lFlm8FYo.d.ts} +2 -2
- package/dist/{node_modules/.pnpm/@jsr_std__assert@0.226.0/node_modules/@jsr/std__assert/assert.js → assert-Dv75vaGI.js} +2 -1
- package/dist/assert_equals-ClvzlhZu.js +1020 -0
- package/dist/{node_modules/.pnpm/@jsr_std__assert@0.226.0/node_modules/@jsr/std__assert/assert_instance_of.js → assert_instance_of--9UCVKsi.js} +2 -1
- package/dist/{node_modules/.pnpm/@jsr_std__assert@0.226.0/node_modules/@jsr/std__assert/assert_is_error.js → assert_is_error-D162gXcM.js} +2 -2
- package/dist/{node_modules/.pnpm/@jsr_std__assert@0.226.0/node_modules/@jsr/std__assert/assert_not_equals.js → assert_not_equals-Cyf5m9Ke.js} +2 -2
- package/dist/{node_modules/.pnpm/@jsr_std__assert@0.226.0/node_modules/@jsr/std__assert/assert_rejects.js → assert_rejects-FOHCtlD2.js} +23 -3
- package/dist/{node_modules/.pnpm/@jsr_std__assert@0.226.0/node_modules/@jsr/std__assert/assert_throws.js → assert_throws-CRfQJvVx.js} +3 -2
- package/dist/{runtime/authdocloader.js → authdocloader-BKZDAq91.js} +5 -4
- package/dist/authdocloader-OfYZlI31.js +51 -0
- package/dist/{federation/builder.js → builder-DSTiU6ue.js} +18 -17
- package/dist/{_virtual/rolldown_runtime.js → chunk-HsBuZ-b2.js} +1 -0
- package/dist/client-Dw1pCSIt.d.ts +299 -0
- package/dist/{nodeinfo/client.js → client-RN5A1Qgw.js} +3 -2
- package/dist/{federation/collection.js → collection-QaGK9TVn.js} +1 -0
- package/dist/compat/mod.d.ts +12 -2
- package/dist/compat/mod.js +2 -1
- package/dist/compat/transformers.test.d.ts +2 -1
- package/dist/compat/transformers.test.js +32 -8
- package/dist/context-CzJXjNR8.d.ts +2034 -0
- package/dist/{testing/context.js → context-DZKXS0DV.js} +5 -4
- package/dist/{x/denokv.js → denokv-iB_ggPGm.js} +3 -1
- package/dist/{testing/docloader.js → docloader-09nVWLAZ.js} +1 -0
- package/dist/{runtime/contexts.js → docloader-BcMxZ9JH.js} +420 -1
- package/dist/docloader-DDFam5Xn.js +4594 -0
- package/dist/{runtime/docloader.d.ts → docloader-DTRsVZPo.d.ts} +1 -1
- package/dist/esm-BxIKwi-M.js +1221 -0
- package/dist/federation/builder.test.d.ts +2 -1
- package/dist/federation/builder.test.js +22 -7
- package/dist/federation/collection.test.d.ts +2 -1
- package/dist/federation/collection.test.js +11 -3
- package/dist/federation/handler.test.d.ts +2 -1
- package/dist/federation/handler.test.js +40 -12
- package/dist/federation/inbox.test.d.ts +2 -1
- package/dist/federation/inbox.test.js +12 -5
- package/dist/federation/keycache.test.d.ts +2 -1
- package/dist/federation/keycache.test.js +12 -7
- package/dist/federation/kv.test.d.ts +2 -1
- package/dist/federation/kv.test.js +11 -3
- package/dist/federation/middleware.test.d.ts +2 -1
- package/dist/federation/middleware.test.js +107 -26
- package/dist/federation/mod.d.ts +13 -13
- package/dist/federation/mod.js +12 -8
- package/dist/federation/mq.test.d.ts +2 -1
- package/dist/federation/mq.test.js +153 -6
- package/dist/federation/retry.test.d.ts +2 -1
- package/dist/federation/retry.test.js +5 -5
- package/dist/federation/router.test.d.ts +2 -1
- package/dist/federation/router.test.js +24 -4
- package/dist/federation/send.test.d.ts +2 -1
- package/dist/federation/send.test.js +25 -13
- package/dist/{federation/mq.js → federation-Bmj7soSg.js} +47 -1
- package/dist/{node_modules/.pnpm/@jsr_hongminhee__deno-mock-fetch@0.3.2/node_modules/@jsr/hongminhee__deno-mock-fetch/router.js → hongminhee__deno-mock-fetch-DJKLj_H-.js} +96 -1
- package/dist/{sig/http.js → http-BFvv3ZId.js} +5 -4
- package/dist/http-BImJcLfv.d.ts +258 -0
- package/dist/http-v1TqJ9Qa.js +720 -0
- package/dist/{federation/inbox.js → inbox-XV_W1qfB.js} +10 -4
- package/dist/key-BNM-ickE.js +16 -0
- package/dist/key-CVIQ7iUB.js +262 -0
- package/dist/{sig/key.js → key-DIk4Rloj.js} +2 -4
- package/dist/key-DiVhk5ik.js +10 -0
- package/dist/{federation/keycache.js → keycache-uTxsh7dt.js} +2 -1
- package/dist/{testing/keys.js → keys-D7lJqunm.js} +2 -2
- package/dist/{federation/kv.js → kv-DohFOP2C.js} +1 -0
- package/dist/{runtime/langstr.js → langstr-DbWheeIS.js} +1 -0
- package/dist/{sig/ld.js → ld-bOhcKpmk.js} +6 -6
- package/dist/{webfinger/lookup.js → lookup-B5KVF6HM.js} +1 -3
- package/dist/lookup-D3xTID-6.js +131 -0
- package/dist/{webfinger/jrd.d.ts → lookup-DAfStZtI.d.ts} +41 -1
- package/dist/{vocab/lookup.js → lookup-D_v0FFGL.js} +5 -5
- package/dist/middleware-BFedQWFA.js +33 -0
- package/dist/middleware-BiYIqI0b.js +3525 -0
- package/dist/{federation/middleware.js → middleware-CPAfRtS5.js} +957 -105
- package/dist/middleware-pAGwVkRf.js +17 -0
- package/dist/mod-1pDWKvUL.d.ts +2 -0
- package/dist/{runtime/key.d.ts → mod-BxwG4X3V.d.ts} +52 -7
- package/dist/{compat/transformers.d.ts → mod-CeLnlsqE.d.ts} +3 -4
- package/dist/{vocab/lookup.d.ts → mod-DysVoXOu.d.ts} +98 -3
- package/dist/mod-GIh5OYxW.d.ts +2 -0
- package/dist/{sig/ld.d.ts → mod-XT0mRthe.d.ts} +126 -4
- package/dist/mod-g0xFzAP9.d.ts +2 -0
- package/dist/mod.d.ts +18 -34
- package/dist/mod.js +17 -27
- package/dist/multibase-DeCHcK8L.js +316 -0
- package/dist/nodeinfo/client.test.d.ts +2 -1
- package/dist/nodeinfo/client.test.js +15 -4
- package/dist/nodeinfo/handler.test.d.ts +2 -1
- package/dist/nodeinfo/handler.test.js +39 -7
- package/dist/nodeinfo/mod.d.ts +4 -3
- package/dist/nodeinfo/mod.js +3 -3
- package/dist/nodeinfo/semver.test.d.ts +2 -1
- package/dist/nodeinfo/semver.test.js +11 -4
- package/dist/nodeinfo/types.test.d.ts +2 -1
- package/dist/nodeinfo/types.test.js +12 -4
- package/dist/{sig/owner.d.ts → owner-BjpObx-L.d.ts} +4 -6
- package/dist/{sig/owner.js → owner-tYPzPLFs.js} +4 -4
- package/dist/proof-D0cf4R25.js +595 -0
- package/dist/{sig/proof.js → proof-DIsZ1VTb.js} +5 -4
- package/dist/{federation/retry.js → retry-BiIhZWgD.js} +1 -0
- package/dist/{federation/router.js → router-D_aVZZUc.js} +20 -1
- package/dist/runtime/authdocloader.test.d.ts +2 -1
- package/dist/runtime/authdocloader.test.js +24 -9
- package/dist/runtime/docloader.test.d.ts +2 -1
- package/dist/runtime/docloader.test.js +15 -11
- package/dist/runtime/key.test.d.ts +2 -1
- package/dist/runtime/key.test.js +19 -4
- package/dist/runtime/langstr.test.d.ts +2 -1
- package/dist/runtime/langstr.test.js +11 -3
- package/dist/runtime/mod.d.ts +5 -4
- package/dist/runtime/mod.js +7 -4
- package/dist/runtime/multibase/multibase.test.d.ts +2 -1
- package/dist/runtime/multibase/multibase.test.js +11 -5
- package/dist/runtime/url.test.d.ts +2 -1
- package/dist/runtime/url.test.js +7 -6
- package/dist/{nodeinfo/semver.js → semver-CbbIgUsa.js} +1 -0
- package/dist/{federation/send.js → send-CFBOnY61.js} +3 -2
- package/dist/sig/http.test.d.ts +2 -1
- package/dist/sig/http.test.js +23 -12
- package/dist/sig/key.test.d.ts +2 -1
- package/dist/sig/key.test.js +21 -8
- package/dist/sig/ld.test.d.ts +2 -1
- package/dist/sig/ld.test.js +19 -11
- package/dist/sig/mod.d.ts +7 -5
- package/dist/sig/mod.js +7 -5
- package/dist/sig/owner.test.d.ts +2 -1
- package/dist/sig/owner.test.js +23 -9
- package/dist/sig/proof.test.d.ts +2 -1
- package/dist/sig/proof.test.js +22 -10
- package/dist/std__assert-CaBUULmX.js +151 -0
- package/dist/testing/docloader.test.d.ts +2 -1
- package/dist/testing/docloader.test.js +11 -3
- package/dist/testing/mod.d.ts +1 -0
- package/dist/testing/mod.js +2 -136
- package/dist/testing-jcGLO9Lp.js +143 -0
- package/dist/{compat/transformers.js → transformers-jxj-4o2K.js} +1 -1
- package/dist/{vocab/type.js → type-D2s5lmbZ.js} +1 -0
- package/dist/{nodeinfo/types.js → types-CqoqWDkp.js} +2 -1
- package/dist/types-D4p7qK8A.js +457 -0
- package/dist/{runtime/url.js → url-kTAI6_KP.js} +1 -0
- package/dist/vocab/actor.test.d.ts +2 -1
- package/dist/vocab/actor.test.js +5853 -14
- package/dist/vocab/lookup.test.d.ts +2 -1
- package/dist/vocab/lookup.test.js +20 -7
- package/dist/vocab/mod.d.ts +5 -5
- package/dist/vocab/mod.js +4 -5
- package/dist/vocab/type.test.d.ts +2 -1
- package/dist/vocab/type.test.js +9 -4
- package/dist/vocab/vocab.test.d.ts +2 -1
- package/dist/vocab/vocab.test.js +2440 -15
- package/dist/vocab-BSNlVPPE.js +172 -0
- package/dist/{vocab/vocab.js → vocab-BxrrllKY.js} +331 -182
- package/dist/{vocab/vocab.d.ts → vocab-CLWdoo7y.d.ts} +21 -9
- package/dist/webfinger/handler.test.d.ts +2 -1
- package/dist/webfinger/handler.test.js +39 -7
- package/dist/webfinger/lookup.test.d.ts +2 -1
- package/dist/webfinger/lookup.test.js +14 -4
- package/dist/webfinger/mod.d.ts +4 -2
- package/dist/webfinger/mod.js +3 -1
- package/dist/x/cfworkers.d.ts +49 -0
- package/dist/x/cfworkers.js +73 -0
- package/dist/x/cfworkers.test.d.ts +3 -0
- package/dist/x/cfworkers.test.js +153 -0
- package/dist/x/hono.d.ts +11 -2
- package/dist/x/sveltekit.d.ts +11 -2
- package/package.json +6 -1
- package/dist/codegen/fs.js +0 -23
- package/dist/codegen/schema.js +0 -88
- package/dist/codegen/type.js +0 -392
- package/dist/compat/types.d.ts +0 -18
- package/dist/deno.js +0 -137
- package/dist/federation/builder.d.ts +0 -19
- package/dist/federation/callback.d.ts +0 -211
- package/dist/federation/collection.d.ts +0 -36
- package/dist/federation/context.d.ts +0 -757
- package/dist/federation/federation.d.ts +0 -689
- package/dist/federation/handler.d.ts +0 -44
- package/dist/federation/handler.js +0 -543
- package/dist/federation/middleware.d.ts +0 -101
- package/dist/federation/negotiation.js +0 -63
- package/dist/federation/retry.d.ts +0 -71
- package/dist/federation/router.d.ts +0 -91
- package/dist/federation/send.d.ts +0 -29
- package/dist/node_modules/.pnpm/@jsr_hongminhee__deno-mock-fetch@0.3.2/node_modules/@jsr/hongminhee__deno-mock-fetch/mod.js +0 -101
- package/dist/node_modules/.pnpm/@jsr_std__assert@0.226.0/node_modules/@jsr/std__assert/assert_equals.js +0 -49
- package/dist/node_modules/.pnpm/@jsr_std__assert@0.226.0/node_modules/@jsr/std__assert/assert_exists.js +0 -32
- package/dist/node_modules/.pnpm/@jsr_std__assert@0.226.0/node_modules/@jsr/std__assert/assert_false.js +0 -26
- package/dist/node_modules/.pnpm/@jsr_std__assert@0.226.0/node_modules/@jsr/std__assert/assert_greater.js +0 -34
- package/dist/node_modules/.pnpm/@jsr_std__assert@0.226.0/node_modules/@jsr/std__assert/assert_greater_or_equal.js +0 -34
- package/dist/node_modules/.pnpm/@jsr_std__assert@0.226.0/node_modules/@jsr/std__assert/assert_strict_equals.js +0 -53
- package/dist/node_modules/.pnpm/@jsr_std__assert@0.226.0/node_modules/@jsr/std__assert/assert_string_includes.js +0 -32
- package/dist/node_modules/.pnpm/@jsr_std__assert@0.226.0/node_modules/@jsr/std__assert/assertion_error.js +0 -33
- package/dist/node_modules/.pnpm/@jsr_std__assert@0.226.0/node_modules/@jsr/std__assert/equal.js +0 -79
- package/dist/node_modules/.pnpm/@jsr_std__assert@0.226.0/node_modules/@jsr/std__assert/mod.js +0 -19
- package/dist/node_modules/.pnpm/@jsr_std__internal@1.0.7/node_modules/@jsr/std__internal/assertion_state.js +0 -177
- package/dist/node_modules/.pnpm/@jsr_std__internal@1.0.7/node_modules/@jsr/std__internal/build_message.js +0 -101
- package/dist/node_modules/.pnpm/@jsr_std__internal@1.0.7/node_modules/@jsr/std__internal/diff.js +0 -274
- package/dist/node_modules/.pnpm/@jsr_std__internal@1.0.7/node_modules/@jsr/std__internal/diff_str.js +0 -148
- package/dist/node_modules/.pnpm/@jsr_std__internal@1.0.7/node_modules/@jsr/std__internal/format.js +0 -37
- package/dist/node_modules/.pnpm/@jsr_std__internal@1.0.7/node_modules/@jsr/std__internal/mod.js +0 -10
- package/dist/node_modules/.pnpm/@jsr_std__internal@1.0.7/node_modules/@jsr/std__internal/styles.js +0 -172
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/_common/assert_path.js +0 -11
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/_common/constants.js +0 -10
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/_common/dirname.js +0 -14
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/_common/from_file_url.js +0 -13
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/_common/normalize.js +0 -14
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/_common/normalize_string.js +0 -60
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/_common/strip_trailing_separators.js +0 -15
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/_os.js +0 -9
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/extname.js +0 -4
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/format.js +0 -4
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/from_file_url.js +0 -34
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/glob_to_regexp.js +0 -4
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/is_absolute.js +0 -4
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/join.js +0 -4
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/join_globs.js +0 -4
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/mod.js +0 -5
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/normalize.js +0 -4
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/normalize_glob.js +0 -4
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/parse.js +0 -4
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/posix/_util.js +0 -13
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/posix/dirname.js +0 -54
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/posix/from_file_url.js +0 -27
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/posix/join.js +0 -47
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/posix/normalize.js +0 -59
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/relative.js +0 -4
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/resolve.js +0 -4
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/to_file_url.js +0 -4
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/to_namespaced_path.js +0 -4
- package/dist/node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/windows/from_file_url.js +0 -31
- package/dist/node_modules/.pnpm/@jsr_std__url@1.0.0-rc.3/node_modules/@jsr/std__url/_strip.js +0 -17
- package/dist/node_modules/.pnpm/@jsr_std__url@1.0.0-rc.3/node_modules/@jsr/std__url/dirname.js +0 -38
- package/dist/node_modules/.pnpm/@jsr_std__url@1.0.0-rc.3/node_modules/@jsr/std__url/join.js +0 -36
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_chars.js +0 -47
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_dumper_state.js +0 -4
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_loader_state.js +0 -884
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_schema.js +0 -120
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_type/binary.js +0 -92
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_type/bool.js +0 -41
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_type/float.js +0 -58
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_type/int.js +0 -118
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_type/map.js +0 -18
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_type/merge.js +0 -14
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_type/nil.js +0 -23
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_type/omap.js +0 -31
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_type/pairs.js +0 -22
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_type/regexp.js +0 -29
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_type/seq.js +0 -14
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_type/set.js +0 -17
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_type/str.js +0 -14
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_type/timestamp.js +0 -57
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_type/undefined.js +0 -24
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/_utils.js +0 -17
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/mod.js +0 -5
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/parse.js +0 -54
- package/dist/node_modules/.pnpm/@jsr_std__yaml@1.0.6/node_modules/@jsr/std__yaml/stringify.js +0 -4
- package/dist/node_modules/.pnpm/dequal@2.0.3/node_modules/dequal/dist/index.js +0 -68
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/AlwaysShrinkableArbitrary.js +0 -30
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/ArrayArbitrary.js +0 -203
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/ArrayInt64Arbitrary.js +0 -122
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/BigIntArbitrary.js +0 -63
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/ConstantArbitrary.js +0 -58
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/FrequencyArbitrary.js +0 -136
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/IntegerArbitrary.js +0 -64
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/LazyArbitrary.js +0 -29
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/StringUnitArbitrary.js +0 -45
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/TupleArbitrary.js +0 -74
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/WithShrinkFromOtherArbitrary.js +0 -40
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/builders/AnyArbitraryBuilder.js +0 -97
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/builders/BoxedArbitraryBuilder.js +0 -13
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/builders/CharacterArbitraryBuilder.js +0 -17
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/builders/RestrictedIntegerArbitraryBuilder.js +0 -23
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/builders/TypedIntArrayArbitraryBuilder.js +0 -32
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/data/GraphemeRanges.js +0 -990
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/ArrayInt64.js +0 -98
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/BiasNumericRange.js +0 -53
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/BuildSlicedGenerator.js +0 -15
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/CustomEqualSet.js +0 -27
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/DepthContext.js +0 -24
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/DoubleHelpers.js +0 -96
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/DoubleOnlyHelpers.js +0 -25
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/FloatHelpers.js +0 -57
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/FloatOnlyHelpers.js +0 -26
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/FloatingOnlyHelpers.js +0 -26
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/GraphemeRangesHelpers.js +0 -58
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/MaxLengthFromMinLength.js +0 -72
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/NoUndefinedAsContext.js +0 -16
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/QualifiedObjectConstraints.js +0 -58
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/SameValueSet.js +0 -41
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/SameValueZeroSet.js +0 -33
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/ShrinkBigInt.js +0 -37
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/ShrinkInteger.js +0 -41
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/SlicesForStringBuilder.js +0 -74
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/StrictlyEqualSet.js +0 -38
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/helpers/TokenizeString.js +0 -47
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/implementations/NoopSlicedGenerator.js +0 -21
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/implementations/SlicedBasedGenerator.js +0 -53
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/mappers/ArrayToMap.js +0 -16
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/mappers/ArrayToSet.js +0 -16
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/mappers/CodePointsToString.js +0 -17
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/mappers/IndexToCharString.js +0 -20
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/mappers/IndexToMappedConstant.js +0 -69
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/mappers/IndexToPrintableIndex.js +0 -18
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/mappers/KeyValuePairsToObject.js +0 -42
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/mappers/PatternsToString.js +0 -32
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/mappers/TimeToDate.js +0 -30
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/_internals/mappers/UnboxedToBoxed.js +0 -22
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/anything.js +0 -14
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/array.js +0 -22
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/bigInt.js +0 -38
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/boolean.js +0 -24
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/constant.js +0 -13
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/constantFrom.js +0 -14
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/date.js +0 -30
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/dictionary.js +0 -27
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/double.js +0 -54
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/float.js +0 -60
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/float32Array.js +0 -22
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/float64Array.js +0 -22
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/fullUnicode.js +0 -24
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/fullUnicodeString.js +0 -20
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/int16Array.js +0 -15
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/int32Array.js +0 -15
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/int8Array.js +0 -15
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/integer.js +0 -26
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/letrec.js +0 -28
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/mapToConstant.js +0 -26
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/maxSafeInteger.js +0 -15
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/nat.js +0 -17
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/noBias.js +0 -11
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/oneof.js +0 -31
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/sparseArray.js +0 -68
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/string.js +0 -32
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/tuple.js +0 -13
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/uint16Array.js +0 -15
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/uint32Array.js +0 -15
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/uint8Array.js +0 -15
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/uint8ClampedArray.js +0 -15
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/arbitrary/uniqueArray.js +0 -47
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/arbitrary/definition/Arbitrary.js +0 -184
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/arbitrary/definition/Value.js +0 -31
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/precondition/PreconditionFailure.js +0 -19
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/property/IRawProperty.js +0 -12
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/property/IgnoreEqualValuesProperty.js +0 -52
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/property/Property.generic.js +0 -77
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/property/Property.js +0 -22
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/property/SkipAfterProperty.js +0 -61
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/property/TimeoutProperty.js +0 -52
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/property/UnbiasedProperty.js +0 -29
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/runner/DecorateProperty.js +0 -26
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/runner/Runner.js +0 -61
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/runner/RunnerIterator.js +0 -47
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/runner/SourceValuesIterator.js +0 -35
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/runner/Tosser.js +0 -33
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/runner/configuration/GlobalParameters.js +0 -12
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/runner/configuration/QualifiedParameters.js +0 -121
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/runner/configuration/VerbosityLevel.js +0 -14
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/runner/reporter/ExecutionStatus.js +0 -14
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/runner/reporter/RunExecution.js +0 -116
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/runner/utils/PathWalker.js +0 -24
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/runner/utils/RunDetailsFormatter.js +0 -135
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/check/symbols.js +0 -15
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/random/generator/Random.js +0 -48
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/stream/LazyIterableIterator.js +0 -24
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/stream/Stream.js +0 -84
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/stream/StreamHelpers.js +0 -50
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/utils/apply.js +0 -28
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/utils/globals.js +0 -309
- package/dist/node_modules/.pnpm/fast-check@3.23.2/node_modules/fast-check/lib/esm/utils/stringify.js +0 -217
- package/dist/node_modules/.pnpm/fetch-mock@12.5.2/node_modules/fetch-mock/dist/esm/CallHistory.js +0 -94
- package/dist/node_modules/.pnpm/fetch-mock@12.5.2/node_modules/fetch-mock/dist/esm/FetchMock.js +0 -143
- package/dist/node_modules/.pnpm/fetch-mock@12.5.2/node_modules/fetch-mock/dist/esm/IsSubsetOf.js +0 -103
- package/dist/node_modules/.pnpm/fetch-mock@12.5.2/node_modules/fetch-mock/dist/esm/Matchers.js +0 -195
- package/dist/node_modules/.pnpm/fetch-mock@12.5.2/node_modules/fetch-mock/dist/esm/RequestUtils.js +0 -83
- package/dist/node_modules/.pnpm/fetch-mock@12.5.2/node_modules/fetch-mock/dist/esm/Route.js +0 -137
- package/dist/node_modules/.pnpm/fetch-mock@12.5.2/node_modules/fetch-mock/dist/esm/Router.js +0 -181
- package/dist/node_modules/.pnpm/fetch-mock@12.5.2/node_modules/fetch-mock/dist/esm/StatusTextMap.js +0 -73
- package/dist/node_modules/.pnpm/fetch-mock@12.5.2/node_modules/fetch-mock/dist/esm/TypeDescriptor.js +0 -97
- package/dist/node_modules/.pnpm/fetch-mock@12.5.2/node_modules/fetch-mock/dist/esm/index.js +0 -11
- package/dist/node_modules/.pnpm/glob-to-regexp@0.4.1/node_modules/glob-to-regexp/index.js +0 -87
- package/dist/node_modules/.pnpm/pure-rand@6.1.0/node_modules/pure-rand/lib/esm/distribution/UniformArrayIntDistribution.js +0 -20
- package/dist/node_modules/.pnpm/pure-rand@6.1.0/node_modules/pure-rand/lib/esm/distribution/UniformBigIntDistribution.js +0 -20
- package/dist/node_modules/.pnpm/pure-rand@6.1.0/node_modules/pure-rand/lib/esm/distribution/UniformIntDistribution.js +0 -20
- package/dist/node_modules/.pnpm/pure-rand@6.1.0/node_modules/pure-rand/lib/esm/distribution/UnsafeUniformArrayIntDistribution.js +0 -20
- package/dist/node_modules/.pnpm/pure-rand@6.1.0/node_modules/pure-rand/lib/esm/distribution/UnsafeUniformBigIntDistribution.js +0 -32
- package/dist/node_modules/.pnpm/pure-rand@6.1.0/node_modules/pure-rand/lib/esm/distribution/UnsafeUniformIntDistribution.js +0 -43
- package/dist/node_modules/.pnpm/pure-rand@6.1.0/node_modules/pure-rand/lib/esm/distribution/internals/ArrayInt.js +0 -139
- package/dist/node_modules/.pnpm/pure-rand@6.1.0/node_modules/pure-rand/lib/esm/distribution/internals/UnsafeUniformArrayIntDistributionInternal.js +0 -26
- package/dist/node_modules/.pnpm/pure-rand@6.1.0/node_modules/pure-rand/lib/esm/distribution/internals/UnsafeUniformIntDistributionInternal.js +0 -14
- package/dist/node_modules/.pnpm/pure-rand@6.1.0/node_modules/pure-rand/lib/esm/generator/LinearCongruential.js +0 -53
- package/dist/node_modules/.pnpm/pure-rand@6.1.0/node_modules/pure-rand/lib/esm/generator/MersenneTwister.js +0 -114
- package/dist/node_modules/.pnpm/pure-rand@6.1.0/node_modules/pure-rand/lib/esm/generator/RandomGenerator.js +0 -26
- package/dist/node_modules/.pnpm/pure-rand@6.1.0/node_modules/pure-rand/lib/esm/generator/XorShift.js +0 -83
- package/dist/node_modules/.pnpm/pure-rand@6.1.0/node_modules/pure-rand/lib/esm/generator/XoroShiro.js +0 -83
- package/dist/node_modules/.pnpm/pure-rand@6.1.0/node_modules/pure-rand/lib/esm/pure-rand-default.js +0 -44
- package/dist/node_modules/.pnpm/pure-rand@6.1.0/node_modules/pure-rand/lib/esm/pure-rand.js +0 -22
- package/dist/node_modules/.pnpm/regexparam@3.0.0/node_modules/regexparam/dist/index.js +0 -37
- package/dist/nodeinfo/client.d.ts +0 -96
- package/dist/nodeinfo/handler.js +0 -46
- package/dist/nodeinfo/semver.d.ts +0 -78
- package/dist/nodeinfo/types.d.ts +0 -140
- package/dist/runtime/authdocloader.d.ts +0 -56
- package/dist/runtime/docloader.js +0 -291
- package/dist/runtime/key.js +0 -156
- package/dist/runtime/langstr.d.ts +0 -24
- package/dist/runtime/multibase/base.js +0 -32
- package/dist/runtime/multibase/constants.js +0 -172
- package/dist/runtime/multibase/index.js +0 -57
- package/dist/runtime/multibase/rfc4648.js +0 -61
- package/dist/runtime/multibase/util.js +0 -21
- package/dist/sig/http.d.ts +0 -143
- package/dist/sig/key.d.ts +0 -125
- package/dist/sig/proof.d.ts +0 -134
- package/dist/testing/fixtures/example.com/person.js +0 -29
- package/dist/testing/fixtures/example.com/person2.js +0 -48
- package/dist/vocab/constants.d.ts +0 -24
- package/dist/vocab/constants.js +0 -17
- package/dist/vocab/type.d.ts +0 -107
- package/dist/webfinger/handler.js +0 -140
- package/dist/webfinger/lookup.d.ts +0 -47
- /package/dist/{node_modules/.pnpm/@jsr_std__assert@0.226.0/node_modules/@jsr/std__assert/assert_object_match.js → compat-Bb5myD13.js} +0 -0
- /package/dist/{testing/fixtures → fixtures}/activitypub.academy/users/brauca_darradiul.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/example.com/announce.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/example.com/collection.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/example.com/create.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/example.com/cross-origin-actor.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/example.com/hong-gildong.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/example.com/invite.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/example.com/key.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/example.com/key2.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/example.com/object.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/example.com/orderedcollectionpage.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/example.com/paged/a.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/example.com/paged/b.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/example.com/paged-collection.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/example.com/person.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/example.com/person2.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/example.com/test.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/example.com/users/handle.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/example.com/wrong-type.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/remote.domain/users/bob.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/server.example/users/alice.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/w3id.org/identity/v1.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/w3id.org/security/data-integrity/v1.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/w3id.org/security/multikey/v1.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/w3id.org/security/v1.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/wizard.casa/users/hongminhee.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/www.w3.org/ns/activitystreams.json +0 -0
- /package/dist/{testing/fixtures → fixtures}/www.w3.org/ns/did/v1.json +0 -0
- /package/dist/{federation/kv.d.ts → kv-BmsWxOQ2.d.ts} +0 -0
- /package/dist/{federation/mq.d.ts → mq-Bue016Tz.d.ts} +0 -0
- /package/dist/{node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/basename.js → nodeinfo-CyEbLjHs.js} +0 -0
- /package/dist/{node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/common.js → runtime-BSkOVUWM.js} +0 -0
- /package/dist/{node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/constants.js → sig-BXJO--F9.js} +0 -0
- /package/dist/{codegen → vocab}/schema.yaml +0 -0
- /package/dist/{node_modules/.pnpm/@jsr_std__path@1.0.9/node_modules/@jsr/std__path/dirname.js → webfinger-C3GIyXIg.js} +0 -0
@@ -1,44 +0,0 @@
|
|
1
|
-
import { Temporal } from "@js-temporal/polyfill";
|
2
|
-
import { URLPattern } from "urlpattern-polyfill";
|
3
|
-
import { DocumentLoader } from "../runtime/docloader.js";
|
4
|
-
import { Object$1 } from "../vocab/vocab.js";
|
5
|
-
import { TracerProvider } from "@opentelemetry/api";
|
6
|
-
|
7
|
-
//#region federation/handler.d.ts
|
8
|
-
/**
|
9
|
-
* Options for the {@link respondWithObject} and
|
10
|
-
* {@link respondWithObjectIfAcceptable} functions.
|
11
|
-
* @since 0.3.0
|
12
|
-
*/
|
13
|
-
|
14
|
-
/**
|
15
|
-
* Options for the {@link respondWithObject} and
|
16
|
-
* {@link respondWithObjectIfAcceptable} functions.
|
17
|
-
* @since 0.3.0
|
18
|
-
*/
|
19
|
-
interface RespondWithObjectOptions {
|
20
|
-
/**
|
21
|
-
* The document loader to use for compacting JSON-LD.
|
22
|
-
* @since 0.8.0
|
23
|
-
*/
|
24
|
-
contextLoader: DocumentLoader;
|
25
|
-
}
|
26
|
-
/**
|
27
|
-
* Responds with the given object in JSON-LD format.
|
28
|
-
*
|
29
|
-
* @param object The object to respond with.
|
30
|
-
* @param options Options.
|
31
|
-
* @since 0.3.0
|
32
|
-
*/
|
33
|
-
declare function respondWithObject(object: Object$1, options?: RespondWithObjectOptions): Promise<Response>;
|
34
|
-
/**
|
35
|
-
* Responds with the given object in JSON-LD format if the request accepts
|
36
|
-
* JSON-LD.
|
37
|
-
*
|
38
|
-
* @param object The object to respond with.
|
39
|
-
* @param request The request to check for JSON-LD acceptability.
|
40
|
-
* @param options Options.
|
41
|
-
* @since 0.3.0
|
42
|
-
*/
|
43
|
-
declare function respondWithObjectIfAcceptable(object: Object$1, request: Request, options?: RespondWithObjectOptions): Promise<Response | null>; //#endregion
|
44
|
-
export { RespondWithObjectOptions, respondWithObject as respondWithObject$1, respondWithObjectIfAcceptable as respondWithObjectIfAcceptable$1 };
|
@@ -1,543 +0,0 @@
|
|
1
|
-
|
2
|
-
import { Temporal } from "@js-temporal/polyfill";
|
3
|
-
import { URLPattern } from "urlpattern-polyfill";
|
4
|
-
|
5
|
-
import { deno_default } from "../deno.js";
|
6
|
-
import { getTypeId } from "../vocab/type.js";
|
7
|
-
import { Activity, Link, Object as Object$1, OrderedCollection, OrderedCollectionPage } from "../vocab/vocab.js";
|
8
|
-
import { routeActivity } from "./inbox.js";
|
9
|
-
import { verifyRequest } from "../sig/http.js";
|
10
|
-
import { detachSignature, verifyJsonLd } from "../sig/ld.js";
|
11
|
-
import { doesActorOwnKey } from "../sig/owner.js";
|
12
|
-
import { verifyObject } from "../sig/proof.js";
|
13
|
-
import { KvKeyCache } from "./keycache.js";
|
14
|
-
import { preferredMediaTypes } from "./negotiation.js";
|
15
|
-
import { getLogger } from "@logtape/logtape";
|
16
|
-
import { SpanKind, SpanStatusCode, trace } from "@opentelemetry/api";
|
17
|
-
|
18
|
-
//#region federation/handler.ts
|
19
|
-
function acceptsJsonLd(request) {
|
20
|
-
const accept = request.headers.get("Accept");
|
21
|
-
const types = accept ? preferredMediaTypes(accept) : ["*/*"];
|
22
|
-
if (types == null) return true;
|
23
|
-
if (types[0] === "text/html" || types[0] === "application/xhtml+xml") return false;
|
24
|
-
return types.includes("application/activity+json") || types.includes("application/ld+json") || types.includes("application/json");
|
25
|
-
}
|
26
|
-
async function handleActor(request, { identifier, context: context$1, actorDispatcher, authorizePredicate, onNotFound, onNotAcceptable, onUnauthorized }) {
|
27
|
-
const logger = getLogger([
|
28
|
-
"fedify",
|
29
|
-
"federation",
|
30
|
-
"actor"
|
31
|
-
]);
|
32
|
-
if (actorDispatcher == null) {
|
33
|
-
logger.debug("Actor dispatcher is not set.", { identifier });
|
34
|
-
return await onNotFound(request);
|
35
|
-
}
|
36
|
-
const actor = await actorDispatcher(context$1, identifier);
|
37
|
-
if (actor == null) {
|
38
|
-
logger.debug("Actor {identifier} not found.", { identifier });
|
39
|
-
return await onNotFound(request);
|
40
|
-
}
|
41
|
-
if (!acceptsJsonLd(request)) return await onNotAcceptable(request);
|
42
|
-
if (authorizePredicate != null) {
|
43
|
-
let key = await context$1.getSignedKey();
|
44
|
-
key = key?.clone({}, { $warning: {
|
45
|
-
category: [
|
46
|
-
"fedify",
|
47
|
-
"federation",
|
48
|
-
"actor"
|
49
|
-
],
|
50
|
-
message: "The third parameter of AuthorizePredicate is deprecated in favor of RequestContext.getSignedKey() method. The third parameter will be removed in a future release."
|
51
|
-
} }) ?? null;
|
52
|
-
let keyOwner = await context$1.getSignedKeyOwner();
|
53
|
-
keyOwner = keyOwner?.clone({}, { $warning: {
|
54
|
-
category: [
|
55
|
-
"fedify",
|
56
|
-
"federation",
|
57
|
-
"actor"
|
58
|
-
],
|
59
|
-
message: "The fourth parameter of AuthorizePredicate is deprecated in favor of RequestContext.getSignedKeyOwner() method. The fourth parameter will be removed in a future release."
|
60
|
-
} }) ?? null;
|
61
|
-
if (!await authorizePredicate(context$1, identifier, key, keyOwner)) return await onUnauthorized(request);
|
62
|
-
}
|
63
|
-
const jsonLd = await actor.toJsonLd(context$1);
|
64
|
-
return new Response(JSON.stringify(jsonLd), { headers: {
|
65
|
-
"Content-Type": "application/activity+json",
|
66
|
-
Vary: "Accept"
|
67
|
-
} });
|
68
|
-
}
|
69
|
-
async function handleObject(request, { values, context: context$1, objectDispatcher, authorizePredicate, onNotFound, onNotAcceptable, onUnauthorized }) {
|
70
|
-
if (objectDispatcher == null) return await onNotFound(request);
|
71
|
-
const object = await objectDispatcher(context$1, values);
|
72
|
-
if (object == null) return await onNotFound(request);
|
73
|
-
if (!acceptsJsonLd(request)) return await onNotAcceptable(request);
|
74
|
-
if (authorizePredicate != null) {
|
75
|
-
let key = await context$1.getSignedKey();
|
76
|
-
key = key?.clone({}, { $warning: {
|
77
|
-
category: [
|
78
|
-
"fedify",
|
79
|
-
"federation",
|
80
|
-
"object"
|
81
|
-
],
|
82
|
-
message: "The third parameter of ObjectAuthorizePredicate is deprecated in favor of RequestContext.getSignedKey() method. The third parameter will be removed in a future release."
|
83
|
-
} }) ?? null;
|
84
|
-
let keyOwner = await context$1.getSignedKeyOwner();
|
85
|
-
keyOwner = keyOwner?.clone({}, { $warning: {
|
86
|
-
category: [
|
87
|
-
"fedify",
|
88
|
-
"federation",
|
89
|
-
"object"
|
90
|
-
],
|
91
|
-
message: "The fourth parameter of ObjectAuthorizePredicate is deprecated in favor of RequestContext.getSignedKeyOwner() method. The fourth parameter will be removed in a future release."
|
92
|
-
} }) ?? null;
|
93
|
-
if (!await authorizePredicate(context$1, values, key, keyOwner)) return await onUnauthorized(request);
|
94
|
-
}
|
95
|
-
const jsonLd = await object.toJsonLd(context$1);
|
96
|
-
return new Response(JSON.stringify(jsonLd), { headers: {
|
97
|
-
"Content-Type": "application/activity+json",
|
98
|
-
Vary: "Accept"
|
99
|
-
} });
|
100
|
-
}
|
101
|
-
async function handleCollection(request, { name, identifier, uriGetter, filter, filterPredicate, context: context$1, collectionCallbacks, tracerProvider, onUnauthorized, onNotFound, onNotAcceptable }) {
|
102
|
-
const spanName = name.trim().replace(/\s+/g, "_");
|
103
|
-
tracerProvider = tracerProvider ?? trace.getTracerProvider();
|
104
|
-
const tracer = tracerProvider.getTracer(deno_default.name, deno_default.version);
|
105
|
-
const url = new URL(request.url);
|
106
|
-
const cursor = url.searchParams.get("cursor");
|
107
|
-
if (collectionCallbacks == null) return await onNotFound(request);
|
108
|
-
let collection;
|
109
|
-
const baseUri = uriGetter(identifier);
|
110
|
-
if (cursor == null) {
|
111
|
-
const firstCursor = await collectionCallbacks.firstCursor?.(context$1, identifier);
|
112
|
-
const totalItems = filter == null ? await collectionCallbacks.counter?.(context$1, identifier) : void 0;
|
113
|
-
if (firstCursor == null) {
|
114
|
-
const itemsOrResponse = await tracer.startActiveSpan(`activitypub.dispatch_collection ${spanName}`, {
|
115
|
-
kind: SpanKind.SERVER,
|
116
|
-
attributes: {
|
117
|
-
"activitypub.collection.id": baseUri.href,
|
118
|
-
"activitypub.collection.type": OrderedCollection.typeId.href
|
119
|
-
}
|
120
|
-
}, async (span) => {
|
121
|
-
if (totalItems != null) span.setAttribute("activitypub.collection.total_items", Number(totalItems));
|
122
|
-
try {
|
123
|
-
const page = await collectionCallbacks.dispatcher(context$1, identifier, null, filter);
|
124
|
-
if (page == null) {
|
125
|
-
span.setStatus({ code: SpanStatusCode.ERROR });
|
126
|
-
return await onNotFound(request);
|
127
|
-
}
|
128
|
-
const { items } = page;
|
129
|
-
span.setAttribute("fedify.collection.items", items.length);
|
130
|
-
return items;
|
131
|
-
} catch (e) {
|
132
|
-
span.setStatus({
|
133
|
-
code: SpanStatusCode.ERROR,
|
134
|
-
message: String(e)
|
135
|
-
});
|
136
|
-
throw e;
|
137
|
-
} finally {
|
138
|
-
span.end();
|
139
|
-
}
|
140
|
-
});
|
141
|
-
if (itemsOrResponse instanceof Response) return itemsOrResponse;
|
142
|
-
collection = new OrderedCollection({
|
143
|
-
id: baseUri,
|
144
|
-
totalItems: totalItems == null ? null : Number(totalItems),
|
145
|
-
items: filterCollectionItems(itemsOrResponse, name, filterPredicate)
|
146
|
-
});
|
147
|
-
} else {
|
148
|
-
const lastCursor = await collectionCallbacks.lastCursor?.(context$1, identifier);
|
149
|
-
const first = new URL(context$1.url);
|
150
|
-
first.searchParams.set("cursor", firstCursor);
|
151
|
-
let last = null;
|
152
|
-
if (lastCursor != null) {
|
153
|
-
last = new URL(context$1.url);
|
154
|
-
last.searchParams.set("cursor", lastCursor);
|
155
|
-
}
|
156
|
-
collection = new OrderedCollection({
|
157
|
-
id: baseUri,
|
158
|
-
totalItems: totalItems == null ? null : Number(totalItems),
|
159
|
-
first,
|
160
|
-
last
|
161
|
-
});
|
162
|
-
}
|
163
|
-
} else {
|
164
|
-
const uri = new URL(baseUri);
|
165
|
-
uri.searchParams.set("cursor", cursor);
|
166
|
-
const pageOrResponse = await tracer.startActiveSpan(`activitypub.dispatch_collection_page ${name}`, {
|
167
|
-
kind: SpanKind.SERVER,
|
168
|
-
attributes: {
|
169
|
-
"activitypub.collection.id": uri.href,
|
170
|
-
"activitypub.collection.type": OrderedCollectionPage.typeId.href,
|
171
|
-
"fedify.collection.cursor": cursor
|
172
|
-
}
|
173
|
-
}, async (span) => {
|
174
|
-
try {
|
175
|
-
const page = await collectionCallbacks.dispatcher(context$1, identifier, cursor, filter);
|
176
|
-
if (page == null) {
|
177
|
-
span.setStatus({ code: SpanStatusCode.ERROR });
|
178
|
-
return await onNotFound(request);
|
179
|
-
}
|
180
|
-
span.setAttribute("fedify.collection.items", page.items.length);
|
181
|
-
return page;
|
182
|
-
} catch (e) {
|
183
|
-
span.setStatus({
|
184
|
-
code: SpanStatusCode.ERROR,
|
185
|
-
message: String(e)
|
186
|
-
});
|
187
|
-
throw e;
|
188
|
-
} finally {
|
189
|
-
span.end();
|
190
|
-
}
|
191
|
-
});
|
192
|
-
if (pageOrResponse instanceof Response) return pageOrResponse;
|
193
|
-
const { items, prevCursor, nextCursor } = pageOrResponse;
|
194
|
-
let prev = null;
|
195
|
-
if (prevCursor != null) {
|
196
|
-
prev = new URL(context$1.url);
|
197
|
-
prev.searchParams.set("cursor", prevCursor);
|
198
|
-
}
|
199
|
-
let next = null;
|
200
|
-
if (nextCursor != null) {
|
201
|
-
next = new URL(context$1.url);
|
202
|
-
next.searchParams.set("cursor", nextCursor);
|
203
|
-
}
|
204
|
-
const partOf = new URL(context$1.url);
|
205
|
-
partOf.searchParams.delete("cursor");
|
206
|
-
collection = new OrderedCollectionPage({
|
207
|
-
id: uri,
|
208
|
-
prev,
|
209
|
-
next,
|
210
|
-
items: filterCollectionItems(items, name, filterPredicate),
|
211
|
-
partOf
|
212
|
-
});
|
213
|
-
}
|
214
|
-
if (!acceptsJsonLd(request)) return await onNotAcceptable(request);
|
215
|
-
if (collectionCallbacks.authorizePredicate != null) {
|
216
|
-
let key = await context$1.getSignedKey();
|
217
|
-
key = key?.clone({}, { $warning: {
|
218
|
-
category: [
|
219
|
-
"fedify",
|
220
|
-
"federation",
|
221
|
-
"collection"
|
222
|
-
],
|
223
|
-
message: "The third parameter of AuthorizePredicate is deprecated in favor of RequestContext.getSignedKey() method. The third parameter will be removed in a future release."
|
224
|
-
} }) ?? null;
|
225
|
-
let keyOwner = await context$1.getSignedKeyOwner();
|
226
|
-
keyOwner = keyOwner?.clone({}, { $warning: {
|
227
|
-
category: [
|
228
|
-
"fedify",
|
229
|
-
"federation",
|
230
|
-
"collection"
|
231
|
-
],
|
232
|
-
message: "The fourth parameter of AuthorizePredicate is deprecated in favor of RequestContext.getSignedKeyOwner() method. The fourth parameter will be removed in a future release."
|
233
|
-
} }) ?? null;
|
234
|
-
if (!await collectionCallbacks.authorizePredicate(context$1, identifier, key, keyOwner)) return await onUnauthorized(request);
|
235
|
-
}
|
236
|
-
const jsonLd = await collection.toJsonLd(context$1);
|
237
|
-
return new Response(JSON.stringify(jsonLd), { headers: {
|
238
|
-
"Content-Type": "application/activity+json",
|
239
|
-
Vary: "Accept"
|
240
|
-
} });
|
241
|
-
}
|
242
|
-
function filterCollectionItems(items, collectionName, filterPredicate) {
|
243
|
-
const result = [];
|
244
|
-
let logged = false;
|
245
|
-
for (const item of items) {
|
246
|
-
let mappedItem;
|
247
|
-
if (item instanceof Object$1 || item instanceof Link || item instanceof URL) mappedItem = item;
|
248
|
-
else if (item.id == null) continue;
|
249
|
-
else mappedItem = item.id;
|
250
|
-
if (filterPredicate != null && !filterPredicate(item)) {
|
251
|
-
if (!logged) {
|
252
|
-
getLogger([
|
253
|
-
"fedify",
|
254
|
-
"federation",
|
255
|
-
"collection"
|
256
|
-
]).warn(`The ${collectionName} collection apparently does not implement filtering. This may result in a large response payload. Please consider implementing filtering for the collection. See also: https://fedify.dev/manual/collections#filtering-by-server`);
|
257
|
-
logged = true;
|
258
|
-
}
|
259
|
-
continue;
|
260
|
-
}
|
261
|
-
result.push(mappedItem);
|
262
|
-
}
|
263
|
-
return result;
|
264
|
-
}
|
265
|
-
async function handleInbox(request, options) {
|
266
|
-
const tracerProvider = options.tracerProvider ?? trace.getTracerProvider();
|
267
|
-
const tracer = tracerProvider.getTracer(deno_default.name, deno_default.version);
|
268
|
-
return await tracer.startActiveSpan("activitypub.inbox", {
|
269
|
-
kind: options.queue == null ? SpanKind.SERVER : SpanKind.PRODUCER,
|
270
|
-
attributes: { "activitypub.shared_inbox": options.recipient == null }
|
271
|
-
}, async (span) => {
|
272
|
-
if (options.recipient != null) span.setAttribute("fedify.inbox.recipient", options.recipient);
|
273
|
-
try {
|
274
|
-
return await handleInboxInternal(request, options, span);
|
275
|
-
} catch (e) {
|
276
|
-
span.setStatus({
|
277
|
-
code: SpanStatusCode.ERROR,
|
278
|
-
message: String(e)
|
279
|
-
});
|
280
|
-
throw e;
|
281
|
-
} finally {
|
282
|
-
span.end();
|
283
|
-
}
|
284
|
-
});
|
285
|
-
}
|
286
|
-
async function handleInboxInternal(request, { recipient, context: ctx, inboxContextFactory, kv, kvPrefixes, queue, actorDispatcher, inboxListeners, inboxErrorHandler, onNotFound, signatureTimeWindow, skipSignatureVerification, tracerProvider }, span) {
|
287
|
-
const logger = getLogger([
|
288
|
-
"fedify",
|
289
|
-
"federation",
|
290
|
-
"inbox"
|
291
|
-
]);
|
292
|
-
if (actorDispatcher == null) {
|
293
|
-
logger.error("Actor dispatcher is not set.", { recipient });
|
294
|
-
span.setStatus({
|
295
|
-
code: SpanStatusCode.ERROR,
|
296
|
-
message: "Actor dispatcher is not set."
|
297
|
-
});
|
298
|
-
return await onNotFound(request);
|
299
|
-
} else if (recipient != null) {
|
300
|
-
const actor = await actorDispatcher(ctx, recipient);
|
301
|
-
if (actor == null) {
|
302
|
-
logger.error("Actor {recipient} not found.", { recipient });
|
303
|
-
span.setStatus({
|
304
|
-
code: SpanStatusCode.ERROR,
|
305
|
-
message: `Actor ${recipient} not found.`
|
306
|
-
});
|
307
|
-
return await onNotFound(request);
|
308
|
-
}
|
309
|
-
}
|
310
|
-
if (request.bodyUsed) {
|
311
|
-
logger.error("Request body has already been read.", { recipient });
|
312
|
-
span.setStatus({
|
313
|
-
code: SpanStatusCode.ERROR,
|
314
|
-
message: "Request body has already been read."
|
315
|
-
});
|
316
|
-
return new Response("Internal server error.", {
|
317
|
-
status: 500,
|
318
|
-
headers: { "Content-Type": "text/plain; charset=utf-8" }
|
319
|
-
});
|
320
|
-
} else if (request.body?.locked) {
|
321
|
-
logger.error("Request body is locked.", { recipient });
|
322
|
-
span.setStatus({
|
323
|
-
code: SpanStatusCode.ERROR,
|
324
|
-
message: "Request body is locked."
|
325
|
-
});
|
326
|
-
return new Response("Internal server error.", {
|
327
|
-
status: 500,
|
328
|
-
headers: { "Content-Type": "text/plain; charset=utf-8" }
|
329
|
-
});
|
330
|
-
}
|
331
|
-
let json;
|
332
|
-
try {
|
333
|
-
json = await request.clone().json();
|
334
|
-
} catch (error) {
|
335
|
-
logger.error("Failed to parse JSON:\n{error}", {
|
336
|
-
recipient,
|
337
|
-
error
|
338
|
-
});
|
339
|
-
try {
|
340
|
-
await inboxErrorHandler?.(ctx, error);
|
341
|
-
} catch (error$1) {
|
342
|
-
logger.error("An unexpected error occurred in inbox error handler:\n{error}", {
|
343
|
-
error: error$1,
|
344
|
-
activity: json,
|
345
|
-
recipient
|
346
|
-
});
|
347
|
-
}
|
348
|
-
span.setStatus({
|
349
|
-
code: SpanStatusCode.ERROR,
|
350
|
-
message: `Failed to parse JSON:\n${error}`
|
351
|
-
});
|
352
|
-
return new Response("Invalid JSON.", {
|
353
|
-
status: 400,
|
354
|
-
headers: { "Content-Type": "text/plain; charset=utf-8" }
|
355
|
-
});
|
356
|
-
}
|
357
|
-
const keyCache = new KvKeyCache(kv, kvPrefixes.publicKey, ctx);
|
358
|
-
let ldSigVerified;
|
359
|
-
try {
|
360
|
-
ldSigVerified = await verifyJsonLd(json, {
|
361
|
-
contextLoader: ctx.contextLoader,
|
362
|
-
documentLoader: ctx.documentLoader,
|
363
|
-
keyCache,
|
364
|
-
tracerProvider
|
365
|
-
});
|
366
|
-
} catch (error) {
|
367
|
-
if (error instanceof Error && error.name === "jsonld.SyntaxError") {
|
368
|
-
logger.error("Failed to parse JSON-LD:\n{error}", {
|
369
|
-
recipient,
|
370
|
-
error
|
371
|
-
});
|
372
|
-
return new Response("Invalid JSON-LD.", {
|
373
|
-
status: 400,
|
374
|
-
headers: { "Content-Type": "text/plain; charset=utf-8" }
|
375
|
-
});
|
376
|
-
}
|
377
|
-
ldSigVerified = false;
|
378
|
-
}
|
379
|
-
const jsonWithoutSig = detachSignature(json);
|
380
|
-
let activity = null;
|
381
|
-
if (ldSigVerified) {
|
382
|
-
logger.debug("Linked Data Signatures are verified.", {
|
383
|
-
recipient,
|
384
|
-
json
|
385
|
-
});
|
386
|
-
activity = await Activity.fromJsonLd(jsonWithoutSig, ctx);
|
387
|
-
} else {
|
388
|
-
logger.debug("Linked Data Signatures are not verified.", {
|
389
|
-
recipient,
|
390
|
-
json
|
391
|
-
});
|
392
|
-
try {
|
393
|
-
activity = await verifyObject(Activity, jsonWithoutSig, {
|
394
|
-
contextLoader: ctx.contextLoader,
|
395
|
-
documentLoader: ctx.documentLoader,
|
396
|
-
keyCache,
|
397
|
-
tracerProvider
|
398
|
-
});
|
399
|
-
} catch (error) {
|
400
|
-
logger.error("Failed to parse activity:\n{error}", {
|
401
|
-
recipient,
|
402
|
-
activity: json,
|
403
|
-
error
|
404
|
-
});
|
405
|
-
try {
|
406
|
-
await inboxErrorHandler?.(ctx, error);
|
407
|
-
} catch (error$1) {
|
408
|
-
logger.error("An unexpected error occurred in inbox error handler:\n{error}", {
|
409
|
-
error: error$1,
|
410
|
-
activity: json,
|
411
|
-
recipient
|
412
|
-
});
|
413
|
-
}
|
414
|
-
span.setStatus({
|
415
|
-
code: SpanStatusCode.ERROR,
|
416
|
-
message: `Failed to parse activity:\n${error}`
|
417
|
-
});
|
418
|
-
return new Response("Invalid activity.", {
|
419
|
-
status: 400,
|
420
|
-
headers: { "Content-Type": "text/plain; charset=utf-8" }
|
421
|
-
});
|
422
|
-
}
|
423
|
-
if (activity == null) logger.debug("Object Integrity Proofs are not verified.", {
|
424
|
-
recipient,
|
425
|
-
activity: json
|
426
|
-
});
|
427
|
-
else logger.debug("Object Integrity Proofs are verified.", {
|
428
|
-
recipient,
|
429
|
-
activity: json
|
430
|
-
});
|
431
|
-
}
|
432
|
-
let httpSigKey = null;
|
433
|
-
if (activity == null) {
|
434
|
-
if (!skipSignatureVerification) {
|
435
|
-
const key = await verifyRequest(request, {
|
436
|
-
contextLoader: ctx.contextLoader,
|
437
|
-
documentLoader: ctx.documentLoader,
|
438
|
-
timeWindow: signatureTimeWindow,
|
439
|
-
keyCache,
|
440
|
-
tracerProvider
|
441
|
-
});
|
442
|
-
if (key == null) {
|
443
|
-
logger.error("Failed to verify the request's HTTP Signatures.", { recipient });
|
444
|
-
span.setStatus({
|
445
|
-
code: SpanStatusCode.ERROR,
|
446
|
-
message: `Failed to verify the request's HTTP Signatures.`
|
447
|
-
});
|
448
|
-
const response = new Response("Failed to verify the request signature.", {
|
449
|
-
status: 401,
|
450
|
-
headers: { "Content-Type": "text/plain; charset=utf-8" }
|
451
|
-
});
|
452
|
-
return response;
|
453
|
-
} else logger.debug("HTTP Signatures are verified.", { recipient });
|
454
|
-
httpSigKey = key;
|
455
|
-
}
|
456
|
-
activity = await Activity.fromJsonLd(jsonWithoutSig, ctx);
|
457
|
-
}
|
458
|
-
if (activity.id != null) span.setAttribute("activitypub.activity.id", activity.id.href);
|
459
|
-
span.setAttribute("activitypub.activity.type", getTypeId(activity).href);
|
460
|
-
const routeResult = await routeActivity({
|
461
|
-
context: ctx,
|
462
|
-
json,
|
463
|
-
activity,
|
464
|
-
recipient,
|
465
|
-
inboxListeners,
|
466
|
-
inboxContextFactory,
|
467
|
-
inboxErrorHandler,
|
468
|
-
kv,
|
469
|
-
kvPrefixes,
|
470
|
-
queue,
|
471
|
-
span,
|
472
|
-
tracerProvider
|
473
|
-
});
|
474
|
-
if (httpSigKey != null && !await doesActorOwnKey(activity, httpSigKey, ctx)) {
|
475
|
-
logger.error("The signer ({keyId}) and the actor ({actorId}) do not match.", {
|
476
|
-
activity: json,
|
477
|
-
recipient,
|
478
|
-
keyId: httpSigKey.id?.href,
|
479
|
-
actorId: activity.actorId?.href
|
480
|
-
});
|
481
|
-
span.setStatus({
|
482
|
-
code: SpanStatusCode.ERROR,
|
483
|
-
message: `The signer (${httpSigKey.id?.href}) and the actor (${activity.actorId?.href}) do not match.`
|
484
|
-
});
|
485
|
-
return new Response("The signer and the actor do not match.", {
|
486
|
-
status: 401,
|
487
|
-
headers: { "Content-Type": "text/plain; charset=utf-8" }
|
488
|
-
});
|
489
|
-
}
|
490
|
-
if (routeResult === "alreadyProcessed") return new Response(`Activity <${activity.id}> has already been processed.`, {
|
491
|
-
status: 202,
|
492
|
-
headers: { "Content-Type": "text/plain; charset=utf-8" }
|
493
|
-
});
|
494
|
-
else if (routeResult === "missingActor") return new Response("Missing actor.", {
|
495
|
-
status: 400,
|
496
|
-
headers: { "Content-Type": "text/plain; charset=utf-8" }
|
497
|
-
});
|
498
|
-
else if (routeResult === "enqueued") return new Response("Activity is enqueued.", {
|
499
|
-
status: 202,
|
500
|
-
headers: { "Content-Type": "text/plain; charset=utf-8" }
|
501
|
-
});
|
502
|
-
else if (routeResult === "unsupportedActivity") return new Response("", {
|
503
|
-
status: 202,
|
504
|
-
headers: { "Content-Type": "text/plain; charset=utf-8" }
|
505
|
-
});
|
506
|
-
else if (routeResult === "error") return new Response("Internal server error.", {
|
507
|
-
status: 500,
|
508
|
-
headers: { "Content-Type": "text/plain; charset=utf-8" }
|
509
|
-
});
|
510
|
-
else return new Response("", {
|
511
|
-
status: 202,
|
512
|
-
headers: { "Content-Type": "text/plain; charset=utf-8" }
|
513
|
-
});
|
514
|
-
}
|
515
|
-
/**
|
516
|
-
* Responds with the given object in JSON-LD format.
|
517
|
-
*
|
518
|
-
* @param object The object to respond with.
|
519
|
-
* @param options Options.
|
520
|
-
* @since 0.3.0
|
521
|
-
*/
|
522
|
-
async function respondWithObject(object, options) {
|
523
|
-
const jsonLd = await object.toJsonLd(options);
|
524
|
-
return new Response(JSON.stringify(jsonLd), { headers: { "Content-Type": "application/activity+json" } });
|
525
|
-
}
|
526
|
-
/**
|
527
|
-
* Responds with the given object in JSON-LD format if the request accepts
|
528
|
-
* JSON-LD.
|
529
|
-
*
|
530
|
-
* @param object The object to respond with.
|
531
|
-
* @param request The request to check for JSON-LD acceptability.
|
532
|
-
* @param options Options.
|
533
|
-
* @since 0.3.0
|
534
|
-
*/
|
535
|
-
async function respondWithObjectIfAcceptable(object, request, options) {
|
536
|
-
if (!acceptsJsonLd(request)) return null;
|
537
|
-
const response = await respondWithObject(object, options);
|
538
|
-
response.headers.set("Vary", "Accept");
|
539
|
-
return response;
|
540
|
-
}
|
541
|
-
|
542
|
-
//#endregion
|
543
|
-
export { acceptsJsonLd, handleActor, handleCollection, handleInbox, handleObject, respondWithObject, respondWithObjectIfAcceptable };
|
@@ -1,101 +0,0 @@
|
|
1
|
-
import { Temporal } from "@js-temporal/polyfill";
|
2
|
-
import { URLPattern } from "urlpattern-polyfill";
|
3
|
-
import { KvKey } from "./kv.js";
|
4
|
-
import { MessageQueue } from "./mq.js";
|
5
|
-
import { Federation, FederationOptions } from "./federation.js";
|
6
|
-
import { Span, TracerProvider } from "@opentelemetry/api";
|
7
|
-
|
8
|
-
//#region federation/middleware.d.ts
|
9
|
-
/**
|
10
|
-
* Options for {@link createFederation} function.
|
11
|
-
* @typeParam TContextData The type of the context data.
|
12
|
-
* @since 0.10.0
|
13
|
-
* @deprecated Use {@link FederationOptions} instead.
|
14
|
-
*/
|
15
|
-
|
16
|
-
/**
|
17
|
-
* Options for {@link createFederation} function.
|
18
|
-
* @typeParam TContextData The type of the context data.
|
19
|
-
* @since 0.10.0
|
20
|
-
* @deprecated Use {@link FederationOptions} instead.
|
21
|
-
*/
|
22
|
-
interface CreateFederationOptions<TContextData> extends FederationOptions<TContextData> {}
|
23
|
-
/**
|
24
|
-
* Configures the task queues for sending and receiving activities.
|
25
|
-
* @since 1.3.0
|
26
|
-
*/
|
27
|
-
interface FederationQueueOptions {
|
28
|
-
/**
|
29
|
-
* The message queue for incoming activities. If not provided, incoming
|
30
|
-
* activities will not be queued and will be processed immediately.
|
31
|
-
*/
|
32
|
-
inbox?: MessageQueue;
|
33
|
-
/**
|
34
|
-
* The message queue for outgoing activities. If not provided, outgoing
|
35
|
-
* activities will not be queued and will be sent immediately.
|
36
|
-
*/
|
37
|
-
outbox?: MessageQueue;
|
38
|
-
/**
|
39
|
-
* The message queue for fanning out outgoing activities. If not provided,
|
40
|
-
* outgoing activities will not be fanned out in the background, but will be
|
41
|
-
* fanned out immediately, which causes slow response times on
|
42
|
-
* {@link Context.sendActivity} calls.
|
43
|
-
*/
|
44
|
-
fanout?: MessageQueue;
|
45
|
-
}
|
46
|
-
/**
|
47
|
-
* Prefixes for namespacing keys in the Deno KV store.
|
48
|
-
*/
|
49
|
-
interface FederationKvPrefixes {
|
50
|
-
/**
|
51
|
-
* The key prefix used for storing whether activities have already been
|
52
|
-
* processed or not.
|
53
|
-
* @default `["_fedify", "activityIdempotence"]`
|
54
|
-
*/
|
55
|
-
activityIdempotence: KvKey;
|
56
|
-
/**
|
57
|
-
* The key prefix used for storing remote JSON-LD documents.
|
58
|
-
* @default `["_fedify", "remoteDocument"]`
|
59
|
-
*/
|
60
|
-
remoteDocument: KvKey;
|
61
|
-
/**
|
62
|
-
* The key prefix used for caching public keys.
|
63
|
-
* @default `["_fedify", "publicKey"]`
|
64
|
-
* @since 0.12.0
|
65
|
-
*/
|
66
|
-
publicKey: KvKey;
|
67
|
-
/**
|
68
|
-
* The key prefix used for caching HTTP Message Signatures specs.
|
69
|
-
* The cached spec is used to reduce the number of requests to make signed
|
70
|
-
* requests ("double-knocking" technique).
|
71
|
-
* @default `["_fedify", "httpMessageSignaturesSpec"]`
|
72
|
-
* @since 1.6.0
|
73
|
-
*/
|
74
|
-
httpMessageSignaturesSpec: KvKey;
|
75
|
-
}
|
76
|
-
/**
|
77
|
-
* Options for {@link CreateFederationOptions.origin} when it is not a string.
|
78
|
-
* @since 1.5.0
|
79
|
-
*/
|
80
|
-
interface FederationOrigin {
|
81
|
-
/**
|
82
|
-
* The canonical hostname for fediverse handles (which are looked up through
|
83
|
-
* WebFinger). This is used for WebFinger lookups. It has to be a valid
|
84
|
-
* hostname, e.g., `"example.com"`.
|
85
|
-
*/
|
86
|
-
handleHost: string;
|
87
|
-
/**
|
88
|
-
* The canonical origin for web URLs. This is used for constructing absolute
|
89
|
-
* URLs. It has to start with either `"http://"` or `"https://"`, and must
|
90
|
-
* not contain a path or query string, e.g., `"https://example.com"`.
|
91
|
-
*/
|
92
|
-
webOrigin: string;
|
93
|
-
}
|
94
|
-
/**
|
95
|
-
* Create a new {@link Federation} instance.
|
96
|
-
* @param parameters Parameters for initializing the instance.
|
97
|
-
* @returns A new {@link Federation} instance.
|
98
|
-
* @since 0.10.0
|
99
|
-
*/
|
100
|
-
declare function createFederation<TContextData>(options: CreateFederationOptions<TContextData>): Federation<TContextData>; //#endregion
|
101
|
-
export { CreateFederationOptions, FederationKvPrefixes, FederationOrigin, FederationQueueOptions, createFederation as createFederation$1 };
|