@stigmer/server 3.15.3-dev.20260914100347 → 3.15.3-dev.20260916211208
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/README.md +3 -3
- package/dist/archive/content-store.d.ts +35 -0
- package/dist/archive/content-store.d.ts.map +1 -0
- package/dist/archive/content-store.js +98 -0
- package/dist/archive/content-store.js.map +1 -0
- package/dist/archive/inflate.d.ts +22 -0
- package/dist/archive/inflate.d.ts.map +1 -0
- package/dist/archive/inflate.js +75 -0
- package/dist/archive/inflate.js.map +1 -0
- package/dist/archive/limits.d.ts +33 -0
- package/dist/archive/limits.d.ts.map +1 -0
- package/dist/archive/limits.js +31 -0
- package/dist/archive/limits.js.map +1 -0
- package/dist/archive/open.d.ts +24 -0
- package/dist/archive/open.d.ts.map +1 -0
- package/dist/archive/open.js +93 -0
- package/dist/archive/open.js.map +1 -0
- package/dist/{domain/skill/storage → archive}/prefilter.d.ts +5 -0
- package/dist/archive/prefilter.d.ts.map +1 -0
- package/dist/archive/prefilter.js.map +1 -0
- package/dist/archive/write.d.ts +8 -0
- package/dist/archive/write.d.ts.map +1 -0
- package/dist/archive/write.js +44 -0
- package/dist/archive/write.js.map +1 -0
- package/dist/authorization/authorizer.d.ts +98 -0
- package/dist/authorization/authorizer.d.ts.map +1 -0
- package/dist/authorization/authorizer.js +156 -0
- package/dist/authorization/authorizer.js.map +1 -0
- package/dist/authorization/derived-tuples.d.ts +42 -0
- package/dist/authorization/derived-tuples.d.ts.map +1 -0
- package/dist/authorization/derived-tuples.js +240 -0
- package/dist/authorization/derived-tuples.js.map +1 -0
- package/dist/authorization/evaluator.d.ts +66 -0
- package/dist/authorization/evaluator.d.ts.map +1 -0
- package/dist/authorization/evaluator.js +153 -0
- package/dist/authorization/evaluator.js.map +1 -0
- package/dist/authorization/facts.d.ts +29 -0
- package/dist/authorization/facts.d.ts.map +1 -0
- package/dist/authorization/facts.js +17 -0
- package/dist/authorization/facts.js.map +1 -0
- package/dist/authorization/list-read-scope.d.ts +18 -0
- package/dist/authorization/list-read-scope.d.ts.map +1 -0
- package/dist/authorization/list-read-scope.js +155 -0
- package/dist/authorization/list-read-scope.js.map +1 -0
- package/dist/authorization/model/agent.d.ts +2 -0
- package/dist/authorization/model/agent.d.ts.map +1 -0
- package/dist/authorization/model/agent.js +42 -0
- package/dist/authorization/model/agent.js.map +1 -0
- package/dist/authorization/model/agent_channel.d.ts +2 -0
- package/dist/authorization/model/agent_channel.d.ts.map +1 -0
- package/dist/authorization/model/agent_channel.js +38 -0
- package/dist/authorization/model/agent_channel.js.map +1 -0
- package/dist/authorization/model/agent_execution.d.ts +2 -0
- package/dist/authorization/model/agent_execution.d.ts.map +1 -0
- package/dist/authorization/model/agent_execution.js +25 -0
- package/dist/authorization/model/agent_execution.js.map +1 -0
- package/dist/authorization/model/agent_instance.d.ts +2 -0
- package/dist/authorization/model/agent_instance.d.ts.map +1 -0
- package/dist/authorization/model/agent_instance.js +47 -0
- package/dist/authorization/model/agent_instance.js.map +1 -0
- package/dist/authorization/model/agent_share.d.ts +2 -0
- package/dist/authorization/model/agent_share.d.ts.map +1 -0
- package/dist/authorization/model/agent_share.js +29 -0
- package/dist/authorization/model/agent_share.js.map +1 -0
- package/dist/authorization/model/api_key.d.ts +2 -0
- package/dist/authorization/model/api_key.d.ts.map +1 -0
- package/dist/authorization/model/api_key.js +27 -0
- package/dist/authorization/model/api_key.js.map +1 -0
- package/dist/authorization/model/artifact.d.ts +2 -0
- package/dist/authorization/model/artifact.d.ts.map +1 -0
- package/dist/authorization/model/artifact.js +27 -0
- package/dist/authorization/model/artifact.js.map +1 -0
- package/dist/authorization/model/channel_app.d.ts +2 -0
- package/dist/authorization/model/channel_app.d.ts.map +1 -0
- package/dist/authorization/model/channel_app.js +28 -0
- package/dist/authorization/model/channel_app.js.map +1 -0
- package/dist/authorization/model/default-of.d.ts +38 -0
- package/dist/authorization/model/default-of.d.ts.map +1 -0
- package/dist/authorization/model/default-of.js +39 -0
- package/dist/authorization/model/default-of.js.map +1 -0
- package/dist/authorization/model/environment.d.ts +2 -0
- package/dist/authorization/model/environment.d.ts.map +1 -0
- package/dist/authorization/model/environment.js +33 -0
- package/dist/authorization/model/environment.js.map +1 -0
- package/dist/authorization/model/execution_context.d.ts +2 -0
- package/dist/authorization/model/execution_context.d.ts.map +1 -0
- package/dist/authorization/model/execution_context.js +19 -0
- package/dist/authorization/model/execution_context.js.map +1 -0
- package/dist/authorization/model/iam_policy.d.ts +2 -0
- package/dist/authorization/model/iam_policy.d.ts.map +1 -0
- package/dist/authorization/model/iam_policy.js +31 -0
- package/dist/authorization/model/iam_policy.js.map +1 -0
- package/dist/authorization/model/identity_account.d.ts +2 -0
- package/dist/authorization/model/identity_account.d.ts.map +1 -0
- package/dist/authorization/model/identity_account.js +25 -0
- package/dist/authorization/model/identity_account.js.map +1 -0
- package/dist/authorization/model/index.d.ts +36 -0
- package/dist/authorization/model/index.d.ts.map +1 -0
- package/dist/authorization/model/index.js +72 -0
- package/dist/authorization/model/index.js.map +1 -0
- package/dist/authorization/model/mcp_server.d.ts +2 -0
- package/dist/authorization/model/mcp_server.d.ts.map +1 -0
- package/dist/authorization/model/mcp_server.js +37 -0
- package/dist/authorization/model/mcp_server.js.map +1 -0
- package/dist/authorization/model/memory.d.ts +2 -0
- package/dist/authorization/model/memory.d.ts.map +1 -0
- package/dist/authorization/model/memory.js +26 -0
- package/dist/authorization/model/memory.js.map +1 -0
- package/dist/authorization/model/oauth_app.d.ts +2 -0
- package/dist/authorization/model/oauth_app.d.ts.map +1 -0
- package/dist/authorization/model/oauth_app.js +30 -0
- package/dist/authorization/model/oauth_app.js.map +1 -0
- package/dist/authorization/model/organization.d.ts +2 -0
- package/dist/authorization/model/organization.d.ts.map +1 -0
- package/dist/authorization/model/organization.js +54 -0
- package/dist/authorization/model/organization.js.map +1 -0
- package/dist/authorization/model/plugin.d.ts +2 -0
- package/dist/authorization/model/plugin.d.ts.map +1 -0
- package/dist/authorization/model/plugin.js +44 -0
- package/dist/authorization/model/plugin.js.map +1 -0
- package/dist/authorization/model/project.d.ts +2 -0
- package/dist/authorization/model/project.d.ts.map +1 -0
- package/dist/authorization/model/project.js +32 -0
- package/dist/authorization/model/project.js.map +1 -0
- package/dist/authorization/model/rewrite.d.ts +127 -0
- package/dist/authorization/model/rewrite.d.ts.map +1 -0
- package/dist/authorization/model/rewrite.js +82 -0
- package/dist/authorization/model/rewrite.js.map +1 -0
- package/dist/authorization/model/schedule.d.ts +2 -0
- package/dist/authorization/model/schedule.d.ts.map +1 -0
- package/dist/authorization/model/schedule.js +29 -0
- package/dist/authorization/model/schedule.js.map +1 -0
- package/dist/authorization/model/session.d.ts +2 -0
- package/dist/authorization/model/session.d.ts.map +1 -0
- package/dist/authorization/model/session.js +38 -0
- package/dist/authorization/model/session.js.map +1 -0
- package/dist/authorization/model/skill.d.ts +2 -0
- package/dist/authorization/model/skill.d.ts.map +1 -0
- package/dist/authorization/model/skill.js +38 -0
- package/dist/authorization/model/skill.js.map +1 -0
- package/dist/authorization/model/workflow.d.ts +2 -0
- package/dist/authorization/model/workflow.d.ts.map +1 -0
- package/dist/authorization/model/workflow.js +38 -0
- package/dist/authorization/model/workflow.js.map +1 -0
- package/dist/authorization/model/workflow_execution.d.ts +2 -0
- package/dist/authorization/model/workflow_execution.d.ts.map +1 -0
- package/dist/authorization/model/workflow_execution.js +32 -0
- package/dist/authorization/model/workflow_execution.js.map +1 -0
- package/dist/authorization/model/workflow_instance.d.ts +2 -0
- package/dist/authorization/model/workflow_instance.d.ts.map +1 -0
- package/dist/authorization/model/workflow_instance.js +92 -0
- package/dist/authorization/model/workflow_instance.js.map +1 -0
- package/dist/authorization/organization-directory.d.ts +13 -0
- package/dist/authorization/organization-directory.d.ts.map +1 -0
- package/dist/authorization/organization-directory.js +83 -0
- package/dist/authorization/organization-directory.js.map +1 -0
- package/dist/authorization/person.d.ts +42 -0
- package/dist/authorization/person.d.ts.map +1 -0
- package/dist/authorization/person.js +19 -0
- package/dist/authorization/person.js.map +1 -0
- package/dist/authorization/posture.d.ts +38 -0
- package/dist/authorization/posture.d.ts.map +1 -0
- package/dist/authorization/posture.js +7 -0
- package/dist/authorization/posture.js.map +1 -0
- package/dist/authorization/schedule-fire-caller.d.ts +12 -0
- package/dist/authorization/schedule-fire-caller.d.ts.map +1 -0
- package/dist/authorization/schedule-fire-caller.js +67 -0
- package/dist/authorization/schedule-fire-caller.js.map +1 -0
- package/dist/authorization/store-test-kit.d.ts +68 -0
- package/dist/authorization/store-test-kit.d.ts.map +1 -0
- package/dist/authorization/store-test-kit.js +311 -0
- package/dist/authorization/store-test-kit.js.map +1 -0
- package/dist/authorization/tuples.d.ts +115 -0
- package/dist/authorization/tuples.d.ts.map +1 -0
- package/dist/authorization/tuples.js +83 -0
- package/dist/authorization/tuples.js.map +1 -0
- package/dist/boot/compose.d.ts.map +1 -1
- package/dist/boot/compose.js +157 -32
- package/dist/boot/compose.js.map +1 -1
- package/dist/boot/inprocess.d.ts +12 -0
- package/dist/boot/inprocess.d.ts.map +1 -1
- package/dist/boot/inprocess.js +62 -20
- package/dist/boot/inprocess.js.map +1 -1
- package/dist/domain/agent/controller.d.ts.map +1 -1
- package/dist/domain/agent/controller.js +9 -0
- package/dist/domain/agent/controller.js.map +1 -1
- package/dist/domain/iampolicy/constants.d.ts +11 -0
- package/dist/domain/iampolicy/constants.d.ts.map +1 -1
- package/dist/domain/iampolicy/constants.js +11 -0
- package/dist/domain/iampolicy/constants.js.map +1 -1
- package/dist/domain/iampolicy/membership.d.ts +72 -1
- package/dist/domain/iampolicy/membership.d.ts.map +1 -1
- package/dist/domain/iampolicy/membership.js +141 -56
- package/dist/domain/iampolicy/membership.js.map +1 -1
- package/dist/domain/identityaccount/actor.d.ts +26 -0
- package/dist/domain/identityaccount/actor.d.ts.map +1 -0
- package/dist/domain/identityaccount/actor.js +17 -0
- package/dist/domain/identityaccount/actor.js.map +1 -0
- package/dist/domain/mcpserver/controller.d.ts.map +1 -1
- package/dist/domain/mcpserver/controller.js +9 -0
- package/dist/domain/mcpserver/controller.js.map +1 -1
- package/dist/domain/plugin/archive.d.ts +37 -0
- package/dist/domain/plugin/archive.d.ts.map +1 -0
- package/dist/domain/plugin/archive.js +50 -0
- package/dist/domain/plugin/archive.js.map +1 -0
- package/dist/domain/plugin/constants.d.ts +38 -0
- package/dist/domain/plugin/constants.d.ts.map +1 -0
- package/dist/domain/plugin/constants.js +46 -0
- package/dist/domain/plugin/constants.js.map +1 -0
- package/dist/domain/plugin/controller.d.ts +25 -0
- package/dist/domain/plugin/controller.d.ts.map +1 -0
- package/dist/domain/plugin/controller.js +493 -0
- package/dist/domain/plugin/controller.js.map +1 -0
- package/dist/domain/plugin/materialize/agent.d.ts +13 -0
- package/dist/domain/plugin/materialize/agent.d.ts.map +1 -0
- package/dist/domain/plugin/materialize/agent.js +128 -0
- package/dist/domain/plugin/materialize/agent.js.map +1 -0
- package/dist/domain/plugin/materialize/default-agent-instructions.d.ts +22 -0
- package/dist/domain/plugin/materialize/default-agent-instructions.d.ts.map +1 -0
- package/dist/domain/plugin/materialize/default-agent-instructions.js +31 -0
- package/dist/domain/plugin/materialize/default-agent-instructions.js.map +1 -0
- package/dist/domain/plugin/materialize/identity.d.ts +28 -0
- package/dist/domain/plugin/materialize/identity.d.ts.map +1 -0
- package/dist/domain/plugin/materialize/identity.js +40 -0
- package/dist/domain/plugin/materialize/identity.js.map +1 -0
- package/dist/domain/plugin/materialize/mcp-servers.d.ts +15 -0
- package/dist/domain/plugin/materialize/mcp-servers.d.ts.map +1 -0
- package/dist/domain/plugin/materialize/mcp-servers.js +131 -0
- package/dist/domain/plugin/materialize/mcp-servers.js.map +1 -0
- package/dist/domain/plugin/materialize/plan.d.ts +24 -0
- package/dist/domain/plugin/materialize/plan.d.ts.map +1 -0
- package/dist/domain/plugin/materialize/plan.js +77 -0
- package/dist/domain/plugin/materialize/plan.js.map +1 -0
- package/dist/domain/plugin/materialize/ports.d.ts +42 -0
- package/dist/domain/plugin/materialize/ports.d.ts.map +1 -0
- package/dist/domain/plugin/materialize/ports.js +2 -0
- package/dist/domain/plugin/materialize/ports.js.map +1 -0
- package/dist/domain/plugin/materialize/skills.d.ts +12 -0
- package/dist/domain/plugin/materialize/skills.d.ts.map +1 -0
- package/dist/domain/plugin/materialize/skills.js +44 -0
- package/dist/domain/plugin/materialize/skills.js.map +1 -0
- package/dist/domain/plugin/materialize/workflows.d.ts +15 -0
- package/dist/domain/plugin/materialize/workflows.d.ts.map +1 -0
- package/dist/domain/plugin/materialize/workflows.js +31 -0
- package/dist/domain/plugin/materialize/workflows.js.map +1 -0
- package/dist/domain/plugin/members.d.ts +42 -0
- package/dist/domain/plugin/members.d.ts.map +1 -0
- package/dist/domain/plugin/members.js +97 -0
- package/dist/domain/plugin/members.js.map +1 -0
- package/dist/domain/plugin/overlay/documents.d.ts +31 -0
- package/dist/domain/plugin/overlay/documents.d.ts.map +1 -0
- package/dist/domain/plugin/overlay/documents.js +38 -0
- package/dist/domain/plugin/overlay/documents.js.map +1 -0
- package/dist/domain/plugin/overlay/parse.d.ts +16 -0
- package/dist/domain/plugin/overlay/parse.d.ts.map +1 -0
- package/dist/domain/plugin/overlay/parse.js +79 -0
- package/dist/domain/plugin/overlay/parse.js.map +1 -0
- package/dist/domain/plugin/overlay/sanitize.d.ts +10 -0
- package/dist/domain/plugin/overlay/sanitize.d.ts.map +1 -0
- package/dist/domain/plugin/overlay/sanitize.js +101 -0
- package/dist/domain/plugin/overlay/sanitize.js.map +1 -0
- package/dist/domain/plugin/push.d.ts +133 -0
- package/dist/domain/plugin/push.d.ts.map +1 -0
- package/dist/domain/plugin/push.js +800 -0
- package/dist/domain/plugin/push.js.map +1 -0
- package/dist/domain/plugin/search-extractor.d.ts +3 -0
- package/dist/domain/plugin/search-extractor.d.ts.map +1 -0
- package/dist/domain/plugin/search-extractor.js +41 -0
- package/dist/domain/plugin/search-extractor.js.map +1 -0
- package/dist/domain/skill/constants.d.ts +6 -11
- package/dist/domain/skill/constants.d.ts.map +1 -1
- package/dist/domain/skill/constants.js +6 -11
- package/dist/domain/skill/constants.js.map +1 -1
- package/dist/domain/skill/controller.d.ts.map +1 -1
- package/dist/domain/skill/controller.js +33 -30
- package/dist/domain/skill/controller.js.map +1 -1
- package/dist/domain/skill/push.d.ts +9 -10
- package/dist/domain/skill/push.d.ts.map +1 -1
- package/dist/domain/skill/push.js +53 -122
- package/dist/domain/skill/push.js.map +1 -1
- package/dist/domain/skill/search-extractor.d.ts.map +1 -1
- package/dist/domain/skill/search-extractor.js.map +1 -1
- package/dist/domain/skill/storage/artifact-storage.d.ts +26 -29
- package/dist/domain/skill/storage/artifact-storage.d.ts.map +1 -1
- package/dist/domain/skill/storage/artifact-storage.js +6 -103
- package/dist/domain/skill/storage/artifact-storage.js.map +1 -1
- package/dist/domain/skill/storage/zip-gate.d.ts +1 -2
- package/dist/domain/skill/storage/zip-gate.d.ts.map +1 -1
- package/dist/domain/skill/storage/zip-gate.js +56 -126
- package/dist/domain/skill/storage/zip-gate.js.map +1 -1
- package/dist/domain/skill/version-resolution.d.ts +5 -5
- package/dist/domain/skill/version-resolution.d.ts.map +1 -1
- package/dist/domain/skill/version-resolution.js +34 -216
- package/dist/domain/skill/version-resolution.js.map +1 -1
- package/dist/domain/workflow/controller.d.ts.map +1 -1
- package/dist/domain/workflow/controller.js +30 -3
- package/dist/domain/workflow/controller.js.map +1 -1
- package/dist/domain/workflow/registry/data/task-kind-registry.json +1 -0
- package/dist/extensions/authorizer.d.ts +10 -5
- package/dist/extensions/authorizer.d.ts.map +1 -1
- package/dist/extensions/drivers.d.ts +4 -1
- package/dist/extensions/drivers.d.ts.map +1 -1
- package/dist/extensions/list-read-scope.d.ts +75 -11
- package/dist/extensions/list-read-scope.d.ts.map +1 -1
- package/dist/extensions/list-read-scope.js +40 -7
- package/dist/extensions/list-read-scope.js.map +1 -1
- package/dist/extensions/organization-directory.d.ts +13 -9
- package/dist/extensions/organization-directory.d.ts.map +1 -1
- package/dist/extensions/organization-directory.js.map +1 -1
- package/dist/extensions/resource-authorization.d.ts +33 -0
- package/dist/extensions/resource-authorization.d.ts.map +1 -1
- package/dist/extensions/schedule-fire-caller.d.ts +45 -18
- package/dist/extensions/schedule-fire-caller.d.ts.map +1 -1
- package/dist/extensions/schedule-fire-caller.js +12 -1
- package/dist/extensions/schedule-fire-caller.js.map +1 -1
- package/dist/index.d.ts +10 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +8 -0
- package/dist/index.js.map +1 -1
- package/dist/pipeline/apiresource-labels.d.ts +23 -3
- package/dist/pipeline/apiresource-labels.d.ts.map +1 -1
- package/dist/pipeline/apiresource-labels.js +20 -0
- package/dist/pipeline/apiresource-labels.js.map +1 -1
- package/dist/pipeline/apiresource-meta.d.ts +21 -0
- package/dist/pipeline/apiresource-meta.d.ts.map +1 -1
- package/dist/pipeline/apiresource-meta.js +28 -0
- package/dist/pipeline/apiresource-meta.js.map +1 -1
- package/dist/pipeline/errors.d.ts.map +1 -1
- package/dist/pipeline/errors.js.map +1 -1
- package/dist/pipeline/steps/authorization-facts.d.ts +12 -0
- package/dist/pipeline/steps/authorization-facts.d.ts.map +1 -0
- package/dist/pipeline/steps/authorization-facts.js +100 -0
- package/dist/pipeline/steps/authorization-facts.js.map +1 -0
- package/dist/pipeline/steps/authorization-tuples.d.ts.map +1 -1
- package/dist/pipeline/steps/authorization-tuples.js +7 -26
- package/dist/pipeline/steps/authorization-tuples.js.map +1 -1
- package/dist/pipeline/steps/delete.d.ts.map +1 -1
- package/dist/pipeline/steps/delete.js +1 -1
- package/dist/pipeline/steps/delete.js.map +1 -1
- package/dist/pipeline/steps/duplicate.d.ts.map +1 -1
- package/dist/pipeline/steps/duplicate.js.map +1 -1
- package/dist/pipeline/steps/guard-plugin-managed.d.ts +12 -0
- package/dist/pipeline/steps/guard-plugin-managed.d.ts.map +1 -0
- package/dist/pipeline/steps/guard-plugin-managed.js +96 -0
- package/dist/pipeline/steps/guard-plugin-managed.js.map +1 -0
- package/dist/pipeline/steps/guard-reserved-labels.d.ts +16 -2
- package/dist/pipeline/steps/guard-reserved-labels.d.ts.map +1 -1
- package/dist/pipeline/steps/guard-reserved-labels.js +11 -7
- package/dist/pipeline/steps/guard-reserved-labels.js.map +1 -1
- package/dist/pipeline/steps/helpers.d.ts.map +1 -1
- package/dist/pipeline/steps/helpers.js.map +1 -1
- package/dist/pipeline/steps/index-search.d.ts.map +1 -1
- package/dist/pipeline/steps/index-search.js.map +1 -1
- package/dist/pipeline/steps/load-existing.d.ts.map +1 -1
- package/dist/pipeline/steps/load-existing.js +1 -1
- package/dist/pipeline/steps/load-existing.js.map +1 -1
- package/dist/pipeline/steps/references.d.ts +16 -0
- package/dist/pipeline/steps/references.d.ts.map +1 -1
- package/dist/pipeline/steps/references.js +18 -0
- package/dist/pipeline/steps/references.js.map +1 -1
- package/dist/pipeline/steps/resolve-artifact-source.d.ts +35 -0
- package/dist/pipeline/steps/resolve-artifact-source.d.ts.map +1 -0
- package/dist/pipeline/steps/resolve-artifact-source.js +27 -0
- package/dist/pipeline/steps/resolve-artifact-source.js.map +1 -0
- package/dist/pipeline/steps/server-stamped-reserved-labels.d.ts.map +1 -1
- package/dist/pipeline/steps/server-stamped-reserved-labels.js.map +1 -1
- package/dist/pipeline/steps/shapes.d.ts +18 -0
- package/dist/pipeline/steps/shapes.d.ts.map +1 -1
- package/dist/pipeline/steps/shapes.js +29 -0
- package/dist/pipeline/steps/shapes.js.map +1 -1
- package/dist/pipeline/steps/slug.d.ts.map +1 -1
- package/dist/pipeline/steps/slug.js.map +1 -1
- package/dist/pipeline/steps/validate-visibility.d.ts +9 -0
- package/dist/pipeline/steps/validate-visibility.d.ts.map +1 -1
- package/dist/pipeline/steps/validate-visibility.js +6 -1
- package/dist/pipeline/steps/validate-visibility.js.map +1 -1
- package/dist/pipeline/steps/validation.d.ts.map +1 -1
- package/dist/pipeline/steps/validation.js.map +1 -1
- package/dist/pipeline/steps/version-archive.d.ts +63 -0
- package/dist/pipeline/steps/version-archive.d.ts.map +1 -0
- package/dist/pipeline/steps/version-archive.js +129 -0
- package/dist/pipeline/steps/version-archive.js.map +1 -0
- package/dist/pipeline/steps/version-history.d.ts +49 -0
- package/dist/pipeline/steps/version-history.d.ts.map +1 -0
- package/dist/pipeline/steps/version-history.js +229 -0
- package/dist/pipeline/steps/version-history.js.map +1 -0
- package/dist/pipeline/steps/visibility-gates.d.ts +8 -0
- package/dist/pipeline/steps/visibility-gates.d.ts.map +1 -1
- package/dist/pipeline/steps/visibility-gates.js +7 -2
- package/dist/pipeline/steps/visibility-gates.js.map +1 -1
- package/dist/query/search/registry.d.ts.map +1 -1
- package/dist/query/search/registry.js +2 -0
- package/dist/query/search/registry.js.map +1 -1
- package/dist/temporal/schedule/run-starter.d.ts +1 -1
- package/dist/temporal/schedule/run-starter.d.ts.map +1 -1
- package/dist/temporal/schedule/run-starter.js +14 -1
- package/dist/temporal/schedule/run-starter.js.map +1 -1
- package/package.json +5 -4
- package/src/archive/__tests__/archive.test.ts +233 -0
- package/src/{domain/skill → archive}/__tests__/prefilter.test.ts +1 -1
- package/src/archive/content-store.ts +132 -0
- package/src/archive/inflate.ts +107 -0
- package/src/archive/limits.ts +42 -0
- package/src/archive/open.ts +131 -0
- package/src/{domain/skill/storage → archive}/prefilter.ts +5 -0
- package/src/archive/write.ts +54 -0
- package/src/authorization/README.md +124 -0
- package/src/authorization/__tests__/authorizer.test.ts +719 -0
- package/src/authorization/__tests__/derived-tuples.test.ts +802 -0
- package/src/authorization/__tests__/drivers.ts +70 -0
- package/src/authorization/__tests__/evaluator.test.ts +359 -0
- package/src/authorization/__tests__/facts.test.ts +155 -0
- package/src/authorization/__tests__/fixtures/fga/agent-channel-owner.fga.yaml +112 -0
- package/src/authorization/__tests__/fixtures/fga/agent-share-owner.fga.yaml +109 -0
- package/src/authorization/__tests__/fixtures/fga/artifact-org-and-owner.fga.yaml +128 -0
- package/src/authorization/__tests__/fixtures/fga/blueprint-private-visibility.fga.yaml +410 -0
- package/src/authorization/__tests__/fixtures/fga/channel-app-owner.fga.yaml +125 -0
- package/src/authorization/__tests__/fixtures/fga/channel-participation.fga.yaml +201 -0
- package/src/authorization/__tests__/fixtures/fga/channel-session-visibility.fga.yaml +187 -0
- package/src/authorization/__tests__/fixtures/fga/cross-org-share-creation.fga.yaml +98 -0
- package/src/authorization/__tests__/fixtures/fga/default-instance-inheritance.fga.yaml +271 -0
- package/src/authorization/__tests__/fixtures/fga/memory-subject-only.fga.yaml +72 -0
- package/src/authorization/__tests__/fixtures/fga/org-admin-owner-inheritance.fga.yaml +328 -0
- package/src/authorization/__tests__/fixtures/fga/org-shared-environment.fga.yaml +144 -0
- package/src/authorization/__tests__/fixtures/fga/platform-visibility.fga.yaml +223 -0
- package/src/authorization/__tests__/fixtures/fga/provider-standing-viewer.fga.yaml +40 -0
- package/src/authorization/__tests__/fixtures/fga/public-visibility-setter.fga.yaml +52 -0
- package/src/authorization/__tests__/fixtures/fga/reserved-label-writer.fga.yaml +41 -0
- package/src/authorization/__tests__/fixtures/fga/schedule-owner.fga.yaml +113 -0
- package/src/authorization/__tests__/fixtures/fga/schedule-session-visibility.fga.yaml +214 -0
- package/src/authorization/__tests__/fixtures/fga/session-personal-resource.fga.yaml +117 -0
- package/src/authorization/__tests__/fixtures/fga/workflow-execution-sharing.fga.yaml +192 -0
- package/src/authorization/__tests__/list-read-scope.measure.test.ts +317 -0
- package/src/authorization/__tests__/list-read-scope.test.ts +796 -0
- package/src/authorization/__tests__/organization-directory.test.ts +236 -0
- package/src/authorization/__tests__/person.test.ts +114 -0
- package/src/authorization/__tests__/posture.test.ts +25 -0
- package/src/authorization/__tests__/schedule-fire-caller.test.ts +134 -0
- package/src/authorization/__tests__/store-tests.test.ts +306 -0
- package/src/authorization/__tests__/support.ts +101 -0
- package/src/authorization/__tests__/tuples.test.ts +62 -0
- package/src/authorization/__tests__/wire-permissions.test.ts +154 -0
- package/src/authorization/authorizer.ts +208 -0
- package/src/authorization/derived-tuples.ts +384 -0
- package/src/authorization/evaluator.ts +283 -0
- package/src/authorization/facts.ts +47 -0
- package/src/authorization/list-read-scope.ts +216 -0
- package/src/authorization/model/__tests__/registry.test.ts +317 -0
- package/src/authorization/model/agent.ts +64 -0
- package/src/authorization/model/agent_channel.ts +49 -0
- package/src/authorization/model/agent_execution.ts +33 -0
- package/src/authorization/model/agent_instance.ts +66 -0
- package/src/authorization/model/agent_share.ts +40 -0
- package/src/authorization/model/api_key.ts +28 -0
- package/src/authorization/model/artifact.ts +38 -0
- package/src/authorization/model/channel_app.ts +39 -0
- package/src/authorization/model/default-of.ts +99 -0
- package/src/authorization/model/environment.ts +48 -0
- package/src/authorization/model/execution_context.ts +20 -0
- package/src/authorization/model/iam_policy.ts +42 -0
- package/src/authorization/model/identity_account.ts +26 -0
- package/src/authorization/model/index.ts +108 -0
- package/src/authorization/model/mcp_server.ts +59 -0
- package/src/authorization/model/memory.ts +27 -0
- package/src/authorization/model/oauth_app.ts +42 -0
- package/src/authorization/model/organization.ts +55 -0
- package/src/authorization/model/plugin.ts +66 -0
- package/src/authorization/model/project.ts +47 -0
- package/src/authorization/model/rewrite.ts +213 -0
- package/src/authorization/model/schedule.ts +40 -0
- package/src/authorization/model/session.ts +50 -0
- package/src/authorization/model/skill.ts +60 -0
- package/src/authorization/model/workflow.ts +60 -0
- package/src/authorization/model/workflow_execution.ts +44 -0
- package/src/authorization/model/workflow_instance.ts +122 -0
- package/src/authorization/organization-directory.ts +114 -0
- package/src/authorization/person.ts +68 -0
- package/src/authorization/posture.ts +49 -0
- package/src/authorization/schedule-fire-caller.ts +91 -0
- package/src/authorization/store-test-kit.ts +454 -0
- package/src/authorization/tuples.ts +190 -0
- package/src/boot/compose.ts +175 -38
- package/src/boot/inprocess.ts +108 -30
- package/src/domain/agent/controller.ts +11 -0
- package/src/domain/iampolicy/__tests__/membership.test.ts +357 -3
- package/src/domain/iampolicy/constants.ts +12 -0
- package/src/domain/iampolicy/membership.ts +221 -66
- package/src/domain/identityaccount/actor.ts +44 -0
- package/src/domain/mcpserver/controller.ts +11 -0
- package/src/domain/plugin/__tests__/materialize.test.ts +303 -0
- package/src/domain/plugin/__tests__/overlay-parse.test.ts +85 -0
- package/src/domain/plugin/__tests__/plugin.test.ts +681 -0
- package/src/domain/plugin/__tests__/sanitize.test.ts +174 -0
- package/src/domain/plugin/archive.ts +89 -0
- package/src/domain/plugin/constants.ts +53 -0
- package/src/domain/plugin/controller.ts +913 -0
- package/src/domain/plugin/materialize/agent.ts +186 -0
- package/src/domain/plugin/materialize/default-agent-instructions.ts +59 -0
- package/src/domain/plugin/materialize/identity.ts +67 -0
- package/src/domain/plugin/materialize/mcp-servers.ts +175 -0
- package/src/domain/plugin/materialize/plan.ts +124 -0
- package/src/domain/plugin/materialize/ports.ts +53 -0
- package/src/domain/plugin/materialize/skills.ts +68 -0
- package/src/domain/plugin/materialize/workflows.ts +51 -0
- package/src/domain/plugin/members.ts +180 -0
- package/src/domain/plugin/overlay/documents.ts +78 -0
- package/src/domain/plugin/overlay/parse.ts +115 -0
- package/src/domain/plugin/overlay/sanitize.ts +149 -0
- package/src/domain/plugin/push.ts +1062 -0
- package/src/domain/plugin/search-extractor.ts +60 -0
- package/src/domain/skill/constants.ts +11 -14
- package/src/domain/skill/controller.ts +44 -36
- package/src/domain/skill/push.ts +61 -156
- package/src/domain/skill/search-extractor.ts +3 -1
- package/src/domain/skill/storage/artifact-storage.ts +23 -124
- package/src/domain/skill/storage/zip-gate.ts +58 -154
- package/src/domain/skill/version-resolution.ts +67 -269
- package/src/domain/workflow/controller.ts +38 -4
- package/src/domain/workflow/registry/data/task-kind-registry.json +1 -0
- package/src/extensions/__tests__/built-in-authorization-composed.test.ts +835 -0
- package/src/extensions/__tests__/composed-support.ts +32 -1
- package/src/extensions/__tests__/extension-composition.test.ts +35 -0
- package/src/extensions/__tests__/list-read-scope.test.ts +245 -3
- package/src/extensions/__tests__/role-reconciliation-composed.test.ts +209 -0
- package/src/extensions/__tests__/tier-truthfulness.test.ts +6 -14
- package/src/extensions/authorizer.ts +10 -5
- package/src/extensions/drivers.ts +4 -1
- package/src/extensions/list-read-scope.ts +116 -16
- package/src/extensions/organization-directory.ts +13 -9
- package/src/extensions/resource-authorization.ts +34 -0
- package/src/extensions/schedule-fire-caller.ts +49 -18
- package/src/index.ts +51 -1
- package/src/pipeline/__tests__/inherited-authorization-parent.test.ts +51 -0
- package/src/pipeline/__tests__/router-transport.test.ts +1 -3
- package/src/pipeline/apiresource-labels.ts +31 -3
- package/src/pipeline/apiresource-meta.ts +37 -0
- package/src/pipeline/errors.ts +5 -5
- package/src/pipeline/steps/__tests__/authorize-annotation-completeness.test.ts +1 -20
- package/src/pipeline/steps/__tests__/guard-memory-capture.test.ts +3 -9
- package/src/pipeline/steps/__tests__/guard-plugin-managed.test.ts +151 -0
- package/src/pipeline/steps/__tests__/guard-reserved-labels.test.ts +83 -8
- package/src/pipeline/steps/authorization-facts.ts +131 -0
- package/src/pipeline/steps/authorization-tuples.ts +7 -28
- package/src/pipeline/steps/delete.ts +11 -3
- package/src/pipeline/steps/duplicate.ts +8 -2
- package/src/pipeline/steps/guard-plugin-managed.ts +133 -0
- package/src/pipeline/steps/guard-reserved-labels.ts +29 -8
- package/src/pipeline/steps/helpers.ts +4 -1
- package/src/pipeline/steps/index-search.ts +28 -15
- package/src/pipeline/steps/load-existing.ts +12 -3
- package/src/pipeline/steps/references.ts +36 -2
- package/src/pipeline/steps/resolve-artifact-source.ts +66 -0
- package/src/pipeline/steps/server-stamped-reserved-labels.ts +2 -1
- package/src/pipeline/steps/shapes.ts +31 -0
- package/src/pipeline/steps/slug.ts +7 -2
- package/src/pipeline/steps/validate-visibility.ts +9 -2
- package/src/pipeline/steps/validation.ts +3 -1
- package/src/pipeline/steps/version-archive.ts +225 -0
- package/src/pipeline/steps/version-history.ts +362 -0
- package/src/pipeline/steps/visibility-gates.ts +12 -9
- package/src/query/README.md +1 -1
- package/src/query/search/__tests__/criteria.test.ts +6 -7
- package/src/query/search/__tests__/query-store.test.ts +9 -2
- package/src/query/search/__tests__/registry.test.ts +6 -4
- package/src/query/search/registry.ts +6 -1
- package/src/temporal/schedule/__tests__/run-starter.test.ts +86 -24
- package/src/temporal/schedule/run-starter.ts +31 -8
- package/dist/domain/skill/storage/prefilter.d.ts.map +0 -1
- package/dist/domain/skill/storage/prefilter.js.map +0 -1
- /package/dist/{domain/skill/storage → archive}/prefilter.js +0 -0
|
@@ -2,32 +2,59 @@
|
|
|
2
2
|
* The schedule-fire caller seam (stigmer-cloud#572) — WHO a schedule fire
|
|
3
3
|
* acts as when the RunStarter re-enters the execution create pipeline.
|
|
4
4
|
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
*
|
|
16
|
-
*
|
|
5
|
+
* With no driver composed a fire enters as the in-process `internal`
|
|
6
|
+
* class — the trusted-local laptop's lane, where the one caller is the
|
|
7
|
+
* server's operator and attribution has nobody to separate. Under an
|
|
8
|
+
* authentication posture that lane is wrong: the internal class carries
|
|
9
|
+
* the operator's email or `"system"`, which no enforcing evaluator
|
|
10
|
+
* recognizes as a person, so the fired session would belong to nobody
|
|
11
|
+
* (the FGA model's own words — "without it a scheduled run is invisible
|
|
12
|
+
* to every human, including the schedule's owner"). Two drivers answer
|
|
13
|
+
* it: the cloud edition mints a schedule JWT per fire (sub = the org's
|
|
14
|
+
* system-schedule account, claim = the firing Schedule id) so the run
|
|
15
|
+
* reaches the schedule's viewer set through the session#schedule link;
|
|
16
|
+
* open source, under the built-in authorization posture, makes the fire
|
|
17
|
+
* act as the schedule's CREATOR (authorization/schedule-fire-caller.ts),
|
|
18
|
+
* so the run and its session are that person's. The fire then propagates
|
|
19
|
+
* the identity through the R5 caller-propagation header exactly like the
|
|
20
|
+
* other request-origin in-process creates.
|
|
17
21
|
*
|
|
18
22
|
* Single-instance point. The mint is per fire — the schedule id is a
|
|
19
|
-
* claim of the minted credential, never a cached field
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
+
* claim of the minted credential, never a cached field. Two failure
|
|
24
|
+
* shapes, and the RunStarter tells them apart by type, the store-fault
|
|
25
|
+
* precedent (`ResourceNotFoundError` is checked with `instanceof`; every
|
|
26
|
+
* other fault is infrastructure):
|
|
27
|
+
*
|
|
28
|
+
* - any other thrown error is an INFRASTRUCTURE fault: the RunStarter
|
|
29
|
+
* lets it propagate, so the tick activity retries (the deterministic
|
|
30
|
+
* execution name absorbs the retry) and a manual trigger surfaces
|
|
31
|
+
* the failure to its caller;
|
|
32
|
+
* - `ScheduleFireCallerRefusedError` is a DETERMINISTIC refusal — this
|
|
33
|
+
* fire can act as nobody, and no retry will change that (a schedule
|
|
34
|
+
* stamped by no person this server knows). The RunStarter answers
|
|
35
|
+
* the `refused` outcome the way it answers a launch gate's refusal:
|
|
36
|
+
* the failure streak counts it and pauses the schedule with the
|
|
37
|
+
* reason, so the person who scheduled it sees why in the console
|
|
38
|
+
* instead of a tick failing quietly forever.
|
|
23
39
|
*/
|
|
24
40
|
import type { CallerIdentity } from "./identity.js";
|
|
25
41
|
export interface ScheduleFireCallerMint {
|
|
26
42
|
/**
|
|
27
43
|
* Mints the caller identity one fire acts as. `rawToken` must carry the
|
|
28
|
-
* edition's verifiable credential for the identity
|
|
29
|
-
* fire-scoped claims
|
|
44
|
+
* edition's verifiable credential for the identity when the edition
|
|
45
|
+
* reads fire-scoped claims from it downstream (the cloud does — the
|
|
46
|
+
* schedule id); an edition that propagates the identity in-process and
|
|
47
|
+
* reads nothing off the token leaves it empty (open source does).
|
|
30
48
|
*/
|
|
31
49
|
mintFireCaller(org: string, scheduleId: string): Promise<CallerIdentity>;
|
|
32
50
|
}
|
|
51
|
+
/**
|
|
52
|
+
* The mint's deterministic refusal (the module header): thrown by a
|
|
53
|
+
* driver when the fire can act as nobody and retrying cannot help. The
|
|
54
|
+
* message is the reason the schedule's status carries, so it is written
|
|
55
|
+
* for the person who scheduled the run.
|
|
56
|
+
*/
|
|
57
|
+
export declare class ScheduleFireCallerRefusedError extends Error {
|
|
58
|
+
constructor(reason: string);
|
|
59
|
+
}
|
|
33
60
|
//# sourceMappingURL=schedule-fire-caller.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schedule-fire-caller.d.ts","sourceRoot":"","sources":["../../src/extensions/schedule-fire-caller.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"schedule-fire-caller.d.ts","sourceRoot":"","sources":["../../src/extensions/schedule-fire-caller.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsCG;AACH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AAEpD,MAAM,WAAW,sBAAsB;IACrC;;;;;;OAMG;IACH,cAAc,CAAC,GAAG,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,cAAc,CAAC,CAAC;CAC1E;AAED;;;;;GAKG;AACH,qBAAa,8BAA+B,SAAQ,KAAK;gBAC3C,MAAM,EAAE,MAAM;CAI3B"}
|
|
@@ -1,2 +1,13 @@
|
|
|
1
|
-
|
|
1
|
+
/**
|
|
2
|
+
* The mint's deterministic refusal (the module header): thrown by a
|
|
3
|
+
* driver when the fire can act as nobody and retrying cannot help. The
|
|
4
|
+
* message is the reason the schedule's status carries, so it is written
|
|
5
|
+
* for the person who scheduled the run.
|
|
6
|
+
*/
|
|
7
|
+
export class ScheduleFireCallerRefusedError extends Error {
|
|
8
|
+
constructor(reason) {
|
|
9
|
+
super(reason);
|
|
10
|
+
this.name = "ScheduleFireCallerRefusedError";
|
|
11
|
+
}
|
|
12
|
+
}
|
|
2
13
|
//# sourceMappingURL=schedule-fire-caller.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schedule-fire-caller.js","sourceRoot":"","sources":["../../src/extensions/schedule-fire-caller.ts"],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"schedule-fire-caller.js","sourceRoot":"","sources":["../../src/extensions/schedule-fire-caller.ts"],"names":[],"mappings":"AAoDA;;;;;GAKG;AACH,MAAM,OAAO,8BAA+B,SAAQ,KAAK;IACvD,YAAY,MAAc;QACxB,KAAK,CAAC,MAAM,CAAC,CAAC;QACd,IAAI,CAAC,IAAI,GAAG,gCAAgC,CAAC;IAC/C,CAAC;CACF"}
|
package/dist/index.d.ts
CHANGED
|
@@ -69,8 +69,18 @@ export type { AuthorizationQueryEngine } from "./extensions/authorization-querie
|
|
|
69
69
|
export type { IdentityFederation } from "./extensions/identity-federation.js";
|
|
70
70
|
export type { AccountsBySubject } from "./domain/identityaccount/resolve.js";
|
|
71
71
|
export { identityIdForSubject } from "./domain/identityaccount/resolve.js";
|
|
72
|
+
export type { DerivedRelation, KindDeclaration, Rewrite, SubjectType, } from "./authorization/model/rewrite.js";
|
|
73
|
+
export type { Model } from "./authorization/model/index.js";
|
|
74
|
+
export { builtInModel, declarationFor, newModel, } from "./authorization/model/index.js";
|
|
75
|
+
export type { CheckContext, ObjectRef, Person, Subject, Tuple, TupleSource, } from "./authorization/tuples.js";
|
|
76
|
+
export type { EvaluationFault } from "./authorization/evaluator.js";
|
|
77
|
+
export { AuthorizationEvaluationError, MAX_RESOLUTION_DEPTH, checkRelation, } from "./authorization/evaluator.js";
|
|
78
|
+
export type { StoreTestCase, StoreTestDocument, StoreTestKit, StoreTestSkip, StoreTestSkipReason, } from "./authorization/store-test-kit.js";
|
|
79
|
+
export { parseStoreTestDocument, storeTestCases, } from "./authorization/store-test-kit.js";
|
|
80
|
+
export { NOT_FOUND_EXEMPT_KINDS } from "./authorization/authorizer.js";
|
|
72
81
|
export type { ListReadScope, ListEntryMeta, } from "./extensions/list-read-scope.js";
|
|
73
82
|
export type { ScheduleFireCallerMint } from "./extensions/schedule-fire-caller.js";
|
|
83
|
+
export { ScheduleFireCallerRefusedError } from "./extensions/schedule-fire-caller.js";
|
|
74
84
|
export type { VisitorErrorPolicy } from "./pipeline/interceptors/error-boundary.js";
|
|
75
85
|
export { createErrorBoundaryInterceptor } from "./pipeline/interceptors/error-boundary.js";
|
|
76
86
|
export { diffVisibilityShapes, visibilityShapesFor, } from "./pipeline/steps/authorization-tuples.js";
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AAGH,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAClD,YAAY,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AACxE,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAC9C,YAAY,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AACrD,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAChD,YAAY,EACV,QAAQ,EACR,SAAS,EACT,MAAM,EACN,aAAa,EACb,QAAQ,EACR,OAAO,GACR,MAAM,kBAAkB,CAAC;AAG1B,YAAY,EACV,4BAA4B,EAC5B,kBAAkB,EAClB,eAAe,GAChB,MAAM,0BAA0B,CAAC;AAClC,YAAY,EACV,WAAW,EACX,cAAc,EACd,gBAAgB,GACjB,MAAM,0BAA0B,CAAC;AASlC,YAAY,EAAE,WAAW,EAAE,MAAM,+BAA+B,CAAC;AAOjE,YAAY,EACV,UAAU,EACV,UAAU,EACV,aAAa,GACd,MAAM,4BAA4B,CAAC;AACpC,YAAY,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAC/D,YAAY,EACV,+BAA+B,EAC/B,yBAAyB,EACzB,4BAA4B,EAC5B,8BAA8B,GAC/B,MAAM,8BAA8B,CAAC;AACtC,YAAY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,CAAC;AACpD,OAAO,EACL,0BAA0B,EAC1B,+BAA+B,EAC/B,iCAAiC,GAClC,MAAM,+CAA+C,CAAC;AACvD,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AAQrE,YAAY,EACV,cAAc,EACd,2BAA2B,EAC3B,sBAAsB,EACtB,uBAAuB,GACxB,MAAM,0CAA0C,CAAC;AAOlD,YAAY,EACV,mBAAmB,EACnB,aAAa,EACb,iBAAiB,EACjB,oBAAoB,GACrB,MAAM,uBAAuB,CAAC;AAI/B,OAAO,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -49,6 +49,14 @@ export { identityAccountStoreContract } from "./domain/identityaccount/store-con
|
|
|
49
49
|
export { DuplicatePolicyError } from "./domain/iampolicy/store.js";
|
|
50
50
|
export { iamPolicyStoreContract } from "./domain/iampolicy/store-contract.js";
|
|
51
51
|
export { identityIdForSubject } from "./domain/identityaccount/resolve.js";
|
|
52
|
+
export { builtInModel, declarationFor, newModel, } from "./authorization/model/index.js";
|
|
53
|
+
export { AuthorizationEvaluationError, MAX_RESOLUTION_DEPTH, checkRelation, } from "./authorization/evaluator.js";
|
|
54
|
+
export { parseStoreTestDocument, storeTestCases, } from "./authorization/store-test-kit.js";
|
|
55
|
+
// The kinds whose missing row the built-in authorizer denies instead of
|
|
56
|
+
// answering not-found — the cloud's probe exemption over the open-source
|
|
57
|
+
// tier; exported so the cloud's drift test pins the two sets equal.
|
|
58
|
+
export { NOT_FOUND_EXEMPT_KINDS } from "./authorization/authorizer.js";
|
|
59
|
+
export { ScheduleFireCallerRefusedError } from "./extensions/schedule-fire-caller.js";
|
|
52
60
|
export { createErrorBoundaryInterceptor } from "./pipeline/interceptors/error-boundary.js";
|
|
53
61
|
export { diffVisibilityShapes, visibilityShapesFor, } from "./pipeline/steps/authorization-tuples.js";
|
|
54
62
|
export { RequestContext } from "./pipeline/request-context.js";
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AAEH,wCAAwC;AACxC,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAElD,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAE9C,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAiEhD,OAAO,EAAE,iBAAiB,EAAE,MAAM,wCAAwC,CAAC;AAQ3E,OAAO,EAAE,qBAAqB,EAAE,MAAM,mCAAmC,CAAC;AAQ1E,OAAO,EAAE,4BAA4B,EAAE,MAAM,4CAA4C,CAAC;AAW1F,OAAO,EAAE,oBAAoB,EAAE,MAAM,6BAA6B,CAAC;AAKnE,OAAO,EAAE,sBAAsB,EAAE,MAAM,sCAAsC,CAAC;AAK9E,OAAO,EAAE,oBAAoB,EAAE,MAAM,qCAAqC,CAAC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AAEH,wCAAwC;AACxC,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAElD,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAE9C,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAiEhD,OAAO,EAAE,iBAAiB,EAAE,MAAM,wCAAwC,CAAC;AAQ3E,OAAO,EAAE,qBAAqB,EAAE,MAAM,mCAAmC,CAAC;AAQ1E,OAAO,EAAE,4BAA4B,EAAE,MAAM,4CAA4C,CAAC;AAW1F,OAAO,EAAE,oBAAoB,EAAE,MAAM,6BAA6B,CAAC;AAKnE,OAAO,EAAE,sBAAsB,EAAE,MAAM,sCAAsC,CAAC;AAK9E,OAAO,EAAE,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ACrE,6DAA6D;AAC7D,uEAAuE;AACvE,qEAAqE;AACrE,gEAAgE;AAChE,0EAA0E;AAC1E,qEAAqE;AACrE,uEAAuE;AACvE,iEAAiE;AACjE,OAAO,EACL,qBAAqB,EACrB,uBAAuB,EACvB,eAAe,EACf,0BAA0B,EAC1B,sBAAsB,EACtB,aAAa,GACd,MAAM,4BAA4B,CAAC;AAepC,OAAO,EAAE,kCAAkC,EAAE,MAAM,0BAA0B,CAAC;AAE9E,yEAAyE;AACzE,wEAAwE;AACxE,0EAA0E;AAC1E,0EAA0E;AAC1E,yEAAyE;AACzE,wEAAwE;AACxE,kDAAkD;AAClD,OAAO,EACL,4BAA4B,EAC5B,eAAe,EACf,gBAAgB,IAAI,sCAAsC,GAC3D,MAAM,4CAA4C,CAAC;AACpD,OAAO,EACL,0BAA0B,EAC1B,+BAA+B,EAC/B,iCAAiC,GAClC,MAAM,+CAA+C,CAAC;AACvD,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AA0BrE,oEAAoE;AACpE,yEAAyE;AACzE,iDAAiD;AACjD,OAAO,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC"}
|
|
@@ -8,9 +8,12 @@
|
|
|
8
8
|
* instances) but never to GRANT anything. Where a grant-shaped decision is
|
|
9
9
|
* needed, key it on server-owned state instead (e.g. the parent blueprint's
|
|
10
10
|
* status.default_instance_id, written only by the create/self-heal flows).
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
11
|
+
* Every write boundary runs GuardReservedLabels over the namespace
|
|
12
|
+
* (pipeline/steps/guard-reserved-labels.ts), but the open-source
|
|
13
|
+
* authorizer's permissive default ALLOWS reserved-label writes by design
|
|
14
|
+
* (the self-hosted operator owns the store), which is why a restrict-shaped
|
|
15
|
+
* predicate here still pairs the label with server-owned state: the
|
|
16
|
+
* plugin-managed guard refuses only beside an existing plugin row.
|
|
14
17
|
*/
|
|
15
18
|
import type { ApiResourceMetadata } from "@stigmer/protos/ai/stigmer/commons/apiresource/metadata_pb";
|
|
16
19
|
/**
|
|
@@ -39,6 +42,23 @@ export declare const SYSTEM_MANAGED_LABEL = "stigmer.ai/system-managed";
|
|
|
39
42
|
* read by the predicates here.
|
|
40
43
|
*/
|
|
41
44
|
export declare const RESERVED_LABEL_TRUE = "true";
|
|
45
|
+
/**
|
|
46
|
+
* The plugin that materialised a resource: the label's value is the
|
|
47
|
+
* plugin's id (`plg_...`), never its slug, because `findAllByLabel` is
|
|
48
|
+
* org-agnostic and two organizations may both install `thermos`. Written
|
|
49
|
+
* only by the plugin controller (in-process, as the installing caller);
|
|
50
|
+
* membership is derived on read from it and stored nowhere else.
|
|
51
|
+
*/
|
|
52
|
+
export declare const PLUGIN_LABEL = "stigmer.ai/plugin";
|
|
53
|
+
/**
|
|
54
|
+
* The archive digest a member was last materialised from — the per-child
|
|
55
|
+
* convergence marker. A re-push compares every member's value with the
|
|
56
|
+
* head's digest before deciding it has nothing to do, so a member another
|
|
57
|
+
* lane deleted or an older install left behind is re-materialised.
|
|
58
|
+
*/
|
|
59
|
+
export declare const PLUGIN_VERSION_LABEL = "stigmer.ai/plugin-version";
|
|
60
|
+
/** The plugin id a resource's labels claim, or undefined when unlabelled. */
|
|
61
|
+
export declare function pluginIdOf(metadata: ApiResourceMetadata | undefined): string | undefined;
|
|
42
62
|
/**
|
|
43
63
|
* Whether the metadata carries the DEFAULT_INSTANCE_LABEL marker
|
|
44
64
|
* (undefined-safe) — Go IsDefaultInstance.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"apiresource-labels.d.ts","sourceRoot":"","sources":["../../src/pipeline/apiresource-labels.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"apiresource-labels.d.ts","sourceRoot":"","sources":["../../src/pipeline/apiresource-labels.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AACH,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,4DAA4D,CAAC;AAEtG;;;;;GAKG;AACH,eAAO,MAAM,qBAAqB,gBAAgB,CAAC;AAEnD;;;;;GAKG;AACH,eAAO,MAAM,sBAAsB,gCAA6C,CAAC;AAEjF;;;GAGG;AACH,eAAO,MAAM,oBAAoB,8BAA2C,CAAC;AAE7E;;;;;GAKG;AACH,eAAO,MAAM,mBAAmB,SAAS,CAAC;AAE1C;;;;;;GAMG;AACH,eAAO,MAAM,YAAY,sBAAmC,CAAC;AAE7D;;;;;GAKG;AACH,eAAO,MAAM,oBAAoB,8BAA2C,CAAC;AAE7E,6EAA6E;AAC7E,wBAAgB,UAAU,CACxB,QAAQ,EAAE,mBAAmB,GAAG,SAAS,GACxC,MAAM,GAAG,SAAS,CAGpB;AAED;;;;;;;;GAQG;AACH,wBAAgB,iBAAiB,CAC/B,QAAQ,EAAE,mBAAmB,GAAG,SAAS,GACxC,OAAO,CAET"}
|
|
@@ -24,6 +24,26 @@ export const SYSTEM_MANAGED_LABEL = `${RESERVED_LABEL_PREFIX}system-managed`;
|
|
|
24
24
|
* read by the predicates here.
|
|
25
25
|
*/
|
|
26
26
|
export const RESERVED_LABEL_TRUE = "true";
|
|
27
|
+
/**
|
|
28
|
+
* The plugin that materialised a resource: the label's value is the
|
|
29
|
+
* plugin's id (`plg_...`), never its slug, because `findAllByLabel` is
|
|
30
|
+
* org-agnostic and two organizations may both install `thermos`. Written
|
|
31
|
+
* only by the plugin controller (in-process, as the installing caller);
|
|
32
|
+
* membership is derived on read from it and stored nowhere else.
|
|
33
|
+
*/
|
|
34
|
+
export const PLUGIN_LABEL = `${RESERVED_LABEL_PREFIX}plugin`;
|
|
35
|
+
/**
|
|
36
|
+
* The archive digest a member was last materialised from — the per-child
|
|
37
|
+
* convergence marker. A re-push compares every member's value with the
|
|
38
|
+
* head's digest before deciding it has nothing to do, so a member another
|
|
39
|
+
* lane deleted or an older install left behind is re-materialised.
|
|
40
|
+
*/
|
|
41
|
+
export const PLUGIN_VERSION_LABEL = `${RESERVED_LABEL_PREFIX}plugin-version`;
|
|
42
|
+
/** The plugin id a resource's labels claim, or undefined when unlabelled. */
|
|
43
|
+
export function pluginIdOf(metadata) {
|
|
44
|
+
const value = metadata?.labels[PLUGIN_LABEL];
|
|
45
|
+
return value === undefined || value === "" ? undefined : value;
|
|
46
|
+
}
|
|
27
47
|
/**
|
|
28
48
|
* Whether the metadata carries the DEFAULT_INSTANCE_LABEL marker
|
|
29
49
|
* (undefined-safe) — Go IsDefaultInstance.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"apiresource-labels.js","sourceRoot":"","sources":["../../src/pipeline/apiresource-labels.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"apiresource-labels.js","sourceRoot":"","sources":["../../src/pipeline/apiresource-labels.ts"],"names":[],"mappings":"AAmBA;;;;;GAKG;AACH,MAAM,CAAC,MAAM,qBAAqB,GAAG,aAAa,CAAC;AAEnD;;;;;GAKG;AACH,MAAM,CAAC,MAAM,sBAAsB,GAAG,GAAG,qBAAqB,kBAAkB,CAAC;AAEjF;;;GAGG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAG,GAAG,qBAAqB,gBAAgB,CAAC;AAE7E;;;;;GAKG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAG,MAAM,CAAC;AAE1C;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG,GAAG,qBAAqB,QAAQ,CAAC;AAE7D;;;;;GAKG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAG,GAAG,qBAAqB,gBAAgB,CAAC;AAE7E,6EAA6E;AAC7E,MAAM,UAAU,UAAU,CACxB,QAAyC;IAEzC,MAAM,KAAK,GAAG,QAAQ,EAAE,MAAM,CAAC,YAAY,CAAC,CAAC;IAC7C,OAAO,KAAK,KAAK,SAAS,IAAI,KAAK,KAAK,EAAE,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,KAAK,CAAC;AACjE,CAAC;AAED;;;;;;;;GAQG;AACH,MAAM,UAAU,iBAAiB,CAC/B,QAAyC;IAEzC,OAAO,QAAQ,EAAE,MAAM,CAAC,sBAAsB,CAAC,KAAK,mBAAmB,CAAC;AAC1E,CAAC"}
|
|
@@ -1,10 +1,31 @@
|
|
|
1
1
|
import { ApiResourceVisibility } from "@stigmer/protos/ai/stigmer/commons/apiresource/enum_pb";
|
|
2
2
|
import { ApiResourceKind, ResourceTier } from "@stigmer/protos/ai/stigmer/commons/apiresource/apiresourcekind/api_resource_kind_pb";
|
|
3
3
|
import type { ApiResourceKindMeta } from "@stigmer/protos/ai/stigmer/commons/apiresource/apiresourcekind/api_resource_kind_pb";
|
|
4
|
+
import type { ParentRelationConfig } from "@stigmer/protos/ai/stigmer/commons/apiresource/apiresourcekind/authorization_config_pb";
|
|
4
5
|
import type { IamRole } from "@stigmer/protos/ai/stigmer/iam/v1/enum_pb";
|
|
5
6
|
import { ServerEdition } from "@stigmer/protos/ai/stigmer/platform/v1/server_info_pb";
|
|
6
7
|
/** Go GetKindMeta: the kind_meta extension of the enum value. */
|
|
7
8
|
export declare function getKindMeta(kind: ApiResourceKind): ApiResourceKindMeta;
|
|
9
|
+
/**
|
|
10
|
+
* The parent a kind's authorization IS — the `kind_meta` declaration that
|
|
11
|
+
* a kind's permissions are its parent's whole, not its own: PARENT scope
|
|
12
|
+
* (the one structural link is to that parent) AND INHERITED owner (no
|
|
13
|
+
* owner tuple of its own; `owner from <parent>` in the FGA model).
|
|
14
|
+
* Undefined for every other kind, including kinds with additional parents
|
|
15
|
+
* whose inheritance is partial (a workflow_execution's opt-in
|
|
16
|
+
* `execution_viewer from workflow_instance` sits beside its own owner).
|
|
17
|
+
*
|
|
18
|
+
* Today exactly one kind answers: agent_execution → session (its
|
|
19
|
+
* `can_view` is `viewer or can_view from session`, and `viewer` is the
|
|
20
|
+
* session's). The list read scope reads this to carry the parent on every
|
|
21
|
+
* candidate (`ListEntryMeta.authorizationParent`, 20260913.04 T04), so a
|
|
22
|
+
* composed driver may ask its authorization backend about the parent —
|
|
23
|
+
* direct tuples — instead of the child, whose resolution walks the
|
|
24
|
+
* parent's whole set. A second kind declaring the pair gets the behavior
|
|
25
|
+
* from this declaration alone; the table pin in __tests__ makes that a
|
|
26
|
+
* reviewed change.
|
|
27
|
+
*/
|
|
28
|
+
export declare function inheritedAuthorizationParentOf(kind: ApiResourceKind): ParentRelationConfig | undefined;
|
|
8
29
|
/** Go GetIdPrefix: e.g. agent → "agt". */
|
|
9
30
|
export declare function getIdPrefix(kind: ApiResourceKind): string;
|
|
10
31
|
/** Go GetKindName: the canonical name, e.g. agent → "Agent" (error copy uses this). */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"apiresource-meta.d.ts","sourceRoot":"","sources":["../../src/pipeline/apiresource-meta.ts"],"names":[],"mappings":"AA+CA,OAAO,EAAE,qBAAqB,EAAE,MAAM,wDAAwD,CAAC;AAC/F,OAAO,EACL,eAAe,EAEf,YAAY,EAEb,MAAM,qFAAqF,CAAC;AAC7F,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,qFAAqF,CAAC;
|
|
1
|
+
{"version":3,"file":"apiresource-meta.d.ts","sourceRoot":"","sources":["../../src/pipeline/apiresource-meta.ts"],"names":[],"mappings":"AA+CA,OAAO,EAAE,qBAAqB,EAAE,MAAM,wDAAwD,CAAC;AAC/F,OAAO,EACL,eAAe,EAEf,YAAY,EAEb,MAAM,qFAAqF,CAAC;AAC7F,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,qFAAqF,CAAC;AAK/H,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,wFAAwF,CAAC;AACnI,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,2CAA2C,CAAC;AACzE,OAAO,EAAE,aAAa,EAAE,MAAM,uDAAuD,CAAC;AAEtF,iEAAiE;AACjE,wBAAgB,WAAW,CAAC,IAAI,EAAE,eAAe,GAAG,mBAAmB,CAMtE;AAED;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,8BAA8B,CAC5C,IAAI,EAAE,eAAe,GACpB,oBAAoB,GAAG,SAAS,CASlC;AAED,0CAA0C;AAC1C,wBAAgB,WAAW,CAAC,IAAI,EAAE,eAAe,GAAG,MAAM,CAEzD;AAED,uFAAuF;AACvF,wBAAgB,WAAW,CAAC,IAAI,EAAE,eAAe,GAAG,MAAM,CAEzD;AAED;;;;GAIG;AACH,wBAAgB,WAAW,CAAC,SAAS,EAAE,MAAM,GAAG,eAAe,CAS9D;AAED;;;;;;;;;GASG;AACH,wBAAgB,cAAc,CAAC,KAAK,EAAE,MAAM,GAAG,eAAe,CAI7D;AAED;;;;;;GAMG;AACH,wBAAgB,YAAY,CAAC,IAAI,EAAE,eAAe,GAAG,MAAM,CAO1D;AAED;;;;;GAKG;AACH,wBAAgB,oBAAoB,CAClC,IAAI,EAAE,eAAe,GACpB,qBAAqB,CAKvB;AAED;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,iBAAiB,CAC/B,IAAI,EAAE,eAAe,GACpB,aAAa,CAAC,OAAO,CAAC,CAMxB;AAED;;;;;;;;;GASG;AACH,wBAAgB,mBAAmB,CACjC,IAAI,EAAE,YAAY,EAClB,OAAO,EAAE,aAAa,GACrB,OAAO,CAKT;AAED;;;;;GAKG;AACH,wBAAgB,mBAAmB,CACjC,IAAI,EAAE,eAAe,EACrB,OAAO,EAAE,aAAa,GACrB,OAAO,CAET;AAkCD;;;;GAIG;AACH,wBAAgB,kBAAkB,CAChC,IAAI,EAAE,eAAe,EACrB,UAAU,EAAE,qBAAqB,GAChC,OAAO,CAYT;AAED;;;;GAIG;AACH,wBAAgB,yBAAyB,CAAC,IAAI,EAAE,eAAe,GAAG,MAAM,CAavE"}
|
|
@@ -45,6 +45,7 @@
|
|
|
45
45
|
import { getOption, hasOption } from "@bufbuild/protobuf";
|
|
46
46
|
import { ApiResourceVisibility } from "@stigmer/protos/ai/stigmer/commons/apiresource/enum_pb";
|
|
47
47
|
import { ApiResourceKind, ApiResourceKindSchema, ResourceTier, kind_meta, } from "@stigmer/protos/ai/stigmer/commons/apiresource/apiresourcekind/api_resource_kind_pb";
|
|
48
|
+
import { AuthorizationScopeType, OwnerAttributionType, } from "@stigmer/protos/ai/stigmer/commons/apiresource/apiresourcekind/authorization_config_pb";
|
|
48
49
|
import { ServerEdition } from "@stigmer/protos/ai/stigmer/platform/v1/server_info_pb";
|
|
49
50
|
/** Go GetKindMeta: the kind_meta extension of the enum value. */
|
|
50
51
|
export function getKindMeta(kind) {
|
|
@@ -54,6 +55,33 @@ export function getKindMeta(kind) {
|
|
|
54
55
|
}
|
|
55
56
|
return getOption(valueDesc, kind_meta);
|
|
56
57
|
}
|
|
58
|
+
/**
|
|
59
|
+
* The parent a kind's authorization IS — the `kind_meta` declaration that
|
|
60
|
+
* a kind's permissions are its parent's whole, not its own: PARENT scope
|
|
61
|
+
* (the one structural link is to that parent) AND INHERITED owner (no
|
|
62
|
+
* owner tuple of its own; `owner from <parent>` in the FGA model).
|
|
63
|
+
* Undefined for every other kind, including kinds with additional parents
|
|
64
|
+
* whose inheritance is partial (a workflow_execution's opt-in
|
|
65
|
+
* `execution_viewer from workflow_instance` sits beside its own owner).
|
|
66
|
+
*
|
|
67
|
+
* Today exactly one kind answers: agent_execution → session (its
|
|
68
|
+
* `can_view` is `viewer or can_view from session`, and `viewer` is the
|
|
69
|
+
* session's). The list read scope reads this to carry the parent on every
|
|
70
|
+
* candidate (`ListEntryMeta.authorizationParent`, 20260913.04 T04), so a
|
|
71
|
+
* composed driver may ask its authorization backend about the parent —
|
|
72
|
+
* direct tuples — instead of the child, whose resolution walks the
|
|
73
|
+
* parent's whole set. A second kind declaring the pair gets the behavior
|
|
74
|
+
* from this declaration alone; the table pin in __tests__ makes that a
|
|
75
|
+
* reviewed change.
|
|
76
|
+
*/
|
|
77
|
+
export function inheritedAuthorizationParentOf(kind) {
|
|
78
|
+
const config = getKindMeta(kind).authorization;
|
|
79
|
+
if (config?.scopeType !== AuthorizationScopeType.PARENT ||
|
|
80
|
+
config.ownerType !== OwnerAttributionType.INHERITED) {
|
|
81
|
+
return undefined;
|
|
82
|
+
}
|
|
83
|
+
return config.parent;
|
|
84
|
+
}
|
|
57
85
|
/** Go GetIdPrefix: e.g. agent → "agt". */
|
|
58
86
|
export function getIdPrefix(kind) {
|
|
59
87
|
return getKindMeta(kind).idPrefix;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"apiresource-meta.js","sourceRoot":"","sources":["../../src/pipeline/apiresource-meta.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2CG;AACH,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAG1D,OAAO,EAAE,qBAAqB,EAAE,MAAM,wDAAwD,CAAC;AAC/F,OAAO,EACL,eAAe,EACf,qBAAqB,EACrB,YAAY,EACZ,SAAS,GACV,MAAM,qFAAqF,CAAC;
|
|
1
|
+
{"version":3,"file":"apiresource-meta.js","sourceRoot":"","sources":["../../src/pipeline/apiresource-meta.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2CG;AACH,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAG1D,OAAO,EAAE,qBAAqB,EAAE,MAAM,wDAAwD,CAAC;AAC/F,OAAO,EACL,eAAe,EACf,qBAAqB,EACrB,YAAY,EACZ,SAAS,GACV,MAAM,qFAAqF,CAAC;AAE7F,OAAO,EACL,sBAAsB,EACtB,oBAAoB,GACrB,MAAM,wFAAwF,CAAC;AAGhG,OAAO,EAAE,aAAa,EAAE,MAAM,uDAAuD,CAAC;AAEtF,iEAAiE;AACjE,MAAM,UAAU,WAAW,CAAC,IAAqB;IAC/C,MAAM,SAAS,GAAG,mBAAmB,CAAC,IAAI,CAAC,CAAC;IAC5C,IAAI,SAAS,KAAK,SAAS,IAAI,CAAC,SAAS,C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,qBAAqB,CAAC,MAAM;aACzB,MAAM,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,SAAS,CAAC,KAAK,EAAE,SAAS,CAAC,CAAC;aAC9C,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC;YACd,iBAAiB,CAAC,SAAS,CAAC,KAAK,EAAE,SAAS,CAAC,CAAC,IAAI,CAAC;YACnD,KAAK,CAAC,MAAyB;SAChC,CAAC,CACL,CAAC;IACJ,CAAC;IACD,OAAO,kBAAkB,CAAC;AAC5B,CAAC;AAED,IAAI,aAAuD,CAAC;AAE5D;;;;;GAKG;AACH,SAAS,eAAe;IACtB,IAAI,aAAa,KAAK,SAAS,EAAE,CAAC;QAChC,aAAa,GAAG,IAAI,GAAG,CACrB,qBAAqB,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC;YAC1C,KAAK,CAAC,IAAI;YACV,KAAK,CAAC,MAAyB;SAChC,CAAC,CACH,CAAC;IACJ,CAAC;IACD,OAAO,aAAa,CAAC;AACvB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../../src/pipeline/errors.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AACH,OAAO,EAAE,IAAI,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAEzD,4CAA4C;AAC5C,wBAAgB,aAAa,CAAC,QAAQ,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,GAAG,YAAY,CAExE;AAED,kEAAkE;AAClE,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,MAAM,GAAG,YAAY,CAElE;AAED,sDAAsD;AACtD,wBAAgB,kBAAkB,CAAC,QAAQ,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,GAAG,YAAY,
|
|
1
|
+
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../../src/pipeline/errors.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;G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IAC3B,CAAC,IAAI,CAAC,eAAe,CAAC,EAAE,iBAAiB;CAC1C,CAAC;AAEF;;;;;GAKG;AACH,MAAM,UAAU,YAAY,CAAC,IAAU;IACrC,OAAO,eAAe,CAAC,IAAI,CAAC,CAAC;AAC/B,CAAC;AAED;;;;;;;;;;;;;;GAcG;AACH,MAAM,UAAU,oBAAoB,CAClC,MAAc,EACd,KAAmB;IAEnB,OAAO,IAAI,YAAY,CAAC,GAAG,MAAM,KAAK,eAAe,CAAC,KAAK,CAAC,EAAE,EAAE,KAAK,CAAC,IAAI,CAAC,CAAC;AAC9E,CAAC;AAED;;;;;;;GAOG;AACH,MAAM,UAAU,eAAe,CAAC,KAAmB;IACjD,OAAO,qBAAqB,eAAe,CAAC,KAAK,CAAC,IAAI,CAAC,WAAW,KAAK,CAAC,UAAU,EAAE,CAAC;AACvF,CAAC;AAED;;;;;;;;;;;;;GAaG;AACH,MAAM,UAAU,mBAAmB,CAAC,KAAmB;IACrD,OAAO,IAAI,YAAY,CAAC,KAAK,CAAC,UAAU,EAAE,KAAK,CAAC,IAAI,CAAC,CAAC;AACxD,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { ApiResourceKind } from "@stigmer/protos/ai/stigmer/commons/apiresource/apiresourcekind/api_resource_kind_pb";
|
|
2
|
+
import type { ResolvedParentLink, RowAuthorizationFacts } from "../../extensions/resource-authorization.js";
|
|
3
|
+
/** The row's facts, read structurally; every absence is the empty value, never a throw. */
|
|
4
|
+
export declare function rowAuthorizationFactsOf(kind: ApiResourceKind, resource: object): RowAuthorizationFacts;
|
|
5
|
+
/** `status.audit.spec_audit.created_by.id` as stamped — "" when any link is absent. */
|
|
6
|
+
export declare function createdByOf(resource: object): string;
|
|
7
|
+
/**
|
|
8
|
+
* The scope link and every configured additional parent the row names, in
|
|
9
|
+
* the tuple lifecycle's order. A parent the row does not name is left out.
|
|
10
|
+
*/
|
|
11
|
+
export declare function parentLinksOf(kind: ApiResourceKind, resource: object, org: string): ReadonlyArray<ResolvedParentLink>;
|
|
12
|
+
//# sourceMappingURL=authorization-facts.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"authorization-facts.d.ts","sourceRoot":"","sources":["../../../src/pipeline/steps/authorization-facts.ts"],"names":[],"mappings":"AA2BA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,qFAAqF,CAAC;AAI3H,OAAO,KAAK,EACV,kBAAkB,EAClB,qBAAqB,EACtB,MAAM,4CAA4C,CAAC;AAUpD,2FAA2F;AAC3F,wBAAgB,uBAAuB,CACrC,IAAI,EAAE,eAAe,EACrB,QAAQ,EAAE,MAAM,GACf,qBAAqB,CAYvB;AAED,uFAAuF;AACvF,wBAAgB,WAAW,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAIpD;AAED;;;GAGG;AACH,wBAAgB,aAAa,CAC3B,IAAI,EAAE,eAAe,EACrB,QAAQ,EAAE,MAAM,EAChB,GAAG,EAAE,MAAM,GACV,aAAa,CAAC,kBAAkB,CAAC,CAsCnC"}
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The facts a stored row's authorization tuples derive from, read back
|
|
3
|
+
* from the row (`RowAuthorizationFacts`, extensions/resource-authorization.ts)
|
|
4
|
+
* — the read-time twin of the tuple lifecycle's create-time resolution in
|
|
5
|
+
* authorization-tuples.ts, and deliberately not that function: the
|
|
6
|
+
* create-time one throws when a row is missing its organization or its
|
|
7
|
+
* parent (a create must not half-succeed), while a row read back years
|
|
8
|
+
* later is a fact, missing pieces included — an empty organization
|
|
9
|
+
* resolves `admin from organization` to nobody, it does not fault a read.
|
|
10
|
+
* The two cannot drift unnoticed: src/authorization/__tests__/facts.test.ts
|
|
11
|
+
* pins that a well-formed row resolves to the same links through both.
|
|
12
|
+
*
|
|
13
|
+
* Two readers share this one resolver, which is the reason it is a leaf
|
|
14
|
+
* of its own: the list lanes' shared helper (extensions/list-read-scope.ts)
|
|
15
|
+
* builds every candidate's `ListEntryMeta` through it, and the built-in
|
|
16
|
+
* authorizer (src/authorization/facts.ts) derives a loaded row's tuples
|
|
17
|
+
* through it. It imports the two pure leaves it needs (apiresource-meta,
|
|
18
|
+
* shapes) and the protos, and nothing else, so the seam may import it by
|
|
19
|
+
* value without a cycle — the third such leaf, beside those two.
|
|
20
|
+
*
|
|
21
|
+
* Every read is structural (shapes.ts's own premise: protobuf-es messages
|
|
22
|
+
* are plain objects sharing the generated metadata and audit types), so
|
|
23
|
+
* the resolver needs no schema — a list lane holds decoded rows of a kind
|
|
24
|
+
* it names, not their descriptors.
|
|
25
|
+
*/
|
|
26
|
+
import { AuthorizationScopeType } from "@stigmer/protos/ai/stigmer/commons/apiresource/apiresourcekind/authorization_config_pb";
|
|
27
|
+
import { ApiResourceVisibility } from "@stigmer/protos/ai/stigmer/commons/apiresource/enum_pb";
|
|
28
|
+
import { getKindEnum, getKindMeta } from "../apiresource-meta.js";
|
|
29
|
+
import { parentIdOf } from "./shapes.js";
|
|
30
|
+
/** The row's facts, read structurally; every absence is the empty value, never a throw. */
|
|
31
|
+
export function rowAuthorizationFactsOf(kind, resource) {
|
|
32
|
+
const metadata = resource.metadata;
|
|
33
|
+
const org = metadata?.org ?? "";
|
|
34
|
+
return {
|
|
35
|
+
id: metadata?.id ?? "",
|
|
36
|
+
org,
|
|
37
|
+
visibility: metadata?.visibility ??
|
|
38
|
+
ApiResourceVisibility.api_resource_visibility_unspecified,
|
|
39
|
+
createdBy: createdByOf(resource),
|
|
40
|
+
parentLinks: parentLinksOf(kind, resource, org),
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
/** `status.audit.spec_audit.created_by.id` as stamped — "" when any link is absent. */
|
|
44
|
+
export function createdByOf(resource) {
|
|
45
|
+
return (resource.status?.audit?.specAudit?.createdBy?.id ?? "");
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* The scope link and every configured additional parent the row names, in
|
|
49
|
+
* the tuple lifecycle's order. A parent the row does not name is left out.
|
|
50
|
+
*/
|
|
51
|
+
export function parentLinksOf(kind, resource, org) {
|
|
52
|
+
const config = getKindMeta(kind).authorization;
|
|
53
|
+
if (config === undefined) {
|
|
54
|
+
return [];
|
|
55
|
+
}
|
|
56
|
+
const links = [];
|
|
57
|
+
switch (config.scopeType) {
|
|
58
|
+
case AuthorizationScopeType.ORGANIZATION:
|
|
59
|
+
if (org !== "") {
|
|
60
|
+
links.push({
|
|
61
|
+
relation: "organization",
|
|
62
|
+
parentKind: getKindEnum("organization"),
|
|
63
|
+
parentId: org,
|
|
64
|
+
});
|
|
65
|
+
}
|
|
66
|
+
break;
|
|
67
|
+
case AuthorizationScopeType.PARENT:
|
|
68
|
+
if (config.parent !== undefined) {
|
|
69
|
+
pushLink(links, resource, config.parent);
|
|
70
|
+
}
|
|
71
|
+
break;
|
|
72
|
+
case AuthorizationScopeType.OWNER_ONLY:
|
|
73
|
+
case AuthorizationScopeType.PLATFORM:
|
|
74
|
+
case AuthorizationScopeType.NONE:
|
|
75
|
+
case AuthorizationScopeType.UNSPECIFIED:
|
|
76
|
+
// No scope link: OWNER_ONLY by design; PLATFORM is dead config in
|
|
77
|
+
// both editions (the lifecycle warns and writes none); NONE and
|
|
78
|
+
// UNSPECIFIED are kinds outside the model.
|
|
79
|
+
break;
|
|
80
|
+
default: {
|
|
81
|
+
const exhaustive = config.scopeType;
|
|
82
|
+
throw new Error(`unknown scope type: ${String(exhaustive)}`);
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
for (const parent of config.additionalParents) {
|
|
86
|
+
pushLink(links, resource, parent);
|
|
87
|
+
}
|
|
88
|
+
return links;
|
|
89
|
+
}
|
|
90
|
+
function pushLink(links, resource, parent) {
|
|
91
|
+
const parentId = parentIdOf(resource, parent.specField);
|
|
92
|
+
if (parentId !== "") {
|
|
93
|
+
links.push({
|
|
94
|
+
relation: parent.relation,
|
|
95
|
+
parentKind: getKindEnum(parent.kind),
|
|
96
|
+
parentId,
|
|
97
|
+
});
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
//# sourceMappingURL=authorization-facts.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"authorization-facts.js","sourceRoot":"","sources":["../../../src/pipeline/steps/authorization-facts.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,OAAO,EAAE,sBAAsB,EAAE,MAAM,wFAAwF,CAAC;AAGhI,OAAO,EAAE,qBAAqB,EAAE,MAAM,wDAAwD,CAAC;AAO/F,OAAO,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AAClE,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAQzC,2FAA2F;AAC3F,MAAM,UAAU,uBAAuB,CACrC,IAAqB,EACrB,QAAgB;IAEhB,MAAM,QAAQ,GAAI,QAA6B,CAAC,QAAQ,CAAC;IACzD,MAAM,GAAG,GAAG,QAAQ,EAAE,GAAG,IAAI,EAAE,CAAC;IAChC,OAAO;QACL,EAAE,EAAE,QAAQ,EAAE,EAAE,IAAI,EAAE;QACtB,GAAG;QACH,UAAU,EACR,QAAQ,EAAE,UAAU;YACpB,qBAAqB,CAAC,mCAAmC;QAC3D,SAAS,EAAE,WAAW,CAAC,QAAQ,CAAC;QAChC,WAAW,EAAE,aAAa,CAAC,IAAI,EAAE,QAAQ,EAAE,GAAG,CAAC;KAChD,CAAC;AACJ,CAAC;AAED,uFAAuF;AACvF,MAAM,UAAU,WAAW,CAAC,QAAgB;IAC1C,OAAO,CACJ,QAA0B,CAAC,MAAM,EAAE,KAAK,EAAE,SAAS,EAAE,SAAS,EAAE,EAAE,IAAI,EAAE,CAC1E,CAAC;AACJ,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,aAAa,CAC3B,IAAqB,EACrB,QAAgB,EAChB,GAAW;IAEX,MAAM,MAAM,GAAG,WAAW,CAAC,IAAI,CAAC,CAAC,aAAa,CAAC;IAC/C,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AC,cAAc,EAAE,aAAa,CAAC,oBAAoB,CAAC,CAAC;IAC7D,QAAQ,CAAC,cAAc,EAAE,aAAa,CAAC,oBAAoB,CAAC,CAAC;CAC9D,CAUA;AAgGD;;;;;;GAMG;AACH,wBAAgB,2BAA2B,CACzC,IAAI,EAAE,eAAe,EACrB,QAAQ,EAAE,OAAO,EACjB,MAAM,EAAE,cAAc,EACtB,MAAM,EAAE,MAAM,GACb,oBAAoB,GAAG,SAAS,CAkClC;AAED;;;GAGG;AACH,wBAAgB,gCAAgC,CAAC,IAAI,SAAS,WAAW,EACvE,SAAS,EAAE,8BAA8B,GAAG,SAAS,EACrD,MAAM,EAAE,MAAM,GACb,YAAY,CAAC,IAAI,CAAC,CAuBpB;AAED;;;;;GAKG;AACH,wBAAgB,yBAAyB,CAAC,IAAI,SAAS,WAAW,EAChE,SAAS,EAAE,8BAA8B,GAAG,SAAS,EACrD,MAAM,EAAE,MAAM,GACb,YAAY,CAAC,IAAI,CAAC,CAiCpB;AAED,uDAAuD;AACvD,eAAO,MAAM,kBAAkB,+BAA+B,CAAC;AAE/D;;;;;GAKG;AACH,wBAAgB,mCAAmC,CAAC,IAAI,SAAS,WAAW,EAC1E,WAAW,EAAE,MAAM,GAClB,YAAY,CAAC,IAAI,CAAC,CAYpB;AAED;;;;;GAKG;AACH,wBAAgB,6BAA6B,CAAC,IAAI,SAAS,WAAW,EACpE,SAAS,EAAE,8BAA8B,GAAG,SAAS,EACrD,WAAW,EAAE,MAAM,GAClB,YAAY,CAAC,IAAI,CAAC,CAoCpB"}
|
|
@@ -18,7 +18,7 @@ export async function notifyDefaultInstanceLinked(lifecycle, event) {
|
|
|
18
18
|
import { getKindEnum, getKindMeta, getKindName } from "../apiresource-meta.js";
|
|
19
19
|
import { internalError } from "../errors.js";
|
|
20
20
|
import { EXISTING_RESOURCE_KEY } from "./load-existing.js";
|
|
21
|
-
import { metadataOf } from "./shapes.js";
|
|
21
|
+
import { metadataOf, parentIdOf } from "./shapes.js";
|
|
22
22
|
// ---------------------------------------------------------------------------
|
|
23
23
|
// Visibility shape policy — the reconciler's level→shape mapping, ported
|
|
24
24
|
// from the Java VisibilityTupleReconciler (its unit-test matrix is
|
|
@@ -81,33 +81,14 @@ export function diffVisibilityShapes(kind, oldLevel, newLevel) {
|
|
|
81
81
|
};
|
|
82
82
|
}
|
|
83
83
|
// ---------------------------------------------------------------------------
|
|
84
|
-
// Parent-id resolution — the ParentIdExtractorRegistry port.
|
|
85
|
-
//
|
|
86
|
-
//
|
|
87
|
-
//
|
|
84
|
+
// Parent-id resolution — the ParentIdExtractorRegistry port. The spec-field
|
|
85
|
+
// read itself is shapes.ts's `parentIdOf`, shared with the list read scope
|
|
86
|
+
// (20260913.04 T04) so the id a tuple is written with and the id the scope
|
|
87
|
+
// asks about are one read. This module adds the create-time rule: a
|
|
88
|
+
// missing parent fails the request.
|
|
88
89
|
// ---------------------------------------------------------------------------
|
|
89
|
-
/** proto snake_case field name → the generated property name. */
|
|
90
|
-
function camelCaseFieldName(specField) {
|
|
91
|
-
return specField.replace(/_([a-z0-9])/g, (_, ch) => ch.toUpperCase());
|
|
92
|
-
}
|
|
93
|
-
/**
|
|
94
|
-
* Extracts the parent id named by the config from the resource's spec.
|
|
95
|
-
* Returns "" for every miss (no spec, no field, non-string value) — the
|
|
96
|
-
* caller decides whether that is fatal, exactly as Java's registry
|
|
97
|
-
* returns null and the service throws.
|
|
98
|
-
*/
|
|
99
|
-
function extractParentId(resource, specField) {
|
|
100
|
-
// Structural access is the shapes.ts idiom: spec messages are plain
|
|
101
|
-
// objects; the property name is the camelCase form of the proto field.
|
|
102
|
-
const spec = resource.spec;
|
|
103
|
-
if (spec === undefined) {
|
|
104
|
-
return "";
|
|
105
|
-
}
|
|
106
|
-
const value = spec[camelCaseFieldName(specField)];
|
|
107
|
-
return typeof value === "string" ? value : "";
|
|
108
|
-
}
|
|
109
90
|
function resolveParentLink(kind, resource, parentConfig) {
|
|
110
|
-
const parentId =
|
|
91
|
+
const parentId = parentIdOf(resource, parentConfig.specField);
|
|
111
92
|
if (parentId === "") {
|
|
112
93
|
// Java: "Parent ID required for X but not found" → the request fails.
|
|
113
94
|
throw internalError(new Error(`parent id for relation '${parentConfig.relation}' (spec field '${parentConfig.specField}') is missing on ${getKindName(kind)}`), "failed to create authorization tuples");
|