emdash 1.0.1 → 1.1.0
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/action-token-AgOs1UWD.mjs +26 -0
- package/dist/action-token-AgOs1UWD.mjs.map +1 -0
- package/dist/activation-xomsCMJg.mjs +387 -0
- package/dist/activation-xomsCMJg.mjs.map +1 -0
- package/dist/adapters-DM1oyHIN.d.mts +173 -0
- package/dist/adapters-DM1oyHIN.d.mts.map +1 -0
- package/dist/allowed-origins-CFtudhyw.mjs +116 -0
- package/dist/allowed-origins-CFtudhyw.mjs.map +1 -0
- package/dist/api/route-utils.d.mts +4 -4
- package/dist/api/route-utils.mjs +48 -47
- package/dist/api/route-utils.mjs.map +1 -1
- package/dist/api/schemas/index.d.mts +2 -2
- package/dist/api/schemas/index.mjs +10 -10
- package/dist/api-CltsXhiX.mjs +4980 -0
- package/dist/api-CltsXhiX.mjs.map +1 -0
- package/dist/api-tokens-P3mAaQgr.mjs +166 -0
- package/dist/api-tokens-P3mAaQgr.mjs.map +1 -0
- package/dist/apply-Q7uvzBWW.mjs +1680 -0
- package/dist/apply-Q7uvzBWW.mjs.map +1 -0
- package/dist/approvals-DycwI6lZ.mjs +460 -0
- package/dist/approvals-DycwI6lZ.mjs.map +1 -0
- package/dist/artifact-fetch-CWxyELVI.mjs +659 -0
- package/dist/artifact-fetch-CWxyELVI.mjs.map +1 -0
- package/dist/artifacts-UzWbysb8.mjs +307 -0
- package/dist/artifacts-UzWbysb8.mjs.map +1 -0
- package/dist/astro/index.d.mts +14 -14
- package/dist/astro/index.d.mts.map +1 -1
- package/dist/astro/index.mjs +38 -12
- package/dist/astro/index.mjs.map +1 -1
- package/dist/astro/middleware/auth.d.mts +12 -12
- package/dist/astro/middleware/auth.mjs +12 -11
- package/dist/astro/middleware/auth.mjs.map +1 -1
- package/dist/astro/middleware/media-usage-write-fence.mjs +6 -6
- package/dist/astro/middleware/redirect.d.mts.map +1 -1
- package/dist/astro/middleware/redirect.mjs +9 -22
- package/dist/astro/middleware/redirect.mjs.map +1 -1
- package/dist/astro/middleware/request-context.d.mts.map +1 -1
- package/dist/astro/middleware/request-context.mjs +33 -21
- package/dist/astro/middleware/request-context.mjs.map +1 -1
- package/dist/astro/middleware/setup.mjs +1 -1
- package/dist/astro/middleware.d.mts +12 -12
- package/dist/astro/middleware.d.mts.map +1 -1
- package/dist/astro/middleware.mjs +203 -120
- package/dist/astro/middleware.mjs.map +1 -1
- package/dist/astro/routes/api/admin/allowed-domains/_domain_.mjs +15 -15
- package/dist/astro/routes/api/admin/allowed-domains/index.mjs +15 -15
- package/dist/astro/routes/api/admin/api-tokens/_id_.mjs +7 -7
- package/dist/astro/routes/api/admin/api-tokens/index.mjs +8 -8
- package/dist/astro/routes/api/admin/byline-fields/_slug_/usage.mjs +7 -7
- package/dist/astro/routes/api/admin/byline-fields/_slug_.mjs +17 -17
- package/dist/astro/routes/api/admin/byline-fields/index.mjs +17 -17
- package/dist/astro/routes/api/admin/byline-fields/reorder.mjs +17 -17
- package/dist/astro/routes/api/admin/bylines/_id_/index.mjs +22 -22
- package/dist/astro/routes/api/admin/bylines/_id_/translations.mjs +22 -23
- package/dist/astro/routes/api/admin/bylines/_id_/translations.mjs.map +1 -1
- package/dist/astro/routes/api/admin/bylines/index.mjs +23 -23
- package/dist/astro/routes/api/admin/bylines/index.mjs.map +1 -1
- package/dist/astro/routes/api/admin/comments/_id_/status.mjs +19 -19
- package/dist/astro/routes/api/admin/comments/_id_.mjs +8 -8
- package/dist/astro/routes/api/admin/comments/bulk.mjs +18 -18
- package/dist/astro/routes/api/admin/comments/counts.mjs +8 -8
- package/dist/astro/routes/api/admin/comments/index.mjs +18 -18
- package/dist/astro/routes/api/admin/core-update.mjs +8 -8
- package/dist/astro/routes/api/admin/hooks/exclusive/_hookName_.mjs +7 -7
- package/dist/astro/routes/api/admin/hooks/exclusive/index.mjs +6 -6
- package/dist/astro/routes/api/admin/media-usage/activation.mjs +21 -21
- package/dist/astro/routes/api/admin/media-usage/collection-deletions/index.mjs +22 -22
- package/dist/astro/routes/api/admin/media-usage/collection-deletions/retry.mjs +22 -22
- package/dist/astro/routes/api/admin/media-usage/progress.mjs +23 -23
- package/dist/astro/routes/api/admin/media-usage/repair.mjs +29 -29
- package/dist/astro/routes/api/admin/media-usage/work/index.mjs +22 -22
- package/dist/astro/routes/api/admin/media-usage/work/retry.mjs +22 -22
- package/dist/astro/routes/api/admin/oauth-clients/_id_.mjs +7 -7
- package/dist/astro/routes/api/admin/oauth-clients/index.mjs +7 -7
- package/dist/astro/routes/api/admin/plugins/_id_/disable.mjs +9 -9
- package/dist/astro/routes/api/admin/plugins/_id_/enable.mjs +9 -9
- package/dist/astro/routes/api/admin/plugins/_id_/index.mjs +72 -71
- package/dist/astro/routes/api/admin/plugins/_id_/index.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/_id_/mcp.mjs +8 -8
- package/dist/astro/routes/api/admin/plugins/_id_/settings.mjs +70 -69
- package/dist/astro/routes/api/admin/plugins/_id_/settings.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/_id_/uninstall.mjs +71 -70
- package/dist/astro/routes/api/admin/plugins/_id_/uninstall.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/_id_/update.mjs +81 -80
- package/dist/astro/routes/api/admin/plugins/_id_/update.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/index.mjs +71 -70
- package/dist/astro/routes/api/admin/plugins/index.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/marketplace/_id_/icon.mjs +8 -8
- package/dist/astro/routes/api/admin/plugins/marketplace/_id_/index.mjs +70 -69
- package/dist/astro/routes/api/admin/plugins/marketplace/_id_/index.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/marketplace/_id_/install.mjs +80 -79
- package/dist/astro/routes/api/admin/plugins/marketplace/_id_/install.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/marketplace/index.mjs +70 -69
- package/dist/astro/routes/api/admin/plugins/marketplace/index.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/registry/_id_/uninstall.mjs +71 -70
- package/dist/astro/routes/api/admin/plugins/registry/_id_/uninstall.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/registry/_id_/update.mjs +82 -81
- package/dist/astro/routes/api/admin/plugins/registry/_id_/update.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/registry/artifact.mjs +10 -10
- package/dist/astro/routes/api/admin/plugins/registry/install.mjs +73 -72
- package/dist/astro/routes/api/admin/plugins/registry/install.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/registry/publisher-handle.mjs +8 -8
- package/dist/astro/routes/api/admin/plugins/registry/verify.mjs +71 -70
- package/dist/astro/routes/api/admin/plugins/registry/verify.mjs.map +1 -1
- package/dist/astro/routes/api/admin/plugins/updates.mjs +70 -69
- package/dist/astro/routes/api/admin/plugins/updates.mjs.map +1 -1
- package/dist/astro/routes/api/admin/scheduled-policy-rejections/_collection_/_id_.mjs +6 -6
- package/dist/astro/routes/api/admin/themes/marketplace/_id_/index.mjs +70 -69
- package/dist/astro/routes/api/admin/themes/marketplace/_id_/index.mjs.map +1 -1
- package/dist/astro/routes/api/admin/themes/marketplace/_id_/thumbnail.mjs +8 -8
- package/dist/astro/routes/api/admin/themes/marketplace/index.mjs +70 -69
- package/dist/astro/routes/api/admin/themes/marketplace/index.mjs.map +1 -1
- package/dist/astro/routes/api/admin/transfer/_...path_.mjs +5 -5
- package/dist/astro/routes/api/admin/transfer/approvals/_id_/approve.mjs +39 -39
- package/dist/astro/routes/api/admin/transfer/approvals/_id_/deny.mjs +39 -39
- package/dist/astro/routes/api/admin/transfer/approvals/index.mjs +41 -41
- package/dist/astro/routes/api/admin/transfer/capabilities.mjs +41 -41
- package/dist/astro/routes/api/admin/transfer/exports/_id_/advance.mjs +41 -41
- package/dist/astro/routes/api/admin/transfer/exports/_id_/archive.mjs +42 -42
- package/dist/astro/routes/api/admin/transfer/exports/_id_/files/_...path_.mjs +42 -42
- package/dist/astro/routes/api/admin/transfer/exports/_id_/index.mjs +41 -41
- package/dist/astro/routes/api/admin/transfer/exports/_id_/manifest.mjs +42 -42
- package/dist/astro/routes/api/admin/transfer/exports/index.mjs +43 -43
- package/dist/astro/routes/api/admin/transfer/imports/_id_/abandon.mjs +41 -41
- package/dist/astro/routes/api/admin/transfer/imports/_id_/advance.mjs +41 -41
- package/dist/astro/routes/api/admin/transfer/imports/_id_/analyze.mjs +43 -43
- package/dist/astro/routes/api/admin/transfer/imports/_id_/cancel.mjs +41 -41
- package/dist/astro/routes/api/admin/transfer/imports/_id_/execute.mjs +43 -43
- package/dist/astro/routes/api/admin/transfer/imports/_id_/files/_...path_.mjs +41 -41
- package/dist/astro/routes/api/admin/transfer/imports/_id_/index.mjs +41 -41
- package/dist/astro/routes/api/admin/transfer/imports/_id_/missing.mjs +43 -43
- package/dist/astro/routes/api/admin/transfer/imports/_id_/plan.mjs +41 -41
- package/dist/astro/routes/api/admin/transfer/imports/_id_/receipt.mjs +41 -41
- package/dist/astro/routes/api/admin/transfer/imports/index.mjs +43 -43
- package/dist/astro/routes/api/admin/users/_id_/disable.mjs +5 -5
- package/dist/astro/routes/api/admin/users/_id_/enable.mjs +5 -5
- package/dist/astro/routes/api/admin/users/_id_/index.mjs +15 -15
- package/dist/astro/routes/api/admin/users/_id_/send-recovery.mjs +7 -7
- package/dist/astro/routes/api/admin/users/index.mjs +15 -15
- package/dist/astro/routes/api/auth/dev-bypass.mjs +7 -7
- package/dist/astro/routes/api/auth/invite/accept.mjs +5 -5
- package/dist/astro/routes/api/auth/invite/complete.mjs +20 -20
- package/dist/astro/routes/api/auth/invite/index.mjs +17 -17
- package/dist/astro/routes/api/auth/invite/register-options.mjs +18 -18
- package/dist/astro/routes/api/auth/logout.mjs +6 -6
- package/dist/astro/routes/api/auth/magic-link/send.mjs +19 -19
- package/dist/astro/routes/api/auth/magic-link/verify.mjs +16 -16
- package/dist/astro/routes/api/auth/me.mjs +16 -16
- package/dist/astro/routes/api/auth/mode.mjs +6 -6
- package/dist/astro/routes/api/auth/oauth/_provider_/callback.d.mts.map +1 -1
- package/dist/astro/routes/api/auth/oauth/_provider_/callback.mjs +36 -13
- package/dist/astro/routes/api/auth/oauth/_provider_/callback.mjs.map +1 -1
- package/dist/astro/routes/api/auth/oauth/_provider_.d.mts.map +1 -1
- package/dist/astro/routes/api/auth/oauth/_provider_.mjs +20 -5
- package/dist/astro/routes/api/auth/oauth/_provider_.mjs.map +1 -1
- package/dist/astro/routes/api/auth/passkey/_id_.mjs +15 -15
- package/dist/astro/routes/api/auth/passkey/index.mjs +5 -5
- package/dist/astro/routes/api/auth/passkey/options.mjs +20 -20
- package/dist/astro/routes/api/auth/passkey/register/options.mjs +18 -18
- package/dist/astro/routes/api/auth/passkey/register/verify.mjs +19 -19
- package/dist/astro/routes/api/auth/passkey/verify.mjs +20 -20
- package/dist/astro/routes/api/auth/signup/complete.mjs +20 -20
- package/dist/astro/routes/api/auth/signup/request.mjs +18 -18
- package/dist/astro/routes/api/auth/signup/verify.mjs +5 -5
- package/dist/astro/routes/api/calendar.d.mts +8 -0
- package/dist/astro/routes/api/calendar.d.mts.map +1 -0
- package/dist/astro/routes/api/calendar.mjs +204 -0
- package/dist/astro/routes/api/calendar.mjs.map +1 -0
- package/dist/astro/routes/api/comments/_collection_/_contentId_/index.mjs +14 -14
- package/dist/astro/routes/api/comments/_collection_/_contentId_/reactions.mjs +20 -20
- package/dist/astro/routes/api/content/_collection_/_id_/compare.mjs +6 -6
- package/dist/astro/routes/api/content/_collection_/_id_/discard-draft.mjs +17 -17
- package/dist/astro/routes/api/content/_collection_/_id_/duplicate.mjs +6 -6
- package/dist/astro/routes/api/content/_collection_/_id_/lock.mjs +17 -17
- package/dist/astro/routes/api/content/_collection_/_id_/permanent.mjs +6 -6
- package/dist/astro/routes/api/content/_collection_/_id_/plugin-extensions/_pluginId_/_kind_/_extensionId_.mjs +12 -12
- package/dist/astro/routes/api/content/_collection_/_id_/preview-url.mjs +31 -31
- package/dist/astro/routes/api/content/_collection_/_id_/publish.mjs +17 -17
- package/dist/astro/routes/api/content/_collection_/_id_/references/_relation_/children.mjs +34 -34
- package/dist/astro/routes/api/content/_collection_/_id_/references/_relation_/parents.mjs +34 -34
- package/dist/astro/routes/api/content/_collection_/_id_/restore.mjs +6 -6
- package/dist/astro/routes/api/content/_collection_/_id_/revisions.mjs +6 -6
- package/dist/astro/routes/api/content/_collection_/_id_/schedule.mjs +17 -17
- package/dist/astro/routes/api/content/_collection_/_id_/terms/_taxonomy_.mjs +24 -24
- package/dist/astro/routes/api/content/_collection_/_id_/translations.mjs +6 -6
- package/dist/astro/routes/api/content/_collection_/_id_/unpublish.mjs +17 -17
- package/dist/astro/routes/api/content/_collection_/_id_.mjs +17 -17
- package/dist/astro/routes/api/content/_collection_/authors.mjs +6 -6
- package/dist/astro/routes/api/content/_collection_/index.mjs +16 -16
- package/dist/astro/routes/api/content/_collection_/trash.mjs +16 -16
- package/dist/astro/routes/api/dashboard.mjs +11 -11
- package/dist/astro/routes/api/dev/emails.mjs +6 -6
- package/dist/astro/routes/api/health.mjs +7 -7
- package/dist/astro/routes/api/import/probe.d.mts +3 -3
- package/dist/astro/routes/api/import/probe.mjs +24 -24
- package/dist/astro/routes/api/import/wordpress/analyze.mjs +6 -6
- package/dist/astro/routes/api/import/wordpress/execute.d.mts +13 -13
- package/dist/astro/routes/api/import/wordpress/execute.mjs +23 -23
- package/dist/astro/routes/api/import/wordpress/media.d.mts +12 -12
- package/dist/astro/routes/api/import/wordpress/media.mjs +20 -20
- package/dist/astro/routes/api/import/wordpress/prepare.mjs +18 -18
- package/dist/astro/routes/api/import/wordpress/rewrite-urls.d.mts +13 -13
- package/dist/astro/routes/api/import/wordpress/rewrite-urls.mjs +27 -27
- package/dist/astro/routes/api/import/wordpress-plugin/analyze.d.mts +1 -1
- package/dist/astro/routes/api/import/wordpress-plugin/analyze.mjs +24 -24
- package/dist/astro/routes/api/import/wordpress-plugin/callback.mjs +1 -1
- package/dist/astro/routes/api/import/wordpress-plugin/execute.d.mts +13 -13
- package/dist/astro/routes/api/import/wordpress-plugin/execute.mjs +32 -32
- package/dist/astro/routes/api/manifest.mjs +7 -7
- package/dist/astro/routes/api/mcp.mjs +94 -94
- package/dist/astro/routes/api/mcp.mjs.map +1 -1
- package/dist/astro/routes/api/media/_id_/confirm.mjs +19 -19
- package/dist/astro/routes/api/media/_id_/replace.mjs +17 -17
- package/dist/astro/routes/api/media/_id_/upload.mjs +10 -10
- package/dist/astro/routes/api/media/_id_/usage.mjs +31 -31
- package/dist/astro/routes/api/media/_id_.mjs +29 -29
- package/dist/astro/routes/api/media/asset/_id_/_filename_.mjs +7 -7
- package/dist/astro/routes/api/media/file/_...key_.mjs +10 -10
- package/dist/astro/routes/api/media/folders/_id_.mjs +17 -17
- package/dist/astro/routes/api/media/folders/index.mjs +17 -17
- package/dist/astro/routes/api/media/providers/_providerId_/_itemId_.mjs +6 -6
- package/dist/astro/routes/api/media/providers/_providerId_/index.mjs +6 -6
- package/dist/astro/routes/api/media/providers/index.mjs +6 -6
- package/dist/astro/routes/api/media/upload-url.mjs +23 -23
- package/dist/astro/routes/api/media/upload-url.mjs.map +1 -1
- package/dist/astro/routes/api/media.mjs +37 -36
- package/dist/astro/routes/api/media.mjs.map +1 -1
- package/dist/astro/routes/api/menus/_name_/items/_id_.mjs +18 -18
- package/dist/astro/routes/api/menus/_name_/items.mjs +18 -18
- package/dist/astro/routes/api/menus/_name_/reorder.mjs +18 -18
- package/dist/astro/routes/api/menus/_name_/translations.mjs +18 -18
- package/dist/astro/routes/api/menus/_name_.mjs +18 -18
- package/dist/astro/routes/api/menus/index.mjs +18 -18
- package/dist/astro/routes/api/oauth/authorize.mjs +6 -6
- package/dist/astro/routes/api/oauth/device/authorize.mjs +9 -9
- package/dist/astro/routes/api/oauth/device/code.mjs +12 -12
- package/dist/astro/routes/api/oauth/device/token.mjs +11 -11
- package/dist/astro/routes/api/oauth/register.mjs +8 -8
- package/dist/astro/routes/api/oauth/token/refresh.mjs +9 -9
- package/dist/astro/routes/api/oauth/token/revoke.mjs +9 -9
- package/dist/astro/routes/api/oauth/token.mjs +9 -9
- package/dist/astro/routes/api/openapi.json.mjs +21 -21
- package/dist/astro/routes/api/plugins/_pluginId_/_...path_.mjs +12 -12
- package/dist/astro/routes/api/redirects/404s/index.mjs +20 -19
- package/dist/astro/routes/api/redirects/404s/index.mjs.map +1 -1
- package/dist/astro/routes/api/redirects/404s/summary.mjs +20 -19
- package/dist/astro/routes/api/redirects/404s/summary.mjs.map +1 -1
- package/dist/astro/routes/api/redirects/_id_.mjs +20 -19
- package/dist/astro/routes/api/redirects/_id_.mjs.map +1 -1
- package/dist/astro/routes/api/redirects/index.mjs +20 -19
- package/dist/astro/routes/api/redirects/index.mjs.map +1 -1
- package/dist/astro/routes/api/relations/_id_/index.mjs +34 -34
- package/dist/astro/routes/api/relations/index.mjs +34 -34
- package/dist/astro/routes/api/revisions/_revisionId_/index.mjs +6 -6
- package/dist/astro/routes/api/revisions/_revisionId_/restore.mjs +17 -17
- package/dist/astro/routes/api/schema/block-types/_slug_/index.mjs +70 -69
- package/dist/astro/routes/api/schema/block-types/_slug_/index.mjs.map +1 -1
- package/dist/astro/routes/api/schema/block-types/_slug_/versions/_version_/activate.mjs +70 -69
- package/dist/astro/routes/api/schema/block-types/_slug_/versions/_version_/activate.mjs.map +1 -1
- package/dist/astro/routes/api/schema/block-types/index.mjs +70 -69
- package/dist/astro/routes/api/schema/block-types/index.mjs.map +1 -1
- package/dist/astro/routes/api/schema/collections/_slug_/fields/_fieldSlug_.mjs +70 -69
- package/dist/astro/routes/api/schema/collections/_slug_/fields/_fieldSlug_.mjs.map +1 -1
- package/dist/astro/routes/api/schema/collections/_slug_/fields/index.mjs +70 -69
- package/dist/astro/routes/api/schema/collections/_slug_/fields/index.mjs.map +1 -1
- package/dist/astro/routes/api/schema/collections/_slug_/fields/reorder.mjs +70 -69
- package/dist/astro/routes/api/schema/collections/_slug_/fields/reorder.mjs.map +1 -1
- package/dist/astro/routes/api/schema/collections/_slug_/index.mjs +70 -69
- package/dist/astro/routes/api/schema/collections/_slug_/index.mjs.map +1 -1
- package/dist/astro/routes/api/schema/collections/index.mjs +70 -69
- package/dist/astro/routes/api/schema/collections/index.mjs.map +1 -1
- package/dist/astro/routes/api/schema/collections/reorder.mjs +70 -69
- package/dist/astro/routes/api/schema/collections/reorder.mjs.map +1 -1
- package/dist/astro/routes/api/schema/index.mjs +16 -16
- package/dist/astro/routes/api/schema/orphans/_slug_.mjs +70 -69
- package/dist/astro/routes/api/schema/orphans/_slug_.mjs.map +1 -1
- package/dist/astro/routes/api/schema/orphans/index.mjs +70 -69
- package/dist/astro/routes/api/schema/orphans/index.mjs.map +1 -1
- package/dist/astro/routes/api/search/enable.mjs +19 -19
- package/dist/astro/routes/api/search/index.mjs +18 -18
- package/dist/astro/routes/api/search/rebuild.mjs +19 -19
- package/dist/astro/routes/api/search/stats.mjs +9 -9
- package/dist/astro/routes/api/search/suggest.mjs +18 -18
- package/dist/astro/routes/api/sections/_slug_.mjs +18 -18
- package/dist/astro/routes/api/sections/index.mjs +18 -18
- package/dist/astro/routes/api/settings/backups/archives/_name_.mjs +8 -8
- package/dist/astro/routes/api/settings/backups/archives/index.mjs +8 -8
- package/dist/astro/routes/api/settings/backups/export.mjs +8 -8
- package/dist/astro/routes/api/settings/backups/index.mjs +9 -9
- package/dist/astro/routes/api/settings/email.mjs +7 -7
- package/dist/astro/routes/api/settings.mjs +22 -22
- package/dist/astro/routes/api/setup/admin-verify.mjs +21 -21
- package/dist/astro/routes/api/setup/admin.mjs +19 -19
- package/dist/astro/routes/api/setup/dev-bypass.mjs +42 -42
- package/dist/astro/routes/api/setup/dev-reset.mjs +5 -5
- package/dist/astro/routes/api/setup/index.mjs +54 -49
- package/dist/astro/routes/api/setup/index.mjs.map +1 -1
- package/dist/astro/routes/api/setup/status.mjs +7 -7
- package/dist/astro/routes/api/snapshot.mjs +10 -10
- package/dist/astro/routes/api/taxonomies/_name_/reorder.mjs +22 -22
- package/dist/astro/routes/api/taxonomies/_name_/terms/_slug_/translations.mjs +22 -22
- package/dist/astro/routes/api/taxonomies/_name_/terms/_slug_.mjs +22 -22
- package/dist/astro/routes/api/taxonomies/_name_/terms/index.mjs +22 -22
- package/dist/astro/routes/api/taxonomies/_name_/translations.mjs +21 -21
- package/dist/astro/routes/api/taxonomies/_name_.mjs +22 -22
- package/dist/astro/routes/api/taxonomies/bulk-tag.mjs +35 -35
- package/dist/astro/routes/api/taxonomies/index.mjs +22 -22
- package/dist/astro/routes/api/themes/preview.mjs +8 -8
- package/dist/astro/routes/api/typegen.mjs +7 -7
- package/dist/astro/routes/api/visual-editing/action-token.mjs +8 -8
- package/dist/astro/routes/api/visual-editing/content/_collection_/_id_/publish.mjs +20 -20
- package/dist/astro/routes/api/visual-editing/toolbar-labels.mjs +5 -5
- package/dist/astro/routes/api/well-known/auth.mjs +1 -1
- package/dist/astro/routes/api/well-known/oauth-authorization-server.mjs +2 -2
- package/dist/astro/routes/api/well-known/oauth-protected-resource.mjs +2 -2
- package/dist/astro/routes/api/widget-areas/_name_/reorder.mjs +17 -17
- package/dist/astro/routes/api/widget-areas/_name_/widgets/_id_.mjs +19 -19
- package/dist/astro/routes/api/widget-areas/_name_/widgets.mjs +19 -19
- package/dist/astro/routes/api/widget-areas/_name_.mjs +9 -9
- package/dist/astro/routes/api/widget-areas/index.mjs +19 -19
- package/dist/astro/routes/api/widget-components.mjs +6 -6
- package/dist/astro/routes/robots.txt.mjs +7 -7
- package/dist/astro/routes/sitemap-_collection_.xml.mjs +9 -9
- package/dist/astro/routes/sitemap.xml.mjs +8 -8
- package/dist/astro/types.d.mts +17 -17
- package/dist/audit-CCH3MA4Y.mjs +127 -0
- package/dist/audit-CCH3MA4Y.mjs.map +1 -0
- package/dist/auth/providers/github.d.mts +1 -1
- package/dist/auth/providers/google.d.mts +1 -1
- package/dist/auth/providers/microsoft.d.mts +27 -0
- package/dist/auth/providers/microsoft.d.mts.map +1 -0
- package/dist/auth/providers/microsoft.mjs +20 -0
- package/dist/auth/providers/microsoft.mjs.map +1 -0
- package/dist/authoritative-records-dSvXCfzb.mjs +5172 -0
- package/dist/authoritative-records-dSvXCfzb.mjs.map +1 -0
- package/dist/authorize-DeWfk--K.mjs +49 -0
- package/dist/authorize-DeWfk--K.mjs.map +1 -0
- package/dist/backup-CFnbdTSJ.mjs +246 -0
- package/dist/backup-CFnbdTSJ.mjs.map +1 -0
- package/dist/base64-BQBZwXCx.mjs +63 -0
- package/dist/base64-BQBZwXCx.mjs.map +1 -0
- package/dist/block-types-C0YFSfR7.mjs +132 -0
- package/dist/block-types-C0YFSfR7.mjs.map +1 -0
- package/dist/block-values-H4E0XwE8.mjs +175 -0
- package/dist/block-values-H4E0XwE8.mjs.map +1 -0
- package/dist/byline-BhVslYLz.mjs +909 -0
- package/dist/byline-BhVslYLz.mjs.map +1 -0
- package/dist/byline-fields-DHJs0Mja.mjs +280 -0
- package/dist/byline-fields-DHJs0Mja.mjs.map +1 -0
- package/dist/byline-fields-xdxE9kxZ.mjs +123 -0
- package/dist/byline-fields-xdxE9kxZ.mjs.map +1 -0
- package/dist/bylines-B_nN9liM.mjs +234 -0
- package/dist/bylines-B_nN9liM.mjs.map +1 -0
- package/dist/bylines-C71YACkL.mjs +150 -0
- package/dist/bylines-C71YACkL.mjs.map +1 -0
- package/dist/cache-aTYCL9nK.mjs +133 -0
- package/dist/cache-aTYCL9nK.mjs.map +1 -0
- package/dist/canonical-Y1dpjCnp.mjs +174 -0
- package/dist/canonical-Y1dpjCnp.mjs.map +1 -0
- package/dist/capture-triggers-C9JKoIdT.mjs +362 -0
- package/dist/capture-triggers-C9JKoIdT.mjs.map +1 -0
- package/dist/challenge-store-CxZxPqaw.mjs +51 -0
- package/dist/challenge-store-CxZxPqaw.mjs.map +1 -0
- package/dist/checksum-DtH6m5uk.mjs +162 -0
- package/dist/checksum-DtH6m5uk.mjs.map +1 -0
- package/dist/chrome-tags-BIKBMZYO.mjs +24 -0
- package/dist/chrome-tags-BIKBMZYO.mjs.map +1 -0
- package/dist/chunks-zlGB5IQP.mjs +25 -0
- package/dist/chunks-zlGB5IQP.mjs.map +1 -0
- package/dist/cli/index.mjs +47 -47
- package/dist/client/cf-access.d.mts +1 -1
- package/dist/client/index.d.mts +121 -121
- package/dist/client/index.mjs +2 -2
- package/dist/collection-slugs-cache-B2Gs9Jwx.mjs +85 -0
- package/dist/collection-slugs-cache-B2Gs9Jwx.mjs.map +1 -0
- package/dist/comment-Bu08Wvr3.mjs +313 -0
- package/dist/comment-Bu08Wvr3.mjs.map +1 -0
- package/dist/comment-reaction-B8SfT-yM.mjs +85 -0
- package/dist/comment-reaction-B8SfT-yM.mjs.map +1 -0
- package/dist/comments-BRtp992B.mjs +99 -0
- package/dist/comments-BRtp992B.mjs.map +1 -0
- package/dist/comments-DVUYqdyC.mjs +195 -0
- package/dist/comments-DVUYqdyC.mjs.map +1 -0
- package/dist/components-CQY-Sgm-.mjs +108 -0
- package/dist/components-CQY-Sgm-.mjs.map +1 -0
- package/dist/config-B-uePMLj.d.mts +39 -0
- package/dist/config-B-uePMLj.d.mts.map +1 -0
- package/dist/config-B6BDSsz2.d.mts +6712 -0
- package/dist/config-B6BDSsz2.d.mts.map +1 -0
- package/dist/config-BsJHiQxC.mjs +228 -0
- package/dist/config-BsJHiQxC.mjs.map +1 -0
- package/dist/connection-B9pIasFd.mjs +36 -0
- package/dist/connection-B9pIasFd.mjs.map +1 -0
- package/dist/content-Dji9vEiW.mjs +2063 -0
- package/dist/content-Dji9vEiW.mjs.map +1 -0
- package/dist/content-list-query-DiNwyKtd.d.mts +26 -0
- package/dist/content-list-query-DiNwyKtd.d.mts.map +1 -0
- package/dist/content-repair-B7wnbzhN.mjs +442 -0
- package/dist/content-repair-B7wnbzhN.mjs.map +1 -0
- package/dist/context-Ctcxc8Ia.mjs +2026 -0
- package/dist/context-Ctcxc8Ia.mjs.map +1 -0
- package/dist/credits-Bu7dlobo.mjs +110 -0
- package/dist/credits-Bu7dlobo.mjs.map +1 -0
- package/dist/cron-xe5XKqA-.mjs +306 -0
- package/dist/cron-xe5XKqA-.mjs.map +1 -0
- package/dist/dashboard-B5hVHOtf.mjs +151 -0
- package/dist/dashboard-B5hVHOtf.mjs.map +1 -0
- package/dist/db/index.d.mts +3 -3
- package/dist/db/index.mjs +1 -1
- package/dist/db/index.mjs.map +1 -1
- package/dist/db/libsql-migrations.d.mts +1 -1
- package/dist/db/libsql-migrations.mjs +5 -5
- package/dist/db/libsql.d.mts +1 -1
- package/dist/db/postgres-migrations.d.mts +1 -1
- package/dist/db/postgres-migrations.mjs +4 -4
- package/dist/db/postgres.d.mts +1 -1
- package/dist/db/sqlite-migrations.d.mts +1 -1
- package/dist/db/sqlite-migrations.mjs +4 -4
- package/dist/db/sqlite.d.mts +1 -1
- package/dist/db/sqlite.mjs +1 -1
- package/dist/default-DaoYyFRS.mjs +81 -0
- package/dist/default-DaoYyFRS.mjs.map +1 -0
- package/dist/deferred-tasks-BYcDx2o_.d.mts +9 -0
- package/dist/deferred-tasks-BYcDx2o_.d.mts.map +1 -0
- package/dist/dev-typegen-Dtl8AfS6.mjs +29 -0
- package/dist/dev-typegen-Dtl8AfS6.mjs.map +1 -0
- package/dist/device-flow-Ma5P5d2e.mjs +521 -0
- package/dist/device-flow-Ma5P5d2e.mjs.map +1 -0
- package/dist/digest-xIpR3o64.mjs +194 -0
- package/dist/digest-xIpR3o64.mjs.map +1 -0
- package/dist/direct-executor-DMWwCey3.mjs +104 -0
- package/dist/direct-executor-DMWwCey3.mjs.map +1 -0
- package/dist/email-console-DmqVF5J_.mjs +50 -0
- package/dist/email-console-DmqVF5J_.mjs.map +1 -0
- package/dist/email-locale-Cc5YSXfJ.mjs +25 -0
- package/dist/email-locale-Cc5YSXfJ.mjs.map +1 -0
- package/dist/emdash-runtime-BlybX9Ui.mjs +4249 -0
- package/dist/emdash-runtime-BlybX9Ui.mjs.map +1 -0
- package/dist/enrich-Duu4sV3a.mjs +194 -0
- package/dist/enrich-Duu4sV3a.mjs.map +1 -0
- package/dist/entry-lock-De1L8qUQ.mjs +163 -0
- package/dist/entry-lock-De1L8qUQ.mjs.map +1 -0
- package/dist/entry-lock-esmMbgI9.d.mts +4551 -0
- package/dist/entry-lock-esmMbgI9.d.mts.map +1 -0
- package/dist/entry-lock-sxz2PGAT.mjs +1197 -0
- package/dist/entry-lock-sxz2PGAT.mjs.map +1 -0
- package/dist/env-types-BkjCtN13.mjs +38 -0
- package/dist/env-types-BkjCtN13.mjs.map +1 -0
- package/dist/error-B0rgPgsQ.mjs +90 -0
- package/dist/error-B0rgPgsQ.mjs.map +1 -0
- package/dist/errors-CuHQRiBW.mjs +120 -0
- package/dist/errors-CuHQRiBW.mjs.map +1 -0
- package/dist/errors-DTE6C3K_.mjs +470 -0
- package/dist/errors-DTE6C3K_.mjs.map +1 -0
- package/dist/escape-nJW7dR0s.mjs +9 -0
- package/dist/escape-nJW7dR0s.mjs.map +1 -0
- package/dist/fence-CGw57S4v.mjs +162 -0
- package/dist/fence-CGw57S4v.mjs.map +1 -0
- package/dist/field-defs-cache-Bw8w499w.mjs +77 -0
- package/dist/field-defs-cache-Bw8w499w.mjs.map +1 -0
- package/dist/field-map-hn-D-SyH.mjs +83 -0
- package/dist/field-map-hn-D-SyH.mjs.map +1 -0
- package/dist/fts-manager-DacCYIe4.mjs +443 -0
- package/dist/fts-manager-DacCYIe4.mjs.map +1 -0
- package/dist/gc-BBplHrv6.mjs +75 -0
- package/dist/gc-BBplHrv6.mjs.map +1 -0
- package/dist/hash-C4DFoJ7Z.mjs +37 -0
- package/dist/hash-C4DFoJ7Z.mjs.map +1 -0
- package/dist/hook-result-DSRRxu_-.d.mts +31 -0
- package/dist/hook-result-DSRRxu_-.d.mts.map +1 -0
- package/dist/hreflang-CKPunvU0.mjs +105 -0
- package/dist/hreflang-CKPunvU0.mjs.map +1 -0
- package/dist/hreflang-egumj6WF.d.mts +50 -0
- package/dist/hreflang-egumj6WF.d.mts.map +1 -0
- package/dist/http-route-dispatch-DjNFZcJ2.mjs +339 -0
- package/dist/http-route-dispatch-DjNFZcJ2.mjs.map +1 -0
- package/dist/identity-Dfrx2_Bc.mjs +35 -0
- package/dist/identity-Dfrx2_Bc.mjs.map +1 -0
- package/dist/import-ROBvhbNc.mjs +2021 -0
- package/dist/import-ROBvhbNc.mjs.map +1 -0
- package/dist/index-B4sIdCAT.d.mts +623 -0
- package/dist/index-B4sIdCAT.d.mts.map +1 -0
- package/dist/index.d.mts +24 -24
- package/dist/index.mjs +98 -97
- package/dist/init-lock-BGmew3r1.mjs +56 -0
- package/dist/init-lock-BGmew3r1.mjs.map +1 -0
- package/dist/install-finalization-CPM7Gged.mjs +58 -0
- package/dist/install-finalization-CPM7Gged.mjs.map +1 -0
- package/dist/keys-DxqxcAD4.mjs +61 -0
- package/dist/keys-DxqxcAD4.mjs.map +1 -0
- package/dist/kinds-BQl5gN6e.mjs +974 -0
- package/dist/kinds-BQl5gN6e.mjs.map +1 -0
- package/dist/lifecycle-DGQI7itS.mjs +25 -0
- package/dist/lifecycle-DGQI7itS.mjs.map +1 -0
- package/dist/load-DMxRl4VK.mjs +28 -0
- package/dist/load-DMxRl4VK.mjs.map +1 -0
- package/dist/loader-1DMiOq5s.mjs +1303 -0
- package/dist/loader-1DMiOq5s.mjs.map +1 -0
- package/dist/loops-Dn1i16FP.mjs +205 -0
- package/dist/loops-Dn1i16FP.mjs.map +1 -0
- package/dist/manifest-builder-CTw4FmZk.mjs +189 -0
- package/dist/manifest-builder-CTw4FmZk.mjs.map +1 -0
- package/dist/manifest-schema-gy37bD_D.mjs +496 -0
- package/dist/manifest-schema-gy37bD_D.mjs.map +1 -0
- package/dist/marketplace-tHWSsCUo.mjs +257 -0
- package/dist/marketplace-tHWSsCUo.mjs.map +1 -0
- package/dist/media/index.d.mts +1 -1
- package/dist/media/index.mjs +1 -1
- package/dist/media/local-runtime.d.mts +14 -14
- package/dist/media/local-runtime.mjs +7 -7
- package/dist/media-Bw-Q65ve.mjs +294 -0
- package/dist/media-Bw-Q65ve.mjs.map +1 -0
- package/dist/media-BzUDu7nl.mjs +373 -0
- package/dist/media-BzUDu7nl.mjs.map +1 -0
- package/dist/media-aahnKHze.mjs +408 -0
- package/dist/media-aahnKHze.mjs.map +1 -0
- package/dist/media-allowlist-RMrjo8TU.mjs +45 -0
- package/dist/media-allowlist-RMrjo8TU.mjs.map +1 -0
- package/dist/media-folders-kabR1oJf.mjs +210 -0
- package/dist/media-folders-kabR1oJf.mjs.map +1 -0
- package/dist/media-url-DloW2xrP.mjs +43 -0
- package/dist/media-url-DloW2xrP.mjs.map +1 -0
- package/dist/media-usage-CHHpV7ee.mjs +282 -0
- package/dist/media-usage-CHHpV7ee.mjs.map +1 -0
- package/dist/media-usage-activation-BinYqC_r.mjs +78 -0
- package/dist/media-usage-activation-BinYqC_r.mjs.map +1 -0
- package/dist/media-usage-work-C734aq6s.mjs +1015 -0
- package/dist/media-usage-work-C734aq6s.mjs.map +1 -0
- package/dist/media-usage-work-lxvV0-UO.mjs +151 -0
- package/dist/media-usage-work-lxvV0-UO.mjs.map +1 -0
- package/dist/menus-6RHNq4ZK.mjs +753 -0
- package/dist/menus-6RHNq4ZK.mjs.map +1 -0
- package/dist/menus-AuCTaO9W.mjs +3704 -0
- package/dist/menus-AuCTaO9W.mjs.map +1 -0
- package/dist/menus-BQKqf0Up.mjs +92 -0
- package/dist/menus-BQKqf0Up.mjs.map +1 -0
- package/dist/migrations/index.d.mts +1 -1
- package/dist/migrations/index.mjs +3 -3
- package/dist/mime-B5M9R53H.mjs +81 -0
- package/dist/mime-B5M9R53H.mjs.map +1 -0
- package/dist/mode-nh0ppSX5.mjs +23 -0
- package/dist/mode-nh0ppSX5.mjs.map +1 -0
- package/dist/node-sqlite-compat-CDOEcc97.mjs +63 -0
- package/dist/node-sqlite-compat-CDOEcc97.mjs.map +1 -0
- package/dist/oauth-authorization-BtYQ80uU.mjs +274 -0
- package/dist/oauth-authorization-BtYQ80uU.mjs.map +1 -0
- package/dist/oauth-clients-C1S4NQHh.mjs +266 -0
- package/dist/oauth-clients-C1S4NQHh.mjs.map +1 -0
- package/dist/oauth-state-store-CpGi2FZH.mjs +50 -0
- package/dist/oauth-state-store-CpGi2FZH.mjs.map +1 -0
- package/dist/oauth-user-lookup-BNp1aFAr.mjs +26 -0
- package/dist/oauth-user-lookup-BNp1aFAr.mjs.map +1 -0
- package/dist/object-cache/memory.d.mts +1 -1
- package/dist/options-B41aLm1I.d.mts +81 -0
- package/dist/options-B41aLm1I.d.mts.map +1 -0
- package/dist/ownership-DoeAIuTg.mjs +12 -0
- package/dist/ownership-DoeAIuTg.mjs.map +1 -0
- package/dist/page/index.d.mts +2 -2
- package/dist/page/index.mjs +6 -6
- package/dist/parse-CmFDTGzp.mjs +81 -0
- package/dist/parse-CmFDTGzp.mjs.map +1 -0
- package/dist/parse-QVS0t5oR.d.mts +172 -0
- package/dist/parse-QVS0t5oR.d.mts.map +1 -0
- package/dist/passkey-config-C-MxsV22.mjs +46 -0
- package/dist/passkey-config-C-MxsV22.mjs.map +1 -0
- package/dist/paths-kr8hAMMI.mjs +77 -0
- package/dist/paths-kr8hAMMI.mjs.map +1 -0
- package/dist/placeholder-Dn7MMdWr.d.mts +306 -0
- package/dist/placeholder-Dn7MMdWr.d.mts.map +1 -0
- package/dist/plan-CuQOeU9g.mjs +135 -0
- package/dist/plan-CuQOeU9g.mjs.map +1 -0
- package/dist/plugin-test-runtime.d.mts +14 -14
- package/dist/plugin-test-runtime.mjs +110 -109
- package/dist/plugin-types.d.mts +2 -2
- package/dist/plugin-utils.d.mts +12 -12
- package/dist/plugins/adapt-sandbox-entry.d.mts +12 -12
- package/dist/plugins/adapt-sandbox-entry.mjs +3 -3
- package/dist/plugins/host.d.mts +5 -5
- package/dist/plugins/host.mjs +44 -43
- package/dist/plugins-CGb-G98c.mjs +261 -0
- package/dist/plugins-CGb-G98c.mjs.map +1 -0
- package/dist/policy-C5wrDXYV.mjs +45 -0
- package/dist/policy-C5wrDXYV.mjs.map +1 -0
- package/dist/portable-text-BnRuiR1-.mjs +307 -0
- package/dist/portable-text-BnRuiR1-.mjs.map +1 -0
- package/dist/preview-xWNSR1Li.mjs +107 -0
- package/dist/preview-xWNSR1Li.mjs.map +1 -0
- package/dist/protocol-ClxN-m1e.d.mts +61 -0
- package/dist/protocol-ClxN-m1e.d.mts.map +1 -0
- package/dist/public-submission-CkmT2SKv.mjs +250 -0
- package/dist/public-submission-CkmT2SKv.mjs.map +1 -0
- package/dist/public-url-B5a0QAh6.mjs +101 -0
- package/dist/public-url-B5a0QAh6.mjs.map +1 -0
- package/dist/query-DHqFiqqH.mjs +41 -0
- package/dist/query-DHqFiqqH.mjs.map +1 -0
- package/dist/query-DT85BehD.mjs +1125 -0
- package/dist/query-DT85BehD.mjs.map +1 -0
- package/dist/rate-limit-iMvcu3eu.mjs +120 -0
- package/dist/rate-limit-iMvcu3eu.mjs.map +1 -0
- package/dist/receipt-Dpp1uaX9.mjs +43 -0
- package/dist/receipt-Dpp1uaX9.mjs.map +1 -0
- package/dist/redirect-BRoLiWQE.mjs +19 -0
- package/dist/redirect-BRoLiWQE.mjs.map +1 -0
- package/dist/redirect-xZNpBoGp.mjs +417 -0
- package/dist/redirect-xZNpBoGp.mjs.map +1 -0
- package/dist/redirects-D4EWeXAo.mjs +148 -0
- package/dist/redirects-D4EWeXAo.mjs.map +1 -0
- package/dist/redirects-DCKqwiWp.mjs +446 -0
- package/dist/redirects-DCKqwiWp.mjs.map +1 -0
- package/dist/registry/testing.mjs +3 -3
- package/dist/registry-DaXmUsD4.mjs +8369 -0
- package/dist/registry-DaXmUsD4.mjs.map +1 -0
- package/dist/relations-JvBP8nGP.mjs +776 -0
- package/dist/relations-JvBP8nGP.mjs.map +1 -0
- package/dist/request-context.d.mts +2 -2
- package/dist/request-context.mjs.map +1 -1
- package/dist/request-meta-B6blULFY.mjs +141 -0
- package/dist/request-meta-B6blULFY.mjs.map +1 -0
- package/dist/resolve-DAhHi5tn.mjs +100 -0
- package/dist/resolve-DAhHi5tn.mjs.map +1 -0
- package/dist/revision-BWEH2qQB.mjs +368 -0
- package/dist/revision-BWEH2qQB.mjs.map +1 -0
- package/dist/route-wire-DK600v4u.mjs +197 -0
- package/dist/route-wire-DK600v4u.mjs.map +1 -0
- package/dist/routes-BeZyaCzv.mjs +272 -0
- package/dist/routes-BeZyaCzv.mjs.map +1 -0
- package/dist/runner-CskI4Hmq.mjs +6372 -0
- package/dist/runner-CskI4Hmq.mjs.map +1 -0
- package/dist/runner-J3Cj6DGk.d.mts +68 -0
- package/dist/runner-J3Cj6DGk.d.mts.map +1 -0
- package/dist/runtime.d.mts +13 -13
- package/dist/runtime.mjs +3 -3
- package/dist/schema/project-env-types.mjs +37 -37
- package/dist/schema-CK0ihqMR.mjs +815 -0
- package/dist/schema-CK0ihqMR.mjs.map +1 -0
- package/dist/schema-VtaZSrC-.mjs +13 -0
- package/dist/schema-VtaZSrC-.mjs.map +1 -0
- package/dist/scopes-BRnGlL9t.mjs +34 -0
- package/dist/scopes-BRnGlL9t.mjs.map +1 -0
- package/dist/search-D6-XK1Sn.mjs +448 -0
- package/dist/search-D6-XK1Sn.mjs.map +1 -0
- package/dist/secrets-Cc_O3Kp-.mjs +369 -0
- package/dist/secrets-Cc_O3Kp-.mjs.map +1 -0
- package/dist/sections-CBDCf7qR.mjs +346 -0
- package/dist/sections-CBDCf7qR.mjs.map +1 -0
- package/dist/seed/index.d.mts +2 -2
- package/dist/seed/index.mjs +35 -35
- package/dist/seo/index.d.mts +3 -3
- package/dist/seo/index.mjs +22 -22
- package/dist/seo-BdeEPDNW.mjs +133 -0
- package/dist/seo-BdeEPDNW.mjs.map +1 -0
- package/dist/seo-C61bnPuV.mjs +114 -0
- package/dist/seo-C61bnPuV.mjs.map +1 -0
- package/dist/service-BuRKLMxa.mjs +150 -0
- package/dist/service-BuRKLMxa.mjs.map +1 -0
- package/dist/session-user-CqkPtrPL.mjs +61 -0
- package/dist/session-user-CqkPtrPL.mjs.map +1 -0
- package/dist/settings-0u0lTthS.mjs +51 -0
- package/dist/settings-0u0lTthS.mjs.map +1 -0
- package/dist/settings-WHr45II1.mjs +61 -0
- package/dist/settings-WHr45II1.mjs.map +1 -0
- package/dist/settings-m5tIYnF0.mjs +443 -0
- package/dist/settings-m5tIYnF0.mjs.map +1 -0
- package/dist/setup-complete-B2_dhZZz.mjs +65 -0
- package/dist/setup-complete-B2_dhZZz.mjs.map +1 -0
- package/dist/setup-nonce-CJV9ftSK.mjs +25 -0
- package/dist/setup-nonce-CJV9ftSK.mjs.map +1 -0
- package/dist/single-flight-cache-D0EaGbN1.mjs +104 -0
- package/dist/single-flight-cache-D0EaGbN1.mjs.map +1 -0
- package/dist/site-settings-KJOqJW6W.mjs +50 -0
- package/dist/site-settings-KJOqJW6W.mjs.map +1 -0
- package/dist/site-url-Ceq_AUK0.mjs +16 -0
- package/dist/site-url-Ceq_AUK0.mjs.map +1 -0
- package/dist/snapshot-Dzsn3NZa.mjs +414 -0
- package/dist/snapshot-Dzsn3NZa.mjs.map +1 -0
- package/dist/ssrf-DsmvZB80.mjs +406 -0
- package/dist/ssrf-DsmvZB80.mjs.map +1 -0
- package/dist/stage-Csnh_yEd.mjs +662 -0
- package/dist/stage-Csnh_yEd.mjs.map +1 -0
- package/dist/staged-Q7pnEVvI.mjs +686 -0
- package/dist/staged-Q7pnEVvI.mjs.map +1 -0
- package/dist/state-kGdOMQRY.mjs +153 -0
- package/dist/state-kGdOMQRY.mjs.map +1 -0
- package/dist/status-D39Fpy8R.mjs +30 -0
- package/dist/status-D39Fpy8R.mjs.map +1 -0
- package/dist/storage/local.d.mts +1 -1
- package/dist/storage/local.mjs +2 -2
- package/dist/storage/s3.d.mts +1 -1
- package/dist/storage/s3.mjs +1 -1
- package/dist/storage-query-C7iy6eUb.d.mts +1615 -0
- package/dist/storage-query-C7iy6eUb.d.mts.map +1 -0
- package/dist/tar-BWiraSUY.mjs +449 -0
- package/dist/tar-BWiraSUY.mjs.map +1 -0
- package/dist/target-DOFs5oUC.mjs +27 -0
- package/dist/target-DOFs5oUC.mjs.map +1 -0
- package/dist/taxonomies-BS40Wxvi.mjs +939 -0
- package/dist/taxonomies-BS40Wxvi.mjs.map +1 -0
- package/dist/taxonomies-DAZU9VDd.mjs +697 -0
- package/dist/taxonomies-DAZU9VDd.mjs.map +1 -0
- package/dist/taxonomy-XzLE95Vx.mjs +525 -0
- package/dist/taxonomy-XzLE95Vx.mjs.map +1 -0
- package/dist/tokens-DSQan4p7.mjs +171 -0
- package/dist/tokens-DSQan4p7.mjs.map +1 -0
- package/dist/transfer-BcCVxDgf.mjs +166 -0
- package/dist/transfer-BcCVxDgf.mjs.map +1 -0
- package/dist/transfer-OMrancOt.mjs +8873 -0
- package/dist/transfer-OMrancOt.mjs.map +1 -0
- package/dist/transfer-download-Dc-ltjZY.mjs +33 -0
- package/dist/transfer-download-Dc-ltjZY.mjs.map +1 -0
- package/dist/transformations-Ddx7UtrY.mjs +196 -0
- package/dist/transformations-Ddx7UtrY.mjs.map +1 -0
- package/dist/transport-flR-Zmds.d.mts +42 -0
- package/dist/transport-flR-Zmds.d.mts.map +1 -0
- package/dist/transport-umzEbgYO.mjs +136 -0
- package/dist/transport-umzEbgYO.mjs.map +1 -0
- package/dist/trusted-proxy-BqfQFs6a.mjs +51 -0
- package/dist/trusted-proxy-BqfQFs6a.mjs.map +1 -0
- package/dist/turnstile-Do60baId.mjs +58 -0
- package/dist/turnstile-Do60baId.mjs.map +1 -0
- package/dist/types-BT1p3uyb.d.mts +1735 -0
- package/dist/types-BT1p3uyb.d.mts.map +1 -0
- package/dist/types-BYaPWs_F.d.mts +198 -0
- package/dist/types-BYaPWs_F.d.mts.map +1 -0
- package/dist/types-C-Xp0CcN.mjs +103 -0
- package/dist/types-C-Xp0CcN.mjs.map +1 -0
- package/dist/types-CLTQ9b_r.d.mts +374 -0
- package/dist/types-CLTQ9b_r.d.mts.map +1 -0
- package/dist/types-CPkQw2T2.d.mts +85 -0
- package/dist/types-CPkQw2T2.d.mts.map +1 -0
- package/dist/types-CQLvuXoZ.d.mts +198 -0
- package/dist/types-CQLvuXoZ.d.mts.map +1 -0
- package/dist/types-CV5xszpF.d.mts +363 -0
- package/dist/types-CV5xszpF.d.mts.map +1 -0
- package/dist/types-CdEMurNh.mjs +77 -0
- package/dist/types-CdEMurNh.mjs.map +1 -0
- package/dist/types-Cj0_yZkn.mjs +18 -0
- package/dist/types-Cj0_yZkn.mjs.map +1 -0
- package/dist/types-CxwtnuSS.mjs +37 -0
- package/dist/types-CxwtnuSS.mjs.map +1 -0
- package/dist/types-DGw8KMX_.mjs +16 -0
- package/dist/types-DGw8KMX_.mjs.map +1 -0
- package/dist/types-DOfVMPoo.d.mts +125 -0
- package/dist/types-DOfVMPoo.d.mts.map +1 -0
- package/dist/types-LtS0SM4F.d.mts +287 -0
- package/dist/types-LtS0SM4F.d.mts.map +1 -0
- package/dist/types-ifgOkcBa.d.mts +916 -0
- package/dist/types-ifgOkcBa.d.mts.map +1 -0
- package/dist/update-check-DOc2aBIU.mjs +161 -0
- package/dist/update-check-DOc2aBIU.mjs.map +1 -0
- package/dist/upload-attempts-nzdc3cay.mjs +32 -0
- package/dist/upload-attempts-nzdc3cay.mjs.map +1 -0
- package/dist/url-pattern-hVbqpXs6.mjs +41 -0
- package/dist/url-pattern-hVbqpXs6.mjs.map +1 -0
- package/dist/user-Dnp53zTq.mjs +171 -0
- package/dist/user-Dnp53zTq.mjs.map +1 -0
- package/dist/utils-CoV-PYhg.mjs +439 -0
- package/dist/utils-CoV-PYhg.mjs.map +1 -0
- package/dist/validate-CfQ9_YlD.d.mts +468 -0
- package/dist/validate-CfQ9_YlD.d.mts.map +1 -0
- package/dist/validate-DBX3DKtL.mjs +516 -0
- package/dist/validate-DBX3DKtL.mjs.map +1 -0
- package/dist/validation-BJMiDhB1.mjs +219 -0
- package/dist/validation-BJMiDhB1.mjs.map +1 -0
- package/dist/version-BaT8yKIT.mjs +7 -0
- package/dist/version-BaT8yKIT.mjs.map +1 -0
- package/dist/version-BwEGkqkx.mjs +9 -0
- package/dist/version-BwEGkqkx.mjs.map +1 -0
- package/dist/virtual-modules-B6vJW15k.mjs +516 -0
- package/dist/virtual-modules-B6vJW15k.mjs.map +1 -0
- package/dist/widgets-BkxBAgZ_.mjs +126 -0
- package/dist/widgets-BkxBAgZ_.mjs.map +1 -0
- package/dist/wxr-taxonomies-D7gAJyOF.mjs +453 -0
- package/dist/wxr-taxonomies-D7gAJyOF.mjs.map +1 -0
- package/dist/wxr-taxonomies-DM5J9AsT.d.mts +34 -0
- package/dist/wxr-taxonomies-DM5J9AsT.d.mts.map +1 -0
- package/dist/zod-generator-BQilAboC.mjs +424 -0
- package/dist/zod-generator-BQilAboC.mjs.map +1 -0
- package/package.json +11 -5
- package/src/api/errors.ts +3 -0
- package/src/api/handlers/bylines.ts +24 -3
- package/src/api/handlers/calendar.ts +246 -0
- package/src/api/handlers/content.ts +12 -5
- package/src/api/handlers/media-allowlist.ts +1 -0
- package/src/api/handlers/media-upload.ts +13 -10
- package/src/api/handlers/plugins.ts +21 -29
- package/src/api/handlers/redirects.ts +6 -6
- package/src/api/schemas/bylines.ts +3 -1
- package/src/api/schemas/content.ts +16 -0
- package/src/astro/integration/index.ts +18 -1
- package/src/astro/integration/routes.ts +5 -0
- package/src/astro/integration/vite-config.ts +11 -0
- package/src/astro/middleware/csp.ts +1 -0
- package/src/astro/middleware/redirect.ts +20 -9
- package/src/astro/middleware/request-context.ts +54 -27
- package/src/astro/middleware.ts +97 -12
- package/src/astro/prefetch.ts +10 -3
- package/src/astro/routes/api/admin/bylines/[id]/translations.ts +0 -5
- package/src/astro/routes/api/admin/bylines/index.ts +1 -1
- package/src/astro/routes/api/admin/plugins/[id]/index.ts +1 -0
- package/src/astro/routes/api/auth/oauth/[provider]/callback.ts +56 -4
- package/src/astro/routes/api/auth/oauth/[provider].ts +37 -4
- package/src/astro/routes/api/calendar.ts +35 -0
- package/src/astro/routes/api/media/upload-url.ts +8 -4
- package/src/astro/routes/api/media.ts +9 -5
- package/src/astro/routes/api/setup/index.ts +14 -2
- package/src/auth/providers/microsoft-admin.tsx +31 -0
- package/src/auth/providers/microsoft.ts +47 -0
- package/src/comments/turnstile.ts +6 -1
- package/src/components/HtmlBlock.astro +17 -6
- package/src/components/HtmlBlockFrame.astro +63 -0
- package/src/components/Iframe.astro +141 -0
- package/src/components/InlinePortableTextEditor.tsx +8 -7
- package/src/components/WebMcpSearch.astro +80 -0
- package/src/components/index.ts +5 -2
- package/src/components/webmcp-search.ts +142 -0
- package/src/config/secrets.ts +27 -15
- package/src/content/converters/portable-text-identity.ts +1 -0
- package/src/content/converters/portable-text-to-prosemirror.ts +36 -2
- package/src/content/converters/prosemirror-to-portable-text.ts +28 -2
- package/src/content/converters/types.ts +24 -0
- package/src/database/content-datetime.ts +11 -4
- package/src/database/migrations/090_redirect_enable_loop_guard.ts +70 -0
- package/src/database/migrations/091_redirect_artifacts.ts +141 -0
- package/src/database/migrations/runner.ts +4 -0
- package/src/database/repositories/content.ts +81 -26
- package/src/database/repositories/redirect.ts +6 -1
- package/src/database/request-scoped.ts +34 -0
- package/src/database/types.ts +23 -0
- package/src/db/adapters.ts +2 -0
- package/src/emdash-runtime.ts +28 -3
- package/src/import/menus.ts +3 -0
- package/src/index.ts +1 -0
- package/src/loader.ts +226 -55
- package/src/mcp/server.ts +12 -4
- package/src/media/mime.ts +21 -0
- package/src/menus/index.ts +30 -26
- package/src/plugins/hooks.ts +10 -0
- package/src/plugins/manager.ts +12 -2
- package/src/plugins/types.ts +16 -0
- package/src/query.ts +12 -29
- package/src/redirects/artifacts.ts +460 -0
- package/src/redirects/cache.ts +76 -41
- package/src/request-context.ts +1 -1
- package/src/seed/apply.ts +65 -57
- package/src/settings/index.ts +17 -12
- package/src/transfer/format/columns.ts +3 -0
- package/src/transfer/import/rebuild.ts +17 -2
- package/src/transfer/import/scaffold.ts +16 -9
- package/src/ui.ts +1 -0
- package/src/utils/sanitize.ts +14 -9
- package/src/virtual-modules.d.ts +3 -0
- package/dist/action-token-D2KE1Rqf.mjs +0 -26
- package/dist/action-token-D2KE1Rqf.mjs.map +0 -1
- package/dist/activation-DDuqAat2.mjs +0 -387
- package/dist/activation-DDuqAat2.mjs.map +0 -1
- package/dist/adapters-Ds-1Pmkm.d.mts +0 -171
- package/dist/adapters-Ds-1Pmkm.d.mts.map +0 -1
- package/dist/allowed-origins-D78QvbTO.mjs +0 -116
- package/dist/allowed-origins-D78QvbTO.mjs.map +0 -1
- package/dist/api-BBZlif0y.mjs +0 -4974
- package/dist/api-BBZlif0y.mjs.map +0 -1
- package/dist/api-tokens-BGbfWZVO.mjs +0 -166
- package/dist/api-tokens-BGbfWZVO.mjs.map +0 -1
- package/dist/apply-CDNV4JJ-.mjs +0 -1672
- package/dist/apply-CDNV4JJ-.mjs.map +0 -1
- package/dist/approvals-CVvJSEBF.mjs +0 -460
- package/dist/approvals-CVvJSEBF.mjs.map +0 -1
- package/dist/artifact-fetch-CGK0DQLj.mjs +0 -659
- package/dist/artifact-fetch-CGK0DQLj.mjs.map +0 -1
- package/dist/audit-BszbE_BP.mjs +0 -127
- package/dist/audit-BszbE_BP.mjs.map +0 -1
- package/dist/authoritative-records-ChM8dTeV.mjs +0 -5172
- package/dist/authoritative-records-ChM8dTeV.mjs.map +0 -1
- package/dist/authorize-CTGywswM.mjs +0 -49
- package/dist/authorize-CTGywswM.mjs.map +0 -1
- package/dist/backup-CDrPP8fI.mjs +0 -246
- package/dist/backup-CDrPP8fI.mjs.map +0 -1
- package/dist/base64-DvnNgP7e.mjs +0 -63
- package/dist/base64-DvnNgP7e.mjs.map +0 -1
- package/dist/block-types-nNEaPkvx.mjs +0 -132
- package/dist/block-types-nNEaPkvx.mjs.map +0 -1
- package/dist/block-values-Bho1nsZF.mjs +0 -175
- package/dist/block-values-Bho1nsZF.mjs.map +0 -1
- package/dist/byline-02tu_Uc-.mjs +0 -909
- package/dist/byline-02tu_Uc-.mjs.map +0 -1
- package/dist/byline-fields-BYbTptTU.mjs +0 -280
- package/dist/byline-fields-BYbTptTU.mjs.map +0 -1
- package/dist/byline-fields-BjQH-1z9.mjs +0 -123
- package/dist/byline-fields-BjQH-1z9.mjs.map +0 -1
- package/dist/bylines-VytjeHBI.mjs +0 -214
- package/dist/bylines-VytjeHBI.mjs.map +0 -1
- package/dist/bylines-gyWBWUUc.mjs +0 -150
- package/dist/bylines-gyWBWUUc.mjs.map +0 -1
- package/dist/cache-CPanL9IO.mjs +0 -114
- package/dist/cache-CPanL9IO.mjs.map +0 -1
- package/dist/canonical-CAecl1UQ.mjs +0 -174
- package/dist/canonical-CAecl1UQ.mjs.map +0 -1
- package/dist/capture-triggers-CdZfvHtF.mjs +0 -362
- package/dist/capture-triggers-CdZfvHtF.mjs.map +0 -1
- package/dist/challenge-store-VePApay4.mjs +0 -51
- package/dist/challenge-store-VePApay4.mjs.map +0 -1
- package/dist/checksum-BSIhEAYW.mjs +0 -162
- package/dist/checksum-BSIhEAYW.mjs.map +0 -1
- package/dist/chrome-tags-CKELm-bo.mjs +0 -24
- package/dist/chrome-tags-CKELm-bo.mjs.map +0 -1
- package/dist/chunks-DBmkKmBH.mjs +0 -25
- package/dist/chunks-DBmkKmBH.mjs.map +0 -1
- package/dist/collection-slugs-cache-BNRAPNiu.mjs +0 -85
- package/dist/collection-slugs-cache-BNRAPNiu.mjs.map +0 -1
- package/dist/comment-Cq1UYN8_.mjs +0 -313
- package/dist/comment-Cq1UYN8_.mjs.map +0 -1
- package/dist/comment-reaction-B5sZzSoA.mjs +0 -85
- package/dist/comment-reaction-B5sZzSoA.mjs.map +0 -1
- package/dist/comments-B3F-ETyh.mjs +0 -195
- package/dist/comments-B3F-ETyh.mjs.map +0 -1
- package/dist/comments-zrTgWBSg.mjs +0 -99
- package/dist/comments-zrTgWBSg.mjs.map +0 -1
- package/dist/components-Dbf4Eq16.mjs +0 -108
- package/dist/components-Dbf4Eq16.mjs.map +0 -1
- package/dist/config-BCM5sQP7.d.mts +0 -6688
- package/dist/config-BCM5sQP7.d.mts.map +0 -1
- package/dist/config-CXPcy2iY.mjs +0 -228
- package/dist/config-CXPcy2iY.mjs.map +0 -1
- package/dist/config-CZkZBuBK.d.mts +0 -39
- package/dist/config-CZkZBuBK.d.mts.map +0 -1
- package/dist/connection-C5GIciX9.mjs +0 -36
- package/dist/connection-C5GIciX9.mjs.map +0 -1
- package/dist/content-RzEXY3QX.mjs +0 -2020
- package/dist/content-RzEXY3QX.mjs.map +0 -1
- package/dist/content-list-query-B6P37Ug_.d.mts +0 -26
- package/dist/content-list-query-B6P37Ug_.d.mts.map +0 -1
- package/dist/content-repair-BDVsYXWK.mjs +0 -442
- package/dist/content-repair-BDVsYXWK.mjs.map +0 -1
- package/dist/context-BpTIzY5h.mjs +0 -2026
- package/dist/context-BpTIzY5h.mjs.map +0 -1
- package/dist/credits-JOE92Gr7.mjs +0 -110
- package/dist/credits-JOE92Gr7.mjs.map +0 -1
- package/dist/cron-ktyapbdB.mjs +0 -306
- package/dist/cron-ktyapbdB.mjs.map +0 -1
- package/dist/dashboard-BoV4pwPP.mjs +0 -151
- package/dist/dashboard-BoV4pwPP.mjs.map +0 -1
- package/dist/default-B7KnYwtQ.mjs +0 -81
- package/dist/default-B7KnYwtQ.mjs.map +0 -1
- package/dist/deferred-tasks-eaUIqXj8.d.mts +0 -9
- package/dist/deferred-tasks-eaUIqXj8.d.mts.map +0 -1
- package/dist/dev-typegen-8JlYYFno.mjs +0 -29
- package/dist/dev-typegen-8JlYYFno.mjs.map +0 -1
- package/dist/device-flow-BlV_z24g.mjs +0 -521
- package/dist/device-flow-BlV_z24g.mjs.map +0 -1
- package/dist/digest-DiYAoZpf.mjs +0 -194
- package/dist/digest-DiYAoZpf.mjs.map +0 -1
- package/dist/direct-executor-Db8xA3zg.mjs +0 -104
- package/dist/direct-executor-Db8xA3zg.mjs.map +0 -1
- package/dist/email-console-Dm78wSmg.mjs +0 -50
- package/dist/email-console-Dm78wSmg.mjs.map +0 -1
- package/dist/email-locale-B4X9LXe9.mjs +0 -25
- package/dist/email-locale-B4X9LXe9.mjs.map +0 -1
- package/dist/emdash-runtime-BakQ6io7.mjs +0 -4239
- package/dist/emdash-runtime-BakQ6io7.mjs.map +0 -1
- package/dist/enrich-BDdVNeDK.mjs +0 -194
- package/dist/enrich-BDdVNeDK.mjs.map +0 -1
- package/dist/entry-lock-DY8B-xcr.d.mts +0 -4544
- package/dist/entry-lock-DY8B-xcr.d.mts.map +0 -1
- package/dist/entry-lock-DrUAdTzf.mjs +0 -163
- package/dist/entry-lock-DrUAdTzf.mjs.map +0 -1
- package/dist/entry-lock-yIkBduqJ.mjs +0 -1180
- package/dist/entry-lock-yIkBduqJ.mjs.map +0 -1
- package/dist/env-types-DkHYR2pl.mjs +0 -38
- package/dist/env-types-DkHYR2pl.mjs.map +0 -1
- package/dist/error-DIYXAVk4.mjs +0 -90
- package/dist/error-DIYXAVk4.mjs.map +0 -1
- package/dist/errors-CNvATh_7.mjs +0 -469
- package/dist/errors-CNvATh_7.mjs.map +0 -1
- package/dist/errors-CjXd1LgH.mjs +0 -120
- package/dist/errors-CjXd1LgH.mjs.map +0 -1
- package/dist/escape-B1GM0yJU.mjs +0 -9
- package/dist/escape-B1GM0yJU.mjs.map +0 -1
- package/dist/fence-8MaKKWhp.mjs +0 -162
- package/dist/fence-8MaKKWhp.mjs.map +0 -1
- package/dist/field-defs-cache-DEkFYCDE.mjs +0 -77
- package/dist/field-defs-cache-DEkFYCDE.mjs.map +0 -1
- package/dist/field-map-D7ioN0r0.mjs +0 -83
- package/dist/field-map-D7ioN0r0.mjs.map +0 -1
- package/dist/fts-manager-DU03MxWu.mjs +0 -443
- package/dist/fts-manager-DU03MxWu.mjs.map +0 -1
- package/dist/gc-DMiE7ezk.mjs +0 -75
- package/dist/gc-DMiE7ezk.mjs.map +0 -1
- package/dist/hash-CY4QdeMJ.mjs +0 -37
- package/dist/hash-CY4QdeMJ.mjs.map +0 -1
- package/dist/hook-result-Cb67D3P3.d.mts +0 -31
- package/dist/hook-result-Cb67D3P3.d.mts.map +0 -1
- package/dist/hreflang-Bterc3b7.mjs +0 -105
- package/dist/hreflang-Bterc3b7.mjs.map +0 -1
- package/dist/hreflang-uIBOE5yg.d.mts +0 -50
- package/dist/hreflang-uIBOE5yg.d.mts.map +0 -1
- package/dist/http-route-dispatch-DubjTibD.mjs +0 -339
- package/dist/http-route-dispatch-DubjTibD.mjs.map +0 -1
- package/dist/identity-DJ-5AcdG.mjs +0 -35
- package/dist/identity-DJ-5AcdG.mjs.map +0 -1
- package/dist/import-DEfuIgRz.mjs +0 -2020
- package/dist/import-DEfuIgRz.mjs.map +0 -1
- package/dist/index-xCy3j0f6.d.mts +0 -623
- package/dist/index-xCy3j0f6.d.mts.map +0 -1
- package/dist/init-lock-4eRRB4Le.mjs +0 -56
- package/dist/init-lock-4eRRB4Le.mjs.map +0 -1
- package/dist/install-finalization-DeGRbaVa.mjs +0 -58
- package/dist/install-finalization-DeGRbaVa.mjs.map +0 -1
- package/dist/keys-DWwMxdZh.mjs +0 -61
- package/dist/keys-DWwMxdZh.mjs.map +0 -1
- package/dist/kinds-D1A-00-F.mjs +0 -974
- package/dist/kinds-D1A-00-F.mjs.map +0 -1
- package/dist/lifecycle-BWtBGNEn.mjs +0 -25
- package/dist/lifecycle-BWtBGNEn.mjs.map +0 -1
- package/dist/load-BR1NEa_3.mjs +0 -28
- package/dist/load-BR1NEa_3.mjs.map +0 -1
- package/dist/loader-D4edocWH.mjs +0 -1197
- package/dist/loader-D4edocWH.mjs.map +0 -1
- package/dist/loops-DLaHFrvI.mjs +0 -205
- package/dist/loops-DLaHFrvI.mjs.map +0 -1
- package/dist/manifest-builder-8jsSLR7s.mjs +0 -189
- package/dist/manifest-builder-8jsSLR7s.mjs.map +0 -1
- package/dist/manifest-schema-DcZjRNEv.mjs +0 -496
- package/dist/manifest-schema-DcZjRNEv.mjs.map +0 -1
- package/dist/marketplace-CNxjq10S.mjs +0 -257
- package/dist/marketplace-CNxjq10S.mjs.map +0 -1
- package/dist/media-3v7mqAVX.mjs +0 -294
- package/dist/media-3v7mqAVX.mjs.map +0 -1
- package/dist/media-Bs6qmlVl.mjs +0 -408
- package/dist/media-Bs6qmlVl.mjs.map +0 -1
- package/dist/media-CputjGE1.mjs +0 -373
- package/dist/media-CputjGE1.mjs.map +0 -1
- package/dist/media-allowlist-isqF1gAh.mjs +0 -44
- package/dist/media-allowlist-isqF1gAh.mjs.map +0 -1
- package/dist/media-folders-D2VdVBf6.mjs +0 -210
- package/dist/media-folders-D2VdVBf6.mjs.map +0 -1
- package/dist/media-url-DbkMY3y6.mjs +0 -43
- package/dist/media-url-DbkMY3y6.mjs.map +0 -1
- package/dist/media-usage-activation-BaT4AlNI.mjs +0 -78
- package/dist/media-usage-activation-BaT4AlNI.mjs.map +0 -1
- package/dist/media-usage-v43L0kR_.mjs +0 -282
- package/dist/media-usage-v43L0kR_.mjs.map +0 -1
- package/dist/media-usage-work-CY8gIeU-.mjs +0 -151
- package/dist/media-usage-work-CY8gIeU-.mjs.map +0 -1
- package/dist/media-usage-work-VO108Q9E.mjs +0 -1015
- package/dist/media-usage-work-VO108Q9E.mjs.map +0 -1
- package/dist/menus-BYyeRemR.mjs +0 -3647
- package/dist/menus-BYyeRemR.mjs.map +0 -1
- package/dist/menus-mC_XTxD7.mjs +0 -92
- package/dist/menus-mC_XTxD7.mjs.map +0 -1
- package/dist/menus-trvc6_fW.mjs +0 -753
- package/dist/menus-trvc6_fW.mjs.map +0 -1
- package/dist/mime-IZf-LHIS.mjs +0 -36
- package/dist/mime-IZf-LHIS.mjs.map +0 -1
- package/dist/mode-B9-gMXL9.mjs +0 -23
- package/dist/mode-B9-gMXL9.mjs.map +0 -1
- package/dist/node-sqlite-compat-DztcWs4y.mjs +0 -63
- package/dist/node-sqlite-compat-DztcWs4y.mjs.map +0 -1
- package/dist/oauth-authorization-BIHy9SGU.mjs +0 -274
- package/dist/oauth-authorization-BIHy9SGU.mjs.map +0 -1
- package/dist/oauth-clients-BZWZvKXa.mjs +0 -266
- package/dist/oauth-clients-BZWZvKXa.mjs.map +0 -1
- package/dist/oauth-state-store-CxXTjXdI.mjs +0 -50
- package/dist/oauth-state-store-CxXTjXdI.mjs.map +0 -1
- package/dist/oauth-user-lookup-GWojfxRl.mjs +0 -26
- package/dist/oauth-user-lookup-GWojfxRl.mjs.map +0 -1
- package/dist/options-DRF6dlXY.d.mts +0 -81
- package/dist/options-DRF6dlXY.d.mts.map +0 -1
- package/dist/ownership-Bd77AmJz.mjs +0 -12
- package/dist/ownership-Bd77AmJz.mjs.map +0 -1
- package/dist/parse-5Y0W39xR.mjs +0 -81
- package/dist/parse-5Y0W39xR.mjs.map +0 -1
- package/dist/parse-BPblgoa-.d.mts +0 -172
- package/dist/parse-BPblgoa-.d.mts.map +0 -1
- package/dist/passkey-config-PiQ5cBnt.mjs +0 -46
- package/dist/passkey-config-PiQ5cBnt.mjs.map +0 -1
- package/dist/paths-DkS74lBM.mjs +0 -77
- package/dist/paths-DkS74lBM.mjs.map +0 -1
- package/dist/placeholder-Bez2282x.d.mts +0 -306
- package/dist/placeholder-Bez2282x.d.mts.map +0 -1
- package/dist/plan-Lw7iGnGD.mjs +0 -135
- package/dist/plan-Lw7iGnGD.mjs.map +0 -1
- package/dist/plugins-D7xSh1Lu.mjs +0 -277
- package/dist/plugins-D7xSh1Lu.mjs.map +0 -1
- package/dist/policy-DMRiMdLn.mjs +0 -45
- package/dist/policy-DMRiMdLn.mjs.map +0 -1
- package/dist/portable-text-kcyN3F-a.mjs +0 -307
- package/dist/portable-text-kcyN3F-a.mjs.map +0 -1
- package/dist/preview--2VDLaND.mjs +0 -107
- package/dist/preview--2VDLaND.mjs.map +0 -1
- package/dist/protocol-FvwLA8P-.d.mts +0 -61
- package/dist/protocol-FvwLA8P-.d.mts.map +0 -1
- package/dist/public-submission-BRyK76U8.mjs +0 -250
- package/dist/public-submission-BRyK76U8.mjs.map +0 -1
- package/dist/public-url-7j0cpCFc.mjs +0 -101
- package/dist/public-url-7j0cpCFc.mjs.map +0 -1
- package/dist/query-BRNTde3V.mjs +0 -41
- package/dist/query-BRNTde3V.mjs.map +0 -1
- package/dist/query-DyYYWOKk.mjs +0 -1161
- package/dist/query-DyYYWOKk.mjs.map +0 -1
- package/dist/rate-limit-D0BcE76H.mjs +0 -120
- package/dist/rate-limit-D0BcE76H.mjs.map +0 -1
- package/dist/receipt-C4icyHlC.mjs +0 -43
- package/dist/receipt-C4icyHlC.mjs.map +0 -1
- package/dist/redirect-9DbtxSNG.mjs +0 -19
- package/dist/redirect-9DbtxSNG.mjs.map +0 -1
- package/dist/redirect-BvFKh8Sz.mjs +0 -416
- package/dist/redirect-BvFKh8Sz.mjs.map +0 -1
- package/dist/redirects-1nhdEaTq.mjs +0 -148
- package/dist/redirects-1nhdEaTq.mjs.map +0 -1
- package/dist/redirects-D1yMnSR9.mjs +0 -446
- package/dist/redirects-D1yMnSR9.mjs.map +0 -1
- package/dist/registry-CzPJNu3H.mjs +0 -8366
- package/dist/registry-CzPJNu3H.mjs.map +0 -1
- package/dist/relations-C8JpSkU6.mjs +0 -776
- package/dist/relations-C8JpSkU6.mjs.map +0 -1
- package/dist/request-meta-Bs60XW1m.mjs +0 -141
- package/dist/request-meta-Bs60XW1m.mjs.map +0 -1
- package/dist/resolve-BHWgMU_X.mjs +0 -100
- package/dist/resolve-BHWgMU_X.mjs.map +0 -1
- package/dist/revision-CGkQA0e5.mjs +0 -366
- package/dist/revision-CGkQA0e5.mjs.map +0 -1
- package/dist/route-wire-ClUVQduA.mjs +0 -197
- package/dist/route-wire-ClUVQduA.mjs.map +0 -1
- package/dist/routes-D2GFl3B7.mjs +0 -272
- package/dist/routes-D2GFl3B7.mjs.map +0 -1
- package/dist/runner-CLpxmhl8.mjs +0 -6197
- package/dist/runner-CLpxmhl8.mjs.map +0 -1
- package/dist/runner-CWl76CH3.d.mts +0 -68
- package/dist/runner-CWl76CH3.d.mts.map +0 -1
- package/dist/schema-27XefSYG.mjs +0 -13
- package/dist/schema-27XefSYG.mjs.map +0 -1
- package/dist/schema-Btvj3BMh.mjs +0 -815
- package/dist/schema-Btvj3BMh.mjs.map +0 -1
- package/dist/scopes-DGCj6K4p.mjs +0 -34
- package/dist/scopes-DGCj6K4p.mjs.map +0 -1
- package/dist/search-pZRRmWjh.mjs +0 -448
- package/dist/search-pZRRmWjh.mjs.map +0 -1
- package/dist/secrets-CIi0nFiR.mjs +0 -341
- package/dist/secrets-CIi0nFiR.mjs.map +0 -1
- package/dist/sections-CIhqs3Ao.mjs +0 -346
- package/dist/sections-CIhqs3Ao.mjs.map +0 -1
- package/dist/seo-DifeiGdl.mjs +0 -114
- package/dist/seo-DifeiGdl.mjs.map +0 -1
- package/dist/seo-DpYxmGaL.mjs +0 -133
- package/dist/seo-DpYxmGaL.mjs.map +0 -1
- package/dist/service-COVdVpSK.mjs +0 -150
- package/dist/service-COVdVpSK.mjs.map +0 -1
- package/dist/session-user-C6IEjuty.mjs +0 -61
- package/dist/session-user-C6IEjuty.mjs.map +0 -1
- package/dist/settings-CwcrX-Ay.mjs +0 -61
- package/dist/settings-CwcrX-Ay.mjs.map +0 -1
- package/dist/settings-D_cJtT48.mjs +0 -439
- package/dist/settings-D_cJtT48.mjs.map +0 -1
- package/dist/settings-tnPQN3Z2.mjs +0 -51
- package/dist/settings-tnPQN3Z2.mjs.map +0 -1
- package/dist/setup-complete-BOrI10UY.mjs +0 -65
- package/dist/setup-complete-BOrI10UY.mjs.map +0 -1
- package/dist/setup-nonce-0XTBLTsX.mjs +0 -25
- package/dist/setup-nonce-0XTBLTsX.mjs.map +0 -1
- package/dist/single-flight-cache-B5O2qhO1.mjs +0 -104
- package/dist/single-flight-cache-B5O2qhO1.mjs.map +0 -1
- package/dist/site-settings-B7vGFRDT.mjs +0 -50
- package/dist/site-settings-B7vGFRDT.mjs.map +0 -1
- package/dist/site-url-wEYRMHBv.mjs +0 -16
- package/dist/site-url-wEYRMHBv.mjs.map +0 -1
- package/dist/snapshot-W36KbLmc.mjs +0 -414
- package/dist/snapshot-W36KbLmc.mjs.map +0 -1
- package/dist/ssrf-CRJ-xom5.mjs +0 -406
- package/dist/ssrf-CRJ-xom5.mjs.map +0 -1
- package/dist/stage-DA0NrTRZ.mjs +0 -662
- package/dist/stage-DA0NrTRZ.mjs.map +0 -1
- package/dist/staged-Bw5eHbKS.mjs +0 -686
- package/dist/staged-Bw5eHbKS.mjs.map +0 -1
- package/dist/state-BTlprvUF.mjs +0 -153
- package/dist/state-BTlprvUF.mjs.map +0 -1
- package/dist/status-C6IrSLMT.mjs +0 -30
- package/dist/status-C6IrSLMT.mjs.map +0 -1
- package/dist/storage-query-CdVF2bng.d.mts +0 -1614
- package/dist/storage-query-CdVF2bng.d.mts.map +0 -1
- package/dist/tar-BGOZARjy.mjs +0 -449
- package/dist/tar-BGOZARjy.mjs.map +0 -1
- package/dist/target-YhYH_0uc.mjs +0 -27
- package/dist/target-YhYH_0uc.mjs.map +0 -1
- package/dist/taxonomies-DK_XBrmT.mjs +0 -697
- package/dist/taxonomies-DK_XBrmT.mjs.map +0 -1
- package/dist/taxonomies-S1M3rUC0.mjs +0 -939
- package/dist/taxonomies-S1M3rUC0.mjs.map +0 -1
- package/dist/taxonomy-BesdHIwi.mjs +0 -525
- package/dist/taxonomy-BesdHIwi.mjs.map +0 -1
- package/dist/tokens-B_ffPF1q.mjs +0 -171
- package/dist/tokens-B_ffPF1q.mjs.map +0 -1
- package/dist/transfer-9fVSxyrV.mjs +0 -166
- package/dist/transfer-9fVSxyrV.mjs.map +0 -1
- package/dist/transfer-B7LUTaYD.mjs +0 -8855
- package/dist/transfer-B7LUTaYD.mjs.map +0 -1
- package/dist/transfer-download-BdNq4VWN.mjs +0 -33
- package/dist/transfer-download-BdNq4VWN.mjs.map +0 -1
- package/dist/transformations-BtQdvyly.mjs +0 -196
- package/dist/transformations-BtQdvyly.mjs.map +0 -1
- package/dist/transport-CriYXY1c.mjs +0 -136
- package/dist/transport-CriYXY1c.mjs.map +0 -1
- package/dist/transport-SnhS6xku.d.mts +0 -42
- package/dist/transport-SnhS6xku.d.mts.map +0 -1
- package/dist/trusted-proxy-C0eHXPd-.mjs +0 -51
- package/dist/trusted-proxy-C0eHXPd-.mjs.map +0 -1
- package/dist/turnstile-BNPrWd1e.mjs +0 -53
- package/dist/turnstile-BNPrWd1e.mjs.map +0 -1
- package/dist/types-B8sF_kE5.d.mts +0 -287
- package/dist/types-B8sF_kE5.d.mts.map +0 -1
- package/dist/types-BYVIYOlD.d.mts +0 -1720
- package/dist/types-BYVIYOlD.d.mts.map +0 -1
- package/dist/types-Bs4bi95j.d.mts +0 -374
- package/dist/types-Bs4bi95j.d.mts.map +0 -1
- package/dist/types-CGuODCZi.d.mts +0 -198
- package/dist/types-CGuODCZi.d.mts.map +0 -1
- package/dist/types-CVsmpTcU.mjs +0 -18
- package/dist/types-CVsmpTcU.mjs.map +0 -1
- package/dist/types-ClFEExxn.mjs +0 -37
- package/dist/types-ClFEExxn.mjs.map +0 -1
- package/dist/types-D994zUWB.d.mts +0 -85
- package/dist/types-D994zUWB.d.mts.map +0 -1
- package/dist/types-DAj1ByJQ.d.mts +0 -125
- package/dist/types-DAj1ByJQ.d.mts.map +0 -1
- package/dist/types-Dlv6esp4.mjs +0 -77
- package/dist/types-Dlv6esp4.mjs.map +0 -1
- package/dist/types-Dr1LVwL7.d.mts +0 -363
- package/dist/types-Dr1LVwL7.d.mts.map +0 -1
- package/dist/types-MN9bOQ1g.d.mts +0 -198
- package/dist/types-MN9bOQ1g.d.mts.map +0 -1
- package/dist/types-d2Szb1oz.mjs +0 -16
- package/dist/types-d2Szb1oz.mjs.map +0 -1
- package/dist/types-ibtP7GEA.d.mts +0 -896
- package/dist/types-ibtP7GEA.d.mts.map +0 -1
- package/dist/types-j6MBDjlZ.mjs +0 -103
- package/dist/types-j6MBDjlZ.mjs.map +0 -1
- package/dist/update-check-D8No-E5s.mjs +0 -161
- package/dist/update-check-D8No-E5s.mjs.map +0 -1
- package/dist/upload-attempts-BodUoFBu.mjs +0 -32
- package/dist/upload-attempts-BodUoFBu.mjs.map +0 -1
- package/dist/url-pattern-DGAG6ZP2.mjs +0 -41
- package/dist/url-pattern-DGAG6ZP2.mjs.map +0 -1
- package/dist/user-BOvuF1sQ.mjs +0 -171
- package/dist/user-BOvuF1sQ.mjs.map +0 -1
- package/dist/utils-Dr01wRKt.mjs +0 -439
- package/dist/utils-Dr01wRKt.mjs.map +0 -1
- package/dist/validate-BttYU7NK.mjs +0 -516
- package/dist/validate-BttYU7NK.mjs.map +0 -1
- package/dist/validate-Df09inbC.d.mts +0 -468
- package/dist/validate-Df09inbC.d.mts.map +0 -1
- package/dist/validation-DH2WRwWO.mjs +0 -219
- package/dist/validation-DH2WRwWO.mjs.map +0 -1
- package/dist/version-BbygH8CT.mjs +0 -7
- package/dist/version-BbygH8CT.mjs.map +0 -1
- package/dist/version-CseoDDOd.mjs +0 -9
- package/dist/version-CseoDDOd.mjs.map +0 -1
- package/dist/virtual-modules-82GlnQyG.mjs +0 -516
- package/dist/virtual-modules-82GlnQyG.mjs.map +0 -1
- package/dist/widgets-DMAgGcQt.mjs +0 -126
- package/dist/widgets-DMAgGcQt.mjs.map +0 -1
- package/dist/wxr-taxonomies-Bi5kFSxQ.mjs +0 -453
- package/dist/wxr-taxonomies-Bi5kFSxQ.mjs.map +0 -1
- package/dist/wxr-taxonomies-y_FpYlDn.d.mts +0 -34
- package/dist/wxr-taxonomies-y_FpYlDn.d.mts.map +0 -1
- package/dist/zod-generator-DnfG5sGQ.mjs +0 -424
- package/dist/zod-generator-DnfG5sGQ.mjs.map +0 -1
- /package/dist/{api-tokens-B4COohsb.mjs → api-tokens-BLz2MtQs.mjs} +0 -0
- /package/dist/{ssrf-sC4_5rxm.mjs → ssrf-tA45vIPX.mjs} +0 -0
|
@@ -1,659 +0,0 @@
|
|
|
1
|
-
import { a as UNSUPPORTED_AUTH_MESSAGE, i as verificationError, n as multihashFromBlobCid, o as unsupportedAuthDetails, r as verifyMultihash } from "./checksum-BSIhEAYW.mjs";
|
|
2
|
-
import { i as resolveAndValidateExternalUrlTarget, t as SsrfError } from "./ssrf-CRJ-xom5.mjs";
|
|
3
|
-
import { RECORD_SCOPED_BLOB_CACHE_TYPE } from "@emdash-cms/registry-lexicons";
|
|
4
|
-
|
|
5
|
-
//#region ../registry-verification/dist/fetch-B66dZAfm.js
|
|
6
|
-
const DIGITS = /^\d+$/;
|
|
7
|
-
const IPV4_LITERAL = /^\d{1,3}(?:\.\d{1,3}){3}$/;
|
|
8
|
-
const IPV4_PART = /^\d{1,3}$/;
|
|
9
|
-
const IPV6_PART = /^[0-9a-f]{1,4}$/i;
|
|
10
|
-
const TRAILING_DOT$1 = /\.+$/;
|
|
11
|
-
const DEFAULT_FETCH_LIMITS = {
|
|
12
|
-
headerTimeoutMs: 1e4,
|
|
13
|
-
totalTimeoutMs: 3e4,
|
|
14
|
-
maxBytes: 25 * 1024 * 1024,
|
|
15
|
-
maxRedirects: 3
|
|
16
|
-
};
|
|
17
|
-
async function fetchVerifiedResource(value, options) {
|
|
18
|
-
const limits = {
|
|
19
|
-
headerTimeoutMs: options.headerTimeoutMs ?? DEFAULT_FETCH_LIMITS.headerTimeoutMs,
|
|
20
|
-
totalTimeoutMs: options.totalTimeoutMs ?? DEFAULT_FETCH_LIMITS.totalTimeoutMs,
|
|
21
|
-
maxBytes: options.maxBytes ?? DEFAULT_FETCH_LIMITS.maxBytes,
|
|
22
|
-
maxRedirects: options.maxRedirects ?? DEFAULT_FETCH_LIMITS.maxRedirects
|
|
23
|
-
};
|
|
24
|
-
if (!areValidLimits(limits)) return verificationError("INVALID_URL", "Fetch limits must be positive integers.");
|
|
25
|
-
const startedAt = Date.now();
|
|
26
|
-
let currentUrl = parseAndValidateUrl(value, void 0, options.allowHttpLocalhost === true);
|
|
27
|
-
if (!currentUrl.success) return currentUrl;
|
|
28
|
-
for (let redirects = 0;; redirects += 1) {
|
|
29
|
-
const remaining = limits.totalTimeoutMs - (Date.now() - startedAt);
|
|
30
|
-
if (remaining <= 0) return verificationError("RESOURCE_TIMEOUT", "The resource fetch exceeded its total timeout.");
|
|
31
|
-
const host = isAllowedLoopback(currentUrl.value, options.allowHttpLocalhost === true) ? {
|
|
32
|
-
success: true,
|
|
33
|
-
value: true
|
|
34
|
-
} : await validateHost(currentUrl.value, options.resolveHostname, remaining);
|
|
35
|
-
if (!host.success) return host;
|
|
36
|
-
const remainingAfterResolution = limits.totalTimeoutMs - (Date.now() - startedAt);
|
|
37
|
-
if (remainingAfterResolution <= 0) return verificationError("RESOURCE_TIMEOUT", "The resource fetch exceeded its total timeout.");
|
|
38
|
-
const response = await fetchResponse(options.fetch, currentUrl.value, Math.min(remainingAfterResolution, limits.headerTimeoutMs));
|
|
39
|
-
if (!response.success) return response;
|
|
40
|
-
if (isRedirect(response.value.status)) {
|
|
41
|
-
if (redirects >= limits.maxRedirects) return verificationError("REDIRECT_LIMIT_EXCEEDED", "The resource exceeded the redirect limit.");
|
|
42
|
-
const location = response.value.headers.get("location");
|
|
43
|
-
if (location === null) return verificationError("REDIRECT_LOCATION_MISSING", "The redirect response has no location header.");
|
|
44
|
-
currentUrl = parseAndValidateUrl(location, currentUrl.value, options.allowHttpLocalhost === true);
|
|
45
|
-
if (!currentUrl.success) return currentUrl;
|
|
46
|
-
continue;
|
|
47
|
-
}
|
|
48
|
-
if (!response.value.ok && !options.allowedStatuses?.includes(response.value.status)) return verificationError("RESOURCE_STATUS_ERROR", `The resource returned HTTP ${response.value.status}.`);
|
|
49
|
-
const contentLength = response.value.headers.get("content-length");
|
|
50
|
-
if (contentLength !== null && (!DIGITS.test(contentLength) || Number(contentLength) > limits.maxBytes)) return verificationError("RESOURCE_SIZE_EXCEEDED", "The resource exceeds the byte limit.");
|
|
51
|
-
const bytes = await readResponse(response.value, limits.maxBytes, startedAt, limits.totalTimeoutMs);
|
|
52
|
-
if (!bytes.success) return bytes;
|
|
53
|
-
return {
|
|
54
|
-
success: true,
|
|
55
|
-
value: {
|
|
56
|
-
bytes: bytes.value,
|
|
57
|
-
url: currentUrl.value,
|
|
58
|
-
status: response.value.status,
|
|
59
|
-
headers: response.value.headers
|
|
60
|
-
}
|
|
61
|
-
};
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
function parseAndValidateUrl(value, base, allowHttpLocalhost = false) {
|
|
65
|
-
let url;
|
|
66
|
-
try {
|
|
67
|
-
url = new URL(value, base);
|
|
68
|
-
} catch {
|
|
69
|
-
return verificationError("INVALID_URL", "The resource URL is invalid.");
|
|
70
|
-
}
|
|
71
|
-
if (url.protocol !== "https:" && !isAllowedLoopback(url, allowHttpLocalhost) || url.username !== "" || url.password !== "") return verificationError("INVALID_URL", "Resource URLs must use HTTPS and cannot include credentials.");
|
|
72
|
-
if (!isAllowedLoopback(url, allowHttpLocalhost) && (isIpLiteral(url.hostname) || isLocalHostname(url.hostname))) return verificationError("HOST_REJECTED", "The resource host is not permitted.");
|
|
73
|
-
return {
|
|
74
|
-
success: true,
|
|
75
|
-
value: url
|
|
76
|
-
};
|
|
77
|
-
}
|
|
78
|
-
function isAllowedLoopback(url, enabled) {
|
|
79
|
-
if (!enabled || url.protocol !== "http:" && url.protocol !== "https:") return false;
|
|
80
|
-
const hostname = url.hostname.toLowerCase().replace(TRAILING_DOT$1, "");
|
|
81
|
-
return hostname === "localhost" || hostname.endsWith(".localhost") || hostname === "127.0.0.1" || hostname === "[::1]" || hostname === "::1";
|
|
82
|
-
}
|
|
83
|
-
async function validateHost(url, resolver, timeoutMs) {
|
|
84
|
-
try {
|
|
85
|
-
const addresses = await withTimeout(Promise.resolve().then(() => resolver(url.hostname)), timeoutMs);
|
|
86
|
-
if (addresses.length === 0 || addresses.some(isForbiddenAddress)) return verificationError("HOST_REJECTED", "The resource host resolved to a forbidden address.");
|
|
87
|
-
return {
|
|
88
|
-
success: true,
|
|
89
|
-
value: true
|
|
90
|
-
};
|
|
91
|
-
} catch (error) {
|
|
92
|
-
if (isAbortError(error)) return verificationError("RESOURCE_TIMEOUT", "The resource fetch exceeded its total timeout.");
|
|
93
|
-
return verificationError("HOST_REJECTED", "The resource host could not be validated.");
|
|
94
|
-
}
|
|
95
|
-
}
|
|
96
|
-
async function fetchResponse(fetchImplementation, url, timeoutMs) {
|
|
97
|
-
const controller = new AbortController();
|
|
98
|
-
try {
|
|
99
|
-
return {
|
|
100
|
-
success: true,
|
|
101
|
-
value: await withTimeout(Promise.resolve().then(() => fetchImplementation(url, {
|
|
102
|
-
method: "GET",
|
|
103
|
-
redirect: "manual",
|
|
104
|
-
signal: controller.signal
|
|
105
|
-
})), timeoutMs, () => controller.abort())
|
|
106
|
-
};
|
|
107
|
-
} catch (error) {
|
|
108
|
-
if (controller.signal.aborted || isAbortError(error)) return verificationError("RESOURCE_TIMEOUT", "The resource response headers timed out.");
|
|
109
|
-
return verificationError("FETCH_FAILED", "The resource request failed.");
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
async function readResponse(response, maximumBytes, startedAt, totalTimeoutMs) {
|
|
113
|
-
if (response.body === null) return {
|
|
114
|
-
success: true,
|
|
115
|
-
value: new Uint8Array()
|
|
116
|
-
};
|
|
117
|
-
const reader = response.body.getReader();
|
|
118
|
-
const chunks = [];
|
|
119
|
-
let length = 0;
|
|
120
|
-
try {
|
|
121
|
-
for (;;) {
|
|
122
|
-
const remaining = totalTimeoutMs - (Date.now() - startedAt);
|
|
123
|
-
if (remaining <= 0) {
|
|
124
|
-
await reader.cancel();
|
|
125
|
-
return verificationError("RESOURCE_TIMEOUT", "The resource fetch exceeded its total timeout.");
|
|
126
|
-
}
|
|
127
|
-
const chunk = await readWithTimeout(reader, remaining);
|
|
128
|
-
if (!chunk.success) {
|
|
129
|
-
await reader.cancel();
|
|
130
|
-
return chunk;
|
|
131
|
-
}
|
|
132
|
-
if (chunk.value.done) break;
|
|
133
|
-
const value = chunk.value.value;
|
|
134
|
-
length += value.length;
|
|
135
|
-
if (length > maximumBytes) {
|
|
136
|
-
await reader.cancel();
|
|
137
|
-
return verificationError("RESOURCE_SIZE_EXCEEDED", "The resource exceeds the byte limit.");
|
|
138
|
-
}
|
|
139
|
-
chunks.push(value);
|
|
140
|
-
}
|
|
141
|
-
} catch {
|
|
142
|
-
return verificationError("FETCH_FAILED", "The resource response could not be read.");
|
|
143
|
-
} finally {
|
|
144
|
-
reader.releaseLock();
|
|
145
|
-
}
|
|
146
|
-
const output = new Uint8Array(length);
|
|
147
|
-
let offset = 0;
|
|
148
|
-
for (const chunk of chunks) {
|
|
149
|
-
output.set(chunk, offset);
|
|
150
|
-
offset += chunk.length;
|
|
151
|
-
}
|
|
152
|
-
return {
|
|
153
|
-
success: true,
|
|
154
|
-
value: output
|
|
155
|
-
};
|
|
156
|
-
}
|
|
157
|
-
async function readWithTimeout(reader, timeoutMs) {
|
|
158
|
-
try {
|
|
159
|
-
return {
|
|
160
|
-
success: true,
|
|
161
|
-
value: await withTimeout(Promise.resolve().then(() => reader.read()), timeoutMs)
|
|
162
|
-
};
|
|
163
|
-
} catch (error) {
|
|
164
|
-
if (isAbortError(error)) return verificationError("RESOURCE_TIMEOUT", "The resource fetch exceeded its total timeout.");
|
|
165
|
-
return verificationError("FETCH_FAILED", "The resource response could not be read.");
|
|
166
|
-
}
|
|
167
|
-
}
|
|
168
|
-
/**
|
|
169
|
-
* Every operation has both fulfillment and rejection handlers, so an operation
|
|
170
|
-
* that loses the timeout race cannot later become an unhandled rejection.
|
|
171
|
-
*/
|
|
172
|
-
function withTimeout(operation, timeoutMs, onTimeout) {
|
|
173
|
-
return new Promise((resolve, reject) => {
|
|
174
|
-
let settled = false;
|
|
175
|
-
const timeout = setTimeout(() => {
|
|
176
|
-
if (settled) return;
|
|
177
|
-
settled = true;
|
|
178
|
-
onTimeout?.();
|
|
179
|
-
reject(new DOMException("Timed out", "AbortError"));
|
|
180
|
-
}, timeoutMs);
|
|
181
|
-
operation.then((value) => {
|
|
182
|
-
if (settled) return void 0;
|
|
183
|
-
settled = true;
|
|
184
|
-
clearTimeout(timeout);
|
|
185
|
-
resolve(value);
|
|
186
|
-
}, (error) => {
|
|
187
|
-
if (settled) return void 0;
|
|
188
|
-
settled = true;
|
|
189
|
-
clearTimeout(timeout);
|
|
190
|
-
reject(error);
|
|
191
|
-
});
|
|
192
|
-
});
|
|
193
|
-
}
|
|
194
|
-
function areValidLimits(limits) {
|
|
195
|
-
return Object.values(limits).every((value) => Number.isSafeInteger(value) && value > 0);
|
|
196
|
-
}
|
|
197
|
-
function isRedirect(status) {
|
|
198
|
-
return status === 301 || status === 302 || status === 303 || status === 307 || status === 308;
|
|
199
|
-
}
|
|
200
|
-
function isAbortError(error) {
|
|
201
|
-
return error instanceof DOMException && error.name === "AbortError";
|
|
202
|
-
}
|
|
203
|
-
function isIpLiteral(hostname) {
|
|
204
|
-
return IPV4_LITERAL.test(hostname) || hostname.includes(":");
|
|
205
|
-
}
|
|
206
|
-
function isLocalHostname(hostname) {
|
|
207
|
-
const normalized = hostname.toLowerCase();
|
|
208
|
-
return normalized === "localhost" || normalized.endsWith(".localhost") || normalized.endsWith(".local") || normalized.endsWith(".internal");
|
|
209
|
-
}
|
|
210
|
-
function isForbiddenAddress(address) {
|
|
211
|
-
const ipv4 = parseIpv4(address);
|
|
212
|
-
if (ipv4 !== null) {
|
|
213
|
-
const [a, b] = ipv4;
|
|
214
|
-
return a === 0 || a === 10 || a === 127 || a === 100 && b >= 64 && b <= 127 || a === 169 && b === 254 || a === 172 && b >= 16 && b <= 31 || a === 192 && (b === 0 || b === 168) || a === 198 && (b === 18 || b === 19) || a >= 224;
|
|
215
|
-
}
|
|
216
|
-
const ipv6 = parseIpv6(address);
|
|
217
|
-
if (ipv6 === null) return true;
|
|
218
|
-
const first = ipv6[0];
|
|
219
|
-
const isUnspecified = ipv6.every((part) => part === 0);
|
|
220
|
-
const isLoopback = ipv6.slice(0, 7).every((part) => part === 0) && ipv6[7] === 1;
|
|
221
|
-
const isPrivate = (first & 65024) === 64512;
|
|
222
|
-
const isLinkLocal = (first & 65472) === 65152;
|
|
223
|
-
const isMulticast = (first & 65280) === 65280;
|
|
224
|
-
if (ipv6.slice(0, 5).every((part) => part === 0) && ipv6[5] === 65535) return isForbiddenAddress(`${ipv6[6] >>> 8}.${ipv6[6] & 255}.${ipv6[7] >>> 8}.${ipv6[7] & 255}`);
|
|
225
|
-
return isUnspecified || isLoopback || isPrivate || isLinkLocal || isMulticast;
|
|
226
|
-
}
|
|
227
|
-
function parseIpv4(value) {
|
|
228
|
-
const parts = value.split(".");
|
|
229
|
-
if (parts.length !== 4) return null;
|
|
230
|
-
const numbers = parts.map((part) => IPV4_PART.test(part) ? Number(part) : NaN);
|
|
231
|
-
if (numbers.some((part) => !Number.isInteger(part) || part < 0 || part > 255)) return null;
|
|
232
|
-
return [
|
|
233
|
-
numbers[0],
|
|
234
|
-
numbers[1],
|
|
235
|
-
numbers[2],
|
|
236
|
-
numbers[3]
|
|
237
|
-
];
|
|
238
|
-
}
|
|
239
|
-
function parseIpv6(value) {
|
|
240
|
-
if (value.includes(":::") || value.split("::").length > 2) return null;
|
|
241
|
-
const [before = "", after = ""] = value.split("::");
|
|
242
|
-
const head = before === "" ? [] : before.split(":");
|
|
243
|
-
const tail = after === "" ? [] : after.split(":");
|
|
244
|
-
const parts = [...head, ...tail];
|
|
245
|
-
if (parts.some((part) => !IPV6_PART.test(part)) || parts.length > 8) return null;
|
|
246
|
-
if (!value.includes("::") && parts.length !== 8) return null;
|
|
247
|
-
const zeroes = value.includes("::") ? 8 - parts.length : 0;
|
|
248
|
-
return [
|
|
249
|
-
...head,
|
|
250
|
-
...Array.from({ length: zeroes }).fill("0"),
|
|
251
|
-
...tail
|
|
252
|
-
].map((part) => Number.parseInt(part, 16));
|
|
253
|
-
}
|
|
254
|
-
|
|
255
|
-
//#endregion
|
|
256
|
-
//#region ../registry-verification/dist/artifact.js
|
|
257
|
-
const DID_DOCUMENT_MAX_BYTES = 256 * 1024;
|
|
258
|
-
const PLC_DID_PATTERN = /^did:plc:[a-z2-7]{24}$/;
|
|
259
|
-
const CID_PATTERN = /^b[a-z2-7]+$/;
|
|
260
|
-
const UNSAFE_PATH_SEGMENT = /[/\\?#]/;
|
|
261
|
-
async function fetchReleaseArtifact(input, options) {
|
|
262
|
-
const deadline = Date.now() + (options.totalTimeoutMs ?? DEFAULT_FETCH_LIMITS.totalTimeoutMs);
|
|
263
|
-
const { artifact } = input;
|
|
264
|
-
if (!artifact.blob && !artifact.url) return verificationError("RELEASE_ARTIFACT_SOURCE_MISSING", "The release artifact must provide a blob or URL.");
|
|
265
|
-
if (artifact.requiresAuth === true || input.auth !== void 0) return unsupportedAuth(input.auth);
|
|
266
|
-
const blobCid = modernBlobCid(artifact.blob);
|
|
267
|
-
const blobMetadata = blobCid && artifact.blob && "ref" in artifact.blob ? artifact.blob : void 0;
|
|
268
|
-
if (artifact.blob && !blobCid) return verificationError("BLOB_REF_INVALID", "Legacy blob references are not supported.");
|
|
269
|
-
if (blobCid) {
|
|
270
|
-
const expected = multihashFromBlobCid(blobCid);
|
|
271
|
-
if (!expected.success) return expected;
|
|
272
|
-
if (expected.value !== artifact.checksum) return verificationError("CHECKSUM_MISMATCH", "The artifact checksum does not match its blob reference CID.");
|
|
273
|
-
}
|
|
274
|
-
let lastError;
|
|
275
|
-
for (const cache of input.artifactCaches ?? []) {
|
|
276
|
-
const serviceEndpoint = recordScopedCacheEndpoint(cache);
|
|
277
|
-
if (!serviceEndpoint || !blobCid) continue;
|
|
278
|
-
const cacheUrl = recordScopedBlobCacheUrl(serviceEndpoint, input.record, blobCid);
|
|
279
|
-
if (!cacheUrl.success) {
|
|
280
|
-
lastError = cacheUrl.error;
|
|
281
|
-
continue;
|
|
282
|
-
}
|
|
283
|
-
const attemptOptions = withinDeadline(options, deadline);
|
|
284
|
-
if (!attemptOptions) return timedOut();
|
|
285
|
-
const result = await fetchAndVerify("artifact-cache", cacheUrl.value, artifact.checksum, withBlobSizeLimit(attemptOptions, blobMetadata), blobMetadata);
|
|
286
|
-
if (result.success) return result;
|
|
287
|
-
lastError = result.error;
|
|
288
|
-
}
|
|
289
|
-
if (blobCid) {
|
|
290
|
-
const resolutionOptions = withinDeadline(options, deadline);
|
|
291
|
-
if (!resolutionOptions) return timedOut();
|
|
292
|
-
const pds = input.pdsEndpoint ? {
|
|
293
|
-
success: true,
|
|
294
|
-
value: input.pdsEndpoint
|
|
295
|
-
} : await resolvePublisherPdsEndpoint(input.record.did, resolutionOptions);
|
|
296
|
-
if (pds.success) {
|
|
297
|
-
const url = blobUrl(pds.value, input.record.did, blobCid);
|
|
298
|
-
if (url.success) {
|
|
299
|
-
const attemptOptions = withinDeadline(options, deadline);
|
|
300
|
-
if (!attemptOptions) return timedOut();
|
|
301
|
-
const result = await fetchAndVerify("blob", url.value, artifact.checksum, withBlobSizeLimit(attemptOptions, blobMetadata), blobMetadata);
|
|
302
|
-
if (result.success) return result;
|
|
303
|
-
lastError = result.error;
|
|
304
|
-
} else lastError = url.error;
|
|
305
|
-
} else lastError = pds.error;
|
|
306
|
-
}
|
|
307
|
-
if (artifact.url) {
|
|
308
|
-
const attemptOptions = withinDeadline(options, deadline);
|
|
309
|
-
if (!attemptOptions) return timedOut();
|
|
310
|
-
const result = await fetchAndVerify("url", artifact.url, artifact.checksum, withBlobSizeLimit(attemptOptions, blobMetadata), blobMetadata);
|
|
311
|
-
if (result.success) return result;
|
|
312
|
-
lastError = result.error;
|
|
313
|
-
}
|
|
314
|
-
return lastError ? {
|
|
315
|
-
success: false,
|
|
316
|
-
error: lastError
|
|
317
|
-
} : verificationError("FETCH_FAILED", "The release artifact could not be fetched.");
|
|
318
|
-
}
|
|
319
|
-
function recordScopedBlobCacheUrl(serviceEndpoint, record, blobCid) {
|
|
320
|
-
try {
|
|
321
|
-
const endpoint = new URL(serviceEndpoint);
|
|
322
|
-
if (endpoint.protocol !== "https:" || endpoint.username || endpoint.password || endpoint.pathname !== "/" || endpoint.search || endpoint.hash) throw new Error();
|
|
323
|
-
const segments = [
|
|
324
|
-
"r",
|
|
325
|
-
record.did,
|
|
326
|
-
record.collection,
|
|
327
|
-
record.rkey,
|
|
328
|
-
record.cid,
|
|
329
|
-
blobCid
|
|
330
|
-
];
|
|
331
|
-
if (!CID_PATTERN.test(record.cid) || !CID_PATTERN.test(blobCid) || segments.some((segment) => !isSafePathSegment(segment))) throw new Error();
|
|
332
|
-
return {
|
|
333
|
-
success: true,
|
|
334
|
-
value: new URL(segments.join("/"), endpoint)
|
|
335
|
-
};
|
|
336
|
-
} catch {
|
|
337
|
-
return verificationError("INVALID_URL", "The record-scoped blob cache endpoint is invalid.");
|
|
338
|
-
}
|
|
339
|
-
}
|
|
340
|
-
function recordScopedImageCacheUrl(serviceEndpoint, preset, record, blobCid) {
|
|
341
|
-
const raw = recordScopedBlobCacheUrl(serviceEndpoint, record, blobCid);
|
|
342
|
-
if (!raw.success) return raw;
|
|
343
|
-
const url = new URL(raw.value);
|
|
344
|
-
url.pathname = `/img/${preset}${url.pathname}`;
|
|
345
|
-
return {
|
|
346
|
-
success: true,
|
|
347
|
-
value: url
|
|
348
|
-
};
|
|
349
|
-
}
|
|
350
|
-
async function resolvePublisherPdsEndpoint(publisherDid, options) {
|
|
351
|
-
const documentUrl = didDocumentUrl(publisherDid);
|
|
352
|
-
if (!documentUrl) return verificationError("PDS_RESOLUTION_FAILED", "The publisher DID is not supported.");
|
|
353
|
-
const fetched = await fetchVerifiedResource(documentUrl, {
|
|
354
|
-
...options,
|
|
355
|
-
maxBytes: DID_DOCUMENT_MAX_BYTES
|
|
356
|
-
});
|
|
357
|
-
if (!fetched.success) return verificationError("PDS_RESOLUTION_FAILED", "The publisher DID document could not be fetched.");
|
|
358
|
-
let document;
|
|
359
|
-
try {
|
|
360
|
-
document = JSON.parse(new TextDecoder().decode(fetched.value.bytes));
|
|
361
|
-
} catch {
|
|
362
|
-
return verificationError("PDS_RESOLUTION_FAILED", "The publisher DID document is malformed.");
|
|
363
|
-
}
|
|
364
|
-
if (!isRecord(document) || document.id !== publisherDid || !Array.isArray(document.service)) return verificationError("PDS_RESOLUTION_FAILED", "The publisher DID document has no valid PDS service.");
|
|
365
|
-
const service = document.service.find((value) => isRecord(value) && (value.id === `${publisherDid}#atproto_pds` || value.id === "#atproto_pds") && value.type === "AtprotoPersonalDataServer" && typeof value.serviceEndpoint === "string");
|
|
366
|
-
if (!isRecord(service) || typeof service.serviceEndpoint !== "string") return verificationError("PDS_RESOLUTION_FAILED", "The publisher DID document has no valid PDS service.");
|
|
367
|
-
try {
|
|
368
|
-
const endpoint = new URL(service.serviceEndpoint);
|
|
369
|
-
if (!(options.allowHttpLocalhost === true && endpoint.protocol === "http:" && (endpoint.hostname === "localhost" || endpoint.hostname === "127.0.0.1")) && endpoint.protocol !== "https:" || endpoint.username || endpoint.password) throw new Error();
|
|
370
|
-
return {
|
|
371
|
-
success: true,
|
|
372
|
-
value: endpoint.href
|
|
373
|
-
};
|
|
374
|
-
} catch {
|
|
375
|
-
return verificationError("PDS_RESOLUTION_FAILED", "The publisher DID document has no valid PDS service.");
|
|
376
|
-
}
|
|
377
|
-
}
|
|
378
|
-
async function fetchAndVerify(source, url, checksum, options, blobMetadata) {
|
|
379
|
-
const fetched = await fetchVerifiedResource(url, options);
|
|
380
|
-
if (!fetched.success) return blobMetadata && fetched.error.code === "RESOURCE_SIZE_EXCEEDED" ? verificationError("BLOB_METADATA_MISMATCH", "The fetched artifact size does not match its signed blob metadata.") : fetched;
|
|
381
|
-
const verified = await verifyMultihash(fetched.value.bytes, checksum);
|
|
382
|
-
if (!verified.success) return verified;
|
|
383
|
-
const contentType = fetched.value.headers.get("content-type")?.split(";", 1)[0]?.trim();
|
|
384
|
-
if (blobMetadata && (fetched.value.bytes.byteLength !== blobMetadata.size || contentType !== void 0 && contentType !== blobMetadata.mimeType)) return verificationError("BLOB_METADATA_MISMATCH", "The fetched artifact does not match its signed blob metadata.");
|
|
385
|
-
return {
|
|
386
|
-
success: true,
|
|
387
|
-
value: {
|
|
388
|
-
bytes: fetched.value.bytes,
|
|
389
|
-
source,
|
|
390
|
-
url: fetched.value.url
|
|
391
|
-
}
|
|
392
|
-
};
|
|
393
|
-
}
|
|
394
|
-
function withBlobSizeLimit(options, blobMetadata) {
|
|
395
|
-
if (!blobMetadata) return options;
|
|
396
|
-
return {
|
|
397
|
-
...options,
|
|
398
|
-
maxBytes: Math.min(options.maxBytes ?? DEFAULT_FETCH_LIMITS.maxBytes, blobMetadata.size)
|
|
399
|
-
};
|
|
400
|
-
}
|
|
401
|
-
function blobUrl(pdsEndpoint, publisherDid, cid) {
|
|
402
|
-
try {
|
|
403
|
-
const url = new URL("/xrpc/com.atproto.sync.getBlob", pdsEndpoint);
|
|
404
|
-
url.searchParams.set("did", publisherDid);
|
|
405
|
-
url.searchParams.set("cid", cid);
|
|
406
|
-
return {
|
|
407
|
-
success: true,
|
|
408
|
-
value: url
|
|
409
|
-
};
|
|
410
|
-
} catch {
|
|
411
|
-
return verificationError("PDS_RESOLUTION_FAILED", "The publisher PDS endpoint is invalid.");
|
|
412
|
-
}
|
|
413
|
-
}
|
|
414
|
-
function didDocumentUrl(did) {
|
|
415
|
-
if (PLC_DID_PATTERN.test(did)) return `https://plc.directory/${encodeURIComponent(did)}`;
|
|
416
|
-
if (!did.startsWith("did:web:")) return null;
|
|
417
|
-
try {
|
|
418
|
-
const parts = did.slice(8).split(":").map(decodeURIComponent);
|
|
419
|
-
const host = parts.shift();
|
|
420
|
-
if (!host || parts.some((part) => part === "" || part === "." || part === "..")) return null;
|
|
421
|
-
const path = parts.length === 0 ? "/.well-known/did.json" : `/${parts.join("/")}/did.json`;
|
|
422
|
-
return new URL(path, `https://${host}`).href;
|
|
423
|
-
} catch {
|
|
424
|
-
return null;
|
|
425
|
-
}
|
|
426
|
-
}
|
|
427
|
-
function unsupportedAuth(auth) {
|
|
428
|
-
return verificationError("AUTH_METHOD_UNSUPPORTED", UNSUPPORTED_AUTH_MESSAGE, unsupportedAuthDetails(auth));
|
|
429
|
-
}
|
|
430
|
-
function withinDeadline(options, deadline) {
|
|
431
|
-
const remaining = deadline - Date.now();
|
|
432
|
-
if (remaining <= 0) return null;
|
|
433
|
-
return {
|
|
434
|
-
...options,
|
|
435
|
-
totalTimeoutMs: remaining
|
|
436
|
-
};
|
|
437
|
-
}
|
|
438
|
-
function timedOut() {
|
|
439
|
-
return verificationError("RESOURCE_TIMEOUT", "Artifact retrieval exceeded its total timeout.");
|
|
440
|
-
}
|
|
441
|
-
function isRecord(value) {
|
|
442
|
-
return value !== null && typeof value === "object" && !Array.isArray(value);
|
|
443
|
-
}
|
|
444
|
-
function modernBlobCid(blob) {
|
|
445
|
-
if (!blob || !("ref" in blob) || typeof blob.ref?.$link !== "string") return null;
|
|
446
|
-
return blob.ref.$link;
|
|
447
|
-
}
|
|
448
|
-
function recordScopedCacheEndpoint(value) {
|
|
449
|
-
if (!isRecord(value) || value.$type !== RECORD_SCOPED_BLOB_CACHE_TYPE) return null;
|
|
450
|
-
return typeof value.serviceEndpoint === "string" ? value.serviceEndpoint : null;
|
|
451
|
-
}
|
|
452
|
-
function isSafePathSegment(value) {
|
|
453
|
-
if (value.length === 0 || UNSAFE_PATH_SEGMENT.test(value)) return false;
|
|
454
|
-
for (const character of value) {
|
|
455
|
-
const codePoint = character.codePointAt(0);
|
|
456
|
-
if (codePoint !== void 0 && (codePoint <= 31 || codePoint === 127)) return false;
|
|
457
|
-
}
|
|
458
|
-
return true;
|
|
459
|
-
}
|
|
460
|
-
|
|
461
|
-
//#endregion
|
|
462
|
-
//#region src/registry/artifact-fetch.ts
|
|
463
|
-
const TRAILING_DOT = /\.+$/;
|
|
464
|
-
const LOCALHOST_HOSTNAMES = new Set([
|
|
465
|
-
"localhost",
|
|
466
|
-
"localhost.localdomain",
|
|
467
|
-
"ip6-localhost",
|
|
468
|
-
"ip6-loopback"
|
|
469
|
-
]);
|
|
470
|
-
let defaultTransport = null;
|
|
471
|
-
function isLocalhostHostname(hostname) {
|
|
472
|
-
const normalized = hostname.toLowerCase().replace(TRAILING_DOT, "");
|
|
473
|
-
return LOCALHOST_HOSTNAMES.has(normalized) || normalized.endsWith(".localhost") || normalized === "127.0.0.1" || normalized === "::1" || normalized === "[::1]" || normalized.startsWith("::ffff:127.") || normalized.startsWith("::ffff:7f00:");
|
|
474
|
-
}
|
|
475
|
-
async function resolveSafeArtifactTarget(urlString) {
|
|
476
|
-
let url;
|
|
477
|
-
try {
|
|
478
|
-
url = new URL(urlString);
|
|
479
|
-
} catch {
|
|
480
|
-
throw new Error(`Invalid artifact URL: ${urlString}`);
|
|
481
|
-
}
|
|
482
|
-
if (url.protocol !== "https:" && url.protocol !== "http:") throw new Error(`Artifact URL protocol not allowed: ${url.protocol}`);
|
|
483
|
-
if (url.username || url.password) throw new Error("Artifact URL must not contain embedded credentials");
|
|
484
|
-
const hostname = stripIpv6Brackets(url.hostname.toLowerCase().replace(TRAILING_DOT, ""));
|
|
485
|
-
const localhost = isLocalhostHostname(hostname);
|
|
486
|
-
if (!import.meta.env.DEV) {
|
|
487
|
-
if (url.protocol === "http:") throw new Error("Artifact URL must use https");
|
|
488
|
-
if (localhost) throw new Error(`Artifact URL points to localhost: ${hostname}`);
|
|
489
|
-
} else if (url.protocol === "http:" && !localhost) throw new Error("Artifact URL must use https (http allowed only for localhost in dev)");
|
|
490
|
-
if (localhost) return {
|
|
491
|
-
url,
|
|
492
|
-
addresses: []
|
|
493
|
-
};
|
|
494
|
-
try {
|
|
495
|
-
return await resolveAndValidateExternalUrlTarget(url.href);
|
|
496
|
-
} catch (error) {
|
|
497
|
-
if (error instanceof SsrfError) throw new Error(`Artifact URL rejected: ${error.message}`, { cause: error });
|
|
498
|
-
throw error;
|
|
499
|
-
}
|
|
500
|
-
}
|
|
501
|
-
async function fetchRegistryArtifactUrl(urlString, options) {
|
|
502
|
-
if (!Number.isSafeInteger(options.maxResponseBytes) || options.maxResponseBytes < 0) throw new TypeError("Registry artifact response limit is invalid");
|
|
503
|
-
const target = await resolveSafeArtifactTarget(urlString);
|
|
504
|
-
if (target.addresses.length === 0) return globalThis.fetch(target.url, {
|
|
505
|
-
redirect: "manual",
|
|
506
|
-
signal: options.signal
|
|
507
|
-
});
|
|
508
|
-
const result = await (defaultTransport ?? await createRuntimeRegistryArtifactTransport()).fetch({
|
|
509
|
-
url: target.url,
|
|
510
|
-
allowedAddresses: target.addresses,
|
|
511
|
-
signal: options.signal,
|
|
512
|
-
maxResponseBytes: options.maxResponseBytes
|
|
513
|
-
});
|
|
514
|
-
if (result.connectedAddress !== null && !target.addresses.includes(result.connectedAddress)) {
|
|
515
|
-
await result.response.body?.cancel().catch(() => void 0);
|
|
516
|
-
throw new Error("Registry artifact transport connected outside the validated address set");
|
|
517
|
-
}
|
|
518
|
-
return result.response;
|
|
519
|
-
}
|
|
520
|
-
async function createRuntimeRegistryArtifactTransport() {
|
|
521
|
-
return isCloudflareWorkersRuntime() ? createWorkersRegistryArtifactTransport() : createNodeRegistryArtifactTransport();
|
|
522
|
-
}
|
|
523
|
-
function createWorkersRegistryArtifactTransport(workerFetch = globalThis.fetch) {
|
|
524
|
-
return { async fetch(input) {
|
|
525
|
-
return {
|
|
526
|
-
response: limitResponseBody(await workerFetch(input.url, {
|
|
527
|
-
redirect: "manual",
|
|
528
|
-
signal: input.signal,
|
|
529
|
-
headers: { "Accept-Encoding": "identity" }
|
|
530
|
-
}), input.maxResponseBytes),
|
|
531
|
-
connectedAddress: null
|
|
532
|
-
};
|
|
533
|
-
} };
|
|
534
|
-
}
|
|
535
|
-
function isCloudflareWorkersRuntime() {
|
|
536
|
-
return typeof navigator !== "undefined" && typeof navigator.userAgent === "string" && navigator.userAgent.includes("Cloudflare-Workers");
|
|
537
|
-
}
|
|
538
|
-
function limitResponseBody(response, maxBytes) {
|
|
539
|
-
if (!response.body) return response;
|
|
540
|
-
let received = 0;
|
|
541
|
-
const body = response.body.pipeThrough(new TransformStream({ transform(chunk, controller) {
|
|
542
|
-
received += chunk.byteLength;
|
|
543
|
-
if (received > maxBytes) {
|
|
544
|
-
controller.error(/* @__PURE__ */ new RangeError("Registry artifact response exceeds its byte limit"));
|
|
545
|
-
return;
|
|
546
|
-
}
|
|
547
|
-
controller.enqueue(chunk);
|
|
548
|
-
} }));
|
|
549
|
-
return new Response(body, {
|
|
550
|
-
status: response.status,
|
|
551
|
-
statusText: response.statusText,
|
|
552
|
-
headers: response.headers
|
|
553
|
-
});
|
|
554
|
-
}
|
|
555
|
-
async function createNodeRegistryArtifactTransport(nodeRequest) {
|
|
556
|
-
const request = nodeRequest ?? (await import("node:https")).request;
|
|
557
|
-
return { async fetch(input) {
|
|
558
|
-
let lastError;
|
|
559
|
-
for (const address of input.allowedAddresses) try {
|
|
560
|
-
return {
|
|
561
|
-
response: await new Promise((resolve, reject) => {
|
|
562
|
-
const chunks = [];
|
|
563
|
-
let total = 0;
|
|
564
|
-
const req = request({
|
|
565
|
-
protocol: "https:",
|
|
566
|
-
hostname: stripIpv6Brackets(input.url.hostname),
|
|
567
|
-
port: parseHttpsPort(input.url),
|
|
568
|
-
path: `${input.url.pathname}${input.url.search}`,
|
|
569
|
-
method: "GET",
|
|
570
|
-
agent: false,
|
|
571
|
-
headers: {
|
|
572
|
-
Host: input.url.host,
|
|
573
|
-
Connection: "close",
|
|
574
|
-
"Accept-Encoding": "identity"
|
|
575
|
-
},
|
|
576
|
-
lookup: (_hostname, options, callback) => {
|
|
577
|
-
const family = address.includes(":") ? 6 : 4;
|
|
578
|
-
if (options.all) callback(null, [{
|
|
579
|
-
address,
|
|
580
|
-
family
|
|
581
|
-
}]);
|
|
582
|
-
else callback(null, address, family);
|
|
583
|
-
},
|
|
584
|
-
signal: input.signal
|
|
585
|
-
}, (upstream) => {
|
|
586
|
-
const contentEncoding = upstream.headers["content-encoding"];
|
|
587
|
-
if (contentEncoding && contentEncoding.toLowerCase() !== "identity") {
|
|
588
|
-
upstream.destroy(/* @__PURE__ */ new Error("Registry artifact response content encoding is unsupported"));
|
|
589
|
-
return;
|
|
590
|
-
}
|
|
591
|
-
upstream.on("data", (chunk) => {
|
|
592
|
-
total += chunk.byteLength;
|
|
593
|
-
if (total > input.maxResponseBytes) {
|
|
594
|
-
upstream.destroy(/* @__PURE__ */ new RangeError("Registry artifact response exceeds its byte limit"));
|
|
595
|
-
return;
|
|
596
|
-
}
|
|
597
|
-
chunks.push(new Uint8Array(chunk));
|
|
598
|
-
});
|
|
599
|
-
upstream.once("error", reject);
|
|
600
|
-
upstream.once("end", () => {
|
|
601
|
-
const bytes = concatBytes(chunks, total);
|
|
602
|
-
const headers = new Headers();
|
|
603
|
-
for (let index = 0; index < upstream.rawHeaders.length; index += 2) headers.append(upstream.rawHeaders[index], upstream.rawHeaders[index + 1]);
|
|
604
|
-
resolve(parsedResponseToWebResponse({
|
|
605
|
-
status: upstream.statusCode ?? 502,
|
|
606
|
-
headers,
|
|
607
|
-
body: bytes
|
|
608
|
-
}));
|
|
609
|
-
});
|
|
610
|
-
});
|
|
611
|
-
req.once("error", reject);
|
|
612
|
-
req.end();
|
|
613
|
-
}),
|
|
614
|
-
connectedAddress: address
|
|
615
|
-
};
|
|
616
|
-
} catch (error) {
|
|
617
|
-
if (input.signal.aborted) throw error;
|
|
618
|
-
lastError = error;
|
|
619
|
-
}
|
|
620
|
-
throw new Error("Registry artifact transport could not connect to an approved address", { cause: lastError });
|
|
621
|
-
} };
|
|
622
|
-
}
|
|
623
|
-
function parsedResponseToWebResponse(parsed) {
|
|
624
|
-
const bodyAllowed = ![
|
|
625
|
-
204,
|
|
626
|
-
205,
|
|
627
|
-
304
|
|
628
|
-
].includes(parsed.status);
|
|
629
|
-
let body = null;
|
|
630
|
-
if (bodyAllowed) {
|
|
631
|
-
body = new ArrayBuffer(parsed.body.byteLength);
|
|
632
|
-
new Uint8Array(body).set(parsed.body);
|
|
633
|
-
}
|
|
634
|
-
return new Response(body, {
|
|
635
|
-
status: parsed.status,
|
|
636
|
-
headers: parsed.headers
|
|
637
|
-
});
|
|
638
|
-
}
|
|
639
|
-
function concatBytes(chunks, total) {
|
|
640
|
-
const bytes = new Uint8Array(total);
|
|
641
|
-
let offset = 0;
|
|
642
|
-
for (const chunk of chunks) {
|
|
643
|
-
bytes.set(chunk, offset);
|
|
644
|
-
offset += chunk.byteLength;
|
|
645
|
-
}
|
|
646
|
-
return bytes;
|
|
647
|
-
}
|
|
648
|
-
function parseHttpsPort(url) {
|
|
649
|
-
const port = url.port === "" ? 443 : Number(url.port);
|
|
650
|
-
if (!Number.isSafeInteger(port) || port < 1 || port > 65535) throw new TypeError("Registry artifact HTTPS port is invalid");
|
|
651
|
-
return port;
|
|
652
|
-
}
|
|
653
|
-
function stripIpv6Brackets(hostname) {
|
|
654
|
-
return hostname.startsWith("[") && hostname.endsWith("]") ? hostname.slice(1, -1) : hostname;
|
|
655
|
-
}
|
|
656
|
-
|
|
657
|
-
//#endregion
|
|
658
|
-
export { fetchVerifiedResource as a, resolvePublisherPdsEndpoint as i, fetchReleaseArtifact as n, recordScopedImageCacheUrl as r, fetchRegistryArtifactUrl as t };
|
|
659
|
-
//# sourceMappingURL=artifact-fetch-CGK0DQLj.mjs.map
|