@noodleseed/one 0.82.0 → 0.84.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/cli.d.ts.map +1 -1
- package/dist/cli.js +4 -1
- package/dist/cli.js.map +1 -1
- package/dist/commands/catalog-data-platform-auth.d.ts.map +1 -1
- package/dist/commands/catalog-data-platform-auth.js +70 -2
- package/dist/commands/catalog-data-platform-auth.js.map +1 -1
- package/dist/commands/platform-account-reset-args.d.ts +40 -0
- package/dist/commands/platform-account-reset-args.d.ts.map +1 -0
- package/dist/commands/platform-account-reset-args.js +181 -0
- package/dist/commands/platform-account-reset-args.js.map +1 -0
- package/dist/commands/platform-account-reset-files.d.ts +9 -0
- package/dist/commands/platform-account-reset-files.d.ts.map +1 -0
- package/dist/commands/platform-account-reset-files.js +45 -0
- package/dist/commands/platform-account-reset-files.js.map +1 -0
- package/dist/commands/platform-account-reset-ops.d.ts +3 -0
- package/dist/commands/platform-account-reset-ops.d.ts.map +1 -0
- package/dist/commands/platform-account-reset-ops.js +162 -0
- package/dist/commands/platform-account-reset-ops.js.map +1 -0
- package/node_modules/@noodle-borg/agent-kit/dist/generated/example-files.js +1 -1
- package/node_modules/@noodle-borg/agent-kit/dist/generated/example-files.js.map +1 -1
- package/node_modules/@noodle-borg/agent-kit/dist/skill-embedded-assistant-ref.d.ts.map +1 -1
- package/node_modules/@noodle-borg/agent-kit/dist/skill-embedded-assistant-ref.js +39 -3
- package/node_modules/@noodle-borg/agent-kit/dist/skill-embedded-assistant-ref.js.map +1 -1
- package/node_modules/@noodle-borg/agent-kit/package.json +1 -1
- package/node_modules/@noodle-borg/service/dist/assistant-interactive.d.ts +1 -0
- package/node_modules/@noodle-borg/service/dist/assistant-interactive.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/assistant-interactive.js +1 -0
- package/node_modules/@noodle-borg/service/dist/assistant-interactive.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/billing/enforcement-activation.d.ts +4 -4
- package/node_modules/@noodle-borg/service/dist/billing/read-contract.d.ts +6 -6
- package/node_modules/@noodle-borg/service/dist/index.d.ts +4 -1
- package/node_modules/@noodle-borg/service/dist/index.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/index.js +2 -0
- package/node_modules/@noodle-borg/service/dist/index.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/main.js +5 -0
- package/node_modules/@noodle-borg/service/dist/main.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/developer-grant-flow.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/developer-grant-flow.js +1 -0
- package/node_modules/@noodle-borg/service/dist/oauth/developer-grant-flow.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/provider.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/provider.js +1 -0
- package/node_modules/@noodle-borg/service/dist/oauth/provider.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/store-postgres-schema.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/store-postgres-schema.js +17 -0
- package/node_modules/@noodle-borg/service/dist/oauth/store-postgres-schema.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/store-postgres.d.ts +2 -2
- package/node_modules/@noodle-borg/service/dist/oauth/store-postgres.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/store-postgres.js +25 -5
- package/node_modules/@noodle-borg/service/dist/oauth/store-postgres.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/store.d.ts +5 -3
- package/node_modules/@noodle-borg/service/dist/oauth/store.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/store.js +5 -5
- package/node_modules/@noodle-borg/service/dist/oauth/store.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/upstream-callback-handler.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/upstream-callback-handler.js +7 -2
- package/node_modules/@noodle-borg/service/dist/oauth/upstream-callback-handler.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/upstream-callback-support.d.ts +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/upstream-callback-support.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/upstream-callback-support.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/upstream-consent.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/upstream-consent.js +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/upstream-consent.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/upstream-federation.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/oauth/upstream-federation.js +6 -1
- package/node_modules/@noodle-borg/service/dist/oauth/upstream-federation.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/options.d.ts +13 -0
- package/node_modules/@noodle-borg/service/dist/options.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-config.d.ts +9 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-config.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-config.js +24 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-config.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-dispatch-lock-postgres.d.ts +12 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-dispatch-lock-postgres.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-dispatch-lock-postgres.js +110 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-dispatch-lock-postgres.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-fingerprint.d.ts +9 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-fingerprint.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-fingerprint.js +46 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-fingerprint.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-operation-postgres.d.ts +77 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-operation-postgres.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-operation-postgres.js +144 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-operation-postgres.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-operator.d.ts +29 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-operator.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-operator.js +59 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-operator.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ownership-helpers.d.ts +11 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ownership-helpers.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ownership-helpers.js +22 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ownership-helpers.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ownership-postgres.d.ts +41 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ownership-postgres.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ownership-postgres.js +314 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ownership-postgres.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ownership-resources-postgres.d.ts +14 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ownership-resources-postgres.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ownership-resources-postgres.js +210 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ownership-resources-postgres.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ownership-rollback-postgres.d.ts +11 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ownership-rollback-postgres.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ownership-rollback-postgres.js +71 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ownership-rollback-postgres.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ports.d.ts +12 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ports.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ports.js +2 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-ports.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-evidence-postgres.d.ts +22 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-evidence-postgres.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-evidence-postgres.js +177 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-evidence-postgres.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-local-postgres.d.ts +35 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-local-postgres.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-local-postgres.js +184 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-local-postgres.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-persistence-postgres.d.ts +11 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-persistence-postgres.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-persistence-postgres.js +120 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-persistence-postgres.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-postgres.d.ts +79 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-postgres.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-postgres.js +286 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-postgres.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-result.d.ts +21 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-result.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-result.js +81 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-preview-result.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-quarantine-postgres.d.ts +46 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-quarantine-postgres.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-quarantine-postgres.js +283 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-quarantine-postgres.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-rollback-eligibility-postgres.d.ts +13 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-rollback-eligibility-postgres.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-rollback-eligibility-postgres.js +81 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-rollback-eligibility-postgres.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-rollback-local-postgres.d.ts +30 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-rollback-local-postgres.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-rollback-local-postgres.js +248 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-rollback-local-postgres.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-rollback-postgres.d.ts +29 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-rollback-postgres.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-rollback-postgres.js +281 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-rollback-postgres.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-rollback-preview-postgres.d.ts +55 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-rollback-preview-postgres.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-rollback-preview-postgres.js +262 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-rollback-preview-postgres.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-schema-postgres.d.ts +7 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-schema-postgres.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-schema-postgres.js +439 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset-schema-postgres.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset.d.ts +276 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset.js +141 -0
- package/node_modules/@noodle-borg/service/dist/platform-account-reset.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-auth-configuration.d.ts +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-auth-inventory-legacy-sources-postgres.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-auth-inventory-legacy-sources-postgres.js +5 -1
- package/node_modules/@noodle-borg/service/dist/platform-auth-inventory-legacy-sources-postgres.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-auth-inventory-local-subjects-postgres.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-auth-inventory-local-subjects-postgres.js +10 -1
- package/node_modules/@noodle-borg/service/dist/platform-auth-inventory-local-subjects-postgres.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-auth-inventory-source-fence-postgres.d.ts +5 -10
- package/node_modules/@noodle-borg/service/dist/platform-auth-inventory-source-fence-postgres.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-auth-inventory-source-fence-postgres.js +86 -47
- package/node_modules/@noodle-borg/service/dist/platform-auth-inventory-source-fence-postgres.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-auth-inventory-source-fence-transaction-postgres.d.ts +17 -0
- package/node_modules/@noodle-borg/service/dist/platform-auth-inventory-source-fence-transaction-postgres.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-auth-inventory-source-fence-transaction-postgres.js +240 -0
- package/node_modules/@noodle-borg/service/dist/platform-auth-inventory-source-fence-transaction-postgres.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/platform-auth-operator.d.ts +63 -63
- package/node_modules/@noodle-borg/service/dist/platform-auth-rollout-support.d.ts +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-auth-runtime.d.ts +18 -1
- package/node_modules/@noodle-borg/service/dist/platform-auth-runtime.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-auth-runtime.js +97 -2
- package/node_modules/@noodle-borg/service/dist/platform-auth-runtime.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-auth-service-bootstrap.d.ts +4 -1
- package/node_modules/@noodle-borg/service/dist/platform-auth-service-bootstrap.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-auth-service-bootstrap.js +4 -0
- package/node_modules/@noodle-borg/service/dist/platform-auth-service-bootstrap.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-identity-postgres.d.ts +7 -2
- package/node_modules/@noodle-borg/service/dist/platform-identity-postgres.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-identity-postgres.js +24 -2
- package/node_modules/@noodle-borg/service/dist/platform-identity-postgres.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-identity-schema-postgres.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-identity-schema-postgres.js +4 -0
- package/node_modules/@noodle-borg/service/dist/platform-identity-schema-postgres.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-identity-sync-postgres.d.ts +7 -1
- package/node_modules/@noodle-borg/service/dist/platform-identity-sync-postgres.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-identity-sync-postgres.js +121 -8
- package/node_modules/@noodle-borg/service/dist/platform-identity-sync-postgres.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-identity-sync-recovery-postgres.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-identity-sync-recovery-postgres.js +11 -1
- package/node_modules/@noodle-borg/service/dist/platform-identity-sync-recovery-postgres.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-identity-sync.d.ts +5 -3
- package/node_modules/@noodle-borg/service/dist/platform-identity-sync.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-identity-sync.js +15 -1
- package/node_modules/@noodle-borg/service/dist/platform-identity-sync.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-identity.d.ts +23 -2
- package/node_modules/@noodle-borg/service/dist/platform-identity.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/platform-identity.js +21 -0
- package/node_modules/@noodle-borg/service/dist/platform-identity.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/registry-state.d.ts +8 -0
- package/node_modules/@noodle-borg/service/dist/registry-state.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/registry-state.js +15 -2
- package/node_modules/@noodle-borg/service/dist/registry-state.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/registry.d.ts +2 -0
- package/node_modules/@noodle-borg/service/dist/registry.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/registry.js +4 -1
- package/node_modules/@noodle-borg/service/dist/registry.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/routes/assistant-agent.d.ts +1 -1
- package/node_modules/@noodle-borg/service/dist/routes/assistant-agent.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/routes/assistant-agent.js +1 -0
- package/node_modules/@noodle-borg/service/dist/routes/assistant-agent.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/routes/platform-account-reset-dispatch.d.ts +8 -0
- package/node_modules/@noodle-borg/service/dist/routes/platform-account-reset-dispatch.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/routes/platform-account-reset-dispatch.js +36 -0
- package/node_modules/@noodle-borg/service/dist/routes/platform-account-reset-dispatch.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/routes/platform-account-reset.d.ts +22 -0
- package/node_modules/@noodle-borg/service/dist/routes/platform-account-reset.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/routes/platform-account-reset.js +201 -0
- package/node_modules/@noodle-borg/service/dist/routes/platform-account-reset.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/routes/private-platform-auth-dispatch.d.ts +18 -0
- package/node_modules/@noodle-borg/service/dist/routes/private-platform-auth-dispatch.d.ts.map +1 -0
- package/node_modules/@noodle-borg/service/dist/routes/private-platform-auth-dispatch.js +36 -0
- package/node_modules/@noodle-borg/service/dist/routes/private-platform-auth-dispatch.js.map +1 -0
- package/node_modules/@noodle-borg/service/dist/serve-options.d.ts +2 -1
- package/node_modules/@noodle-borg/service/dist/serve-options.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/serve.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/serve.js +16 -1
- package/node_modules/@noodle-borg/service/dist/serve.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/service.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/service.js +4 -5
- package/node_modules/@noodle-borg/service/dist/service.js.map +1 -1
- package/node_modules/@noodle-borg/service/dist/workos-directory.d.ts +22 -3
- package/node_modules/@noodle-borg/service/dist/workos-directory.d.ts.map +1 -1
- package/node_modules/@noodle-borg/service/dist/workos-directory.js +56 -5
- package/node_modules/@noodle-borg/service/dist/workos-directory.js.map +1 -1
- package/node_modules/@noodle-borg/wire-contracts/dist/assistant.d.ts +7 -0
- package/node_modules/@noodle-borg/wire-contracts/dist/assistant.d.ts.map +1 -1
- package/node_modules/@noodle-borg/wire-contracts/dist/assistant.js +5 -0
- package/node_modules/@noodle-borg/wire-contracts/dist/assistant.js.map +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,314 @@
|
|
|
1
|
+
import { canonicalJson, sha256Canonical } from './platform-account-reset-fingerprint.js';
|
|
2
|
+
import { platformAccountResetAppKey as appKey, comparePlatformAccountResetText as compareText, groupPlatformAccountResetRows as groupBy, incrementPlatformAccountResetCount as increment, queryPlatformAccountResetRows as rows, } from './platform-account-reset-ownership-helpers.js';
|
|
3
|
+
import { addPlatformAccountResetBillingProviders, addPlatformAccountResetCleanupResource, addPlatformAccountResetCredentialScopes, addPlatformAccountResetHostedAssets, addPlatformAccountResetRepositories, addPlatformAccountResetStateScopes, } from './platform-account-reset-ownership-resources-postgres.js';
|
|
4
|
+
import { loadPlatformAccountResetFrozenOwnerOnlyApps } from './platform-account-reset-ownership-rollback-postgres.js';
|
|
5
|
+
/**
|
|
6
|
+
* Classifies only explicit relational ownership. Email fields are deliberately absent from every ownership
|
|
7
|
+
* predicate; the preview layer handles contact hints separately as restrictive evidence.
|
|
8
|
+
*/
|
|
9
|
+
export async function loadPlatformAccountResetOwnershipSnapshot(pool, input) {
|
|
10
|
+
const targets = [...new Set(input.targetPrincipalIds)].sort(compareText);
|
|
11
|
+
const targetSet = new Set(targets);
|
|
12
|
+
const blockers = new Map();
|
|
13
|
+
const relationships = [];
|
|
14
|
+
const resources = [];
|
|
15
|
+
const personal = await rows(pool, `SELECT principal_subject, org_slug, billing_account_id
|
|
16
|
+
FROM personal_workspace_bindings
|
|
17
|
+
WHERE principal_subject = ANY($1::text[])`, [targets]);
|
|
18
|
+
const personalOrgOwners = new Map(personal.map((row) => [row.org_slug, row.principal_subject]));
|
|
19
|
+
const targetOwnerOnlyDeployments = await rows(pool, `SELECT org_slug, app_slug
|
|
20
|
+
FROM deploy_records
|
|
21
|
+
WHERE active AND archived_at IS NULL
|
|
22
|
+
AND access_mode = 'owner-only'
|
|
23
|
+
AND created_by_subject = ANY($1::text[])`, [targets]);
|
|
24
|
+
const frozenOwnerOnlyApps = input.quarantine === undefined
|
|
25
|
+
? []
|
|
26
|
+
: await loadPlatformAccountResetFrozenOwnerOnlyApps(pool, input.quarantine.operationId, targets, input.quarantine.cleanupResources);
|
|
27
|
+
const membershipRows = await rows(pool, `SELECT org_slug, subject, role
|
|
28
|
+
FROM org_members
|
|
29
|
+
WHERE subject = ANY($1::text[])`, [targets]);
|
|
30
|
+
const involvedOrgs = [
|
|
31
|
+
...new Set([
|
|
32
|
+
...membershipRows.map((row) => row.org_slug),
|
|
33
|
+
...personal.map((row) => row.org_slug),
|
|
34
|
+
...targetOwnerOnlyDeployments.map((row) => row.org_slug),
|
|
35
|
+
...frozenOwnerOnlyApps.map((row) => row.org_slug),
|
|
36
|
+
]),
|
|
37
|
+
].sort(compareText);
|
|
38
|
+
const owners = involvedOrgs.length === 0
|
|
39
|
+
? []
|
|
40
|
+
: await rows(pool, `SELECT member.org_slug, member.subject, principal.status
|
|
41
|
+
FROM org_members member
|
|
42
|
+
LEFT JOIN platform_principals principal ON principal.principal_id = member.subject
|
|
43
|
+
WHERE member.org_slug = ANY($1::text[]) AND member.role = 'owner'`, [involvedOrgs]);
|
|
44
|
+
const ownersByOrg = groupBy(owners, (row) => row.org_slug);
|
|
45
|
+
const membershipsByOrg = groupBy(membershipRows, (row) => row.org_slug);
|
|
46
|
+
const ownedOrgs = new Map();
|
|
47
|
+
const preservedOrgs = new Set();
|
|
48
|
+
let validPersonalOrganizations = 0;
|
|
49
|
+
for (const org of involvedOrgs) {
|
|
50
|
+
const orgOwners = ownersByOrg.get(org) ?? [];
|
|
51
|
+
if (orgOwners.some((owner) => owner.status === null)) {
|
|
52
|
+
increment(blockers, 'ownership_ambiguous');
|
|
53
|
+
relationships.push({ disposition: 'blocker', kind: 'owner_status', org });
|
|
54
|
+
continue;
|
|
55
|
+
}
|
|
56
|
+
const personalOwner = personalOrgOwners.get(org);
|
|
57
|
+
if (personalOwner !== undefined) {
|
|
58
|
+
const expectedMemberships = (membershipsByOrg.get(org) ?? []).filter((member) => member.subject === personalOwner && member.role === 'owner');
|
|
59
|
+
if (expectedMemberships.length !== 1 ||
|
|
60
|
+
orgOwners.some((owner) => owner.subject !== personalOwner)) {
|
|
61
|
+
increment(blockers, 'ownership_ambiguous');
|
|
62
|
+
relationships.push({ disposition: 'blocker', kind: 'personal_membership', org });
|
|
63
|
+
continue;
|
|
64
|
+
}
|
|
65
|
+
ownedOrgs.set(org, 'personal_org');
|
|
66
|
+
validPersonalOrganizations += 1;
|
|
67
|
+
relationships.push({
|
|
68
|
+
disposition: 'personal_org',
|
|
69
|
+
org,
|
|
70
|
+
principalId: personalOwner,
|
|
71
|
+
});
|
|
72
|
+
continue;
|
|
73
|
+
}
|
|
74
|
+
const targetOwners = orgOwners.filter((owner) => targetSet.has(owner.subject));
|
|
75
|
+
const foreignOwners = orgOwners.filter((owner) => !targetSet.has(owner.subject));
|
|
76
|
+
const activeForeignOwners = foreignOwners.filter((owner) => owner.status === 'active');
|
|
77
|
+
if (activeForeignOwners.length !== 0) {
|
|
78
|
+
preservedOrgs.add(org);
|
|
79
|
+
relationships.push({
|
|
80
|
+
disposition: 'preserved_shared_org',
|
|
81
|
+
org,
|
|
82
|
+
targetPrincipals: (membershipsByOrg.get(org) ?? []).map((member) => member.subject),
|
|
83
|
+
});
|
|
84
|
+
continue;
|
|
85
|
+
}
|
|
86
|
+
if (foreignOwners.length !== 0) {
|
|
87
|
+
increment(blockers, 'ownership_ambiguous');
|
|
88
|
+
relationships.push({ disposition: 'blocker', kind: 'inactive_foreign_owner', org });
|
|
89
|
+
continue;
|
|
90
|
+
}
|
|
91
|
+
if (targetOwners.length !== 0 && targetOwners.length === orgOwners.length) {
|
|
92
|
+
ownedOrgs.set(org, 'sole_owned_org');
|
|
93
|
+
relationships.push({
|
|
94
|
+
disposition: 'sole_owned_org',
|
|
95
|
+
org,
|
|
96
|
+
targetPrincipals: targetOwners.map((owner) => owner.subject),
|
|
97
|
+
});
|
|
98
|
+
continue;
|
|
99
|
+
}
|
|
100
|
+
increment(blockers, 'shared_org_owner_required');
|
|
101
|
+
relationships.push({ disposition: 'blocker', kind: 'remaining_owner', org });
|
|
102
|
+
}
|
|
103
|
+
const apps = involvedOrgs.length === 0
|
|
104
|
+
? []
|
|
105
|
+
: await rows(pool, `SELECT org_slug, slug FROM apps WHERE org_slug = ANY($1::text[])`, [involvedOrgs]);
|
|
106
|
+
const storedDeployments = involvedOrgs.length === 0
|
|
107
|
+
? []
|
|
108
|
+
: await rows(pool, `SELECT deployment_id, org_slug, app_slug, environment, active, archived_at,
|
|
109
|
+
access_mode, created_by_subject, hosted_assets,
|
|
110
|
+
CASE WHEN $2::text IS NULL THEN false
|
|
111
|
+
ELSE archived_at = (
|
|
112
|
+
SELECT quarantined_at FROM platform_account_reset_operations
|
|
113
|
+
WHERE operation_id = $2
|
|
114
|
+
)
|
|
115
|
+
END AS operation_archived
|
|
116
|
+
FROM deploy_records
|
|
117
|
+
WHERE org_slug = ANY($1::text[])`, [involvedOrgs, input.quarantine?.operationId ?? null]);
|
|
118
|
+
const operationArchivedDeployments = new Set((input.quarantine?.cleanupResources ?? [])
|
|
119
|
+
.filter((resource) => resource.provider === 'postgres' &&
|
|
120
|
+
resource.resourceKind === 'deployment' &&
|
|
121
|
+
resource.locator.archived === false)
|
|
122
|
+
.map((resource) => resource.locator.deploymentId)
|
|
123
|
+
.filter((deploymentId) => typeof deploymentId === 'string'));
|
|
124
|
+
const allDeployments = storedDeployments.map((deployment) => input.quarantine !== undefined &&
|
|
125
|
+
operationArchivedDeployments.has(deployment.deployment_id) &&
|
|
126
|
+
deployment.operation_archived
|
|
127
|
+
? { ...deployment, archived_at: null }
|
|
128
|
+
: deployment);
|
|
129
|
+
const activeByApp = groupBy(allDeployments.filter((row) => row.active && row.archived_at === null), appKey);
|
|
130
|
+
const eligibleApps = new Set();
|
|
131
|
+
let targetOwnerOnlyApps = 0;
|
|
132
|
+
for (const app of apps) {
|
|
133
|
+
const key = appKey(app);
|
|
134
|
+
const ownedDisposition = ownedOrgs.get(app.org_slug);
|
|
135
|
+
if (ownedDisposition !== undefined) {
|
|
136
|
+
eligibleApps.add(key);
|
|
137
|
+
relationships.push({
|
|
138
|
+
disposition: ownedDisposition,
|
|
139
|
+
kind: 'app',
|
|
140
|
+
org: app.org_slug,
|
|
141
|
+
app: app.slug,
|
|
142
|
+
});
|
|
143
|
+
continue;
|
|
144
|
+
}
|
|
145
|
+
if (!preservedOrgs.has(app.org_slug))
|
|
146
|
+
continue;
|
|
147
|
+
const active = activeByApp.get(key) ?? [];
|
|
148
|
+
const targetOwnerOnly = active.filter((deployment) => deployment.access_mode === 'owner-only' &&
|
|
149
|
+
deployment.created_by_subject !== null &&
|
|
150
|
+
targetSet.has(deployment.created_by_subject));
|
|
151
|
+
const conflicting = active.some((deployment) => deployment.access_mode !== 'owner-only' ||
|
|
152
|
+
deployment.created_by_subject === null ||
|
|
153
|
+
!targetSet.has(deployment.created_by_subject));
|
|
154
|
+
if (targetOwnerOnly.length !== 0 && conflicting) {
|
|
155
|
+
increment(blockers, 'ownership_ambiguous');
|
|
156
|
+
relationships.push({
|
|
157
|
+
disposition: 'blocker',
|
|
158
|
+
kind: 'mixed_app_ownership',
|
|
159
|
+
org: app.org_slug,
|
|
160
|
+
app: app.slug,
|
|
161
|
+
});
|
|
162
|
+
}
|
|
163
|
+
else if (targetOwnerOnly.length !== 0) {
|
|
164
|
+
eligibleApps.add(key);
|
|
165
|
+
targetOwnerOnlyApps += 1;
|
|
166
|
+
relationships.push({
|
|
167
|
+
disposition: 'target_owner_only_app',
|
|
168
|
+
org: app.org_slug,
|
|
169
|
+
app: app.slug,
|
|
170
|
+
});
|
|
171
|
+
}
|
|
172
|
+
else if (active.some((deployment) => deployment.access_mode === 'org-members')) {
|
|
173
|
+
relationships.push({
|
|
174
|
+
disposition: 'preserved_org_members_app',
|
|
175
|
+
org: app.org_slug,
|
|
176
|
+
app: app.slug,
|
|
177
|
+
});
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
for (const [org, disposition] of ownedOrgs) {
|
|
181
|
+
addPlatformAccountResetCleanupResource(resources, 'postgres', 'organization', {
|
|
182
|
+
org,
|
|
183
|
+
disposition,
|
|
184
|
+
targetPrincipals: (membershipsByOrg.get(org) ?? []).map((row) => row.subject),
|
|
185
|
+
});
|
|
186
|
+
}
|
|
187
|
+
for (const org of preservedOrgs) {
|
|
188
|
+
for (const member of membershipsByOrg.get(org) ?? []) {
|
|
189
|
+
addPlatformAccountResetCleanupResource(resources, 'postgres', 'preserved_membership', {
|
|
190
|
+
org,
|
|
191
|
+
principalId: member.subject,
|
|
192
|
+
role: member.role,
|
|
193
|
+
});
|
|
194
|
+
}
|
|
195
|
+
}
|
|
196
|
+
for (const app of apps) {
|
|
197
|
+
if (!eligibleApps.has(appKey(app)))
|
|
198
|
+
continue;
|
|
199
|
+
addPlatformAccountResetCleanupResource(resources, 'postgres', 'application', {
|
|
200
|
+
org: app.org_slug,
|
|
201
|
+
app: app.slug,
|
|
202
|
+
});
|
|
203
|
+
}
|
|
204
|
+
const eligibleDeployments = allDeployments.filter((row) => eligibleApps.has(appKey(row)));
|
|
205
|
+
const eligibleDeploymentIds = new Set(eligibleDeployments.map((row) => row.deployment_id));
|
|
206
|
+
for (const deployment of eligibleDeployments) {
|
|
207
|
+
addPlatformAccountResetCleanupResource(resources, 'postgres', 'deployment', {
|
|
208
|
+
deploymentId: deployment.deployment_id,
|
|
209
|
+
org: deployment.org_slug,
|
|
210
|
+
app: deployment.app_slug,
|
|
211
|
+
environment: deployment.environment,
|
|
212
|
+
active: deployment.active,
|
|
213
|
+
archived: deployment.archived_at !== null,
|
|
214
|
+
});
|
|
215
|
+
}
|
|
216
|
+
await addPlatformAccountResetHostedAssets(pool, resources, () => increment(blockers, 'ownership_ambiguous'), eligibleDeployments, eligibleDeploymentIds);
|
|
217
|
+
await addPlatformAccountResetRepositories(pool, resources, eligibleApps);
|
|
218
|
+
await addPlatformAccountResetStateScopes(pool, resources, eligibleDeploymentIds);
|
|
219
|
+
const selectedBillingAccounts = [...new Set(personal.map((row) => row.billing_account_id))].sort(compareText);
|
|
220
|
+
if (selectedBillingAccounts.length !== 0) {
|
|
221
|
+
const billingHomes = await rows(pool, `SELECT org_slug, billing_account_id,
|
|
222
|
+
home_owner_identity_issuer, home_owner_subject
|
|
223
|
+
FROM org_billing_home_accounts
|
|
224
|
+
WHERE billing_account_id = ANY($1::text[])`, [selectedBillingAccounts]);
|
|
225
|
+
for (const home of billingHomes) {
|
|
226
|
+
if (!ownedOrgs.has(home.org_slug))
|
|
227
|
+
increment(blockers, 'ownership_ambiguous');
|
|
228
|
+
else
|
|
229
|
+
addPlatformAccountResetCleanupResource(resources, 'postgres', 'billing_home_account', {
|
|
230
|
+
org: home.org_slug,
|
|
231
|
+
billingAccountId: home.billing_account_id,
|
|
232
|
+
homeOwnerIdentityIssuer: home.home_owner_identity_issuer,
|
|
233
|
+
homeOwnerSubject: home.home_owner_subject,
|
|
234
|
+
});
|
|
235
|
+
}
|
|
236
|
+
const billingLinks = await rows(pool, `SELECT org_slug, billing_account_id, home_free_billing_account_id,
|
|
237
|
+
fallback_billing_account_id, version,
|
|
238
|
+
linked_by_identity_issuer, linked_by_subject
|
|
239
|
+
FROM org_billing_links
|
|
240
|
+
WHERE active
|
|
241
|
+
AND (
|
|
242
|
+
billing_account_id = ANY($1::text[])
|
|
243
|
+
OR home_free_billing_account_id = ANY($1::text[])
|
|
244
|
+
OR fallback_billing_account_id = ANY($1::text[])
|
|
245
|
+
)`, [selectedBillingAccounts]);
|
|
246
|
+
for (const link of billingLinks) {
|
|
247
|
+
if (!ownedOrgs.has(link.org_slug)) {
|
|
248
|
+
increment(blockers, 'ownership_ambiguous');
|
|
249
|
+
continue;
|
|
250
|
+
}
|
|
251
|
+
addPlatformAccountResetCleanupResource(resources, 'postgres', 'org_billing_link', {
|
|
252
|
+
org: link.org_slug,
|
|
253
|
+
billingAccountId: link.billing_account_id,
|
|
254
|
+
homeFreeBillingAccountId: link.home_free_billing_account_id,
|
|
255
|
+
fallbackBillingAccountId: link.fallback_billing_account_id,
|
|
256
|
+
version: link.version,
|
|
257
|
+
linkedByIdentityIssuer: link.linked_by_identity_issuer,
|
|
258
|
+
linkedBySubject: link.linked_by_subject,
|
|
259
|
+
});
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
for (const account of selectedBillingAccounts)
|
|
263
|
+
addPlatformAccountResetCleanupResource(resources, 'postgres', 'billing_account', {
|
|
264
|
+
billingAccountId: account,
|
|
265
|
+
});
|
|
266
|
+
await addPlatformAccountResetBillingProviders(pool, resources, selectedBillingAccounts);
|
|
267
|
+
await addPlatformAccountResetCredentialScopes(pool, resources, targets, input.quarantine?.cleanupResources);
|
|
268
|
+
const normalizedResources = resources.sort((left, right) => canonicalJson(left).localeCompare(canonicalJson(right)));
|
|
269
|
+
const cleanupSetFingerprint = sha256Canonical({
|
|
270
|
+
schemaVersion: 1,
|
|
271
|
+
label: 'platform_account_reset_cleanup_set',
|
|
272
|
+
resources: normalizedResources,
|
|
273
|
+
});
|
|
274
|
+
const ownershipFingerprint = sha256Canonical({
|
|
275
|
+
schemaVersion: 1,
|
|
276
|
+
label: 'platform_account_reset_ownership',
|
|
277
|
+
relationships,
|
|
278
|
+
});
|
|
279
|
+
const counts = {
|
|
280
|
+
personalOrganizationCount: validPersonalOrganizations,
|
|
281
|
+
soleOwnedOrganizationCount: [...ownedOrgs.values()].filter((disposition) => disposition === 'sole_owned_org').length,
|
|
282
|
+
ownerOnlyAppCount: targetOwnerOnlyApps,
|
|
283
|
+
preservedSharedOrganizationCount: preservedOrgs.size,
|
|
284
|
+
membershipCount: membershipRows.length,
|
|
285
|
+
billingAccountCount: selectedBillingAccounts.length,
|
|
286
|
+
credentialCount: normalizedResources.filter((resource) => [
|
|
287
|
+
'developer_grant',
|
|
288
|
+
'oauth_consent',
|
|
289
|
+
'device_authorization',
|
|
290
|
+
'refresh_subject',
|
|
291
|
+
'authorization_code',
|
|
292
|
+
].includes(resource.resourceKind)).length,
|
|
293
|
+
providerObjectCount: normalizedResources.filter((resource) => resource.provider !== 'postgres' || resource.resourceKind === 'state_scope').length,
|
|
294
|
+
};
|
|
295
|
+
const blockerList = [...blockers]
|
|
296
|
+
.map(([code, count]) => ({ code, count }))
|
|
297
|
+
.sort((left, right) => left.code.localeCompare(right.code));
|
|
298
|
+
return {
|
|
299
|
+
counts,
|
|
300
|
+
blockers: blockerList,
|
|
301
|
+
cleanupResources: normalizedResources,
|
|
302
|
+
ownershipFingerprint,
|
|
303
|
+
cleanupSetFingerprint,
|
|
304
|
+
fingerprint: sha256Canonical({
|
|
305
|
+
schemaVersion: 1,
|
|
306
|
+
label: 'platform_account_reset_ownership_snapshot',
|
|
307
|
+
counts,
|
|
308
|
+
blockers: blockerList,
|
|
309
|
+
ownershipFingerprint,
|
|
310
|
+
cleanupSetFingerprint,
|
|
311
|
+
}),
|
|
312
|
+
};
|
|
313
|
+
}
|
|
314
|
+
//# sourceMappingURL=platform-account-reset-ownership-postgres.js.map
|
package/node_modules/@noodle-borg/service/dist/platform-account-reset-ownership-postgres.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"platform-account-reset-ownership-postgres.js","sourceRoot":"","sources":["../src/platform-account-reset-ownership-postgres.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,yCAAyC,CAAC;AACzF,OAAO,EACL,0BAA0B,IAAI,MAAM,EACpC,+BAA+B,IAAI,WAAW,EAC9C,6BAA6B,IAAI,OAAO,EACxC,kCAAkC,IAAI,SAAS,EAC/C,6BAA6B,IAAI,IAAI,GACtC,MAAM,+CAA+C,CAAC;AACvD,OAAO,EACL,uCAAuC,EACvC,sCAAsC,EACtC,uCAAuC,EACvC,mCAAmC,EACnC,mCAAmC,EACnC,kCAAkC,GACnC,MAAM,0DAA0D,CAAC;AAClE,OAAO,EAAE,2CAA2C,EAAE,MAAM,yDAAyD,CAAC;AAiGtH;;;GAGG;AACH,MAAM,CA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ACrC,oBAAoB;QACpB,qBAAqB;QACrB,WAAW,EAAE,eAAe,CAAC;YAC3B,aAAa,EAAE,CAAC;YAChB,KAAK,EAAE,2CAA2C;YAClD,MAAM;YACN,QAAQ,EAAE,WAAW;YACrB,oBAAoB;YACpB,qBAAqB;SACtB,CAAC;KACH,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { PlatformAccountResetCleanupResource } from './platform-account-reset-ownership-postgres.js';
|
|
2
|
+
import type { PlatformIdentityQueryable } from './platform-identity-postgres.js';
|
|
3
|
+
interface DeploymentResourceRow {
|
|
4
|
+
readonly deployment_id: string;
|
|
5
|
+
readonly hosted_assets: unknown;
|
|
6
|
+
}
|
|
7
|
+
export declare function addPlatformAccountResetHostedAssets(pool: PlatformIdentityQueryable, resources: PlatformAccountResetCleanupResource[], onAmbiguous: () => void, eligibleDeployments: readonly DeploymentResourceRow[], eligibleDeploymentIds: ReadonlySet<string>): Promise<void>;
|
|
8
|
+
export declare function addPlatformAccountResetRepositories(pool: PlatformIdentityQueryable, resources: PlatformAccountResetCleanupResource[], eligibleApps: ReadonlySet<string>): Promise<void>;
|
|
9
|
+
export declare function addPlatformAccountResetStateScopes(pool: PlatformIdentityQueryable, resources: PlatformAccountResetCleanupResource[], deploymentIds: ReadonlySet<string>): Promise<void>;
|
|
10
|
+
export declare function addPlatformAccountResetBillingProviders(pool: PlatformIdentityQueryable, resources: PlatformAccountResetCleanupResource[], billingAccountIds: readonly string[]): Promise<void>;
|
|
11
|
+
export declare function addPlatformAccountResetCredentialScopes(pool: PlatformIdentityQueryable, resources: PlatformAccountResetCleanupResource[], targets: readonly string[], frozenResources?: readonly PlatformAccountResetCleanupResource[]): Promise<void>;
|
|
12
|
+
export declare function addPlatformAccountResetCleanupResource(resources: PlatformAccountResetCleanupResource[], provider: PlatformAccountResetCleanupResource['provider'], resourceKind: string, locator: Readonly<Record<string, unknown>>): void;
|
|
13
|
+
export {};
|
|
14
|
+
//# sourceMappingURL=platform-account-reset-ownership-resources-postgres.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"platform-account-reset-ownership-resources-postgres.d.ts","sourceRoot":"","sources":["../src/platform-account-reset-ownership-resources-postgres.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,mCAAmC,EAAE,MAAM,gDAAgD,CAAC;AAC1G,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,iCAAiC,CAAC;AAEjF,UAAU,qBAAqB;IAC7B,QAAQ,CAAC,aAAa,EAAE,MAAM,CAAC;IAC/B,QAAQ,CAAC,aAAa,EAAE,OAAO,CAAC;CACjC;AAuBD,wBAAsB,mCAAmC,CACvD,IAAI,EAAE,yBAAyB,EAC/B,SAAS,EAAE,mCAAmC,EAAE,EAChD,WAAW,EAAE,MAAM,IAAI,EACvB,mBAAmB,EAAE,SAAS,qBAAqB,EAAE,EACrD,qBAAqB,EAAE,WAAW,CAAC,MAAM,CAAC,GACzC,OAAO,CAAC,IAAI,CAAC,CA+Bf;AAED,wBAAsB,mCAAmC,CACvD,IAAI,EAAE,yBAAyB,EAC/B,SAAS,EAAE,mCAAmC,EAAE,EAChD,YAAY,EAAE,WAAW,CAAC,MAAM,CAAC,GAChC,OAAO,CAAC,IAAI,CAAC,CAuCf;AAED,wBAAsB,kCAAkC,CACtD,IAAI,EAAE,yBAAyB,EAC/B,SAAS,EAAE,mCAAmC,EAAE,EAChD,aAAa,EAAE,WAAW,CAAC,MAAM,CAAC,GACjC,OAAO,CAAC,IAAI,CAAC,CAgBf;AAED,wBAAsB,uCAAuC,CAC3D,IAAI,EAAE,yBAAyB,EAC/B,SAAS,EAAE,mCAAmC,EAAE,EAChD,iBAAiB,EAAE,SAAS,MAAM,EAAE,GACnC,OAAO,CAAC,IAAI,CAAC,CA4Bf;AAED,wBAAsB,uCAAuC,CAC3D,IAAI,EAAE,yBAAyB,EAC/B,SAAS,EAAE,mCAAmC,EAAE,EAChD,OAAO,EAAE,SAAS,MAAM,EAAE,EAC1B,eAAe,CAAC,EAAE,SAAS,mCAAmC,EAAE,GAC/D,OAAO,CAAC,IAAI,CAAC,CAoGf;AAUD,wBAAgB,sCAAsC,CACpD,SAAS,EAAE,mCAAmC,EAAE,EAChD,QAAQ,EAAE,mCAAmC,CAAC,UAAU,CAAC,EACzD,YAAY,EAAE,MAAM,EACpB,OAAO,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,GACzC,IAAI,CAgBN"}
|
|
@@ -0,0 +1,210 @@
|
|
|
1
|
+
import { sha256Canonical } from './platform-account-reset-fingerprint.js';
|
|
2
|
+
import { platformAccountResetAppKey as appKey, comparePlatformAccountResetText as compareText, queryPlatformAccountResetRows as rows, } from './platform-account-reset-ownership-helpers.js';
|
|
3
|
+
export async function addPlatformAccountResetHostedAssets(pool, resources, onAmbiguous, eligibleDeployments, eligibleDeploymentIds) {
|
|
4
|
+
const allDeployments = await rows(pool, 'SELECT deployment_id, hosted_assets FROM deploy_records');
|
|
5
|
+
const references = new Map();
|
|
6
|
+
for (const deployment of allDeployments) {
|
|
7
|
+
for (const objectKey of parseAssetKeys(deployment.hosted_assets).keys) {
|
|
8
|
+
const deploymentIds = references.get(objectKey) ?? new Set();
|
|
9
|
+
deploymentIds.add(deployment.deployment_id);
|
|
10
|
+
references.set(objectKey, deploymentIds);
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
for (const deployment of eligibleDeployments) {
|
|
14
|
+
const parsed = parseAssetKeys(deployment.hosted_assets);
|
|
15
|
+
if (!parsed.valid) {
|
|
16
|
+
onAmbiguous();
|
|
17
|
+
continue;
|
|
18
|
+
}
|
|
19
|
+
for (const objectKey of parsed.keys) {
|
|
20
|
+
const deploymentIds = [...(references.get(objectKey) ?? [])].sort(compareText);
|
|
21
|
+
if (deploymentIds.some((id) => !eligibleDeploymentIds.has(id))) {
|
|
22
|
+
onAmbiguous();
|
|
23
|
+
continue;
|
|
24
|
+
}
|
|
25
|
+
addPlatformAccountResetCleanupResource(resources, 'object_storage', 'hosted_asset', {
|
|
26
|
+
objectKey,
|
|
27
|
+
deploymentIds,
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
export async function addPlatformAccountResetRepositories(pool, resources, eligibleApps) {
|
|
33
|
+
const all = await rows(pool, `SELECT github_repository_id, installation_id, org_slug, app_slug, enabled
|
|
34
|
+
FROM repo_connections`);
|
|
35
|
+
const normalized = all.map((row) => ({
|
|
36
|
+
...row,
|
|
37
|
+
github_repository_id: canonicalGitHubId(row.github_repository_id),
|
|
38
|
+
installation_id: canonicalGitHubId(row.installation_id),
|
|
39
|
+
}));
|
|
40
|
+
const selected = normalized.filter((row) => eligibleApps.has(appKey(row)));
|
|
41
|
+
for (const repository of selected) {
|
|
42
|
+
addPlatformAccountResetCleanupResource(resources, 'github', 'repository_connection', {
|
|
43
|
+
githubRepositoryId: repository.github_repository_id,
|
|
44
|
+
installationId: repository.installation_id,
|
|
45
|
+
enabled: repository.enabled,
|
|
46
|
+
org: repository.org_slug,
|
|
47
|
+
app: repository.app_slug,
|
|
48
|
+
});
|
|
49
|
+
}
|
|
50
|
+
for (const installationId of [...new Set(selected.map((row) => row.installation_id))].sort(compareCanonicalDecimal)) {
|
|
51
|
+
addPlatformAccountResetCleanupResource(resources, 'github', 'installation_reachability', {
|
|
52
|
+
installationId,
|
|
53
|
+
selectedRepositoryIds: selected
|
|
54
|
+
.filter((row) => row.installation_id === installationId)
|
|
55
|
+
.map((row) => row.github_repository_id)
|
|
56
|
+
.sort(compareCanonicalDecimal),
|
|
57
|
+
survivingRepositoryIds: normalized
|
|
58
|
+
.filter((row) => row.installation_id === installationId && !eligibleApps.has(appKey(row)) && row.enabled)
|
|
59
|
+
.map((row) => row.github_repository_id)
|
|
60
|
+
.sort(compareCanonicalDecimal),
|
|
61
|
+
});
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
export async function addPlatformAccountResetStateScopes(pool, resources, deploymentIds) {
|
|
65
|
+
if (deploymentIds.size === 0)
|
|
66
|
+
return;
|
|
67
|
+
const state = await rows(pool, `SELECT deployment_id, handle_name, owner_key, state_key
|
|
68
|
+
FROM state_handle_records
|
|
69
|
+
WHERE deployment_id = ANY($1::text[])`, [[...deploymentIds]]);
|
|
70
|
+
for (const row of state)
|
|
71
|
+
addPlatformAccountResetCleanupResource(resources, 'postgres', 'state_scope', {
|
|
72
|
+
deploymentId: row.deployment_id,
|
|
73
|
+
handleName: row.handle_name,
|
|
74
|
+
ownerKey: row.owner_key,
|
|
75
|
+
stateKey: row.state_key,
|
|
76
|
+
});
|
|
77
|
+
}
|
|
78
|
+
export async function addPlatformAccountResetBillingProviders(pool, resources, billingAccountIds) {
|
|
79
|
+
if (billingAccountIds.length === 0)
|
|
80
|
+
return;
|
|
81
|
+
const customers = await rows(pool, `SELECT billing_account_id, mode, customer_id AS provider_id
|
|
82
|
+
FROM billing_stripe_customers
|
|
83
|
+
WHERE billing_account_id = ANY($1::text[])`, [billingAccountIds]);
|
|
84
|
+
const subscriptions = await rows(pool, `SELECT billing_account_id, mode, provider_subscription_id AS provider_id
|
|
85
|
+
FROM billing_stripe_subscription_bindings
|
|
86
|
+
WHERE billing_account_id = ANY($1::text[])`, [billingAccountIds]);
|
|
87
|
+
for (const row of customers)
|
|
88
|
+
addPlatformAccountResetCleanupResource(resources, 'stripe', 'billing_customer', {
|
|
89
|
+
billingAccountId: row.billing_account_id,
|
|
90
|
+
mode: row.mode,
|
|
91
|
+
customerId: row.provider_id,
|
|
92
|
+
});
|
|
93
|
+
for (const row of subscriptions)
|
|
94
|
+
addPlatformAccountResetCleanupResource(resources, 'stripe', 'billing_subscription', {
|
|
95
|
+
billingAccountId: row.billing_account_id,
|
|
96
|
+
mode: row.mode,
|
|
97
|
+
subscriptionId: row.provider_id,
|
|
98
|
+
});
|
|
99
|
+
}
|
|
100
|
+
export async function addPlatformAccountResetCredentialScopes(pool, resources, targets, frozenResources) {
|
|
101
|
+
if (frozenResources !== undefined) {
|
|
102
|
+
for (const resource of frozenResources) {
|
|
103
|
+
if (resource.provider === 'postgres' && CREDENTIAL_RESOURCE_KINDS.has(resource.resourceKind))
|
|
104
|
+
addPlatformAccountResetCleanupResource(resources, resource.provider, resource.resourceKind, resource.locator);
|
|
105
|
+
}
|
|
106
|
+
return;
|
|
107
|
+
}
|
|
108
|
+
const grants = await rows(pool, `SELECT id, subject FROM developer_access_grants
|
|
109
|
+
WHERE subject = ANY($1::text[]) AND revoked_at IS NULL
|
|
110
|
+
AND (expires_at IS NULL OR expires_at > now())`, [targets]);
|
|
111
|
+
for (const row of grants)
|
|
112
|
+
addPlatformAccountResetCleanupResource(resources, 'postgres', 'developer_grant', {
|
|
113
|
+
grantId: row.id,
|
|
114
|
+
principalId: row.subject,
|
|
115
|
+
});
|
|
116
|
+
const consent = await rows(pool, `SELECT DISTINCT client_id, owner_subject, resource
|
|
117
|
+
FROM (
|
|
118
|
+
SELECT client_id, owner_subject, resource
|
|
119
|
+
FROM oauth_consent_grant_provenance
|
|
120
|
+
WHERE owner_subject = ANY($1::text[]) AND identity_kind = 'platform'
|
|
121
|
+
UNION ALL
|
|
122
|
+
SELECT client_id, owner_subject, resource
|
|
123
|
+
FROM oauth_consent_grants
|
|
124
|
+
WHERE owner_subject = ANY($1::text[]) AND identity_kind = 'platform'
|
|
125
|
+
) consent`, [targets]);
|
|
126
|
+
for (const row of consent)
|
|
127
|
+
addPlatformAccountResetCleanupResource(resources, 'postgres', 'oauth_consent', {
|
|
128
|
+
clientId: row.client_id,
|
|
129
|
+
principalId: row.owner_subject,
|
|
130
|
+
resource: row.resource,
|
|
131
|
+
});
|
|
132
|
+
const devices = await rows(pool, `SELECT device_code, owner_subject FROM oauth_device_authorizations
|
|
133
|
+
WHERE owner_subject = ANY($1::text[])
|
|
134
|
+
AND identity_kind IS DISTINCT FROM 'customer'
|
|
135
|
+
AND status IN ('pending', 'approved') AND expires_at > now()`, [targets]);
|
|
136
|
+
for (const row of devices)
|
|
137
|
+
addPlatformAccountResetCleanupResource(resources, 'postgres', 'device_authorization', {
|
|
138
|
+
deviceCode: row.device_code,
|
|
139
|
+
principalId: row.owner_subject,
|
|
140
|
+
});
|
|
141
|
+
const refresh = await rows(pool, `SELECT owner_subject,
|
|
142
|
+
array_agg(DISTINCT family_id) FILTER (WHERE family_id IS NOT NULL) AS family_ids
|
|
143
|
+
FROM oauth_refresh_tokens
|
|
144
|
+
WHERE owner_subject = ANY($1::text[])
|
|
145
|
+
AND identity_kind IS DISTINCT FROM 'customer'
|
|
146
|
+
AND expires_at > now() AND rotated_at IS NULL AND superseded_by IS NULL
|
|
147
|
+
GROUP BY owner_subject`, [targets]);
|
|
148
|
+
for (const row of refresh)
|
|
149
|
+
addPlatformAccountResetCleanupResource(resources, 'postgres', 'refresh_subject', {
|
|
150
|
+
principalId: row.owner_subject,
|
|
151
|
+
familyIds: row.family_ids ?? [],
|
|
152
|
+
});
|
|
153
|
+
const codes = await rows(pool, `SELECT code, owner_subject FROM oauth_authorization_codes
|
|
154
|
+
WHERE owner_subject = ANY($1::text[])
|
|
155
|
+
AND identity_kind IS DISTINCT FROM 'customer' AND expires_at > now()`, [targets]);
|
|
156
|
+
for (const row of codes)
|
|
157
|
+
addPlatformAccountResetCleanupResource(resources, 'postgres', 'authorization_code', {
|
|
158
|
+
codeFingerprint: sha256Canonical({
|
|
159
|
+
schemaVersion: 1,
|
|
160
|
+
label: 'oauth_authorization_code',
|
|
161
|
+
code: row.code,
|
|
162
|
+
}),
|
|
163
|
+
principalId: row.owner_subject,
|
|
164
|
+
});
|
|
165
|
+
}
|
|
166
|
+
const CREDENTIAL_RESOURCE_KINDS = new Set([
|
|
167
|
+
'developer_grant',
|
|
168
|
+
'oauth_consent',
|
|
169
|
+
'device_authorization',
|
|
170
|
+
'refresh_subject',
|
|
171
|
+
'authorization_code',
|
|
172
|
+
]);
|
|
173
|
+
export function addPlatformAccountResetCleanupResource(resources, provider, resourceKind, locator) {
|
|
174
|
+
const locatorFingerprint = sha256Canonical({
|
|
175
|
+
schemaVersion: 1,
|
|
176
|
+
label: `platform_account_reset_locator:${provider}:${resourceKind}`,
|
|
177
|
+
locator,
|
|
178
|
+
});
|
|
179
|
+
if (resources.some((resource) => resource.provider === provider &&
|
|
180
|
+
resource.resourceKind === resourceKind &&
|
|
181
|
+
resource.locatorFingerprint === locatorFingerprint))
|
|
182
|
+
return;
|
|
183
|
+
resources.push({ provider, resourceKind, locator, locatorFingerprint });
|
|
184
|
+
}
|
|
185
|
+
function parseAssetKeys(value) {
|
|
186
|
+
if (value === null)
|
|
187
|
+
return { valid: true, keys: [] };
|
|
188
|
+
if (!Array.isArray(value))
|
|
189
|
+
return { valid: false, keys: [] };
|
|
190
|
+
const keys = [];
|
|
191
|
+
for (const entry of value) {
|
|
192
|
+
if (typeof entry !== 'object' ||
|
|
193
|
+
entry === null ||
|
|
194
|
+
!('objectKey' in entry) ||
|
|
195
|
+
typeof entry.objectKey !== 'string' ||
|
|
196
|
+
entry.objectKey.length === 0)
|
|
197
|
+
return { valid: false, keys: [] };
|
|
198
|
+
keys.push(entry.objectKey);
|
|
199
|
+
}
|
|
200
|
+
return { valid: true, keys: [...new Set(keys)].sort(compareText) };
|
|
201
|
+
}
|
|
202
|
+
function canonicalGitHubId(value) {
|
|
203
|
+
if (!/^[1-9][0-9]*$/.test(value))
|
|
204
|
+
throw new Error('GitHub identifier is not canonical');
|
|
205
|
+
return value;
|
|
206
|
+
}
|
|
207
|
+
function compareCanonicalDecimal(left, right) {
|
|
208
|
+
return left.length - right.length || compareText(left, right);
|
|
209
|
+
}
|
|
210
|
+
//# sourceMappingURL=platform-account-reset-ownership-resources-postgres.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"platform-account-reset-ownership-resources-postgres.js","sourceRoot":"","sources":["../src/platform-account-reset-ownership-resources-postgres.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,M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O,EAAE,KAAK,EAAE,KAAK,EAAE,IAAI,EAAE,EAAE,EAAE,CAAC;IAC7D,MAAM,IAAI,GAAa,EAAE,CAAC;IAC1B,KAAK,MAAM,KAAK,IAAI,KAAK,EAAE,CAAC;QAC1B,IACE,OAAO,KAAK,KAAK,QAAQ;YACzB,KAAK,KAAK,IAAI;YACd,CAAC,CAAC,WAAW,IAAI,KAAK,CAAC;YACvB,OAAO,KAAK,CAAC,SAAS,KAAK,QAAQ;YACnC,KAAK,CAAC,SAAS,CAAC,MAAM,KAAK,CAAC;YAE5B,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,IAAI,EAAE,EAAE,EAAE,CAAC;QACpC,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC;IAC7B,CAAC;IACD,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC,GAAG,IAAI,GAAG,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,WAAW,CAAC,EAAE,CAAC;AACrE,CAAC;AAED,SAAS,iBAAiB,CAAC,KAAa;IACtC,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,KAAK,CAAC;QAAE,MAAM,IAAI,KAAK,CAAC,oCAAoC,CAAC,CAAC;IACxF,OAAO,KAAK,CAAC;AACf,CAAC;AAED,SAAS,uBAAuB,CAAC,IAAY,EAAE,KAAa;IAC1D,OAAO,IAAI,CAAC,MAAM,GAAG,KAAK,CAAC,MAAM,IAAI,WAAW,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;AAChE,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { PlatformAccountResetCleanupResource } from './platform-account-reset-ownership-postgres.js';
|
|
2
|
+
import type { PlatformIdentityQueryable } from './platform-identity-postgres.js';
|
|
3
|
+
/**
|
|
4
|
+
* Reintroduces only exact frozen owner-only app locators into rollback discovery. The current row must
|
|
5
|
+
* still carry this operation's quarantine archive stamp; broader archived deployment scans are forbidden.
|
|
6
|
+
*/
|
|
7
|
+
export declare function loadPlatformAccountResetFrozenOwnerOnlyApps(pool: PlatformIdentityQueryable, operationId: string, targetPrincipalIds: readonly string[], cleanupResources: readonly PlatformAccountResetCleanupResource[]): Promise<readonly {
|
|
8
|
+
readonly org_slug: string;
|
|
9
|
+
readonly app_slug: string;
|
|
10
|
+
}[]>;
|
|
11
|
+
//# sourceMappingURL=platform-account-reset-ownership-rollback-postgres.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"platform-account-reset-ownership-rollback-postgres.d.ts","sourceRoot":"","sources":["../src/platform-account-reset-ownership-rollback-postgres.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,mCAAmC,EAAE,MAAM,gDAAgD,CAAC;AAC1G,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,iCAAiC,CAAC;AAyBjF;;;GAGG;AACH,wBAAsB,2CAA2C,CAC/D,IAAI,EAAE,yBAAyB,EAC/B,WAAW,EAAE,MAAM,EACnB,kBAAkB,EAAE,SAAS,MAAM,EAAE,EACrC,gBAAgB,EAAE,SAAS,mCAAmC,EAAE,GAC/D,OAAO,CAAC,SAAS;IAAE,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAA;CAAE,EAAE,CAAC,CA0D9E"}
|