permdock 0.23.0 → 0.25.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/a2a/index.d.ts +4 -4
- package/dist/a2a/index.js +4 -4
- package/dist/{adoption-scan-CNoE5yBA.js → adoption-scan-DhZejKH8.js} +1 -1
- package/dist/agent/index.d.ts +2 -2
- package/dist/agent/index.js +1 -1
- package/dist/ai-sdk/index.d.ts +3 -3
- package/dist/ai-sdk/index.js +3 -3
- package/dist/app/index.d.ts +28 -10
- package/dist/app/index.js +69 -46
- package/dist/{app-DIvM65Mv.js → app-J9PE1LNm.js} +1 -1
- package/dist/{approval-policies-D7moEfTM.d.ts → approval-policies-BiXMlYBu.d.ts} +1 -1
- package/dist/{approval-prompt-DtfKSH-8.d.ts → approval-prompt-j5PTItiy.d.ts} +1 -1
- package/dist/approvals/index.d.ts +3 -3
- package/dist/{arazzo-rsYPFgga.js → arazzo-2_9pOddr.js} +2 -2
- package/dist/{arazzo-4rMFOHbu.js → arazzo-BDDzHgwW.js} +1 -1
- package/dist/astro/index.d.ts +4 -4
- package/dist/astro/index.js +1 -1
- package/dist/{audience-N2BqOvES.js → audience-DLoopY4q.js} +1 -1
- package/dist/authzen/index.d.ts +5 -5
- package/dist/authzen/index.js +1 -1
- package/dist/{automation-CrGcfIZn.d.ts → automation-_iGeP54L.d.ts} +1 -1
- package/dist/better-auth/index.d.ts +1 -1
- package/dist/better-supabase/index.d.ts +63 -38
- package/dist/better-supabase/index.js +55 -38
- package/dist/{bind-N5jf6kjk.d.ts → bind-CTj4dHc1.d.ts} +7 -7
- package/dist/{bind-Cx10JuJ-.js → bind-LQ6zbARV.js} +2 -2
- package/dist/{build-instance-BDGzsGcn.js → build-instance-Bq8wkJ4i.js} +1 -1
- package/dist/{capability-mLbd3KZ0.d.ts → capability-DqCyFGip.d.ts} +1 -1
- package/dist/{casbin-CjUT-wqV.js → casbin-BspH3-6_.js} +1 -1
- package/dist/{casbin-Dg5N0Gfa.js → casbin-XFqehd6I.js} +1 -1
- package/dist/catalog/index.d.ts +4 -4
- package/dist/catalog/index.js +4 -4
- package/dist/{catalog-BJu0A15r.js → catalog-B1MAmRQI.js} +2 -2
- package/dist/catalog-BCVIH7kq.js +1 -0
- package/dist/{catalog-CgA6-DQA.js → catalog-CaZoXBD8.js} +1 -1
- package/dist/{challenge-DVw1SrH9.js → challenge-DKJpP-5P.js} +1 -1
- package/dist/chat/index.d.ts +1 -1
- package/dist/chat/index.js +2 -2
- package/dist/chat-sdk/index.d.ts +3 -3
- package/dist/claude-agent/index.d.ts +3 -3
- package/dist/claude-agent/index.js +2 -2
- package/dist/clerk/index.d.ts +2 -2
- package/dist/cli/bin.js +1 -1
- package/dist/cli/index.d.ts +4 -4
- package/dist/cli/index.js +3 -3
- package/dist/cloud/index.d.ts +8 -8
- package/dist/cloud/index.js +1 -1
- package/dist/{cloud-Blw4AaQv.js → cloud-CUvR7okV.js} +2 -2
- package/dist/{codemod-BFFXaS-S.js → codemod-iwXnO0fg.js} +1 -1
- package/dist/{codemod-ByRUKVp-.js → codemod-uZsk1b6T.js} +2 -2
- package/dist/{collect-D3ToPa6Z.js → collect-BG-SXFQv.js} +1 -1
- package/dist/{collect-COqPRz6O.js → collect-CxPJRjoc.js} +2 -2
- package/dist/collect-ZLgHgujd.js +1 -0
- package/dist/compile/index.d.ts +1 -1
- package/dist/{compile-DSwZUJmL.d.ts → compile-Dh9pW_Co.d.ts} +2 -2
- package/dist/{completion-BW53byZN.js → completion-DenWMczI.js} +1 -1
- package/dist/{config-B0qti4jI.js → config-CoUYTCCu.js} +1 -1
- package/dist/{config-DyNanTjZ.js → config-DC7aiuhP.js} +2 -2
- package/dist/{config-report-DgMqeeK6.js → config-report-C5D1rPiF.js} +2 -2
- package/dist/{config-shape-C4zqzG2K.js → config-shape-ChhsuGSV.js} +2 -1
- package/dist/{context-KrAhRY22.js → context-BXM0MDB0.js} +2 -2
- package/dist/convex/index.d.ts +4 -4
- package/dist/convex/index.js +2 -2
- package/dist/{core-DMQsq2Gv.js → core-BTJlqWsv.js} +5 -5
- package/dist/{core-KsoqXWhf.d.ts → core-BhZEo5Le.d.ts} +2 -2
- package/dist/{coverage-D8jBJdgD.d.ts → coverage-BuGlwUms.d.ts} +30 -9
- package/dist/{coverage-Dh2W_DmF.js → coverage-CGu_Kovx.js} +114 -64
- package/dist/{create-goT32QIN.d.ts → create--q7-j0hX.d.ts} +6 -6
- package/dist/{create-ChK8bpCK.d.ts → create-C5IQw_-i.d.ts} +7 -7
- package/dist/{create-DGFv7Dje.d.ts → create-CYj0cjTu.d.ts} +4 -4
- package/dist/{create-BRr7Gu7N.js → create-D7D94oNh.js} +4 -4
- package/dist/{create-bYkJ4-tg.js → create-DaddhCIg.js} +3 -3
- package/dist/{credentials-UwTE2wCW.js → credentials-BZU7Twpt.js} +1 -1
- package/dist/{credentials-fqa_Xzzh.d.ts → credentials-Bq-Xa7Vq.d.ts} +2 -2
- package/dist/delivery/index.d.ts +4 -4
- package/dist/delivery/index.js +1 -1
- package/dist/{denied-text-BTMxIn5W.d.ts → denied-text-B6s29jcf.d.ts} +1 -1
- package/dist/{describe-CazEjtOH.d.ts → describe-DwcoWMLB.d.ts} +1 -1
- package/dist/{diff-DLcsCeVo.js → diff-BnYHpRSI.js} +3 -3
- package/dist/{diff-BkuW_5dK.js → diff-H75YU6Q-.js} +1 -1
- package/dist/{doctor-oD08zL1e.js → doctor-CF9TXVkX.js} +68 -32
- package/dist/{doctor-Jk2Ifezw.js → doctor-DreyO1At.js} +2 -2
- package/dist/drizzle/index.d.ts +3 -3
- package/dist/elysia/index.d.ts +4 -4
- package/dist/elysia/index.js +1 -1
- package/dist/{errors-CXxQwtbZ.d.ts → errors-D_SnqcRn.d.ts} +1 -1
- package/dist/{evaluate-_JdlbJ32.js → evaluate-BQ2nWOki.js} +2 -2
- package/dist/{evaluations-DcUW5VkX.d.ts → evaluations-BVtY66lF.d.ts} +3 -3
- package/dist/evaluator-CDl2YUd_.js +2 -0
- package/dist/{evaluator-eager-DvmrpdZt.js → evaluator-eager-CULtQ8t6.js} +1 -1
- package/dist/eve/index.d.ts +4 -4
- package/dist/eve/index.js +2 -2
- package/dist/express/index.d.ts +4 -4
- package/dist/express/index.js +1 -1
- package/dist/fastify/index.d.ts +4 -4
- package/dist/fastify/index.js +1 -1
- package/dist/{fetch-adapter-eQ-mdk8n.d.ts → fetch-adapter-BJ76IZZg.d.ts} +2 -2
- package/dist/{fetch-adapter-CAA3VJMX.js → fetch-adapter-CXeBg4CH.js} +1 -1
- package/dist/{fields-B17OWcPx.js → fields-D9PIYlJy.js} +13 -7
- package/dist/{from-snapshot-CdGYjHUg.js → from-snapshot-FdVXG_QZ.js} +20 -14
- package/dist/{gen-BwcwwLok.js → gen-BU5glz2Q.js} +2 -2
- package/dist/{gen-D4ulqsYR.js → gen-C75KIBdA.js} +1 -1
- package/dist/h3/index.d.ts +4 -4
- package/dist/h3/index.js +2 -2
- package/dist/hono/index.d.ts +4 -4
- package/dist/hono/index.js +1 -1
- package/dist/{hosted-cPDyrlsQ.js → hosted-CQW_YNx7.js} +1 -1
- package/dist/{hosted-BUCpV8-u.d.ts → hosted-D5StFpKa.d.ts} +1 -1
- package/dist/{import-BsrnU4BF.js → import-B34PyXgL.js} +3 -16
- package/dist/{import-B2jgnNS0.js → import-BYYXmHvP.js} +1 -1
- package/dist/{index-DD2FBFdm.d.ts → index-B1-tE0Kx.d.ts} +14 -7
- package/dist/{index-DQCBzEhO.d.ts → index-BwSEp_O5.d.ts} +4 -4
- package/dist/{index-CvKGALWb.d.ts → index-CB_eM-qx.d.ts} +4 -4
- package/dist/{index-BXS29UnX.d.ts → index-CvcE9mYP.d.ts} +1 -1
- package/dist/{index-DYAJ9JX1.d.ts → index-D7sMtTf6.d.ts} +4 -4
- package/dist/{index-CxA-ygwc.d.ts → index-d7f0hNss.d.ts} +2 -2
- package/dist/index.d.ts +17 -17
- package/dist/index.js +13 -13
- package/dist/{init-Baq0yYfu.js → init-C-nzibt_.js} +1 -1
- package/dist/{init-Cik6ITgM.js → init-C1Bj0BFA.js} +3 -3
- package/dist/{instance-options-BDHB3qBG.d.ts → instance-options-DhQVCuhT.d.ts} +1 -1
- package/dist/{instance-snapshot-LPNBG9np.js → instance-snapshot-DyG_5ASl.js} +5 -5
- package/dist/jwt/index.d.ts +4 -4
- package/dist/{kernel-BY3rVRs2.js → kernel-D9AxUqmz.js} +5 -5
- package/dist/kysely/index.d.ts +3 -3
- package/dist/{login-CUboKh0f.js → login-Cm_ebe5M.js} +3 -3
- package/dist/{login-CcBS1xkU.js → login-DjuUQqqK.js} +1 -1
- package/dist/{manifest-CIlVL-QT.js → manifest-9KSrH_1h.js} +35 -35
- package/dist/{may-use-D0_wNcgB.js → may-use-WDhFPqGG.js} +5 -6
- package/dist/mcp/index.d.ts +8 -8
- package/dist/mcp/index.js +3 -3
- package/dist/{membership-filter-CfLdP_F9.js → membership-filter-BWnfRQzo.js} +1 -1
- package/dist/{module-values-BLiVlO1X.js → module-values-CdaVwrab.js} +1 -1
- package/dist/nest/index.d.ts +4 -4
- package/dist/nest/index.js +1 -1
- package/dist/next/index.d.ts +10 -10
- package/dist/next/index.js +2 -2
- package/dist/next/plugin.d.ts +1 -1
- package/dist/next/plugin.js +1 -1
- package/dist/node/index.d.ts +4 -4
- package/dist/node/index.js +1 -1
- package/dist/oauth-security-X7Em8DbH.js +26 -0
- package/dist/openai/index.d.ts +4 -4
- package/dist/openai/index.js +3 -3
- package/dist/openapi/index.d.ts +4 -4
- package/dist/openapi/index.js +1 -1
- package/dist/{openapi-DobvXTF6.js → openapi-C2WGtmFa.js} +2 -2
- package/dist/{openapi-DglIpD53.js → openapi-DvTtFkwY.js} +2 -2
- package/dist/orpc/index.d.ts +5 -5
- package/dist/orpc/index.js +2 -2
- package/dist/otel/index.d.ts +3 -3
- package/dist/{output-B81GJ6u6.js → output-CuJfGWo6.js} +1 -1
- package/dist/{ownership-B7Ea-hUY.js → ownership-C_5eZ6N2.js} +1 -1
- package/dist/{parse-local-manifest-DzZOzDsK.d.ts → parse-local-manifest-w_ksIkB9.d.ts} +1 -1
- package/dist/pdp/index.d.ts +3 -3
- package/dist/pdp/index.js +1 -1
- package/dist/{permdock-HfTF99xX.js → permdock-B3zE16To.js} +14 -18
- package/dist/{permdock-vD3mwLSm.d.ts → permdock-DV3opaI3.d.ts} +3 -3
- package/dist/{permissions-CGYZqYsY.js → permissions-D-M48hW-.js} +1 -1
- package/dist/{policy-B_cqFLHu.d.ts → policy-DIHfTqm6.d.ts} +1 -1
- package/dist/{policy-from-catalog-lKL280I8.js → policy-from-catalog-Z0hvSffr.js} +3 -3
- package/dist/{policy-types-CCBrL7me.d.ts → policy-types-DU389Elz.d.ts} +30 -3
- package/dist/{postgrest-5WOO47Ud.d.ts → postgrest-3dE9SGx9.d.ts} +2 -2
- package/dist/powersync-BO1ty3Mf.js +1 -0
- package/dist/{powersync-BUUqJfH2.js → powersync-Bqy5Un2J.js} +6 -6
- package/dist/{powersync-B6f4l8C1.js → powersync-CCQAqiOo.js} +2 -2
- package/dist/prisma/index.d.ts +2 -2
- package/dist/{protected-action-DGuJNiMA.d.ts → protected-action-CjSUoPGx.d.ts} +5 -5
- package/dist/{protected-action-CdqR2-E2.js → protected-action-D41o5LvP.js} +6 -3
- package/dist/provider-Bzzux0TR.js +12 -0
- package/dist/{provider-yIM04TwN.d.ts → provider-D1jsNJ85.d.ts} +1 -1
- package/dist/{provider-store-BLd4UEmg.js → provider-store-tIAwP4aW.js} +3 -3
- package/dist/{provider-6mpRZO1E.js → provider-with-Do28DhxP.js} +6 -24
- package/dist/pull-CYdd5HzX.js +1 -0
- package/dist/{pull-4Yi8zYeU.js → pull-DLkaZBwH.js} +2 -2
- package/dist/{push-Dv1nfFPr.js → push-sJ5dy46a.js} +2 -2
- package/dist/{pushed-policy-B2ZSpnRY.d.ts → pushed-policy-Db651nih.d.ts} +1 -1
- package/dist/{pushed-policy-DJoyBZsd.js → pushed-policy-UZyQinrL.js} +1 -1
- package/dist/react/index.d.ts +6 -6
- package/dist/react/index.js +3 -3
- package/dist/react/lazy.d.ts +12 -0
- package/dist/react/lazy.js +36 -0
- package/dist/react/provider-client.d.ts +1 -1
- package/dist/react/provider-client.js +1 -1
- package/dist/react-native/index.d.ts +8 -8
- package/dist/react-native/index.js +7 -7
- package/dist/{replay-CsErjiHt.d.ts → replay-BpmpY2ev.d.ts} +1 -1
- package/dist/{request-context-B_L4ev8L.js → request-context-dyCY4V1t.js} +1 -1
- package/dist/resend/index.d.ts +4 -4
- package/dist/{resolve-names-SGcLjtFc.js → resolve-names-DHDedxk0.js} +2 -2
- package/dist/{rls-hmwRIS3-.js → rls-B3-tGA4r.js} +13 -13
- package/dist/{rls-Df9NEWD3.js → rls-BW2u4lQW.js} +1 -1
- package/dist/{rpc-DFtputZ1.js → rpc-BdFGYcWm.js} +1 -1
- package/dist/{rpc-D3St8vPO.d.ts → rpc-DKRQobOX.d.ts} +1 -1
- package/dist/{run-BXmJIjRA.js → run-2GwcSago.js} +3 -3
- package/dist/run-CdGNonHf.js +1 -0
- package/dist/{run-ticket-zfABczfh.d.ts → run-ticket-o4RxoaEN.d.ts} +2 -2
- package/dist/{saas-DIThcxbn.js → saas-D9maBt0q.js} +3 -3
- package/dist/{scan-BrTSlc_5.js → scan-CB46GDQ0.js} +1 -1
- package/dist/{schema-UOeI_LTB.js → schema-CyEB_zeO.js} +1 -1
- package/dist/scim/index.d.ts +1 -1
- package/dist/server/index.d.ts +11 -11
- package/dist/server/index.js +2 -2
- package/dist/{server-types-CtJSDhOv.d.ts → server-types-C4q8_8MM.d.ts} +8 -8
- package/dist/{sink-BskpqwLl.d.ts → sink-C3KDccl9.d.ts} +2 -2
- package/dist/{skills-BTVeFptV.js → skills-BYHCObpD.js} +1 -1
- package/dist/{skills-CAgWKbDR.js → skills-C-9wjNaE.js} +1 -1
- package/dist/{snapshot-BcHYtUIg.js → snapshot-D0VOanxQ.js} +7 -0
- package/dist/{snapshot-cache-BnXMcJbK.d.ts → snapshot-cache-C1mN0pXe.d.ts} +2 -2
- package/dist/snapshot-compact-CUtXsx6i.js +75 -0
- package/dist/{snapshot-empty-BoPBFoB8.js → snapshot-empty-F7d5BRlc.js} +1 -0
- package/dist/{snapshot-evaluate-CwYVSUgO.js → snapshot-evaluate-C3ZA35O_.js} +1 -1
- package/dist/{snapshot-reads-DOsTYC82.js → snapshot-reads-CNNmp1cK.js} +2 -2
- package/dist/solid/index.d.ts +5 -5
- package/dist/solid/index.js +2 -2
- package/dist/solid-start/index.d.ts +4 -4
- package/dist/solid-start/index.js +2 -2
- package/dist/{sources-DhCtO9G8.d.ts → sources-2virTxHt.d.ts} +1 -1
- package/dist/{src-BZKQe1lr.js → src-ieIv22BA.js} +11 -7
- package/dist/ssf/index.d.ts +3 -3
- package/dist/{standard-webhooks-kQDkIPj3.d.ts → standard-webhooks-B2g_yWK8.d.ts} +2 -2
- package/dist/{store-core-CDabEiO9.d.ts → store-core-BI-9ZU-5.d.ts} +4 -4
- package/dist/{store-options-COLWAd1K.js → store-options-BYKNX_JG.js} +8 -6
- package/dist/{stores-DYxx75fk.js → stores-DtM8pt8o.js} +1 -1
- package/dist/{stores-Mw_VAJ3B.d.ts → stores-DwGfIcmq.d.ts} +5 -5
- package/dist/{subject-cache-DrJGnRiV.d.ts → subject-cache-TY2tw-k9.d.ts} +1 -1
- package/dist/{subject-BqFwS6l3.js → subject-jG6o8eKo.js} +1 -1
- package/dist/supabase/index.d.ts +6 -6
- package/dist/supabase/index.js +2 -2
- package/dist/supabase/middleware.d.ts +5 -5
- package/dist/supabase/middleware.js +4 -4
- package/dist/{supabase-BDr-fIHp.js → supabase-BlAqmxD8.js} +1 -1
- package/dist/{supabase-Bt8rb-ah.js → supabase-C1hExXsZ.js} +2 -2
- package/dist/supabase-hook-DCemge7i.js +1 -0
- package/dist/{supabase-hook-Cb3UZpGC.js → supabase-hook-DJA8AJYz.js} +5 -5
- package/dist/{supautils-CuR9rPsi.js → supautils-DuwkBqKm.js} +7 -7
- package/dist/svelte/index.d.ts +5 -5
- package/dist/svelte/index.js +3 -3
- package/dist/svelte/runtime.d.ts +3 -3
- package/dist/svelte/runtime.js +1 -1
- package/dist/svelte/source.d.ts +5 -5
- package/dist/svelte/source.js +2 -2
- package/dist/sveltekit/index.d.ts +4 -4
- package/dist/sveltekit/index.js +1 -1
- package/dist/{tables-Bl_ozD0k.js → tables-B3w3EtUF.js} +1 -1
- package/dist/tanstack-start/index.d.ts +4 -4
- package/dist/tanstack-start/index.js +1 -1
- package/dist/terminal/index.d.ts +5 -5
- package/dist/terminal/index.js +6 -5
- package/dist/testing/core.d.ts +1 -1
- package/dist/testing/core.js +1 -1
- package/dist/testing/fixtures/index.d.ts +3 -3
- package/dist/testing/fixtures/index.js +2 -2
- package/dist/testing/index.d.ts +32 -25
- package/dist/testing/index.js +25 -16
- package/dist/testing/saas/index.d.ts +3 -3
- package/dist/testing/saas/index.js +2 -2
- package/dist/testing/saas/permissions.js +1 -1
- package/dist/trpc/index.d.ts +5 -5
- package/dist/trpc/index.js +2 -2
- package/dist/{type-helpers-fQdBvtU0.d.ts → type-helpers-tDoGEIsd.d.ts} +1 -1
- package/dist/{types-JmB6unT6.d.ts → types-61f3KMtI.d.ts} +7 -2
- package/dist/{types-CdXM6qPc.d.ts → types-BDgMzK1i.d.ts} +2 -2
- package/dist/{types-DyA4Loy4.d.ts → types-BIvkpVoc.d.ts} +3 -3
- package/dist/{types-CXUwgZ3d.d.ts → types-BWjNPQkS.d.ts} +2 -2
- package/dist/{types-CErg7ft6.d.ts → types-Bq4AU68k.d.ts} +3 -3
- package/dist/{types-ChYCRn7Y.d.ts → types-BsqLNNvG.d.ts} +1 -1
- package/dist/{types-Cc68_zqR.d.ts → types-CH67RMvL.d.ts} +2 -2
- package/dist/{types-BSGrzDPi.d.ts → types-DEDocm4c.d.ts} +4 -4
- package/dist/{types-DDlaFDM3.d.ts → types-DQQkzF97.d.ts} +4 -4
- package/dist/{types-DM0o1YyJ.d.ts → types-DdeivUBP.d.ts} +4 -4
- package/dist/{types-CAp7UGiB.d.ts → types-X40XNxRP.d.ts} +1 -1
- package/dist/unplugin/index.d.ts +1 -1
- package/dist/unplugin/index.js +1 -1
- package/dist/{usage-B6sQwycY.js → usage-BBEm7GVn.js} +4 -4
- package/dist/{usage-CNkKk27O.js → usage-CkKbvpmL.js} +1 -1
- package/dist/usage-GQxn7qkA.js +1 -0
- package/dist/{validation-error-BE8bpmhR.d.ts → validation-error-CV0nV6_L.d.ts} +1 -1
- package/dist/{verify-OtU4yCzg.js → verify-lgYu1Twv.js} +10 -10
- package/dist/{version-sources-BZ7V6Z8Z.js → version-sources-BRb9ZteH.js} +1 -1
- package/dist/vue/index.d.ts +5 -5
- package/dist/vue/index.js +2 -2
- package/dist/{waiter-LdnPaBJE.d.ts → waiter-BophA4BT.d.ts} +2 -2
- package/dist/{watch-CR2ZIT_5.js → watch-CJKYQYNb.js} +2 -2
- package/dist/watch-Cv-xvI6e.js +1 -0
- package/dist/webmcp/index.d.ts +1 -1
- package/dist/webmcp/index.js +9 -1
- package/dist/{who-can-DcrHB6ya.js → who-can-Yh9WdiwK.js} +1 -1
- package/dist/workflow/index.d.ts +3 -3
- package/dist/workflow/index.js +2 -2
- package/dist/workflow-sdk/index.d.ts +4 -4
- package/dist/{wrap-CVBPIuEs.d.ts → wrap-Bq9fHwuT.d.ts} +2 -2
- package/package.json +8 -4
- package/schemas/snapshot-v1.json +208 -52
- package/skills/permdock-wire/references/adapters.md +4 -2
- package/dist/catalog-DqYnQz8U.js +0 -1
- package/dist/collect-CjFczu8a.js +0 -1
- package/dist/evaluator-mHAoYEkk.js +0 -2
- package/dist/powersync-D12Q6Chj.js +0 -1
- package/dist/pull-Dr6Bq5Jo.js +0 -1
- package/dist/run-DnzrDgU-.js +0 -1
- package/dist/supabase-hook-D1pwHu87.js +0 -1
- package/dist/usage-Cem1FOeJ.js +0 -1
- package/dist/watch-B8F7Wgdy.js +0 -1
- package/dist/{catalog-doc-BoSOQRXT.js → catalog-doc-DnQDviXY.js} +1 -1
- package/dist/{credential-DrVrRL7z.js → credential-BMsbcaeP.js} +1 -1
- package/dist/{policy-BovcTojN.js → policy-DnNOTENd.js} +1 -1
package/dist/cloud/index.d.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { m as ApprovalStore } from "../types-
|
|
3
|
-
import { i as CatalogEventData, l as CloudEventType, r as CLOUD_EVENT_TYPES, s as CloudEvent } from "../sink-
|
|
4
|
-
import { c as DeliveryTransport } from "../types-
|
|
5
|
-
import { a as CloudConnectionOptions, c as CloudOptions, i as CloudClient, l as CloudSignerOptions, n as CloudCatalog, o as CloudEndpointOptions, r as CloudCatalogPush, s as CloudEndpoints, t as CloudApproverOptions } from "../types-
|
|
6
|
-
import { n as ApprovalWaiter } from "../waiter-
|
|
7
|
-
import { l as ReplayStore } from "../types-
|
|
8
|
-
import { f as WebhookVerifier, r as WebhookFailureCause$1, s as WebhookJwks } from "../standard-webhooks-
|
|
1
|
+
import { _n as MembershipEvent, _t as TokenSigner, dn as DecisionEvent, fn as DeliveryChannel, hn as DirectoryEvent, ln as AutomationEvent, pn as DeliveryEvent, qt as Instant, sn as AccessEvent, un as CredentialEvent } from "../policy-types-DU389Elz.js";
|
|
2
|
+
import { m as ApprovalStore } from "../types-X40XNxRP.js";
|
|
3
|
+
import { i as CatalogEventData, l as CloudEventType, r as CLOUD_EVENT_TYPES, s as CloudEvent } from "../sink-C3KDccl9.js";
|
|
4
|
+
import { c as DeliveryTransport } from "../types-BIvkpVoc.js";
|
|
5
|
+
import { a as CloudConnectionOptions, c as CloudOptions, i as CloudClient, l as CloudSignerOptions, n as CloudCatalog, o as CloudEndpointOptions, r as CloudCatalogPush, s as CloudEndpoints, t as CloudApproverOptions } from "../types-DQQkzF97.js";
|
|
6
|
+
import { n as ApprovalWaiter } from "../waiter-BophA4BT.js";
|
|
7
|
+
import { l as ReplayStore } from "../types-BDgMzK1i.js";
|
|
8
|
+
import { f as WebhookVerifier, r as WebhookFailureCause$1, s as WebhookJwks } from "../standard-webhooks-B2g_yWK8.js";
|
|
9
9
|
//#region src/cloud/base-url.d.ts
|
|
10
10
|
/**
|
|
11
11
|
* The one base URL of PermDock Cloud. The platform issuer is this URL; its
|
package/dist/cloud/index.js
CHANGED
|
@@ -12,7 +12,7 @@ import { c as stringField, n as discoverAuthorizationServer, r as parseToken } f
|
|
|
12
12
|
import { t as pollingApprovalWaiter } from "../waiter-aBLM63_f.js";
|
|
13
13
|
import { i as isDeliveryTarget } from "../target-qdEAnnhU.js";
|
|
14
14
|
import { t as CLOUD_BASE_URL } from "../base-url-BQbddZO5.js";
|
|
15
|
-
import { a as isCompactJws, i as cloudEndpoints, n as cloud, o as resolveCloudEndpoints, r as cloudConnection, t as bearerChallenge } from "../challenge-
|
|
15
|
+
import { a as isCompactJws, i as cloudEndpoints, n as cloud, o as resolveCloudEndpoints, r as cloudConnection, t as bearerChallenge } from "../challenge-DKJpP-5P.js";
|
|
16
16
|
import { n as randomToken, t as pkce } from "../pkce-CnmmYqUZ.js";
|
|
17
17
|
//#region src/cloud/oauth-error.ts
|
|
18
18
|
/**
|
|
@@ -41,7 +41,7 @@ const push = defineLeaf({
|
|
|
41
41
|
},
|
|
42
42
|
async run(ctx, { flags }) {
|
|
43
43
|
const env = await withStdinSecret(ctx, "key", flags["key-stdin"], "PERMDOCK_CLOUD_KEY");
|
|
44
|
-
return (await import("./push-
|
|
44
|
+
return (await import("./push-sJ5dy46a.js")).runCloud({
|
|
45
45
|
cwd: ctx.cwd,
|
|
46
46
|
config: ctx.config,
|
|
47
47
|
url: given(flags.url),
|
|
@@ -70,7 +70,7 @@ const pull = defineLeaf({
|
|
|
70
70
|
},
|
|
71
71
|
async run(ctx, { flags }) {
|
|
72
72
|
const env = await withStdinSecret(ctx, "token", flags["token-stdin"], "PERMDOCK_CLOUD_TOKEN");
|
|
73
|
-
return (await import("./pull-
|
|
73
|
+
return (await import("./pull-CYdd5HzX.js")).runCloudPull({
|
|
74
74
|
cwd: ctx.cwd,
|
|
75
75
|
config: ctx.config,
|
|
76
76
|
url: given(flags.url),
|
|
@@ -2,7 +2,7 @@ import { n as CliError } from "./errors-BhRkoNS7.js";
|
|
|
2
2
|
import { a as rel } from "./files-BSjrtIHw.js";
|
|
3
3
|
import { i as visitorKeyTypes, r as parseSync, t as createVisitor } from "./optional-8TKc-0j4.js";
|
|
4
4
|
import { t as beforeFirst } from "./text-BMFRfBqc.js";
|
|
5
|
-
import { n as ROOT } from "./manifest-
|
|
5
|
+
import { n as ROOT } from "./manifest-9KSrH_1h.js";
|
|
6
6
|
import { i as refuseDirty, t as applyFiles } from "./files-CfiRtQ-m.js";
|
|
7
7
|
import { readFileSync, readdirSync, statSync } from "node:fs";
|
|
8
8
|
import { basename, extname, join, resolve } from "node:path";
|
|
@@ -7,7 +7,7 @@ const codemod = defineLeaf({
|
|
|
7
7
|
description: "The release to migrate to (0.5)",
|
|
8
8
|
required: true,
|
|
9
9
|
async complete() {
|
|
10
|
-
return (await import("./codemod-
|
|
10
|
+
return (await import("./codemod-iwXnO0fg.js")).codemodVersions();
|
|
11
11
|
}
|
|
12
12
|
}, {
|
|
13
13
|
name: "paths",
|
|
@@ -22,7 +22,7 @@ const codemod = defineLeaf({
|
|
|
22
22
|
}
|
|
23
23
|
},
|
|
24
24
|
async run(ctx, { flags, args, rest }) {
|
|
25
|
-
return (await import("./codemod-
|
|
25
|
+
return (await import("./codemod-iwXnO0fg.js")).runCodemod({
|
|
26
26
|
cwd: ctx.cwd,
|
|
27
27
|
version: args["version"],
|
|
28
28
|
paths: rest,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { a as describeError, n as CliError } from "./errors-BhRkoNS7.js";
|
|
2
2
|
import { a as rel, r as listSourceFiles, s as writeFileEnsuringDir, t as defaultSrcPath } from "./files-BSjrtIHw.js";
|
|
3
|
-
import { n as catalogForCompare, o as formatCatalogJson, r as catalogForDrift, t as buildCatalog } from "./catalog-doc-
|
|
3
|
+
import { n as catalogForCompare, o as formatCatalogJson, r as catalogForDrift, t as buildCatalog } from "./catalog-doc-DnQDviXY.js";
|
|
4
4
|
import { i as visitorKeyTypes, r as parseSync, t as createVisitor } from "./optional-8TKc-0j4.js";
|
|
5
5
|
import { a as loadModule, i as loadConfiguredPolicy, r as leavesOf, s as pickNamed, t as asPermissionTree } from "./load-C4p4VgwR.js";
|
|
6
6
|
import { t as loadConfiguredOperations } from "./catalog-operations-Do1eD-Rt.js";
|
|
@@ -29,9 +29,9 @@ const collect = defineLeaf({
|
|
|
29
29
|
};
|
|
30
30
|
if (flags.watch) {
|
|
31
31
|
if (flags.check) throw new CliError("usage", "collect: --watch writes the catalog; drop --check", { code: "invalid_value" });
|
|
32
|
-
return (await import("./watch-
|
|
32
|
+
return (await import("./watch-Cv-xvI6e.js")).watchCollect(ctx, overrides);
|
|
33
33
|
}
|
|
34
|
-
const result = await (await import("./collect-
|
|
34
|
+
const result = await (await import("./collect-ZLgHgujd.js")).runCollect({
|
|
35
35
|
cwd: ctx.cwd,
|
|
36
36
|
config: ctx.config,
|
|
37
37
|
collect: overrides,
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { r as runCollect } from "./collect-BG-SXFQv.js";
|
package/dist/compile/index.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { n as GraphSqlPart, r as RelationsMapping, t as GraphSql } from "../graph-sql-BwFC4Qjs.js";
|
|
2
|
-
import { a as CompiledWhere, c as compileWhere, i as CompiledSql, l as escapeLike, n as CompiledCompare, o as MembershipTable, r as CompiledExists, s as MembershipsMapping, t as CompileWhereOptions } from "../compile-
|
|
2
|
+
import { a as CompiledWhere, c as compileWhere, i as CompiledSql, l as escapeLike, n as CompiledCompare, o as MembershipTable, r as CompiledExists, s as MembershipsMapping, t as CompileWhereOptions } from "../compile-Dh9pW_Co.js";
|
|
3
3
|
export { type CompileWhereOptions, type CompiledCompare, type CompiledExists, type CompiledSql, type CompiledWhere, type GraphSql, type GraphSqlPart, type MembershipTable, type MembershipsMapping, type RelationsMapping, compileWhere, escapeLike };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Cn as Scope, Dr as Condition, Sr as Subject, qt as Instant } from "./policy-types-DU389Elz.js";
|
|
2
2
|
import { P as ResourceNode } from "./vocabulary-DeZvUaTw.js";
|
|
3
|
-
import { f as WhereResult } from "./permdock-
|
|
3
|
+
import { f as WhereResult } from "./permdock-DV3opaI3.js";
|
|
4
4
|
import { r as RelationsMapping, t as GraphSql } from "./graph-sql-BwFC4Qjs.js";
|
|
5
5
|
//#region src/conditions/compile.d.ts
|
|
6
6
|
type MembershipTable = {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as CliError } from "./errors-BhRkoNS7.js";
|
|
2
2
|
import { a as GLOBAL_FLAGS, i as suggestion } from "./args-iafbHiXn.js";
|
|
3
|
-
import { a as resolve } from "./manifest-
|
|
3
|
+
import { a as resolve } from "./manifest-9KSrH_1h.js";
|
|
4
4
|
import { t as defineLeaf } from "./command-L8EstFNm.js";
|
|
5
5
|
//#region src/cli/core/completion.ts
|
|
6
6
|
const SHELLS = [
|
|
@@ -10,7 +10,7 @@ const config = defineLeaf({
|
|
|
10
10
|
...failOnFlag
|
|
11
11
|
},
|
|
12
12
|
async run(ctx, { flags }) {
|
|
13
|
-
const { runConfig } = await import("./config-report-
|
|
13
|
+
const { runConfig } = await import("./config-report-C5D1rPiF.js");
|
|
14
14
|
return runConfig({
|
|
15
15
|
cwd: ctx.cwd,
|
|
16
16
|
config: ctx.config,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { r as isRecord } from "./compact-CAf557ZB.js";
|
|
2
2
|
import { i as configError, n as CliError } from "./errors-BhRkoNS7.js";
|
|
3
3
|
import { a as betterSupabaseInstalled, i as betterSupabaseDefaults, r as betterSupabaseConfig } from "./better-supabase-DF8f8oly.js";
|
|
4
|
-
import { a as isSection, i as isModuleKey, n as MODULE_KEYS, o as kindOf, r as describeKinds, t as CONFIG_SHAPE } from "./config-shape-
|
|
4
|
+
import { a as isSection, i as isModuleKey, n as MODULE_KEYS, o as kindOf, r as describeKinds, t as CONFIG_SHAPE } from "./config-shape-ChhsuGSV.js";
|
|
5
5
|
import { existsSync } from "node:fs";
|
|
6
6
|
import { dirname, relative, resolve } from "node:path";
|
|
7
7
|
//#region src/cli/project/config-schema.ts
|
|
@@ -97,7 +97,7 @@ function hasModuleValue(raw) {
|
|
|
97
97
|
return isRecord(raw) && Object.keys(MODULE_KEYS).some((key) => isRecord(raw[key]));
|
|
98
98
|
}
|
|
99
99
|
async function traceValues(cwd, file, display, config, options) {
|
|
100
|
-
const { traceModuleValues } = await import("./module-values-
|
|
100
|
+
const { traceModuleValues } = await import("./module-values-CdaVwrab.js");
|
|
101
101
|
return traceModuleValues({
|
|
102
102
|
cwd,
|
|
103
103
|
file,
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { a as rel, t as defaultSrcPath } from "./files-BSjrtIHw.js";
|
|
2
2
|
import { r as CONFIG_REPORT_SCHEMA } from "./version-DMQ0dnN5.js";
|
|
3
3
|
import { t as catalogPath } from "./catalog-path-CnI0XTFK.js";
|
|
4
|
-
import { n as guessPermissions, t as barrelFile } from "./collect-
|
|
4
|
+
import { n as guessPermissions, t as barrelFile } from "./collect-BG-SXFQv.js";
|
|
5
5
|
import "./sources-C4vkzZJV.js";
|
|
6
|
-
import { t as DOCS_BASE } from "./manifest-
|
|
6
|
+
import { t as DOCS_BASE } from "./manifest-9KSrH_1h.js";
|
|
7
7
|
import { n as MIGRATION_DIRS, t as DEFAULT_SENSITIVE_ACTIONS } from "./constants-DcJABbLW.js";
|
|
8
8
|
//#region src/cli/config-report.ts
|
|
9
9
|
function configReport(input) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { t as compact } from "./compact-CAf557ZB.js";
|
|
2
|
-
import { l as isPromiseLike } from "./store-options-
|
|
3
|
-
import { n as switchTenant, t as providerStore } from "./provider-store-
|
|
2
|
+
import { l as isPromiseLike } from "./store-options-BYKNX_JG.js";
|
|
3
|
+
import { n as switchTenant, t as providerStore } from "./provider-store-tIAwP4aW.js";
|
|
4
4
|
import { getContext, onDestroy, setContext } from "svelte";
|
|
5
5
|
import { toStore } from "svelte/store";
|
|
6
6
|
//#region src/svelte/context.ts
|
package/dist/convex/index.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { D as Policy, N as PolicyVocabulary,
|
|
1
|
+
import { D as Policy, N as PolicyVocabulary, br as Principal } from "../policy-types-DU389Elz.js";
|
|
2
2
|
import { w as Permission } from "../vocabulary-DeZvUaTw.js";
|
|
3
|
-
import { a as PermDock } from "../permdock-
|
|
4
|
-
import { a as ProblemDetails, r as PermDockDeniedError } from "../errors-
|
|
5
|
-
import { t as InstanceOptions } from "../instance-options-
|
|
3
|
+
import { a as PermDock } from "../permdock-DV3opaI3.js";
|
|
4
|
+
import { a as ProblemDetails, r as PermDockDeniedError } from "../errors-D_SnqcRn.js";
|
|
5
|
+
import { t as InstanceOptions } from "../instance-options-DhQVCuhT.js";
|
|
6
6
|
//#region src/convex/types.d.ts
|
|
7
7
|
type ConvexContextLike = {
|
|
8
8
|
readonly auth?: {
|
package/dist/convex/index.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { t as compact } from "../compact-CAf557ZB.js";
|
|
2
2
|
import { n as PermDockValidationError } from "../validation-error-CYg2kJEw.js";
|
|
3
3
|
import { n as PermDockDeniedError, t as PermDockApprovalRequiredError } from "../errors-ynga1EQy.js";
|
|
4
|
-
import { r as withApp } from "../app-
|
|
4
|
+
import { r as withApp } from "../app-J9PE1LNm.js";
|
|
5
5
|
import { n as tenantScope, t as actorFrom } from "../adapter-context-OHikyRqV.js";
|
|
6
|
-
import { n as resolveOrNull, t as buildInstance } from "../build-instance-
|
|
6
|
+
import { n as resolveOrNull, t as buildInstance } from "../build-instance-Bq8wkJ4i.js";
|
|
7
7
|
//#region src/convex/create.ts
|
|
8
8
|
/**
|
|
9
9
|
* Convex's runtime sends `data` to the client only for an error carrying this
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { D as memoryCustomRoleSource } from "./src-
|
|
1
|
+
import { D as memoryCustomRoleSource } from "./src-ieIv22BA.js";
|
|
2
2
|
import { c as listPermissions } from "./permission-registry-B8tYxPIt.js";
|
|
3
3
|
import { d as scopeList } from "./scopes-gdH__vDZ.js";
|
|
4
|
-
import { n as parseSnapshot } from "./snapshot-
|
|
5
|
-
import { t as getPermDock } from "./permdock-
|
|
6
|
-
import { y as membershipsClaim } from "./evaluate-
|
|
7
|
-
import { t as fromSnapshot } from "./from-snapshot-
|
|
4
|
+
import { n as parseSnapshot } from "./snapshot-D0VOanxQ.js";
|
|
5
|
+
import { t as getPermDock } from "./permdock-B3zE16To.js";
|
|
6
|
+
import { y as membershipsClaim } from "./evaluate-BQ2nWOki.js";
|
|
7
|
+
import { t as fromSnapshot } from "./from-snapshot-FdVXG_QZ.js";
|
|
8
8
|
import "./budget-BBCPDOGP.js";
|
|
9
9
|
import { c as quoteSqlTable, n as defaultSqlCommand, o as quoteSqlIdent, t as SQL_IDENT } from "./sql-0WjxIp9g.js";
|
|
10
10
|
//#region src/testing/policy-matrix.ts
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { D as Policy,
|
|
1
|
+
import { D as Policy, Xn as Decision, mr as CustomRole, yr as Membership } from "./policy-types-DU389Elz.js";
|
|
2
2
|
import { w as Permission } from "./vocabulary-DeZvUaTw.js";
|
|
3
|
-
import { f as WhereResult, o as PermDockOptions } from "./permdock-
|
|
3
|
+
import { f as WhereResult, o as PermDockOptions } from "./permdock-DV3opaI3.js";
|
|
4
4
|
//#region src/testing/policy-matrix.d.ts
|
|
5
5
|
type MatrixOutcome = "granted" | "denied" | "approval-required";
|
|
6
6
|
type MatrixCell = MatrixOutcome | {
|
|
@@ -1,25 +1,41 @@
|
|
|
1
1
|
import { E as PermissionTree, w as Permission } from "./vocabulary-DeZvUaTw.js";
|
|
2
2
|
//#region src/openapi/operations.d.ts
|
|
3
|
+
/**
|
|
4
|
+
* Who enforces an operation. `kernel` is the default: the server kernel checks
|
|
5
|
+
* the permission before the handler runs. `handler` marks an operation whose
|
|
6
|
+
* handler checks the permission itself, so a kernel gate must not require an
|
|
7
|
+
* entry for it.
|
|
8
|
+
*/
|
|
9
|
+
type OperationEnforcement = "kernel" | "handler";
|
|
3
10
|
/**
|
|
4
11
|
* One declared operation: a permission, or a permission with the operation id a
|
|
5
|
-
* tool name uses
|
|
6
|
-
* route that checks no permission (`protect(null)`).
|
|
12
|
+
* tool name uses, the OAuth scopes that reach it and who enforces it, or only
|
|
13
|
+
* OAuth scopes for a route that checks no permission (`protect(null)`).
|
|
7
14
|
*/
|
|
8
15
|
type OperationEntry = Permission | {
|
|
9
16
|
readonly permission: Permission;
|
|
10
17
|
readonly operationId?: string;
|
|
11
18
|
readonly oauthScopes?: readonly string[];
|
|
19
|
+
readonly enforcement?: OperationEnforcement;
|
|
12
20
|
} | {
|
|
13
21
|
readonly permission?: undefined;
|
|
14
22
|
readonly operationId?: string;
|
|
15
23
|
readonly oauthScopes: readonly string[];
|
|
24
|
+
readonly enforcement?: OperationEnforcement;
|
|
16
25
|
};
|
|
17
26
|
/**
|
|
18
27
|
* The permission of each operation of an API, declared once and read by the
|
|
19
28
|
* HTTP gate and by `permdock/mcp`'s `permissionFor`, so a REST route and the
|
|
20
29
|
* MCP tool that calls it can never disagree.
|
|
21
30
|
*/
|
|
22
|
-
type OperationPermissions = {
|
|
31
|
+
type OperationPermissions = OperationLookup & {
|
|
32
|
+
/** The operations the kernel enforces; an entry with no `enforcement` is one. */
|
|
33
|
+
readonly kernel: OperationLookup;
|
|
34
|
+
/** The operations whose handler enforces them. */
|
|
35
|
+
readonly handler: OperationLookup;
|
|
36
|
+
};
|
|
37
|
+
/** The lookups of a set of operations. */
|
|
38
|
+
type OperationLookup = {
|
|
23
39
|
/**
|
|
24
40
|
* The permission of a request: the declared operation whose method and path
|
|
25
41
|
* template match, a literal segment winning over a `{param}`. `undefined` for
|
|
@@ -49,6 +65,7 @@ type OperationDeclaration = {
|
|
|
49
65
|
readonly permission?: Permission;
|
|
50
66
|
readonly operationId?: string;
|
|
51
67
|
readonly oauthScopes?: readonly string[];
|
|
68
|
+
readonly enforcement: OperationEnforcement;
|
|
52
69
|
};
|
|
53
70
|
/** An OpenAPI operation `operationPermissionsFromOpenApi` read. */
|
|
54
71
|
type OpenApiOperationRef = {
|
|
@@ -57,7 +74,7 @@ type OpenApiOperationRef = {
|
|
|
57
74
|
readonly operationId?: string;
|
|
58
75
|
};
|
|
59
76
|
/** Why `operationPermissionsFromOpenApi` left an operation out. */
|
|
60
|
-
type OperationSkipCause = "no-permission" | "several-permissions" | "unknown-permission" | "invalid-extension";
|
|
77
|
+
type OperationSkipCause = "no-permission" | "several-permissions" | "unknown-permission" | "invalid-extension" | "public";
|
|
61
78
|
/** Every skip cause, for a table or an exhaustive switch. */
|
|
62
79
|
declare const OPERATION_SKIP_CAUSES: readonly OperationSkipCause[];
|
|
63
80
|
/**
|
|
@@ -71,9 +88,13 @@ declare function operationPermissions(operations: Readonly<Record<string, Operat
|
|
|
71
88
|
/**
|
|
72
89
|
* The operation permissions an OpenAPI document declares: every operation whose
|
|
73
90
|
* `x-permdock-permissions` names exactly one permission of `tree`, keyed by its
|
|
74
|
-
* method, path and `operationId
|
|
75
|
-
*
|
|
76
|
-
*
|
|
91
|
+
* method, path and `operationId`, and every operation that has OAuth scopes in
|
|
92
|
+
* its `security` requirement and names no permission (a scope-only entry). The
|
|
93
|
+
* scopes come from `operation.security`, else `document.security`, for `oauth2`
|
|
94
|
+
* and `openIdConnect` schemes. `x-permdock-enforcement` is `kernel` (the
|
|
95
|
+
* default) or `handler`. An operation naming several or an unknown key, an
|
|
96
|
+
* invalid extension, or `security: []` is left out, so a gate denies it;
|
|
97
|
+
* `onSkip` hears each one with its cause.
|
|
77
98
|
*/
|
|
78
99
|
declare function operationPermissionsFromOpenApi(document: unknown, tree: PermissionTree, options?: {
|
|
79
100
|
readonly base?: string;
|
|
@@ -109,6 +130,6 @@ type OperationCoverage = {
|
|
|
109
130
|
* matches no operation is `stale`. `testOperationCoverage` and `permdock
|
|
110
131
|
* doctor` (PD091) run this one function.
|
|
111
132
|
*/
|
|
112
|
-
declare function operationCoverage(operations:
|
|
133
|
+
declare function operationCoverage(operations: OperationLookup, document: unknown, options: OperationCoverageOptions): OperationCoverage;
|
|
113
134
|
//#endregion
|
|
114
|
-
export { OpenApiOperationRef as a,
|
|
135
|
+
export { OpenApiOperationRef as a, OperationEntry as c, OperationSkipCause as d, operationPermissions as f, OPERATION_SKIP_CAUSES as i, OperationLookup as l, OperationCoverageOptions as n, OperationDeclaration as o, operationPermissionsFromOpenApi as p, operationCoverage as r, OperationEnforcement as s, OperationCoverage as t, OperationPermissions as u };
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { r as isRecord } from "./compact-CAf557ZB.js";
|
|
2
2
|
import { n as findPermission, o as isPermission } from "./permission-registry-B8tYxPIt.js";
|
|
3
|
+
import { n as oauthScopesOf, t as oauthSchemes } from "./oauth-security-X7Em8DbH.js";
|
|
3
4
|
//#region src/openapi/operations.ts
|
|
4
5
|
const HTTP_METHODS = /* @__PURE__ */ new Set([
|
|
5
6
|
"GET",
|
|
@@ -17,7 +18,8 @@ const OPERATION_SKIP_CAUSES = [
|
|
|
17
18
|
"no-permission",
|
|
18
19
|
"several-permissions",
|
|
19
20
|
"unknown-permission",
|
|
20
|
-
"invalid-extension"
|
|
21
|
+
"invalid-extension",
|
|
22
|
+
"public"
|
|
21
23
|
];
|
|
22
24
|
function segmentsOf$1(path) {
|
|
23
25
|
return path.split("/").filter((segment) => segment !== "");
|
|
@@ -42,6 +44,12 @@ function score(route, segments) {
|
|
|
42
44
|
function isEntryObject(entry) {
|
|
43
45
|
return !isPermission(entry);
|
|
44
46
|
}
|
|
47
|
+
function enforcementOf(key, entry) {
|
|
48
|
+
if (!isEntryObject(entry) || entry.enforcement === void 0) return "kernel";
|
|
49
|
+
const value = entry.enforcement;
|
|
50
|
+
if (value !== "kernel" && value !== "handler") throw new TypeError(`PermDock: operation '${key}' sets enforcement to '${String(value)}', which must be 'kernel' or 'handler'`);
|
|
51
|
+
return value;
|
|
52
|
+
}
|
|
45
53
|
function scopesOf(key, entry) {
|
|
46
54
|
if (!isEntryObject(entry) || entry.oauthScopes === void 0) return;
|
|
47
55
|
const scopes = entry.oauthScopes;
|
|
@@ -69,66 +77,85 @@ function operationPermissions(operations, options = {}) {
|
|
|
69
77
|
...isEntryObject(entry) && entry.operationId !== void 0 ? { operationId: entry.operationId } : {},
|
|
70
78
|
segments: segmentsOf$1(path),
|
|
71
79
|
permission: isEntryObject(entry) ? entry.permission : entry,
|
|
72
|
-
...oauthScopes === void 0 ? {} : { oauthScopes }
|
|
80
|
+
...oauthScopes === void 0 ? {} : { oauthScopes },
|
|
81
|
+
enforcement: enforcementOf(key, entry)
|
|
73
82
|
};
|
|
74
83
|
routes.push(route);
|
|
75
84
|
if (isEntryObject(entry) && entry.operationId !== void 0) byId.set(entry.operationId, route);
|
|
76
85
|
}
|
|
77
86
|
const base = segmentsOf$1(options.base ?? "");
|
|
78
|
-
const
|
|
79
|
-
const
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
87
|
+
const lookupOf = (subset, ids) => {
|
|
88
|
+
const matchMethod = (upper, path) => {
|
|
89
|
+
const full = segmentsOf$1(path.split("?")[0] ?? "");
|
|
90
|
+
if (base.some((segment, index) => full[index] !== segment)) return;
|
|
91
|
+
const segments = full.slice(base.length);
|
|
92
|
+
let best;
|
|
93
|
+
let bestScore = -1;
|
|
94
|
+
for (const route of subset) {
|
|
95
|
+
if (route.method !== upper) continue;
|
|
96
|
+
const value = score(route, segments);
|
|
97
|
+
if (value > bestScore) {
|
|
98
|
+
best = route;
|
|
99
|
+
bestScore = value;
|
|
100
|
+
}
|
|
90
101
|
}
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
102
|
+
return best;
|
|
103
|
+
};
|
|
104
|
+
const match = (method, path) => {
|
|
105
|
+
const upper = method.toUpperCase();
|
|
106
|
+
const route = matchMethod(upper, path);
|
|
107
|
+
return route === void 0 && upper === "HEAD" ? matchMethod("GET", path) : route;
|
|
108
|
+
};
|
|
109
|
+
return {
|
|
110
|
+
forRequest(method, path) {
|
|
111
|
+
return match(method, path)?.permission;
|
|
112
|
+
},
|
|
113
|
+
forOperation(id) {
|
|
114
|
+
return ids.get(id)?.permission;
|
|
115
|
+
},
|
|
116
|
+
oauthScopesForRequest(method, path) {
|
|
117
|
+
return match(method, path)?.oauthScopes;
|
|
118
|
+
},
|
|
119
|
+
oauthScopesForOperation(id) {
|
|
120
|
+
return ids.get(id)?.oauthScopes;
|
|
121
|
+
},
|
|
122
|
+
entries() {
|
|
123
|
+
return subset.map((route) => ({
|
|
124
|
+
method: route.method,
|
|
125
|
+
path: route.path,
|
|
126
|
+
...route.permission === void 0 ? {} : { permission: route.permission },
|
|
127
|
+
...route.operationId === void 0 ? {} : { operationId: route.operationId },
|
|
128
|
+
...route.oauthScopes === void 0 ? {} : { oauthScopes: route.oauthScopes },
|
|
129
|
+
enforcement: route.enforcement
|
|
130
|
+
}));
|
|
131
|
+
}
|
|
132
|
+
};
|
|
98
133
|
};
|
|
134
|
+
const idsOf = (subset) => new Map(subset.flatMap((route) => route.operationId === void 0 ? [] : [[route.operationId, route]]));
|
|
135
|
+
const only = (enforcement) => routes.filter((route) => route.enforcement === enforcement);
|
|
136
|
+
const kernel = only("kernel");
|
|
137
|
+
const handler = only("handler");
|
|
99
138
|
return {
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
forOperation(id) {
|
|
104
|
-
return byId.get(id)?.permission;
|
|
105
|
-
},
|
|
106
|
-
oauthScopesForRequest(method, path) {
|
|
107
|
-
return match(method, path)?.oauthScopes;
|
|
108
|
-
},
|
|
109
|
-
oauthScopesForOperation(id) {
|
|
110
|
-
return byId.get(id)?.oauthScopes;
|
|
111
|
-
},
|
|
112
|
-
entries() {
|
|
113
|
-
return routes.map((route) => ({
|
|
114
|
-
method: route.method,
|
|
115
|
-
path: route.path,
|
|
116
|
-
...route.permission === void 0 ? {} : { permission: route.permission },
|
|
117
|
-
...route.operationId === void 0 ? {} : { operationId: route.operationId },
|
|
118
|
-
...route.oauthScopes === void 0 ? {} : { oauthScopes: route.oauthScopes }
|
|
119
|
-
}));
|
|
120
|
-
}
|
|
139
|
+
...lookupOf(routes, byId),
|
|
140
|
+
kernel: lookupOf(kernel, idsOf(kernel)),
|
|
141
|
+
handler: lookupOf(handler, idsOf(handler))
|
|
121
142
|
};
|
|
122
143
|
}
|
|
123
144
|
/**
|
|
124
145
|
* The operation permissions an OpenAPI document declares: every operation whose
|
|
125
146
|
* `x-permdock-permissions` names exactly one permission of `tree`, keyed by its
|
|
126
|
-
* method, path and `operationId
|
|
127
|
-
*
|
|
128
|
-
*
|
|
147
|
+
* method, path and `operationId`, and every operation that has OAuth scopes in
|
|
148
|
+
* its `security` requirement and names no permission (a scope-only entry). The
|
|
149
|
+
* scopes come from `operation.security`, else `document.security`, for `oauth2`
|
|
150
|
+
* and `openIdConnect` schemes. `x-permdock-enforcement` is `kernel` (the
|
|
151
|
+
* default) or `handler`. An operation naming several or an unknown key, an
|
|
152
|
+
* invalid extension, or `security: []` is left out, so a gate denies it;
|
|
153
|
+
* `onSkip` hears each one with its cause.
|
|
129
154
|
*/
|
|
130
155
|
function operationPermissionsFromOpenApi(document, tree, options = {}) {
|
|
131
156
|
const operations = {};
|
|
157
|
+
const schemes = oauthSchemes(document);
|
|
158
|
+
const documentSecurity = isRecord(document) ? document["security"] : void 0;
|
|
132
159
|
const paths = isRecord(document) && isRecord(document["paths"]) ? document["paths"] : {};
|
|
133
160
|
for (const [path, item] of Object.entries(paths)) {
|
|
134
161
|
if (!isRecord(item)) continue;
|
|
@@ -140,29 +167,52 @@ function operationPermissionsFromOpenApi(document, tree, options = {}) {
|
|
|
140
167
|
path,
|
|
141
168
|
...typeof operationId === "string" ? { operationId } : {}
|
|
142
169
|
};
|
|
143
|
-
const
|
|
144
|
-
if (
|
|
145
|
-
options.onSkip?.(ref, "no-permission");
|
|
146
|
-
continue;
|
|
147
|
-
}
|
|
148
|
-
if (!Array.isArray(keys) || !keys.every((key) => typeof key === "string")) {
|
|
170
|
+
const enforcement = operation["x-permdock-enforcement"];
|
|
171
|
+
if (enforcement !== void 0 && enforcement !== "kernel" && enforcement !== "handler") {
|
|
149
172
|
options.onSkip?.(ref, "invalid-extension");
|
|
150
173
|
continue;
|
|
151
174
|
}
|
|
152
|
-
const
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
175
|
+
const mode = enforcement === "kernel" || enforcement === "handler" ? enforcement : void 0;
|
|
176
|
+
const security = Object.hasOwn(operation, "security") ? operation["security"] : documentSecurity;
|
|
177
|
+
const scopes = oauthScopesOf(security, schemes);
|
|
178
|
+
const keys = operation["x-permdock-permissions"];
|
|
179
|
+
let permission;
|
|
180
|
+
if (keys === void 0) {
|
|
181
|
+
if (scopes.length === 0) {
|
|
182
|
+
const open = Array.isArray(security) && security.length === 0;
|
|
183
|
+
options.onSkip?.(ref, open ? "public" : "no-permission");
|
|
184
|
+
continue;
|
|
185
|
+
}
|
|
186
|
+
} else {
|
|
187
|
+
if (!Array.isArray(keys) || !keys.every((key) => typeof key === "string")) {
|
|
188
|
+
options.onSkip?.(ref, "invalid-extension");
|
|
189
|
+
continue;
|
|
190
|
+
}
|
|
191
|
+
const [key] = keys;
|
|
192
|
+
if (key === void 0 || keys.length !== 1) {
|
|
193
|
+
options.onSkip?.(ref, key === void 0 ? "no-permission" : "several-permissions");
|
|
194
|
+
continue;
|
|
195
|
+
}
|
|
196
|
+
permission = findPermission(tree, key);
|
|
197
|
+
if (permission === void 0) {
|
|
198
|
+
options.onSkip?.(ref, "unknown-permission");
|
|
199
|
+
continue;
|
|
200
|
+
}
|
|
161
201
|
}
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
202
|
+
const extras = {
|
|
203
|
+
...typeof operationId === "string" ? { operationId } : {},
|
|
204
|
+
...scopes.length === 0 ? {} : { oauthScopes: scopes },
|
|
205
|
+
...mode === void 0 ? {} : { enforcement: mode }
|
|
206
|
+
};
|
|
207
|
+
const label = `${ref.method} ${path}`;
|
|
208
|
+
if (permission === void 0) operations[label] = {
|
|
209
|
+
...extras,
|
|
210
|
+
oauthScopes: scopes
|
|
211
|
+
};
|
|
212
|
+
else operations[label] = Object.keys(extras).length === 0 ? permission : {
|
|
213
|
+
...extras,
|
|
214
|
+
permission
|
|
215
|
+
};
|
|
166
216
|
}
|
|
167
217
|
}
|
|
168
218
|
return operationPermissions(operations, options.base === void 0 ? {} : { base: options.base });
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { D as Policy, N as PolicyVocabulary, Xn as
|
|
1
|
+
import { D as Policy, N as PolicyVocabulary, Xn as Decision, Zn as Denial, _t as TokenSigner, br as Principal, cn as AuthEvent, qt as Instant, vt as TokenVerifier } from "./policy-types-DU389Elz.js";
|
|
2
2
|
import { w as Permission } from "./vocabulary-DeZvUaTw.js";
|
|
3
|
-
import { _ as PrincipalSource, a as PermDock, n as DecideOptions, o as PermDockOptions } from "./permdock-
|
|
4
|
-
import { m as ApprovalStore } from "./types-
|
|
5
|
-
import { a as AutomationSource } from "./automation-
|
|
6
|
-
import { n as ApprovalWaiter } from "./waiter-
|
|
7
|
-
import { c as RunResource, i as RunBinding, r as RunAutomation } from "./run-ticket-
|
|
3
|
+
import { _ as PrincipalSource, a as PermDock, n as DecideOptions, o as PermDockOptions } from "./permdock-DV3opaI3.js";
|
|
4
|
+
import { m as ApprovalStore } from "./types-X40XNxRP.js";
|
|
5
|
+
import { a as AutomationSource } from "./automation-_iGeP54L.js";
|
|
6
|
+
import { n as ApprovalWaiter } from "./waiter-BophA4BT.js";
|
|
7
|
+
import { c as RunResource, i as RunBinding, r as RunAutomation } from "./run-ticket-o4RxoaEN.js";
|
|
8
8
|
//#region src/workflow/create.d.ts
|
|
9
9
|
type WorkflowPermDockOptions = PermDockOptions & {
|
|
10
10
|
/** Signs the run tickets `start` mints. */
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { D as Policy, N as PolicyVocabulary,
|
|
1
|
+
import { D as Policy, N as PolicyVocabulary, Sr as Subject, Xn as Decision, br as Principal, gr as Delegation } from "./policy-types-DU389Elz.js";
|
|
2
2
|
import { w as Permission } from "./vocabulary-DeZvUaTw.js";
|
|
3
3
|
import { t as Operation } from "./operations-BMPx7HyO.js";
|
|
4
|
-
import { a as PermDock } from "./permdock-
|
|
5
|
-
import { m as ApprovalStore } from "./types-
|
|
6
|
-
import { t as InstanceOptions } from "./instance-options-
|
|
4
|
+
import { a as PermDock } from "./permdock-DV3opaI3.js";
|
|
5
|
+
import { m as ApprovalStore } from "./types-X40XNxRP.js";
|
|
6
|
+
import { t as InstanceOptions } from "./instance-options-DhQVCuhT.js";
|
|
7
7
|
import { t as RequestContext } from "./request-context-C2_1lchh.js";
|
|
8
|
-
import { n as PermDockWrap } from "./wrap-
|
|
9
|
-
import { o as OtelWrap } from "./types-
|
|
10
|
-
import { t as DeniedText } from "./denied-text-
|
|
8
|
+
import { n as PermDockWrap } from "./wrap-Bq9fHwuT.js";
|
|
9
|
+
import { o as OtelWrap } from "./types-BWjNPQkS.js";
|
|
10
|
+
import { t as DeniedText } from "./denied-text-B6s29jcf.js";
|
|
11
11
|
//#region src/agent/step-up.d.ts
|
|
12
12
|
/**
|
|
13
13
|
* What the user can do to lift a denial: authenticate again with the `acr` and
|