@synopackageland/cli 0.5.3 → 0.6.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/README.md +69 -38
- package/dist/add.d.ts +4 -0
- package/dist/add.js +124 -0
- package/dist/build-spk/delete-app-data.d.ts +2 -2
- package/dist/build-spk/generator.js +3 -90
- package/dist/build-spk/native-lifecycle.d.ts +3 -49
- package/dist/build-spk/native-lifecycle.js +8 -187
- package/dist/build-spk/notices.d.ts +1 -1
- package/dist/build-spk/notices.js +8 -12
- package/dist/build-spk/uninstall-wizard.d.ts +3 -10
- package/dist/build-spk/uninstall-wizard.js +5 -3
- package/dist/build-spk/wizard-messages.d.ts +28 -6
- package/dist/build-spk/wizard-messages.js +33 -11
- package/dist/capabilities.d.ts +4 -0
- package/dist/capabilities.js +12 -0
- package/dist/cli.js +329 -467
- package/dist/compose/analyze.js +2 -2
- package/dist/contract/unsupported-types.js +1 -1
- package/dist/deploy/deploy.d.ts +1 -1
- package/dist/deploy/deploy.js +1 -3
- package/dist/deploy/plan.d.ts +1 -1
- package/dist/deploy/plan.js +55 -24
- package/dist/discovery.d.ts +1 -2
- package/dist/discovery.js +3 -3
- package/dist/error-registry.js +70 -298
- package/dist/host/dsm-client.js +79 -7
- package/dist/host/types.d.ts +13 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/info.d.ts +20 -2
- package/dist/info.js +140 -0
- package/dist/init.d.ts +2 -14
- package/dist/init.js +89 -90
- package/dist/inspect.js +1 -1
- package/dist/log.d.ts +5 -0
- package/dist/log.js +18 -0
- package/dist/runtime/executor-build.d.ts +22 -0
- package/dist/runtime/executor-build.js +36 -0
- package/dist/runtime/executor-inspect.d.ts +15 -0
- package/dist/runtime/executor-inspect.js +32 -0
- package/dist/runtime/executor-policy.d.ts +25 -0
- package/dist/runtime/executor-policy.js +24 -0
- package/dist/runtime/executor-tasks.d.ts +16 -0
- package/dist/runtime/executor-tasks.js +28 -0
- package/dist/runtime/uninstall-cleanup.d.ts +7 -0
- package/dist/runtime/uninstall-cleanup.js +10 -0
- package/dist/skill.js +3 -1
- package/dist/standalone/api-permissions.d.ts +18 -0
- package/dist/standalone/api-permissions.js +63 -0
- package/dist/standalone/build.d.ts +1 -1
- package/dist/standalone/build.js +26 -40
- package/dist/standalone/dsm-window.js +42 -23
- package/dist/standalone/inspect-spk.d.ts +9 -3
- package/dist/standalone/inspect-spk.js +64 -68
- package/dist/standalone/lifecycle.d.ts +1 -1
- package/dist/standalone/lifecycle.js +31 -27
- package/dist/standalone/manifest.d.ts +17 -14
- package/dist/standalone/manifest.js +77 -53
- package/dist/standalone/resource.d.ts +2 -2
- package/dist/standalone/resource.js +1 -1
- package/dist/standalone/root-ops.d.ts +1 -30
- package/dist/standalone/root-ops.js +1 -68
- package/dist/standalone/root-window.d.ts +5 -38
- package/dist/standalone/root-window.js +116 -399
- package/dist/standalone/spk.d.ts +3 -5
- package/dist/standalone/spk.js +24 -49
- package/dist/templates/_executor/README.md +204 -0
- package/dist/templates/_executor/apppriv_review_test.go +28 -0
- package/dist/templates/_executor/auth_presence_review_test.go +38 -0
- package/dist/templates/_executor/cmd/lifecycle/main.go +42 -0
- package/dist/templates/_executor/cookie_review_test.go +27 -0
- package/dist/templates/_executor/digest_review_test.go +120 -0
- package/dist/templates/_executor/directories.go +40 -0
- package/dist/templates/_executor/dsm.go +319 -0
- package/dist/templates/_executor/dsm_test.go +196 -0
- package/dist/templates/_executor/executor.go +524 -0
- package/dist/templates/_executor/executor_test.go +284 -0
- package/dist/templates/_executor/go.mod +3 -0
- package/dist/templates/_executor/identity.go +48 -0
- package/dist/templates/_executor/internal/lifecycle/lifecycle.go +90 -0
- package/dist/templates/_executor/internal/lifecycle/lifecycle_test.go +174 -0
- package/dist/templates/_executor/internal/taskscript/boot.sh +31 -0
- package/dist/templates/_executor/internal/taskscript/cmd/main.go +19 -0
- package/dist/templates/_executor/internal/taskscript/control.sh +26 -0
- package/dist/templates/_executor/internal/taskscript/tasks.go +42 -0
- package/dist/templates/_executor/json_review_test.go +40 -0
- package/dist/templates/_executor/lifecycle_test.go +86 -0
- package/dist/templates/_executor/main.go +518 -0
- package/dist/templates/_executor/managed.go +117 -0
- package/dist/templates/_executor/managed_test.go +137 -0
- package/dist/templates/_executor/path_test.go +17 -0
- package/dist/templates/_executor/platform_linux.go +336 -0
- package/dist/templates/_executor/platform_linux_test.go +247 -0
- package/dist/templates/_executor/platform_other.go +42 -0
- package/dist/templates/_executor/process.go +139 -0
- package/dist/templates/_executor/socket_linux_test.go +46 -0
- package/dist/templates/_executor/store.go +90 -0
- package/dist/templates/_executor/task_race_review_test.go +47 -0
- package/dist/templates/_executor/tasks.go +283 -0
- package/dist/templates/_executor/tasks_review_test.go +43 -0
- package/dist/templates/_executor/tasks_test.go +166 -0
- package/dist/templates/_executor/testdata/evidence/cleanup.json +24 -0
- package/dist/templates/_executor/testdata/evidence/final-smoke.jsonl +9 -0
- package/dist/templates/_executor/testdata/evidence/kernel-acl.json +6 -0
- package/dist/templates/_executor/testdata/evidence/linux-tests.log +123 -0
- package/dist/templates/_executor/testdata/evidence/live.jsonl +23 -0
- package/dist/templates/_executor/testdata/evidence/storage.json +90 -0
- package/dist/templates/_executor/testdata/evidence/validation.json +55 -0
- package/dist/templates/_executor/testdata/live_probe.py +98 -0
- package/dist/templates/_executor/upgrade_watch_test.go +236 -0
- package/dist/templates/_executor/watch.go +156 -0
- package/dist/templates/_executor/watch_test.go +270 -0
- package/dist/templates/_executor/write_review_linux_test.go +95 -0
- package/dist/templates/_shared/AGENTS.md +17 -0
- package/dist/templates/_shared/CLAUDE.md +1 -0
- package/dist/templates/binary/LICENSES/GO-LICENSE +27 -0
- package/dist/templates/binary/LICENSES/GO-PATENTS +22 -0
- package/dist/templates/binary/dsm-package.yaml +19 -0
- package/dist/templates/binary/example/main.go +16 -0
- package/dist/templates/binary/gitignore +2 -0
- package/dist/templates/binary/ui/app.css +4 -0
- package/dist/templates/binary/ui/app.js +17 -0
- package/dist/templates/native-go/README.md +128 -139
- package/dist/templates/native-go/backend/THIRD_PARTY_NOTICES.txt +1 -1
- package/dist/templates/native-go/backend/cmd/app/main.go +33 -26
- package/dist/templates/native-go/backend/internal/api/cgi_framing_test.go +32 -0
- package/dist/templates/native-go/backend/internal/api/cookie_review_test.go +28 -0
- package/dist/templates/native-go/backend/internal/api/deadline_test.go +114 -0
- package/dist/templates/native-go/backend/internal/api/dsm-session.go +54 -0
- package/dist/templates/native-go/backend/internal/api/dsm-session_test.go +51 -0
- package/dist/templates/native-go/backend/internal/api/errors.go +14 -0
- package/dist/templates/native-go/backend/internal/api/permissions.go +161 -0
- package/dist/templates/native-go/backend/internal/api/permissions.json +5 -0
- package/dist/templates/native-go/backend/internal/api/permissions_test.go +113 -0
- package/dist/templates/native-go/backend/internal/api/policy_fixture_test.go +8 -0
- package/dist/templates/native-go/backend/internal/api/registry.go +48 -32
- package/dist/templates/native-go/backend/internal/api/registry_test.go +16 -1
- package/dist/templates/native-go/backend/internal/api/resource_limits_test.go +87 -0
- package/dist/templates/native-go/backend/internal/api/sdk-permissions.json +46 -0
- package/dist/templates/native-go/backend/internal/api/sdk_policy_test.go +31 -0
- package/dist/templates/native-go/backend/internal/api/server.go +135 -8
- package/dist/templates/native-go/backend/internal/api/testdata/permissions-cases.json +172 -0
- package/dist/templates/native-go/backend/internal/app/background.go +23 -44
- package/dist/templates/native-go/backend/internal/app/background_owner.go +0 -21
- package/dist/templates/native-go/backend/internal/app/background_owner_test.go +40 -22
- package/dist/templates/native-go/backend/internal/app/background_schedule.go +0 -5
- package/dist/templates/native-go/backend/internal/app/background_schedule_test.go +1 -1
- package/dist/templates/native-go/backend/internal/app/background_test.go +15 -41
- package/dist/templates/native-go/backend/internal/app/delegate_none.go +5 -0
- package/dist/templates/native-go/backend/internal/app/identity.go +20 -0
- package/dist/templates/native-go/backend/internal/app/identity_test.go +15 -0
- package/dist/templates/native-go/backend/internal/app/routes.go +12 -36
- package/dist/templates/native-go/backend/internal/app/routes_test.go +16 -40
- package/dist/templates/native-go/backend/internal/app/session_files.go +4 -10
- package/dist/templates/native-go/backend/internal/app/session_files_test.go +8 -20
- package/dist/templates/native-go/backend/internal/app/shared_folder_test.go +4 -4
- package/dist/templates/native-go/backend/internal/background/lock_test.go +131 -0
- package/dist/templates/native-go/backend/internal/background/owner_test.go +12 -20
- package/dist/templates/native-go/backend/internal/background/runner_test.go +1 -1
- package/dist/templates/native-go/backend/internal/background/schedule.go +53 -17
- package/dist/templates/native-go/backend/internal/background/schedule_test.go +42 -9
- package/dist/templates/native-go/backend/internal/background/store.go +115 -99
- package/dist/templates/native-go/backend/internal/background/store_test.go +10 -52
- package/dist/templates/native-go/backend/internal/dsm/admin.go +70 -0
- package/dist/templates/native-go/backend/internal/dsm/admin_linux.go +80 -0
- package/dist/templates/native-go/backend/internal/dsm/admin_linux_test.go +49 -0
- package/dist/templates/native-go/backend/internal/dsm/admin_other.go +12 -0
- package/dist/templates/native-go/backend/internal/dsm/admin_test.go +67 -0
- package/dist/templates/native-go/backend/internal/dsm/auth.go +24 -48
- package/dist/templates/native-go/backend/internal/dsm/auth_test.go +43 -23
- package/dist/templates/native-go/backend/internal/dsm/native/admin-aarch64.elf +0 -0
- package/dist/templates/native-go/backend/internal/dsm/native/admin-x86_64.elf +0 -0
- package/dist/templates/native-go/backend/internal/dsm/native/admin_check.c +28 -0
- package/dist/templates/native-go/backend/internal/dsm/native/build.sh +9 -0
- package/dist/templates/native-go/backend/internal/dsm/native/licenses/GLIBC-NOTICES.txt +400 -0
- package/dist/templates/native-go/backend/internal/dsm/native/licenses/LGPL-2.1.txt +501 -0
- package/dist/templates/native-go/backend/internal/dsm/native/licenses/SOURCE.txt +5 -0
- package/dist/templates/native-go/backend/internal/dsm/native/licenses/ZIG-MIT.txt +21 -0
- package/dist/templates/native-go/backend/internal/dsm/native/provenance.json +12 -0
- package/dist/templates/native-go/backend/internal/filestation/client.go +68 -18
- package/dist/templates/native-go/backend/internal/filestation/client_test.go +7 -7
- package/dist/templates/native-go/backend/internal/filestation/doc.go +1 -1
- package/dist/templates/native-go/backend/internal/filestation/http.go +70 -0
- package/dist/templates/native-go/backend/internal/filestation/http_test.go +188 -0
- package/dist/templates/native-go/backend/internal/filestation/operations_test.go +206 -0
- package/dist/templates/native-go/backend/internal/filestation/read_file_test.go +2 -3
- package/dist/templates/native-go/backend/internal/filestation/service.go +117 -117
- package/dist/templates/native-go/backend/internal/filestation/service_test.go +30 -50
- package/dist/templates/native-go/backend/internal/filestation/upload_stream.go +76 -0
- package/dist/templates/native-go/backend/internal/filestation/upload_stream_test.go +77 -0
- package/dist/templates/native-go/backend/internal/filestation/write.go +0 -40
- package/dist/templates/native-go/backend/internal/filestation/write_test.go +6 -5
- package/dist/templates/native-go/backend/internal/identity/README.md +55 -0
- package/dist/templates/native-go/backend/internal/identity/dsm.go +96 -0
- package/dist/templates/native-go/backend/internal/identity/http.go +291 -0
- package/dist/templates/native-go/backend/internal/identity/identity_test.go +483 -0
- package/dist/templates/native-go/backend/internal/identity/service.go +159 -0
- package/dist/templates/native-go/backend/internal/identity/store.go +109 -0
- package/dist/templates/native-go/backend/internal/jsonlimits/limits.go +48 -0
- package/dist/templates/native-go/backend/internal/jsonlimits/limits_test.go +52 -0
- package/dist/templates/native-go/dsm-package.yaml +8 -17
- package/dist/templates/native-go-delegate/DELEGATE.md +142 -0
- package/dist/templates/native-go-delegate/backend/cmd/background-worker/main.go +41 -0
- package/dist/templates/native-go-delegate/backend/internal/app/delegate.go +15 -0
- package/dist/templates/native-go-delegate/backend/internal/app/delegate_on.go +5 -0
- package/dist/templates/native-go-delegate/backend/internal/app/delegate_routes_test.go +17 -0
- package/dist/templates/native-go-delegate/backend/internal/background/delegate_review_test.go +174 -0
- package/dist/templates/native-go-delegate/backend/internal/background/delegated.go +277 -0
- package/dist/templates/native-go-delegate/backend/internal/background/delegated_test.go +34 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/busy_review_test.go +15 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/client.go +143 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/client_test.go +214 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/files.go +132 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/retry.go +106 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/retry_test.go +143 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/service.go +323 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/service_test.go +318 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/wait_cancel_test.go +101 -0
- package/dist/templates/native-go-delegate/backend/internal/delegate/worker.go +225 -0
- package/dist/templates/native-go-delegate/backend/internal/filestation/files.go +73 -0
- package/dist/templates/native-go-delegate/backend/internal/filestation/files_test.go +59 -0
- package/dist/templates/native-go-delegate/frontend/src/CapabilityPanels.vue +10 -0
- package/dist/templates/native-go-delegate/frontend/src/delegate/DelegatePanel.vue +70 -0
- package/dist/templates/native-go-delegate/frontend/src/delegate/copy.ts +9 -0
- package/dist/templates/native-go-delegate/frontend/src/delegate/i18n/waiting.json +11 -0
- package/dist/templates/native-go-delegate/frontend/test/delegate.test.ts +130 -0
- package/dist/templates/native-go-delegate/test-frontend.sh +12 -0
- package/dist/templates/native-go-delegate/test.sh +17 -0
- package/dist/templates/native-go-jobs/BACKGROUND.md +108 -0
- package/dist/templates/native-go-jobs/backend/internal/app/background_routes_test.go +90 -0
- package/dist/templates/native-go-jobs/frontend/src/background/BackgroundPanel.vue +170 -0
- package/dist/templates/native-go-jobs/frontend/src/background/i18n/de.json +75 -0
- package/dist/templates/native-go-jobs/frontend/src/background/i18n/en.json +75 -0
- package/dist/templates/native-go-jobs/frontend/src/background/i18n/es.json +75 -0
- package/dist/templates/native-go-jobs/frontend/src/background/i18n/fr.json +75 -0
- package/dist/templates/native-go-jobs/frontend/src/background/i18n/it.json +75 -0
- package/dist/templates/native-go-jobs/frontend/src/background/i18n/ja.json +75 -0
- package/dist/templates/native-go-jobs/frontend/src/background/i18n/ko.json +75 -0
- package/dist/templates/native-go-jobs/frontend/src/background/i18n/zh-CN.json +75 -0
- package/dist/templates/native-go-jobs/frontend/src/background/i18n/zh-TW.json +75 -0
- package/dist/templates/native-go-jobs/frontend/src/background/picker-provider.ts +12 -0
- package/dist/templates/native-go-jobs/frontend/src/background/request-key.ts +5 -0
- package/dist/templates/native-go-jobs/frontend/test/background.test.ts +208 -0
- package/dist/templates/native-go-root-ops/backend/internal/app/executor.go +112 -0
- package/dist/templates/native-go-root-ops/backend/internal/app/executor_test.go +53 -0
- package/dist/templates/native-go-root-ops/root/whoami.sh +3 -0
- package/dist/templates/native-go-vue/README.md +36 -248
- package/dist/templates/native-go-vue/frontend/DESIGN.md +20 -49
- package/dist/templates/native-go-vue/frontend/package-lock.json +278 -159
- package/dist/templates/native-go-vue/frontend/package.json +2 -2
- package/dist/templates/native-go-vue/frontend/src/App.vue +55 -151
- package/dist/templates/native-go-vue/frontend/src/CapabilityPanels.vue +6 -0
- package/dist/templates/native-go-vue/frontend/src/context.ts +2 -14
- package/dist/templates/native-go-vue/frontend/src/delegate/ExecutorSettings.vue +25 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/copy.ts +4 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/executor-setup.ts +18 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/en.json +36 -0
- package/dist/templates/native-go-vue/frontend/src/delegate/i18n/zh-TW.json +36 -0
- package/dist/templates/native-go-vue/frontend/src/files/FileBrowser.vue +131 -0
- package/dist/templates/native-go-vue/frontend/src/files/FilesPage.vue +35 -0
- package/dist/templates/native-go-vue/frontend/src/files/files.test.ts +93 -0
- package/dist/templates/native-go-vue/frontend/src/files/provider.test.ts +48 -0
- package/dist/templates/native-go-vue/frontend/src/files/transfers.test.ts +27 -0
- package/dist/templates/native-go-vue/frontend/src/files/transfers.ts +25 -0
- package/dist/templates/native-go-vue/frontend/src/identity/DESIGN.md +46 -0
- package/dist/templates/native-go-vue/frontend/src/identity/LoginPage.vue +76 -0
- package/dist/templates/native-go-vue/frontend/src/identity/login.test.ts +32 -0
- package/dist/templates/native-go-vue/frontend/src/identity/session.test.ts +29 -0
- package/dist/templates/native-go-vue/frontend/src/identity/session.ts +73 -0
- package/dist/templates/native-go-vue/frontend/src/main.ts +7 -4
- package/dist/templates/native-go-vue/frontend/src/nas/NasPicker.vue +23 -0
- package/dist/templates/native-go-vue/frontend/src/nas/contract.ts +12 -0
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/files/de.json +41 -0
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/files/en.json +41 -0
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/files/es.json +41 -0
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/files/fr.json +41 -0
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/files/it.json +41 -0
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/files/ja.json +41 -0
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/files/ko.json +41 -0
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/files/zh-CN.json +41 -0
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/files/zh-TW.json +41 -0
- package/dist/templates/native-go-vue/frontend/src/nas/i18n.ts +2 -38
- package/dist/templates/native-go-vue/frontend/src/nas/locale.ts +24 -0
- package/dist/templates/native-go-vue/frontend/src/nas/provider.ts +46 -55
- package/dist/templates/native-go-vue/frontend/src/nas/use-request.ts +13 -22
- package/dist/templates/native-go-vue/frontend/src/shell/AppShell.vue +3 -3
- package/dist/templates/native-go-vue/frontend/src/shell/i18n/de.json +1 -7
- package/dist/templates/native-go-vue/frontend/src/shell/i18n/en.json +1 -7
- package/dist/templates/native-go-vue/frontend/src/shell/i18n/es.json +1 -7
- package/dist/templates/native-go-vue/frontend/src/shell/i18n/fr.json +1 -7
- package/dist/templates/native-go-vue/frontend/src/shell/i18n/it.json +1 -7
- package/dist/templates/native-go-vue/frontend/src/shell/i18n/ja.json +1 -7
- package/dist/templates/native-go-vue/frontend/src/shell/i18n/ko.json +1 -7
- package/dist/templates/native-go-vue/frontend/src/shell/i18n/zh-CN.json +1 -7
- package/dist/templates/native-go-vue/frontend/src/shell/i18n/zh-TW.json +1 -7
- package/dist/templates/native-go-vue/frontend/src/shell/pages.ts +3 -22
- package/dist/templates/native-go-vue/frontend/test/apps.test.ts +33 -201
- package/dist/templates/native-go-vue/frontend/test/shell-ui.test.ts +15 -109
- package/dist/templates/native-go-vue/frontend/test/shell.test.ts +4 -19
- package/dist/templates/native-go-vue/frontend/vite.config.ts +2 -2
- package/dist/types.d.ts +1 -1
- package/dist/validate.js +27 -36
- package/package.json +2 -5
- package/skills/SKILL.md +21 -3
- package/skills/reference/create.md +15 -6
- package/skills/reference/deploy.md +5 -3
- package/skills/reference/diagnose.md +1 -1
- package/skills/reference/files.md +8 -6
- package/skills/reference/identity.md +9 -3
- package/skills/reference/ui-json.md +78 -0
- package/skills/reference/ui-vue.md +71 -0
- package/skills/reference/wrap.md +3 -4
- package/templates/_executor/README.md +204 -0
- package/templates/_executor/apppriv_review_test.go +28 -0
- package/templates/_executor/auth_presence_review_test.go +38 -0
- package/templates/_executor/cmd/lifecycle/main.go +42 -0
- package/templates/_executor/cookie_review_test.go +27 -0
- package/templates/_executor/digest_review_test.go +120 -0
- package/templates/_executor/directories.go +40 -0
- package/templates/_executor/dsm.go +319 -0
- package/templates/_executor/dsm_test.go +196 -0
- package/templates/_executor/executor.go +524 -0
- package/templates/_executor/executor_test.go +284 -0
- package/templates/_executor/go.mod +3 -0
- package/templates/_executor/identity.go +48 -0
- package/templates/_executor/internal/lifecycle/lifecycle.go +90 -0
- package/templates/_executor/internal/lifecycle/lifecycle_test.go +174 -0
- package/templates/_executor/internal/taskscript/boot.sh +31 -0
- package/templates/_executor/internal/taskscript/cmd/main.go +19 -0
- package/templates/_executor/internal/taskscript/control.sh +26 -0
- package/templates/_executor/internal/taskscript/tasks.go +42 -0
- package/templates/_executor/json_review_test.go +40 -0
- package/templates/_executor/lifecycle_test.go +86 -0
- package/templates/_executor/main.go +518 -0
- package/templates/_executor/managed.go +117 -0
- package/templates/_executor/managed_test.go +137 -0
- package/templates/_executor/path_test.go +17 -0
- package/templates/_executor/platform_linux.go +336 -0
- package/templates/_executor/platform_linux_test.go +247 -0
- package/templates/_executor/platform_other.go +42 -0
- package/templates/_executor/process.go +139 -0
- package/templates/_executor/socket_linux_test.go +46 -0
- package/templates/_executor/store.go +90 -0
- package/templates/_executor/task_race_review_test.go +47 -0
- package/templates/_executor/tasks.go +283 -0
- package/templates/_executor/tasks_review_test.go +43 -0
- package/templates/_executor/tasks_test.go +166 -0
- package/templates/_executor/testdata/evidence/cleanup.json +24 -0
- package/templates/_executor/testdata/evidence/final-smoke.jsonl +9 -0
- package/templates/_executor/testdata/evidence/kernel-acl.json +6 -0
- package/templates/_executor/testdata/evidence/linux-tests.log +123 -0
- package/templates/_executor/testdata/evidence/live.jsonl +23 -0
- package/templates/_executor/testdata/evidence/storage.json +90 -0
- package/templates/_executor/testdata/evidence/validation.json +55 -0
- package/templates/_executor/testdata/live_probe.py +98 -0
- package/templates/_executor/upgrade_watch_test.go +236 -0
- package/templates/_executor/watch.go +156 -0
- package/templates/_executor/watch_test.go +270 -0
- package/templates/_executor/write_review_linux_test.go +95 -0
- package/templates/_shared/AGENTS.md +17 -0
- package/templates/_shared/CLAUDE.md +1 -0
- package/templates/binary/LICENSES/GO-LICENSE +27 -0
- package/templates/binary/LICENSES/GO-PATENTS +22 -0
- package/templates/binary/dsm-package.yaml +19 -0
- package/templates/binary/example/main.go +16 -0
- package/templates/binary/gitignore +2 -0
- package/templates/binary/ui/app.css +4 -0
- package/templates/binary/ui/app.js +17 -0
- package/templates/native-go/README.md +128 -139
- package/templates/native-go/backend/THIRD_PARTY_NOTICES.txt +1 -1
- package/templates/native-go/backend/cmd/app/main.go +33 -26
- package/templates/native-go/backend/internal/api/cgi_framing_test.go +32 -0
- package/templates/native-go/backend/internal/api/cookie_review_test.go +28 -0
- package/templates/native-go/backend/internal/api/deadline_test.go +114 -0
- package/templates/native-go/backend/internal/api/dsm-session.go +54 -0
- package/templates/native-go/backend/internal/api/dsm-session_test.go +51 -0
- package/templates/native-go/backend/internal/api/errors.go +14 -0
- package/templates/native-go/backend/internal/api/permissions.go +161 -0
- package/templates/native-go/backend/internal/api/permissions.json +5 -0
- package/templates/native-go/backend/internal/api/permissions_test.go +113 -0
- package/templates/native-go/backend/internal/api/policy_fixture_test.go +8 -0
- package/templates/native-go/backend/internal/api/registry.go +48 -32
- package/templates/native-go/backend/internal/api/registry_test.go +16 -1
- package/templates/native-go/backend/internal/api/resource_limits_test.go +87 -0
- package/templates/native-go/backend/internal/api/sdk-permissions.json +46 -0
- package/templates/native-go/backend/internal/api/sdk_policy_test.go +31 -0
- package/templates/native-go/backend/internal/api/server.go +135 -8
- package/templates/native-go/backend/internal/api/testdata/permissions-cases.json +172 -0
- package/templates/native-go/backend/internal/app/background.go +23 -44
- package/templates/native-go/backend/internal/app/background_owner.go +0 -21
- package/templates/native-go/backend/internal/app/background_owner_test.go +40 -22
- package/templates/native-go/backend/internal/app/background_schedule.go +0 -5
- package/templates/native-go/backend/internal/app/background_schedule_test.go +1 -1
- package/templates/native-go/backend/internal/app/background_test.go +15 -41
- package/templates/native-go/backend/internal/app/delegate_none.go +5 -0
- package/templates/native-go/backend/internal/app/identity.go +20 -0
- package/templates/native-go/backend/internal/app/identity_test.go +15 -0
- package/templates/native-go/backend/internal/app/routes.go +12 -36
- package/templates/native-go/backend/internal/app/routes_test.go +16 -40
- package/templates/native-go/backend/internal/app/session_files.go +4 -10
- package/templates/native-go/backend/internal/app/session_files_test.go +8 -20
- package/templates/native-go/backend/internal/app/shared_folder_test.go +4 -4
- package/templates/native-go/backend/internal/background/lock_test.go +131 -0
- package/templates/native-go/backend/internal/background/owner_test.go +12 -20
- package/templates/native-go/backend/internal/background/runner_test.go +1 -1
- package/templates/native-go/backend/internal/background/schedule.go +53 -17
- package/templates/native-go/backend/internal/background/schedule_test.go +42 -9
- package/templates/native-go/backend/internal/background/store.go +115 -99
- package/templates/native-go/backend/internal/background/store_test.go +10 -52
- package/templates/native-go/backend/internal/dsm/admin.go +70 -0
- package/templates/native-go/backend/internal/dsm/admin_linux.go +80 -0
- package/templates/native-go/backend/internal/dsm/admin_linux_test.go +49 -0
- package/templates/native-go/backend/internal/dsm/admin_other.go +12 -0
- package/templates/native-go/backend/internal/dsm/admin_test.go +67 -0
- package/templates/native-go/backend/internal/dsm/auth.go +24 -48
- package/templates/native-go/backend/internal/dsm/auth_test.go +43 -23
- package/templates/native-go/backend/internal/dsm/native/admin-aarch64.elf +0 -0
- package/templates/native-go/backend/internal/dsm/native/admin-x86_64.elf +0 -0
- package/templates/native-go/backend/internal/dsm/native/admin_check.c +28 -0
- package/templates/native-go/backend/internal/dsm/native/build.sh +9 -0
- package/templates/native-go/backend/internal/dsm/native/licenses/GLIBC-NOTICES.txt +400 -0
- package/templates/native-go/backend/internal/dsm/native/licenses/LGPL-2.1.txt +501 -0
- package/templates/native-go/backend/internal/dsm/native/licenses/SOURCE.txt +5 -0
- package/templates/native-go/backend/internal/dsm/native/licenses/ZIG-MIT.txt +21 -0
- package/templates/native-go/backend/internal/dsm/native/provenance.json +12 -0
- package/templates/native-go/backend/internal/filestation/client.go +68 -18
- package/templates/native-go/backend/internal/filestation/client_test.go +7 -7
- package/templates/native-go/backend/internal/filestation/doc.go +1 -1
- package/templates/native-go/backend/internal/filestation/http.go +70 -0
- package/templates/native-go/backend/internal/filestation/http_test.go +188 -0
- package/templates/native-go/backend/internal/filestation/operations_test.go +206 -0
- package/templates/native-go/backend/internal/filestation/read_file_test.go +2 -3
- package/templates/native-go/backend/internal/filestation/service.go +117 -117
- package/templates/native-go/backend/internal/filestation/service_test.go +30 -50
- package/templates/native-go/backend/internal/filestation/upload_stream.go +76 -0
- package/templates/native-go/backend/internal/filestation/upload_stream_test.go +77 -0
- package/templates/native-go/backend/internal/filestation/write.go +0 -40
- package/templates/native-go/backend/internal/filestation/write_test.go +6 -5
- package/templates/native-go/backend/internal/identity/README.md +55 -0
- package/templates/native-go/backend/internal/identity/dsm.go +96 -0
- package/templates/native-go/backend/internal/identity/http.go +291 -0
- package/templates/native-go/backend/internal/identity/identity_test.go +483 -0
- package/templates/native-go/backend/internal/identity/service.go +159 -0
- package/templates/native-go/backend/internal/identity/store.go +109 -0
- package/templates/native-go/backend/internal/jsonlimits/limits.go +48 -0
- package/templates/native-go/backend/internal/jsonlimits/limits_test.go +52 -0
- package/templates/native-go/dsm-package.yaml +8 -17
- package/templates/native-go-delegate/DELEGATE.md +142 -0
- package/templates/native-go-delegate/backend/cmd/background-worker/main.go +41 -0
- package/templates/native-go-delegate/backend/internal/app/delegate.go +15 -0
- package/templates/native-go-delegate/backend/internal/app/delegate_on.go +5 -0
- package/templates/native-go-delegate/backend/internal/app/delegate_routes_test.go +17 -0
- package/templates/native-go-delegate/backend/internal/background/delegate_review_test.go +174 -0
- package/templates/native-go-delegate/backend/internal/background/delegated.go +277 -0
- package/templates/native-go-delegate/backend/internal/background/delegated_test.go +34 -0
- package/templates/native-go-delegate/backend/internal/delegate/busy_review_test.go +15 -0
- package/templates/native-go-delegate/backend/internal/delegate/client.go +143 -0
- package/templates/native-go-delegate/backend/internal/delegate/client_test.go +214 -0
- package/templates/native-go-delegate/backend/internal/delegate/files.go +132 -0
- package/templates/native-go-delegate/backend/internal/delegate/retry.go +106 -0
- package/templates/native-go-delegate/backend/internal/delegate/retry_test.go +143 -0
- package/templates/native-go-delegate/backend/internal/delegate/service.go +323 -0
- package/templates/native-go-delegate/backend/internal/delegate/service_test.go +318 -0
- package/templates/native-go-delegate/backend/internal/delegate/wait_cancel_test.go +101 -0
- package/templates/native-go-delegate/backend/internal/delegate/worker.go +225 -0
- package/templates/native-go-delegate/backend/internal/filestation/files.go +73 -0
- package/templates/native-go-delegate/backend/internal/filestation/files_test.go +59 -0
- package/templates/native-go-delegate/frontend/src/CapabilityPanels.vue +10 -0
- package/templates/native-go-delegate/frontend/src/delegate/DelegatePanel.vue +70 -0
- package/templates/native-go-delegate/frontend/src/delegate/copy.ts +9 -0
- package/templates/native-go-delegate/frontend/src/delegate/i18n/waiting.json +11 -0
- package/templates/native-go-delegate/frontend/test/delegate.test.ts +130 -0
- package/templates/native-go-delegate/test-frontend.sh +12 -0
- package/templates/native-go-delegate/test.sh +17 -0
- package/templates/native-go-jobs/BACKGROUND.md +108 -0
- package/templates/native-go-jobs/backend/internal/app/background_routes_test.go +90 -0
- package/templates/native-go-jobs/frontend/src/background/BackgroundPanel.vue +170 -0
- package/templates/native-go-jobs/frontend/src/background/i18n/de.json +75 -0
- package/templates/native-go-jobs/frontend/src/background/i18n/en.json +75 -0
- package/templates/native-go-jobs/frontend/src/background/i18n/es.json +75 -0
- package/templates/native-go-jobs/frontend/src/background/i18n/fr.json +75 -0
- package/templates/native-go-jobs/frontend/src/background/i18n/it.json +75 -0
- package/templates/native-go-jobs/frontend/src/background/i18n/ja.json +75 -0
- package/templates/native-go-jobs/frontend/src/background/i18n/ko.json +75 -0
- package/templates/native-go-jobs/frontend/src/background/i18n/zh-CN.json +75 -0
- package/templates/native-go-jobs/frontend/src/background/i18n/zh-TW.json +75 -0
- package/templates/native-go-jobs/frontend/src/background/picker-provider.ts +12 -0
- package/templates/native-go-jobs/frontend/src/background/request-key.ts +5 -0
- package/templates/native-go-jobs/frontend/test/background.test.ts +208 -0
- package/templates/native-go-root-ops/backend/internal/app/executor.go +112 -0
- package/templates/native-go-root-ops/backend/internal/app/executor_test.go +53 -0
- package/templates/native-go-root-ops/root/whoami.sh +3 -0
- package/templates/native-go-vue/README.md +36 -248
- package/templates/native-go-vue/frontend/DESIGN.md +20 -49
- package/templates/native-go-vue/frontend/package-lock.json +278 -159
- package/templates/native-go-vue/frontend/package.json +2 -2
- package/templates/native-go-vue/frontend/src/App.vue +55 -151
- package/templates/native-go-vue/frontend/src/CapabilityPanels.vue +6 -0
- package/templates/native-go-vue/frontend/src/context.ts +2 -14
- package/templates/native-go-vue/frontend/src/delegate/ExecutorSettings.vue +25 -0
- package/templates/native-go-vue/frontend/src/delegate/copy.ts +4 -0
- package/templates/native-go-vue/frontend/src/delegate/executor-setup.ts +18 -0
- package/templates/native-go-vue/frontend/src/delegate/i18n/en.json +36 -0
- package/templates/native-go-vue/frontend/src/delegate/i18n/zh-TW.json +36 -0
- package/templates/native-go-vue/frontend/src/files/FileBrowser.vue +131 -0
- package/templates/native-go-vue/frontend/src/files/FilesPage.vue +35 -0
- package/templates/native-go-vue/frontend/src/files/files.test.ts +93 -0
- package/templates/native-go-vue/frontend/src/files/provider.test.ts +48 -0
- package/templates/native-go-vue/frontend/src/files/transfers.test.ts +27 -0
- package/templates/native-go-vue/frontend/src/files/transfers.ts +25 -0
- package/templates/native-go-vue/frontend/src/identity/DESIGN.md +46 -0
- package/templates/native-go-vue/frontend/src/identity/LoginPage.vue +76 -0
- package/templates/native-go-vue/frontend/src/identity/login.test.ts +32 -0
- package/templates/native-go-vue/frontend/src/identity/session.test.ts +29 -0
- package/templates/native-go-vue/frontend/src/identity/session.ts +73 -0
- package/templates/native-go-vue/frontend/src/main.ts +7 -4
- package/templates/native-go-vue/frontend/src/nas/NasPicker.vue +23 -0
- package/templates/native-go-vue/frontend/src/nas/contract.ts +12 -0
- package/templates/native-go-vue/frontend/src/nas/i18n/files/de.json +41 -0
- package/templates/native-go-vue/frontend/src/nas/i18n/files/en.json +41 -0
- package/templates/native-go-vue/frontend/src/nas/i18n/files/es.json +41 -0
- package/templates/native-go-vue/frontend/src/nas/i18n/files/fr.json +41 -0
- package/templates/native-go-vue/frontend/src/nas/i18n/files/it.json +41 -0
- package/templates/native-go-vue/frontend/src/nas/i18n/files/ja.json +41 -0
- package/templates/native-go-vue/frontend/src/nas/i18n/files/ko.json +41 -0
- package/templates/native-go-vue/frontend/src/nas/i18n/files/zh-CN.json +41 -0
- package/templates/native-go-vue/frontend/src/nas/i18n/files/zh-TW.json +41 -0
- package/templates/native-go-vue/frontend/src/nas/i18n.ts +2 -38
- package/templates/native-go-vue/frontend/src/nas/locale.ts +24 -0
- package/templates/native-go-vue/frontend/src/nas/provider.ts +46 -55
- package/templates/native-go-vue/frontend/src/nas/use-request.ts +13 -22
- package/templates/native-go-vue/frontend/src/shell/AppShell.vue +3 -3
- package/templates/native-go-vue/frontend/src/shell/i18n/de.json +1 -7
- package/templates/native-go-vue/frontend/src/shell/i18n/en.json +1 -7
- package/templates/native-go-vue/frontend/src/shell/i18n/es.json +1 -7
- package/templates/native-go-vue/frontend/src/shell/i18n/fr.json +1 -7
- package/templates/native-go-vue/frontend/src/shell/i18n/it.json +1 -7
- package/templates/native-go-vue/frontend/src/shell/i18n/ja.json +1 -7
- package/templates/native-go-vue/frontend/src/shell/i18n/ko.json +1 -7
- package/templates/native-go-vue/frontend/src/shell/i18n/zh-CN.json +1 -7
- package/templates/native-go-vue/frontend/src/shell/i18n/zh-TW.json +1 -7
- package/templates/native-go-vue/frontend/src/shell/pages.ts +3 -22
- package/templates/native-go-vue/frontend/test/apps.test.ts +33 -201
- package/templates/native-go-vue/frontend/test/shell-ui.test.ts +15 -109
- package/templates/native-go-vue/frontend/test/shell.test.ts +4 -19
- package/templates/native-go-vue/frontend/vite.config.ts +2 -2
- package/dist/authorization-sdk.d.ts +0 -5
- package/dist/authorization-sdk.js +0 -5
- package/dist/build-spk/native-payload.d.ts +0 -37
- package/dist/build-spk/native-payload.js +0 -679
- package/dist/native/load.d.ts +0 -8
- package/dist/native/load.js +0 -11
- package/dist/native/types.d.ts +0 -28
- package/dist/native/types.js +0 -3
- package/dist/native/validate.d.ts +0 -6
- package/dist/native/validate.js +0 -143
- package/dist/standalone/authorization-window.d.ts +0 -2
- package/dist/standalone/authorization-window.js +0 -28
- package/dist/standalone/authorization.d.ts +0 -48
- package/dist/standalone/authorization.js +0 -116
- package/dist/standalone/helper-inventory.d.ts +0 -31
- package/dist/standalone/helper-inventory.js +0 -11
- package/dist/standalone/helper.d.ts +0 -22
- package/dist/standalone/helper.js +0 -123
- package/dist/standalone/inspect-helper.d.ts +0 -6
- package/dist/standalone/inspect-helper.js +0 -103
- package/dist/standalone/job-diagnostics.d.ts +0 -1
- package/dist/standalone/job-diagnostics.js +0 -49
- package/dist/standalone/lifecycle-helper.d.ts +0 -2
- package/dist/standalone/lifecycle-helper.js +0 -12
- package/dist/standalone/native-layout.d.ts +0 -74
- package/dist/standalone/native-layout.js +0 -318
- package/dist/standalone/root-messages.d.ts +0 -7
- package/dist/standalone/root-messages.js +0 -259
- package/dist/standalone/worker-contract-json.d.ts +0 -8
- package/dist/standalone/worker-contract-json.js +0 -141
- package/dist/standalone/worker-contract.d.ts +0 -189
- package/dist/standalone/worker-contract.js +0 -175
- package/dist/standalone/worker-registry.d.ts +0 -40
- package/dist/standalone/worker-registry.js +0 -167
- package/dist/templates/_authorization/main.go +0 -104
- package/dist/templates/_authorization/main_test.go +0 -35
- package/dist/templates/_shared/notice-overrides/index.json +0 -14
- package/dist/templates/_shared/notice-overrides/utils-0.4.2-LICENSE +0 -21
- package/dist/templates/_shared/notice-overrides/utils-0.5.0-LICENSE +0 -21
- package/dist/templates/binary/native.yaml +0 -16
- package/dist/templates/binary/synology-app.yaml +0 -7
- package/dist/templates/compose-import/compose.yaml +0 -10
- package/dist/templates/compose-import/synology-app.yaml +0 -15
- package/dist/templates/native-go/backend/cmd/app/sdk_main.go +0 -62
- package/dist/templates/native-go/backend/cmd/dsm-readonly-probe/main_linux.go +0 -46
- package/dist/templates/native-go/backend/cmd/helper/main.go +0 -64
- package/dist/templates/native-go/backend/cmd/helper/sdk_registry.go +0 -19
- package/dist/templates/native-go/backend/internal/api/binary.go +0 -154
- package/dist/templates/native-go/backend/internal/api/binary_test.go +0 -165
- package/dist/templates/native-go/backend/internal/app/authorization_none.go +0 -5
- package/dist/templates/native-go/backend/internal/app/integration_state.go +0 -16
- package/dist/templates/native-go/backend/internal/app/nas_cgi_artifact_test.go +0 -129
- package/dist/templates/native-go/backend/internal/app/nas_refusal_test.go +0 -46
- package/dist/templates/native-go/backend/internal/app/sdk_jobs.go +0 -70
- package/dist/templates/native-go/backend/internal/app/sdk_jobs_test.go +0 -116
- package/dist/templates/native-go/backend/internal/app/sdk_routes.go +0 -177
- package/dist/templates/native-go/backend/internal/dsmprobe/collector_linux.go +0 -335
- package/dist/templates/native-go/backend/internal/dsmprobe/collector_linux_test.go +0 -41
- package/dist/templates/native-go/backend/internal/dsmprobe/protocol.go +0 -179
- package/dist/templates/native-go/backend/internal/dsmprobe/protocol_test.go +0 -29
- package/dist/templates/native-go/backend/internal/filestation/repository.go +0 -207
- package/dist/templates/native-go/backend/internal/filestation/repository_test.go +0 -104
- package/dist/templates/native-go/backend/internal/filestation/sdk_session.go +0 -241
- package/dist/templates/native-go/backend/internal/filestation/sdk_session_test.go +0 -183
- package/dist/templates/native-go/backend/internal/filestation/session_semantics_test.go +0 -383
- package/dist/templates/native-go/backend/internal/helper/background_proof.go +0 -163
- package/dist/templates/native-go/backend/internal/helper/background_proof_contract.go +0 -46
- package/dist/templates/native-go/backend/internal/helper/background_proof_test.go +0 -161
- package/dist/templates/native-go/backend/internal/helper/cohort.go +0 -393
- package/dist/templates/native-go/backend/internal/helper/cohort_publication.go +0 -18
- package/dist/templates/native-go/backend/internal/helper/cohort_publication_test.go +0 -105
- package/dist/templates/native-go/backend/internal/helper/cohort_test.go +0 -372
- package/dist/templates/native-go/backend/internal/helper/control.go +0 -424
- package/dist/templates/native-go/backend/internal/helper/control_test.go +0 -250
- package/dist/templates/native-go/backend/internal/helper/data_contract.go +0 -245
- package/dist/templates/native-go/backend/internal/helper/data_contract_test.go +0 -51
- package/dist/templates/native-go/backend/internal/helper/data_decode.go +0 -184
- package/dist/templates/native-go/backend/internal/helper/data_decode_pointer_test.go +0 -30
- package/dist/templates/native-go/backend/internal/helper/data_protocol.go +0 -419
- package/dist/templates/native-go/backend/internal/helper/data_protocol_test.go +0 -449
- package/dist/templates/native-go/backend/internal/helper/dsm_acl_linux.go +0 -139
- package/dist/templates/native-go/backend/internal/helper/dsm_acl_linux_test.go +0 -121
- package/dist/templates/native-go/backend/internal/helper/dsm_acl_syscall_linux.go +0 -95
- package/dist/templates/native-go/backend/internal/helper/dsm_acl_syscall_linux_test.go +0 -56
- package/dist/templates/native-go/backend/internal/helper/dsm_bridge_linux.go +0 -144
- package/dist/templates/native-go/backend/internal/helper/dsm_bridge_linux_test.go +0 -89
- package/dist/templates/native-go/backend/internal/helper/dsm_home_linux.go +0 -107
- package/dist/templates/native-go/backend/internal/helper/dsm_home_linux_test.go +0 -82
- package/dist/templates/native-go/backend/internal/helper/dsm_probe_transport_linux.go +0 -151
- package/dist/templates/native-go/backend/internal/helper/dsm_probe_transport_linux_test.go +0 -66
- package/dist/templates/native-go/backend/internal/helper/grant_authority.go +0 -519
- package/dist/templates/native-go/backend/internal/helper/grant_authority_contract.go +0 -88
- package/dist/templates/native-go/backend/internal/helper/grant_authority_test.go +0 -510
- package/dist/templates/native-go/backend/internal/helper/grant_cohort.go +0 -389
- package/dist/templates/native-go/backend/internal/helper/grant_cohort_test.go +0 -239
- package/dist/templates/native-go/backend/internal/helper/grant_delivery.go +0 -49
- package/dist/templates/native-go/backend/internal/helper/grant_delivery_methods.go +0 -273
- package/dist/templates/native-go/backend/internal/helper/grant_delivery_test.go +0 -322
- package/dist/templates/native-go/backend/internal/helper/grant_operation_contract.go +0 -47
- package/dist/templates/native-go/backend/internal/helper/grant_readonly_test.go +0 -180
- package/dist/templates/native-go/backend/internal/helper/grant_repository_linux.go +0 -416
- package/dist/templates/native-go/backend/internal/helper/grant_repository_linux_test.go +0 -469
- package/dist/templates/native-go/backend/internal/helper/grant_rpc.go +0 -147
- package/dist/templates/native-go/backend/internal/helper/grant_rpc_test.go +0 -51
- package/dist/templates/native-go/backend/internal/helper/grant_snapshot.go +0 -78
- package/dist/templates/native-go/backend/internal/helper/grant_supervisor_linux.go +0 -134
- package/dist/templates/native-go/backend/internal/helper/grant_supervisor_linux_test.go +0 -254
- package/dist/templates/native-go/backend/internal/helper/jobcontract/bindings.go +0 -48
- package/dist/templates/native-go/backend/internal/helper/jobcontract/contract_test.go +0 -436
- package/dist/templates/native-go/backend/internal/helper/jobcontract/decode.go +0 -185
- package/dist/templates/native-go/backend/internal/helper/jobcontract/digest.go +0 -55
- package/dist/templates/native-go/backend/internal/helper/jobcontract/registry.go +0 -85
- package/dist/templates/native-go/backend/internal/helper/jobcontract/registry_test.go +0 -73
- package/dist/templates/native-go/backend/internal/helper/jobcontract/result.go +0 -53
- package/dist/templates/native-go/backend/internal/helper/jobcontract/stub.go +0 -8
- package/dist/templates/native-go/backend/internal/helper/jobcontract/testdata/input-digests.json +0 -127
- package/dist/templates/native-go/backend/internal/helper/jobcontract/types.go +0 -234
- package/dist/templates/native-go/backend/internal/helper/jobcontract/types_test.go +0 -29
- package/dist/templates/native-go/backend/internal/helper/jobcontract/validate.go +0 -462
- package/dist/templates/native-go/backend/internal/helper/lease.go +0 -112
- package/dist/templates/native-go/backend/internal/helper/lease_linux.go +0 -44
- package/dist/templates/native-go/backend/internal/helper/lease_other.go +0 -8
- package/dist/templates/native-go/backend/internal/helper/legacy_authority_schema_linux_test.go +0 -34
- package/dist/templates/native-go/backend/internal/helper/legacy_authority_schema_test.go +0 -6
- package/dist/templates/native-go/backend/internal/helper/lifecycle.go +0 -234
- package/dist/templates/native-go/backend/internal/helper/lifecycle_test.go +0 -473
- package/dist/templates/native-go/backend/internal/helper/managed_pilot.go +0 -284
- package/dist/templates/native-go/backend/internal/helper/managed_pilot_repository_linux.go +0 -74
- package/dist/templates/native-go/backend/internal/helper/managed_pilot_repository_linux_test.go +0 -40
- package/dist/templates/native-go/backend/internal/helper/managed_pilot_test.go +0 -210
- package/dist/templates/native-go/backend/internal/helper/management.go +0 -86
- package/dist/templates/native-go/backend/internal/helper/nas_shipped_refusal_linux_test.go +0 -97
- package/dist/templates/native-go/backend/internal/helper/native_discovery.go +0 -79
- package/dist/templates/native-go/backend/internal/helper/native_identity.go +0 -89
- package/dist/templates/native-go/backend/internal/helper/native_provider.go +0 -159
- package/dist/templates/native-go/backend/internal/helper/native_provider_test.go +0 -421
- package/dist/templates/native-go/backend/internal/helper/observation.go +0 -244
- package/dist/templates/native-go/backend/internal/helper/observation_health_test.go +0 -127
- package/dist/templates/native-go/backend/internal/helper/observation_reload_budget_test.go +0 -117
- package/dist/templates/native-go/backend/internal/helper/observation_test.go +0 -196
- package/dist/templates/native-go/backend/internal/helper/observer_diagnostic.go +0 -155
- package/dist/templates/native-go/backend/internal/helper/observer_diagnostic_linux.go +0 -76
- package/dist/templates/native-go/backend/internal/helper/observer_diagnostic_linux_test.go +0 -130
- package/dist/templates/native-go/backend/internal/helper/observer_diagnostic_test.go +0 -98
- package/dist/templates/native-go/backend/internal/helper/observer_diagnostic_writer.go +0 -40
- package/dist/templates/native-go/backend/internal/helper/operation_bootstrap_linux.go +0 -193
- package/dist/templates/native-go/backend/internal/helper/operation_credentials_linux.go +0 -56
- package/dist/templates/native-go/backend/internal/helper/operation_linux.go +0 -480
- package/dist/templates/native-go/backend/internal/helper/operation_linux_test.go +0 -528
- package/dist/templates/native-go/backend/internal/helper/peer_linux.go +0 -44
- package/dist/templates/native-go/backend/internal/helper/peer_other.go +0 -7
- package/dist/templates/native-go/backend/internal/helper/process_linux.go +0 -180
- package/dist/templates/native-go/backend/internal/helper/process_other.go +0 -5
- package/dist/templates/native-go/backend/internal/helper/publication_test.go +0 -178
- package/dist/templates/native-go/backend/internal/helper/purge.go +0 -115
- package/dist/templates/native-go/backend/internal/helper/purge_test.go +0 -59
- package/dist/templates/native-go/backend/internal/helper/query_deadline_linux_test.go +0 -115
- package/dist/templates/native-go/backend/internal/helper/query_pending_diagnostic_test.go +0 -254
- package/dist/templates/native-go/backend/internal/helper/read_stream_cohort_linux_test.go +0 -156
- package/dist/templates/native-go/backend/internal/helper/read_transfer.go +0 -40
- package/dist/templates/native-go/backend/internal/helper/read_transfer_linux.go +0 -109
- package/dist/templates/native-go/backend/internal/helper/read_transfer_linux_test.go +0 -118
- package/dist/templates/native-go/backend/internal/helper/read_transfer_test.go +0 -177
- package/dist/templates/native-go/backend/internal/helper/readonly.go +0 -105
- package/dist/templates/native-go/backend/internal/helper/readonly_admission.go +0 -85
- package/dist/templates/native-go/backend/internal/helper/readonly_cohort_linux_test.go +0 -253
- package/dist/templates/native-go/backend/internal/helper/readonly_linux_test.go +0 -378
- package/dist/templates/native-go/backend/internal/helper/readonly_mount_linux.go +0 -65
- package/dist/templates/native-go/backend/internal/helper/readonly_mount_proxy_linux.go +0 -113
- package/dist/templates/native-go/backend/internal/helper/readonly_operations_linux.go +0 -168
- package/dist/templates/native-go/backend/internal/helper/readonly_resolver_linux.go +0 -241
- package/dist/templates/native-go/backend/internal/helper/readonly_test.go +0 -40
- package/dist/templates/native-go/backend/internal/helper/relaxed_identity.go +0 -252
- package/dist/templates/native-go/backend/internal/helper/relaxed_identity_contract.go +0 -105
- package/dist/templates/native-go/backend/internal/helper/relaxed_identity_test.go +0 -406
- package/dist/templates/native-go/backend/internal/helper/relaxed_invalidation.go +0 -203
- package/dist/templates/native-go/backend/internal/helper/repair.go +0 -132
- package/dist/templates/native-go/backend/internal/helper/repair_test.go +0 -271
- package/dist/templates/native-go/backend/internal/helper/revoke.go +0 -109
- package/dist/templates/native-go/backend/internal/helper/revoke_test.go +0 -121
- package/dist/templates/native-go/backend/internal/helper/s1r_actor_acl_linux_test.go +0 -303
- package/dist/templates/native-go/backend/internal/helper/s1r_actor_fixture_linux_test.go +0 -184
- package/dist/templates/native-go/backend/internal/helper/s1r_actor_races_linux_test.go +0 -250
- package/dist/templates/native-go/backend/internal/helper/s1r_fixture_contract_linux_test.go +0 -18
- package/dist/templates/native-go/backend/internal/helper/sdk_assembly_linux.go +0 -51
- package/dist/templates/native-go/backend/internal/helper/sdk_attach.go +0 -83
- package/dist/templates/native-go/backend/internal/helper/sdk_attach_contract.go +0 -32
- package/dist/templates/native-go/backend/internal/helper/sdk_attach_test.go +0 -184
- package/dist/templates/native-go/backend/internal/helper/sdk_authority_schema_test.go +0 -6
- package/dist/templates/native-go/backend/internal/helper/sdk_background_authority.go +0 -832
- package/dist/templates/native-go/backend/internal/helper/sdk_background_authority_test.go +0 -714
- package/dist/templates/native-go/backend/internal/helper/sdk_background_invalidation.go +0 -218
- package/dist/templates/native-go/backend/internal/helper/sdk_background_lease.go +0 -218
- package/dist/templates/native-go/backend/internal/helper/sdk_background_snapshot.go +0 -110
- package/dist/templates/native-go/backend/internal/helper/sdk_background_store_linux_test.go +0 -261
- package/dist/templates/native-go/backend/internal/helper/sdk_background_store_test.go +0 -58
- package/dist/templates/native-go/backend/internal/helper/sdk_bindings.go +0 -60
- package/dist/templates/native-go/backend/internal/helper/sdk_data_contract.go +0 -251
- package/dist/templates/native-go/backend/internal/helper/sdk_data_protocol.go +0 -424
- package/dist/templates/native-go/backend/internal/helper/sdk_dispatch_absence_test.go +0 -51
- package/dist/templates/native-go/backend/internal/helper/sdk_display.go +0 -488
- package/dist/templates/native-go/backend/internal/helper/sdk_display_contract.go +0 -121
- package/dist/templates/native-go/backend/internal/helper/sdk_display_test.go +0 -459
- package/dist/templates/native-go/backend/internal/helper/sdk_grant_authority.go +0 -559
- package/dist/templates/native-go/backend/internal/helper/sdk_grant_repository_linux.go +0 -417
- package/dist/templates/native-go/backend/internal/helper/sdk_grant_snapshot.go +0 -94
- package/dist/templates/native-go/backend/internal/helper/sdk_history.go +0 -80
- package/dist/templates/native-go/backend/internal/helper/sdk_history_test.go +0 -76
- package/dist/templates/native-go/backend/internal/helper/sdk_job.go +0 -697
- package/dist/templates/native-go/backend/internal/helper/sdk_job_child_linux.go +0 -309
- package/dist/templates/native-go/backend/internal/helper/sdk_job_contract.go +0 -122
- package/dist/templates/native-go/backend/internal/helper/sdk_job_linux_test.go +0 -159
- package/dist/templates/native-go/backend/internal/helper/sdk_job_process_linux.go +0 -327
- package/dist/templates/native-go/backend/internal/helper/sdk_job_test.go +0 -501
- package/dist/templates/native-go/backend/internal/helper/sdk_job_vm_linux_test.go +0 -343
- package/dist/templates/native-go/backend/internal/helper/sdk_journal.go +0 -77
- package/dist/templates/native-go/backend/internal/helper/sdk_journal_linux.go +0 -244
- package/dist/templates/native-go/backend/internal/helper/sdk_journal_linux_test.go +0 -295
- package/dist/templates/native-go/backend/internal/helper/sdk_journal_test.go +0 -71
- package/dist/templates/native-go/backend/internal/helper/sdk_picker_test.go +0 -50
- package/dist/templates/native-go/backend/internal/helper/sdk_process_linux.go +0 -184
- package/dist/templates/native-go/backend/internal/helper/sdk_public_vm_linux_test.go +0 -129
- package/dist/templates/native-go/backend/internal/helper/sdk_relaxed_invalidation.go +0 -242
- package/dist/templates/native-go/backend/internal/helper/sdk_rpc.go +0 -299
- package/dist/templates/native-go/backend/internal/helper/sdk_rpc_contract.go +0 -70
- package/dist/templates/native-go/backend/internal/helper/sdk_rpc_test.go +0 -135
- package/dist/templates/native-go/backend/internal/helper/sdk_server_linux.go +0 -161
- package/dist/templates/native-go/backend/internal/helper/sdk_session.go +0 -677
- package/dist/templates/native-go/backend/internal/helper/sdk_session_contract.go +0 -72
- package/dist/templates/native-go/backend/internal/helper/sdk_session_fence_test.go +0 -215
- package/dist/templates/native-go/backend/internal/helper/sdk_session_test.go +0 -475
- package/dist/templates/native-go/backend/internal/helper/sdk_supervisor_frame.go +0 -78
- package/dist/templates/native-go/backend/internal/helper/sdk_supervisor_linux.go +0 -414
- package/dist/templates/native-go/backend/internal/helper/sdk_transport.go +0 -79
- package/dist/templates/native-go/backend/internal/helper/sdk_transport_linux.go +0 -82
- package/dist/templates/native-go/backend/internal/helper/sdk_transport_test.go +0 -64
- package/dist/templates/native-go/backend/internal/helper/server_linux.go +0 -136
- package/dist/templates/native-go/backend/internal/helper/stale_management_linux_test.go +0 -126
- package/dist/templates/native-go/backend/internal/helper/stale_management_test.go +0 -122
- package/dist/templates/native-go/backend/internal/helper/startup_diagnostic.go +0 -68
- package/dist/templates/native-go/backend/internal/helper/startup_diagnostic_linux_test.go +0 -126
- package/dist/templates/native-go/backend/internal/helper/startup_diagnostic_test.go +0 -117
- package/dist/templates/native-go/backend/internal/helper/status.go +0 -343
- package/dist/templates/native-go/backend/internal/helper/status_test.go +0 -333
- package/dist/templates/native-go/backend/internal/helper/supervision.go +0 -107
- package/dist/templates/native-go/backend/internal/helper/supervision_test.go +0 -124
- package/dist/templates/native-go/backend/internal/helper/supervisor_frame.go +0 -79
- package/dist/templates/native-go/backend/internal/helper/supervisor_frame_linux_test.go +0 -69
- package/dist/templates/native-go/backend/internal/helper/supervisor_frame_test.go +0 -107
- package/dist/templates/native-go/backend/internal/helper/supervisor_linux.go +0 -367
- package/dist/templates/native-go/backend/internal/helper/supervisor_linux_test.go +0 -913
- package/dist/templates/native-go/backend/internal/helper/supervisor_socket_eof_test.go +0 -74
- package/dist/templates/native-go/backend/internal/helper/supervisor_socket_test.go +0 -45
- package/dist/templates/native-go/backend/internal/helper/testdata/protocol2/create.json +0 -23
- package/dist/templates/native-go/backend/internal/helper/testdata/protocol2/frames.json +0 -67
- package/dist/templates/native-go/backend/internal/helper/testdata/protocol2/grant-store.json +0 -52
- package/dist/templates/native-go/backend/internal/helper/testdata/protocol2/intent.json +0 -20
- package/dist/templates/native-go/backend/internal/helper/testdata/protocol2/list.json +0 -20
- package/dist/templates/native-go/backend/internal/helper/testdata/protocol2/publish.json +0 -20
- package/dist/templates/native-go/backend/internal/helper/testdata/protocol2/read.json +0 -22
- package/dist/templates/native-go/backend/internal/helper/testdata/protocol2/stat.json +0 -22
- package/dist/templates/native-go/backend/internal/helper/testdata/protocol2/write-stream.json +0 -22
- package/dist/templates/native-go/backend/internal/helper/unit_connection.go +0 -75
- package/dist/templates/native-go/backend/internal/helper/unit_connection_linux_test.go +0 -135
- package/dist/templates/native-go/backend/internal/helper/unit_connection_test.go +0 -151
- package/dist/templates/native-go/backend/internal/helper/unit_frame_test.go +0 -32
- package/dist/templates/native-go/backend/internal/helper/unit_linux.go +0 -368
- package/dist/templates/native-go/backend/internal/helper/unit_linux_test.go +0 -46
- package/dist/templates/native-go/backend/internal/helper/unit_mechanisms_linux_test.go +0 -217
- package/dist/templates/native-go/backend/internal/helper/unit_padding_linux_test.go +0 -178
- package/dist/templates/native-go/backend/internal/helper/unit_query_linux.go +0 -115
- package/dist/templates/native-go/backend/internal/helper/unit_reload_linux_test.go +0 -372
- package/dist/templates/native-go/backend/internal/helper/unit_reload_sequence_linux_test.go +0 -232
- package/dist/templates/native-go/backend/internal/helper/write.go +0 -77
- package/dist/templates/native-go/backend/internal/helper/write_admission.go +0 -260
- package/dist/templates/native-go/backend/internal/helper/write_admission_test.go +0 -135
- package/dist/templates/native-go/backend/internal/helper/write_cohort_linux_test.go +0 -218
- package/dist/templates/native-go/backend/internal/helper/write_files_linux.go +0 -205
- package/dist/templates/native-go/backend/internal/helper/write_files_linux_test.go +0 -225
- package/dist/templates/native-go/backend/internal/helper/write_intent_linux.go +0 -116
- package/dist/templates/native-go/backend/internal/helper/write_intent_linux_test.go +0 -74
- package/dist/templates/native-go/backend/internal/helper/write_operation_linux.go +0 -245
- package/dist/templates/native-go/backend/internal/helper/write_test.go +0 -53
- package/dist/templates/native-go-authorization/backend/internal/app/authorization.go +0 -298
- package/dist/templates/native-go-authorization/backend/internal/app/authorization_test.go +0 -96
- package/dist/templates/native-go-authorization/frontend/src/authorization/AuthorizationGate.vue +0 -89
- package/dist/templates/native-go-authorization/frontend/src/authorization/i18n/de.json +0 -36
- package/dist/templates/native-go-authorization/frontend/src/authorization/i18n/en.json +0 -36
- package/dist/templates/native-go-authorization/frontend/src/authorization/i18n/es.json +0 -36
- package/dist/templates/native-go-authorization/frontend/src/authorization/i18n/fr.json +0 -36
- package/dist/templates/native-go-authorization/frontend/src/authorization/i18n/index.ts +0 -15
- package/dist/templates/native-go-authorization/frontend/src/authorization/i18n/it.json +0 -36
- package/dist/templates/native-go-authorization/frontend/src/authorization/i18n/ja.json +0 -36
- package/dist/templates/native-go-authorization/frontend/src/authorization/i18n/ko.json +0 -36
- package/dist/templates/native-go-authorization/frontend/src/authorization/i18n/zh-CN.json +0 -36
- package/dist/templates/native-go-authorization/frontend/src/authorization/i18n/zh-TW.json +0 -36
- package/dist/templates/native-go-authorization/frontend/test/authorization-preview.html +0 -14
- package/dist/templates/native-go-authorization/frontend/test/authorization.test.ts +0 -59
- package/dist/templates/native-go-background/BACKGROUND.md +0 -111
- package/dist/templates/native-go-background/backend/internal/app/background_routes_test.go +0 -32
- package/dist/templates/native-go-background/frontend/src/background/BackgroundPanel.vue +0 -178
- package/dist/templates/native-go-background/frontend/src/background/i18n/de.json +0 -83
- package/dist/templates/native-go-background/frontend/src/background/i18n/en.json +0 -83
- package/dist/templates/native-go-background/frontend/src/background/i18n/es.json +0 -83
- package/dist/templates/native-go-background/frontend/src/background/i18n/fr.json +0 -83
- package/dist/templates/native-go-background/frontend/src/background/i18n/it.json +0 -83
- package/dist/templates/native-go-background/frontend/src/background/i18n/ja.json +0 -83
- package/dist/templates/native-go-background/frontend/src/background/i18n/ko.json +0 -83
- package/dist/templates/native-go-background/frontend/src/background/i18n/zh-CN.json +0 -83
- package/dist/templates/native-go-background/frontend/src/background/i18n/zh-TW.json +0 -83
- package/dist/templates/native-go-background/frontend/src/background/picker-provider.ts +0 -13
- package/dist/templates/native-go-background/frontend/test/background.test.ts +0 -179
- package/dist/templates/native-go-better-auth/backend/internal/app/identity.go +0 -208
- package/dist/templates/native-go-better-auth/backend/internal/app/identity_test.go +0 -113
- package/dist/templates/native-go-better-auth/node/app.mjs +0 -72
- package/dist/templates/native-go-better-auth/node/build.mjs +0 -4
- package/dist/templates/native-go-better-auth/node/package-lock.json +0 -862
- package/dist/templates/native-go-better-auth/node/package.json +0 -1
- package/dist/templates/native-go-better-auth/node/test/auth.test.mjs +0 -31
- package/dist/templates/native-go-integration/backend/internal/app/identity_none.go +0 -6
- package/dist/templates/native-go-integration/backend/internal/app/personal.go +0 -203
- package/dist/templates/native-go-integration/backend/internal/app/personal_test.go +0 -156
- package/dist/templates/native-go-root/backend/internal/app/root.go +0 -107
- package/dist/templates/native-go-root/backend/internal/app/root_test.go +0 -124
- package/dist/templates/native-go-root/root/whoami.sh +0 -6
- package/dist/templates/native-go-vue/frontend/README-JOBS.md +0 -75
- package/dist/templates/native-go-vue/frontend/README-M2.md +0 -64
- package/dist/templates/native-go-vue/frontend/src/M2App.vue +0 -57
- package/dist/templates/native-go-vue/frontend/src/SDKApp.vue +0 -203
- package/dist/templates/native-go-vue/frontend/src/jobs/InteractiveJobForm.vue +0 -70
- package/dist/templates/native-go-vue/frontend/src/jobs/JobsAdminPanel.vue +0 -33
- package/dist/templates/native-go-vue/frontend/src/jobs/JobsPanel.vue +0 -135
- package/dist/templates/native-go-vue/frontend/src/jobs/connected-provider.ts +0 -179
- package/dist/templates/native-go-vue/frontend/src/jobs/i18n/de.json +0 -62
- package/dist/templates/native-go-vue/frontend/src/jobs/i18n/en.json +0 -62
- package/dist/templates/native-go-vue/frontend/src/jobs/i18n/es.json +0 -62
- package/dist/templates/native-go-vue/frontend/src/jobs/i18n/fr.json +0 -62
- package/dist/templates/native-go-vue/frontend/src/jobs/i18n/it.json +0 -62
- package/dist/templates/native-go-vue/frontend/src/jobs/i18n/ja.json +0 -62
- package/dist/templates/native-go-vue/frontend/src/jobs/i18n/ko.json +0 -62
- package/dist/templates/native-go-vue/frontend/src/jobs/i18n/zh-CN.json +0 -62
- package/dist/templates/native-go-vue/frontend/src/jobs/i18n/zh-TW.json +0 -62
- package/dist/templates/native-go-vue/frontend/src/jobs/i18n.ts +0 -15
- package/dist/templates/native-go-vue/frontend/src/jobs/mock-provider.ts +0 -67
- package/dist/templates/native-go-vue/frontend/src/jobs/provider.ts +0 -60
- package/dist/templates/native-go-vue/frontend/src/jobs/validate.ts +0 -44
- package/dist/templates/native-go-vue/frontend/src/m2-main.ts +0 -21
- package/dist/templates/native-go-vue/frontend/src/m2-style.css +0 -7
- package/dist/templates/native-go-vue/frontend/src/nas/M2Files.vue +0 -94
- package/dist/templates/native-go-vue/frontend/src/nas/M2PathPicker.vue +0 -70
- package/dist/templates/native-go-vue/frontend/src/nas/M2Settings.vue +0 -69
- package/dist/templates/native-go-vue/frontend/src/nas/NasGrantSettings.vue +0 -74
- package/dist/templates/native-go-vue/frontend/src/nas/NasPathPicker.vue +0 -106
- package/dist/templates/native-go-vue/frontend/src/nas/NasUnavailable.vue +0 -20
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/de.json +0 -74
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/en.json +0 -74
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/es.json +0 -74
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/fr.json +0 -74
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/it.json +0 -74
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/ja.json +0 -74
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/ko.json +0 -74
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/m2/de.json +0 -56
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/m2/en.json +0 -56
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/m2/es.json +0 -56
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/m2/fr.json +0 -56
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/m2/it.json +0 -56
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/m2/ja.json +0 -56
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/m2/ko.json +0 -56
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/m2/zh-CN.json +0 -56
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/m2/zh-TW.json +0 -56
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/zh-CN.json +0 -74
- package/dist/templates/native-go-vue/frontend/src/nas/i18n/zh-TW.json +0 -74
- package/dist/templates/native-go-vue/frontend/src/nas/m2-contract.ts +0 -33
- package/dist/templates/native-go-vue/frontend/src/nas/m2-i18n.ts +0 -24
- package/dist/templates/native-go-vue/frontend/src/nas/m2-provider.ts +0 -104
- package/dist/templates/native-go-vue/frontend/src/nas/mock-provider.ts +0 -119
- package/dist/templates/native-go-vue/frontend/src/nas/use-m2-request.ts +0 -18
- package/dist/templates/native-go-vue/frontend/src/sdk-main.ts +0 -39
- package/dist/templates/native-go-vue/frontend/test/jobs-connected.test.ts +0 -163
- package/dist/templates/native-go-vue/frontend/test/jobs-preview.html +0 -22
- package/dist/templates/native-go-vue/frontend/test/jobs.test.ts +0 -176
- package/dist/templates/native-go-vue/frontend/test/m2-preview.html +0 -27
- package/dist/templates/native-go-vue/frontend/test/m2-provider.test.ts +0 -87
- package/dist/templates/native-go-vue/frontend/test/m2-ui.test.ts +0 -209
- package/dist/templates/native-go-vue/frontend/test/nas-provider.test.ts +0 -81
- package/dist/templates/native-go-vue/frontend/test/nas-request.test.ts +0 -21
- package/dist/templates/native-go-vue/frontend/test/nas-ui.test.ts +0 -261
- package/dist/templates/native-go-vue/frontend/test/picker-wire.test.ts +0 -110
- package/dist/templates/native-go-vue/frontend/test/shell-preview.html +0 -19
- package/dist/templates/native-go-vue/frontend/test/shell-sdk.test.ts +0 -73
- package/templates/_authorization/main.go +0 -104
- package/templates/_authorization/main_test.go +0 -35
- package/templates/_shared/notice-overrides/index.json +0 -14
- package/templates/_shared/notice-overrides/utils-0.4.2-LICENSE +0 -21
- package/templates/_shared/notice-overrides/utils-0.5.0-LICENSE +0 -21
- package/templates/binary/native.yaml +0 -16
- package/templates/binary/synology-app.yaml +0 -7
- package/templates/compose-import/compose.yaml +0 -10
- package/templates/compose-import/synology-app.yaml +0 -15
- package/templates/native-go/backend/cmd/app/sdk_main.go +0 -62
- package/templates/native-go/backend/cmd/dsm-readonly-probe/main_linux.go +0 -46
- package/templates/native-go/backend/cmd/helper/main.go +0 -64
- package/templates/native-go/backend/cmd/helper/sdk_registry.go +0 -19
- package/templates/native-go/backend/internal/api/binary.go +0 -154
- package/templates/native-go/backend/internal/api/binary_test.go +0 -165
- package/templates/native-go/backend/internal/app/authorization_none.go +0 -5
- package/templates/native-go/backend/internal/app/integration_state.go +0 -16
- package/templates/native-go/backend/internal/app/nas_cgi_artifact_test.go +0 -129
- package/templates/native-go/backend/internal/app/nas_refusal_test.go +0 -46
- package/templates/native-go/backend/internal/app/sdk_jobs.go +0 -70
- package/templates/native-go/backend/internal/app/sdk_jobs_test.go +0 -116
- package/templates/native-go/backend/internal/app/sdk_routes.go +0 -177
- package/templates/native-go/backend/internal/dsmprobe/collector_linux.go +0 -335
- package/templates/native-go/backend/internal/dsmprobe/collector_linux_test.go +0 -41
- package/templates/native-go/backend/internal/dsmprobe/protocol.go +0 -179
- package/templates/native-go/backend/internal/dsmprobe/protocol_test.go +0 -29
- package/templates/native-go/backend/internal/filestation/repository.go +0 -207
- package/templates/native-go/backend/internal/filestation/repository_test.go +0 -104
- package/templates/native-go/backend/internal/filestation/sdk_session.go +0 -241
- package/templates/native-go/backend/internal/filestation/sdk_session_test.go +0 -183
- package/templates/native-go/backend/internal/filestation/session_semantics_test.go +0 -383
- package/templates/native-go/backend/internal/helper/background_proof.go +0 -163
- package/templates/native-go/backend/internal/helper/background_proof_contract.go +0 -46
- package/templates/native-go/backend/internal/helper/background_proof_test.go +0 -161
- package/templates/native-go/backend/internal/helper/cohort.go +0 -393
- package/templates/native-go/backend/internal/helper/cohort_publication.go +0 -18
- package/templates/native-go/backend/internal/helper/cohort_publication_test.go +0 -105
- package/templates/native-go/backend/internal/helper/cohort_test.go +0 -372
- package/templates/native-go/backend/internal/helper/control.go +0 -424
- package/templates/native-go/backend/internal/helper/control_test.go +0 -250
- package/templates/native-go/backend/internal/helper/data_contract.go +0 -245
- package/templates/native-go/backend/internal/helper/data_contract_test.go +0 -51
- package/templates/native-go/backend/internal/helper/data_decode.go +0 -184
- package/templates/native-go/backend/internal/helper/data_decode_pointer_test.go +0 -30
- package/templates/native-go/backend/internal/helper/data_protocol.go +0 -419
- package/templates/native-go/backend/internal/helper/data_protocol_test.go +0 -449
- package/templates/native-go/backend/internal/helper/dsm_acl_linux.go +0 -139
- package/templates/native-go/backend/internal/helper/dsm_acl_linux_test.go +0 -121
- package/templates/native-go/backend/internal/helper/dsm_acl_syscall_linux.go +0 -95
- package/templates/native-go/backend/internal/helper/dsm_acl_syscall_linux_test.go +0 -56
- package/templates/native-go/backend/internal/helper/dsm_bridge_linux.go +0 -144
- package/templates/native-go/backend/internal/helper/dsm_bridge_linux_test.go +0 -89
- package/templates/native-go/backend/internal/helper/dsm_home_linux.go +0 -107
- package/templates/native-go/backend/internal/helper/dsm_home_linux_test.go +0 -82
- package/templates/native-go/backend/internal/helper/dsm_probe_transport_linux.go +0 -151
- package/templates/native-go/backend/internal/helper/dsm_probe_transport_linux_test.go +0 -66
- package/templates/native-go/backend/internal/helper/grant_authority.go +0 -519
- package/templates/native-go/backend/internal/helper/grant_authority_contract.go +0 -88
- package/templates/native-go/backend/internal/helper/grant_authority_test.go +0 -510
- package/templates/native-go/backend/internal/helper/grant_cohort.go +0 -389
- package/templates/native-go/backend/internal/helper/grant_cohort_test.go +0 -239
- package/templates/native-go/backend/internal/helper/grant_delivery.go +0 -49
- package/templates/native-go/backend/internal/helper/grant_delivery_methods.go +0 -273
- package/templates/native-go/backend/internal/helper/grant_delivery_test.go +0 -322
- package/templates/native-go/backend/internal/helper/grant_operation_contract.go +0 -47
- package/templates/native-go/backend/internal/helper/grant_readonly_test.go +0 -180
- package/templates/native-go/backend/internal/helper/grant_repository_linux.go +0 -416
- package/templates/native-go/backend/internal/helper/grant_repository_linux_test.go +0 -469
- package/templates/native-go/backend/internal/helper/grant_rpc.go +0 -147
- package/templates/native-go/backend/internal/helper/grant_rpc_test.go +0 -51
- package/templates/native-go/backend/internal/helper/grant_snapshot.go +0 -78
- package/templates/native-go/backend/internal/helper/grant_supervisor_linux.go +0 -134
- package/templates/native-go/backend/internal/helper/grant_supervisor_linux_test.go +0 -254
- package/templates/native-go/backend/internal/helper/jobcontract/bindings.go +0 -48
- package/templates/native-go/backend/internal/helper/jobcontract/contract_test.go +0 -436
- package/templates/native-go/backend/internal/helper/jobcontract/decode.go +0 -185
- package/templates/native-go/backend/internal/helper/jobcontract/digest.go +0 -55
- package/templates/native-go/backend/internal/helper/jobcontract/registry.go +0 -85
- package/templates/native-go/backend/internal/helper/jobcontract/registry_test.go +0 -73
- package/templates/native-go/backend/internal/helper/jobcontract/result.go +0 -53
- package/templates/native-go/backend/internal/helper/jobcontract/stub.go +0 -8
- package/templates/native-go/backend/internal/helper/jobcontract/testdata/input-digests.json +0 -127
- package/templates/native-go/backend/internal/helper/jobcontract/types.go +0 -234
- package/templates/native-go/backend/internal/helper/jobcontract/types_test.go +0 -29
- package/templates/native-go/backend/internal/helper/jobcontract/validate.go +0 -462
- package/templates/native-go/backend/internal/helper/lease.go +0 -112
- package/templates/native-go/backend/internal/helper/lease_linux.go +0 -44
- package/templates/native-go/backend/internal/helper/lease_other.go +0 -8
- package/templates/native-go/backend/internal/helper/legacy_authority_schema_linux_test.go +0 -34
- package/templates/native-go/backend/internal/helper/legacy_authority_schema_test.go +0 -6
- package/templates/native-go/backend/internal/helper/lifecycle.go +0 -234
- package/templates/native-go/backend/internal/helper/lifecycle_test.go +0 -473
- package/templates/native-go/backend/internal/helper/managed_pilot.go +0 -284
- package/templates/native-go/backend/internal/helper/managed_pilot_repository_linux.go +0 -74
- package/templates/native-go/backend/internal/helper/managed_pilot_repository_linux_test.go +0 -40
- package/templates/native-go/backend/internal/helper/managed_pilot_test.go +0 -210
- package/templates/native-go/backend/internal/helper/management.go +0 -86
- package/templates/native-go/backend/internal/helper/nas_shipped_refusal_linux_test.go +0 -97
- package/templates/native-go/backend/internal/helper/native_discovery.go +0 -79
- package/templates/native-go/backend/internal/helper/native_identity.go +0 -89
- package/templates/native-go/backend/internal/helper/native_provider.go +0 -159
- package/templates/native-go/backend/internal/helper/native_provider_test.go +0 -421
- package/templates/native-go/backend/internal/helper/observation.go +0 -244
- package/templates/native-go/backend/internal/helper/observation_health_test.go +0 -127
- package/templates/native-go/backend/internal/helper/observation_reload_budget_test.go +0 -117
- package/templates/native-go/backend/internal/helper/observation_test.go +0 -196
- package/templates/native-go/backend/internal/helper/observer_diagnostic.go +0 -155
- package/templates/native-go/backend/internal/helper/observer_diagnostic_linux.go +0 -76
- package/templates/native-go/backend/internal/helper/observer_diagnostic_linux_test.go +0 -130
- package/templates/native-go/backend/internal/helper/observer_diagnostic_test.go +0 -98
- package/templates/native-go/backend/internal/helper/observer_diagnostic_writer.go +0 -40
- package/templates/native-go/backend/internal/helper/operation_bootstrap_linux.go +0 -193
- package/templates/native-go/backend/internal/helper/operation_credentials_linux.go +0 -56
- package/templates/native-go/backend/internal/helper/operation_linux.go +0 -480
- package/templates/native-go/backend/internal/helper/operation_linux_test.go +0 -528
- package/templates/native-go/backend/internal/helper/peer_linux.go +0 -44
- package/templates/native-go/backend/internal/helper/peer_other.go +0 -7
- package/templates/native-go/backend/internal/helper/process_linux.go +0 -180
- package/templates/native-go/backend/internal/helper/process_other.go +0 -5
- package/templates/native-go/backend/internal/helper/publication_test.go +0 -178
- package/templates/native-go/backend/internal/helper/purge.go +0 -115
- package/templates/native-go/backend/internal/helper/purge_test.go +0 -59
- package/templates/native-go/backend/internal/helper/query_deadline_linux_test.go +0 -115
- package/templates/native-go/backend/internal/helper/query_pending_diagnostic_test.go +0 -254
- package/templates/native-go/backend/internal/helper/read_stream_cohort_linux_test.go +0 -156
- package/templates/native-go/backend/internal/helper/read_transfer.go +0 -40
- package/templates/native-go/backend/internal/helper/read_transfer_linux.go +0 -109
- package/templates/native-go/backend/internal/helper/read_transfer_linux_test.go +0 -118
- package/templates/native-go/backend/internal/helper/read_transfer_test.go +0 -177
- package/templates/native-go/backend/internal/helper/readonly.go +0 -105
- package/templates/native-go/backend/internal/helper/readonly_admission.go +0 -85
- package/templates/native-go/backend/internal/helper/readonly_cohort_linux_test.go +0 -253
- package/templates/native-go/backend/internal/helper/readonly_linux_test.go +0 -378
- package/templates/native-go/backend/internal/helper/readonly_mount_linux.go +0 -65
- package/templates/native-go/backend/internal/helper/readonly_mount_proxy_linux.go +0 -113
- package/templates/native-go/backend/internal/helper/readonly_operations_linux.go +0 -168
- package/templates/native-go/backend/internal/helper/readonly_resolver_linux.go +0 -241
- package/templates/native-go/backend/internal/helper/readonly_test.go +0 -40
- package/templates/native-go/backend/internal/helper/relaxed_identity.go +0 -252
- package/templates/native-go/backend/internal/helper/relaxed_identity_contract.go +0 -105
- package/templates/native-go/backend/internal/helper/relaxed_identity_test.go +0 -406
- package/templates/native-go/backend/internal/helper/relaxed_invalidation.go +0 -203
- package/templates/native-go/backend/internal/helper/repair.go +0 -132
- package/templates/native-go/backend/internal/helper/repair_test.go +0 -271
- package/templates/native-go/backend/internal/helper/revoke.go +0 -109
- package/templates/native-go/backend/internal/helper/revoke_test.go +0 -121
- package/templates/native-go/backend/internal/helper/s1r_actor_acl_linux_test.go +0 -303
- package/templates/native-go/backend/internal/helper/s1r_actor_fixture_linux_test.go +0 -184
- package/templates/native-go/backend/internal/helper/s1r_actor_races_linux_test.go +0 -250
- package/templates/native-go/backend/internal/helper/s1r_fixture_contract_linux_test.go +0 -18
- package/templates/native-go/backend/internal/helper/sdk_assembly_linux.go +0 -51
- package/templates/native-go/backend/internal/helper/sdk_attach.go +0 -83
- package/templates/native-go/backend/internal/helper/sdk_attach_contract.go +0 -32
- package/templates/native-go/backend/internal/helper/sdk_attach_test.go +0 -184
- package/templates/native-go/backend/internal/helper/sdk_authority_schema_test.go +0 -6
- package/templates/native-go/backend/internal/helper/sdk_background_authority.go +0 -832
- package/templates/native-go/backend/internal/helper/sdk_background_authority_test.go +0 -714
- package/templates/native-go/backend/internal/helper/sdk_background_invalidation.go +0 -218
- package/templates/native-go/backend/internal/helper/sdk_background_lease.go +0 -218
- package/templates/native-go/backend/internal/helper/sdk_background_snapshot.go +0 -110
- package/templates/native-go/backend/internal/helper/sdk_background_store_linux_test.go +0 -261
- package/templates/native-go/backend/internal/helper/sdk_background_store_test.go +0 -58
- package/templates/native-go/backend/internal/helper/sdk_bindings.go +0 -60
- package/templates/native-go/backend/internal/helper/sdk_data_contract.go +0 -251
- package/templates/native-go/backend/internal/helper/sdk_data_protocol.go +0 -424
- package/templates/native-go/backend/internal/helper/sdk_dispatch_absence_test.go +0 -51
- package/templates/native-go/backend/internal/helper/sdk_display.go +0 -488
- package/templates/native-go/backend/internal/helper/sdk_display_contract.go +0 -121
- package/templates/native-go/backend/internal/helper/sdk_display_test.go +0 -459
- package/templates/native-go/backend/internal/helper/sdk_grant_authority.go +0 -559
- package/templates/native-go/backend/internal/helper/sdk_grant_repository_linux.go +0 -417
- package/templates/native-go/backend/internal/helper/sdk_grant_snapshot.go +0 -94
- package/templates/native-go/backend/internal/helper/sdk_history.go +0 -80
- package/templates/native-go/backend/internal/helper/sdk_history_test.go +0 -76
- package/templates/native-go/backend/internal/helper/sdk_job.go +0 -697
- package/templates/native-go/backend/internal/helper/sdk_job_child_linux.go +0 -309
- package/templates/native-go/backend/internal/helper/sdk_job_contract.go +0 -122
- package/templates/native-go/backend/internal/helper/sdk_job_linux_test.go +0 -159
- package/templates/native-go/backend/internal/helper/sdk_job_process_linux.go +0 -327
- package/templates/native-go/backend/internal/helper/sdk_job_test.go +0 -501
- package/templates/native-go/backend/internal/helper/sdk_job_vm_linux_test.go +0 -343
- package/templates/native-go/backend/internal/helper/sdk_journal.go +0 -77
- package/templates/native-go/backend/internal/helper/sdk_journal_linux.go +0 -244
- package/templates/native-go/backend/internal/helper/sdk_journal_linux_test.go +0 -295
- package/templates/native-go/backend/internal/helper/sdk_journal_test.go +0 -71
- package/templates/native-go/backend/internal/helper/sdk_picker_test.go +0 -50
- package/templates/native-go/backend/internal/helper/sdk_process_linux.go +0 -184
- package/templates/native-go/backend/internal/helper/sdk_public_vm_linux_test.go +0 -129
- package/templates/native-go/backend/internal/helper/sdk_relaxed_invalidation.go +0 -242
- package/templates/native-go/backend/internal/helper/sdk_rpc.go +0 -299
- package/templates/native-go/backend/internal/helper/sdk_rpc_contract.go +0 -70
- package/templates/native-go/backend/internal/helper/sdk_rpc_test.go +0 -135
- package/templates/native-go/backend/internal/helper/sdk_server_linux.go +0 -161
- package/templates/native-go/backend/internal/helper/sdk_session.go +0 -677
- package/templates/native-go/backend/internal/helper/sdk_session_contract.go +0 -72
- package/templates/native-go/backend/internal/helper/sdk_session_fence_test.go +0 -215
- package/templates/native-go/backend/internal/helper/sdk_session_test.go +0 -475
- package/templates/native-go/backend/internal/helper/sdk_supervisor_frame.go +0 -78
- package/templates/native-go/backend/internal/helper/sdk_supervisor_linux.go +0 -414
- package/templates/native-go/backend/internal/helper/sdk_transport.go +0 -79
- package/templates/native-go/backend/internal/helper/sdk_transport_linux.go +0 -82
- package/templates/native-go/backend/internal/helper/sdk_transport_test.go +0 -64
- package/templates/native-go/backend/internal/helper/server_linux.go +0 -136
- package/templates/native-go/backend/internal/helper/stale_management_linux_test.go +0 -126
- package/templates/native-go/backend/internal/helper/stale_management_test.go +0 -122
- package/templates/native-go/backend/internal/helper/startup_diagnostic.go +0 -68
- package/templates/native-go/backend/internal/helper/startup_diagnostic_linux_test.go +0 -126
- package/templates/native-go/backend/internal/helper/startup_diagnostic_test.go +0 -117
- package/templates/native-go/backend/internal/helper/status.go +0 -343
- package/templates/native-go/backend/internal/helper/status_test.go +0 -333
- package/templates/native-go/backend/internal/helper/supervision.go +0 -107
- package/templates/native-go/backend/internal/helper/supervision_test.go +0 -124
- package/templates/native-go/backend/internal/helper/supervisor_frame.go +0 -79
- package/templates/native-go/backend/internal/helper/supervisor_frame_linux_test.go +0 -69
- package/templates/native-go/backend/internal/helper/supervisor_frame_test.go +0 -107
- package/templates/native-go/backend/internal/helper/supervisor_linux.go +0 -367
- package/templates/native-go/backend/internal/helper/supervisor_linux_test.go +0 -913
- package/templates/native-go/backend/internal/helper/supervisor_socket_eof_test.go +0 -74
- package/templates/native-go/backend/internal/helper/supervisor_socket_test.go +0 -45
- package/templates/native-go/backend/internal/helper/testdata/protocol2/create.json +0 -23
- package/templates/native-go/backend/internal/helper/testdata/protocol2/frames.json +0 -67
- package/templates/native-go/backend/internal/helper/testdata/protocol2/grant-store.json +0 -52
- package/templates/native-go/backend/internal/helper/testdata/protocol2/intent.json +0 -20
- package/templates/native-go/backend/internal/helper/testdata/protocol2/list.json +0 -20
- package/templates/native-go/backend/internal/helper/testdata/protocol2/publish.json +0 -20
- package/templates/native-go/backend/internal/helper/testdata/protocol2/read.json +0 -22
- package/templates/native-go/backend/internal/helper/testdata/protocol2/stat.json +0 -22
- package/templates/native-go/backend/internal/helper/testdata/protocol2/write-stream.json +0 -22
- package/templates/native-go/backend/internal/helper/unit_connection.go +0 -75
- package/templates/native-go/backend/internal/helper/unit_connection_linux_test.go +0 -135
- package/templates/native-go/backend/internal/helper/unit_connection_test.go +0 -151
- package/templates/native-go/backend/internal/helper/unit_frame_test.go +0 -32
- package/templates/native-go/backend/internal/helper/unit_linux.go +0 -368
- package/templates/native-go/backend/internal/helper/unit_linux_test.go +0 -46
- package/templates/native-go/backend/internal/helper/unit_mechanisms_linux_test.go +0 -217
- package/templates/native-go/backend/internal/helper/unit_padding_linux_test.go +0 -178
- package/templates/native-go/backend/internal/helper/unit_query_linux.go +0 -115
- package/templates/native-go/backend/internal/helper/unit_reload_linux_test.go +0 -372
- package/templates/native-go/backend/internal/helper/unit_reload_sequence_linux_test.go +0 -232
- package/templates/native-go/backend/internal/helper/write.go +0 -77
- package/templates/native-go/backend/internal/helper/write_admission.go +0 -260
- package/templates/native-go/backend/internal/helper/write_admission_test.go +0 -135
- package/templates/native-go/backend/internal/helper/write_cohort_linux_test.go +0 -218
- package/templates/native-go/backend/internal/helper/write_files_linux.go +0 -205
- package/templates/native-go/backend/internal/helper/write_files_linux_test.go +0 -225
- package/templates/native-go/backend/internal/helper/write_intent_linux.go +0 -116
- package/templates/native-go/backend/internal/helper/write_intent_linux_test.go +0 -74
- package/templates/native-go/backend/internal/helper/write_operation_linux.go +0 -245
- package/templates/native-go/backend/internal/helper/write_test.go +0 -53
- package/templates/native-go-authorization/backend/internal/app/authorization.go +0 -298
- package/templates/native-go-authorization/backend/internal/app/authorization_test.go +0 -96
- package/templates/native-go-authorization/frontend/src/authorization/AuthorizationGate.vue +0 -89
- package/templates/native-go-authorization/frontend/src/authorization/i18n/de.json +0 -36
- package/templates/native-go-authorization/frontend/src/authorization/i18n/en.json +0 -36
- package/templates/native-go-authorization/frontend/src/authorization/i18n/es.json +0 -36
- package/templates/native-go-authorization/frontend/src/authorization/i18n/fr.json +0 -36
- package/templates/native-go-authorization/frontend/src/authorization/i18n/index.ts +0 -15
- package/templates/native-go-authorization/frontend/src/authorization/i18n/it.json +0 -36
- package/templates/native-go-authorization/frontend/src/authorization/i18n/ja.json +0 -36
- package/templates/native-go-authorization/frontend/src/authorization/i18n/ko.json +0 -36
- package/templates/native-go-authorization/frontend/src/authorization/i18n/zh-CN.json +0 -36
- package/templates/native-go-authorization/frontend/src/authorization/i18n/zh-TW.json +0 -36
- package/templates/native-go-authorization/frontend/test/authorization-preview.html +0 -14
- package/templates/native-go-authorization/frontend/test/authorization.test.ts +0 -59
- package/templates/native-go-background/BACKGROUND.md +0 -111
- package/templates/native-go-background/backend/internal/app/background_routes_test.go +0 -32
- package/templates/native-go-background/frontend/src/background/BackgroundPanel.vue +0 -178
- package/templates/native-go-background/frontend/src/background/i18n/de.json +0 -83
- package/templates/native-go-background/frontend/src/background/i18n/en.json +0 -83
- package/templates/native-go-background/frontend/src/background/i18n/es.json +0 -83
- package/templates/native-go-background/frontend/src/background/i18n/fr.json +0 -83
- package/templates/native-go-background/frontend/src/background/i18n/it.json +0 -83
- package/templates/native-go-background/frontend/src/background/i18n/ja.json +0 -83
- package/templates/native-go-background/frontend/src/background/i18n/ko.json +0 -83
- package/templates/native-go-background/frontend/src/background/i18n/zh-CN.json +0 -83
- package/templates/native-go-background/frontend/src/background/i18n/zh-TW.json +0 -83
- package/templates/native-go-background/frontend/src/background/picker-provider.ts +0 -13
- package/templates/native-go-background/frontend/test/background.test.ts +0 -179
- package/templates/native-go-better-auth/backend/internal/app/identity.go +0 -208
- package/templates/native-go-better-auth/backend/internal/app/identity_test.go +0 -113
- package/templates/native-go-better-auth/node/app.mjs +0 -72
- package/templates/native-go-better-auth/node/build.mjs +0 -4
- package/templates/native-go-better-auth/node/package-lock.json +0 -862
- package/templates/native-go-better-auth/node/package.json +0 -1
- package/templates/native-go-better-auth/node/test/auth.test.mjs +0 -31
- package/templates/native-go-integration/backend/internal/app/identity_none.go +0 -6
- package/templates/native-go-integration/backend/internal/app/personal.go +0 -203
- package/templates/native-go-integration/backend/internal/app/personal_test.go +0 -156
- package/templates/native-go-root/backend/internal/app/root.go +0 -107
- package/templates/native-go-root/backend/internal/app/root_test.go +0 -124
- package/templates/native-go-root/root/whoami.sh +0 -6
- package/templates/native-go-vue/frontend/README-JOBS.md +0 -75
- package/templates/native-go-vue/frontend/README-M2.md +0 -64
- package/templates/native-go-vue/frontend/src/M2App.vue +0 -57
- package/templates/native-go-vue/frontend/src/SDKApp.vue +0 -203
- package/templates/native-go-vue/frontend/src/jobs/InteractiveJobForm.vue +0 -70
- package/templates/native-go-vue/frontend/src/jobs/JobsAdminPanel.vue +0 -33
- package/templates/native-go-vue/frontend/src/jobs/JobsPanel.vue +0 -135
- package/templates/native-go-vue/frontend/src/jobs/connected-provider.ts +0 -179
- package/templates/native-go-vue/frontend/src/jobs/i18n/de.json +0 -62
- package/templates/native-go-vue/frontend/src/jobs/i18n/en.json +0 -62
- package/templates/native-go-vue/frontend/src/jobs/i18n/es.json +0 -62
- package/templates/native-go-vue/frontend/src/jobs/i18n/fr.json +0 -62
- package/templates/native-go-vue/frontend/src/jobs/i18n/it.json +0 -62
- package/templates/native-go-vue/frontend/src/jobs/i18n/ja.json +0 -62
- package/templates/native-go-vue/frontend/src/jobs/i18n/ko.json +0 -62
- package/templates/native-go-vue/frontend/src/jobs/i18n/zh-CN.json +0 -62
- package/templates/native-go-vue/frontend/src/jobs/i18n/zh-TW.json +0 -62
- package/templates/native-go-vue/frontend/src/jobs/i18n.ts +0 -15
- package/templates/native-go-vue/frontend/src/jobs/mock-provider.ts +0 -67
- package/templates/native-go-vue/frontend/src/jobs/provider.ts +0 -60
- package/templates/native-go-vue/frontend/src/jobs/validate.ts +0 -44
- package/templates/native-go-vue/frontend/src/m2-main.ts +0 -21
- package/templates/native-go-vue/frontend/src/m2-style.css +0 -7
- package/templates/native-go-vue/frontend/src/nas/M2Files.vue +0 -94
- package/templates/native-go-vue/frontend/src/nas/M2PathPicker.vue +0 -70
- package/templates/native-go-vue/frontend/src/nas/M2Settings.vue +0 -69
- package/templates/native-go-vue/frontend/src/nas/NasGrantSettings.vue +0 -74
- package/templates/native-go-vue/frontend/src/nas/NasPathPicker.vue +0 -106
- package/templates/native-go-vue/frontend/src/nas/NasUnavailable.vue +0 -20
- package/templates/native-go-vue/frontend/src/nas/i18n/de.json +0 -74
- package/templates/native-go-vue/frontend/src/nas/i18n/en.json +0 -74
- package/templates/native-go-vue/frontend/src/nas/i18n/es.json +0 -74
- package/templates/native-go-vue/frontend/src/nas/i18n/fr.json +0 -74
- package/templates/native-go-vue/frontend/src/nas/i18n/it.json +0 -74
- package/templates/native-go-vue/frontend/src/nas/i18n/ja.json +0 -74
- package/templates/native-go-vue/frontend/src/nas/i18n/ko.json +0 -74
- package/templates/native-go-vue/frontend/src/nas/i18n/m2/de.json +0 -56
- package/templates/native-go-vue/frontend/src/nas/i18n/m2/en.json +0 -56
- package/templates/native-go-vue/frontend/src/nas/i18n/m2/es.json +0 -56
- package/templates/native-go-vue/frontend/src/nas/i18n/m2/fr.json +0 -56
- package/templates/native-go-vue/frontend/src/nas/i18n/m2/it.json +0 -56
- package/templates/native-go-vue/frontend/src/nas/i18n/m2/ja.json +0 -56
- package/templates/native-go-vue/frontend/src/nas/i18n/m2/ko.json +0 -56
- package/templates/native-go-vue/frontend/src/nas/i18n/m2/zh-CN.json +0 -56
- package/templates/native-go-vue/frontend/src/nas/i18n/m2/zh-TW.json +0 -56
- package/templates/native-go-vue/frontend/src/nas/i18n/zh-CN.json +0 -74
- package/templates/native-go-vue/frontend/src/nas/i18n/zh-TW.json +0 -74
- package/templates/native-go-vue/frontend/src/nas/m2-contract.ts +0 -33
- package/templates/native-go-vue/frontend/src/nas/m2-i18n.ts +0 -24
- package/templates/native-go-vue/frontend/src/nas/m2-provider.ts +0 -104
- package/templates/native-go-vue/frontend/src/nas/mock-provider.ts +0 -119
- package/templates/native-go-vue/frontend/src/nas/use-m2-request.ts +0 -18
- package/templates/native-go-vue/frontend/src/sdk-main.ts +0 -39
- package/templates/native-go-vue/frontend/test/jobs-connected.test.ts +0 -163
- package/templates/native-go-vue/frontend/test/jobs-preview.html +0 -22
- package/templates/native-go-vue/frontend/test/jobs.test.ts +0 -176
- package/templates/native-go-vue/frontend/test/m2-preview.html +0 -27
- package/templates/native-go-vue/frontend/test/m2-provider.test.ts +0 -87
- package/templates/native-go-vue/frontend/test/m2-ui.test.ts +0 -209
- package/templates/native-go-vue/frontend/test/nas-provider.test.ts +0 -81
- package/templates/native-go-vue/frontend/test/nas-request.test.ts +0 -21
- package/templates/native-go-vue/frontend/test/nas-ui.test.ts +0 -261
- package/templates/native-go-vue/frontend/test/picker-wire.test.ts +0 -110
- package/templates/native-go-vue/frontend/test/shell-preview.html +0 -19
- package/templates/native-go-vue/frontend/test/shell-sdk.test.ts +0 -73
- /package/dist/templates/{hello-files → compose}/compose.yaml +0 -0
- /package/dist/templates/{hello-files → compose}/synology-app.yaml +0 -0
- /package/dist/templates/{native-go-background → native-go-jobs}/backend/internal/app/background_on.go +0 -0
- /package/dist/templates/{native-go-background → native-go-jobs}/frontend/src/background/i18n.ts +0 -0
- /package/templates/{hello-files → compose}/compose.yaml +0 -0
- /package/templates/{hello-files → compose}/synology-app.yaml +0 -0
- /package/templates/{native-go-background → native-go-jobs}/backend/internal/app/background_on.go +0 -0
- /package/templates/{native-go-background → native-go-jobs}/frontend/src/background/i18n.ts +0 -0
|
@@ -1,389 +0,0 @@
|
|
|
1
|
-
package helper
|
|
2
|
-
|
|
3
|
-
import (
|
|
4
|
-
"bytes"
|
|
5
|
-
"context"
|
|
6
|
-
"encoding/json"
|
|
7
|
-
"slices"
|
|
8
|
-
)
|
|
9
|
-
|
|
10
|
-
type cohortReceipt struct {
|
|
11
|
-
binding operationBinding
|
|
12
|
-
bytes uint64
|
|
13
|
-
write *retiredWriteReceipt
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
func (c *operationCohort) retire(id string, op *cohortOperation) {
|
|
17
|
-
if c.receipts == nil {
|
|
18
|
-
c.receipts = map[string]cohortReceipt{}
|
|
19
|
-
}
|
|
20
|
-
receipt := cohortReceipt{binding: op.binding, bytes: op.bytes}
|
|
21
|
-
if op.writeWork != nil {
|
|
22
|
-
value, code, known := MutationReceipt{}, ErrCleanupRequired, false
|
|
23
|
-
if p, ok := op.process.(writeMutationProcess); ok {
|
|
24
|
-
value, code, known = p.mutationResult()
|
|
25
|
-
}
|
|
26
|
-
value.EffectsUnknown = !known
|
|
27
|
-
retired := *op
|
|
28
|
-
retired.process = nil
|
|
29
|
-
receipt.write = &retiredWriteReceipt{retired, value, code, !known}
|
|
30
|
-
}
|
|
31
|
-
c.receipts[id] = receipt
|
|
32
|
-
delete(c.operations, id)
|
|
33
|
-
c.reaped++
|
|
34
|
-
}
|
|
35
|
-
func (q GrantDrainProof) valid() bool {
|
|
36
|
-
return allReferences(q.Key.Epoch, q.Key.GrantID) && q.Key.Revision > 0 && q.Started <= MaxReplayEntries && q.Started == q.Reaped && q.AdmittedBytes <= MaxReplayEntries*MaxTransferBytes && q.BytesWritten <= q.AdmittedBytes && q.WriteOperations <= q.Started && q.PublishedOperations <= q.WriteOperations && q.CommittedOperations <= q.PublishedOperations && (!q.WriteEffectsUnknown || q.WriteOperations > 0)
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
// Sole supervisor owner/reaper only. This derives Q from S2's actual removal
|
|
40
|
-
// condition (Wait4 + stopped relay/FDs), including operations previously polled.
|
|
41
|
-
func (c *operationCohort) DrainGrant(ctx context.Context, key GrantDrainKey) (GrantQuiescence, Code) {
|
|
42
|
-
if key.Epoch != c.epoch || !allReferences(key.GrantID) || key.Revision == 0 {
|
|
43
|
-
return GrantQuiescence{}, ErrStale
|
|
44
|
-
}
|
|
45
|
-
if err := c.cancelGrant(ctx, key.GrantID, key.Revision); err != nil {
|
|
46
|
-
return GrantQuiescence{}, ErrCleanupRequired
|
|
47
|
-
}
|
|
48
|
-
if ctx.Err() != nil {
|
|
49
|
-
return GrantQuiescence{}, ErrCleanupRequired
|
|
50
|
-
}
|
|
51
|
-
for _, op := range c.operations {
|
|
52
|
-
if op.binding.GrantID == key.GrantID {
|
|
53
|
-
return GrantQuiescence{}, ErrCleanupRequired
|
|
54
|
-
}
|
|
55
|
-
}
|
|
56
|
-
proof := GrantDrainProof{Key: key}
|
|
57
|
-
for _, receipt := range c.receipts {
|
|
58
|
-
if receipt.binding.GrantID != key.GrantID {
|
|
59
|
-
continue
|
|
60
|
-
}
|
|
61
|
-
if receipt.binding.Epoch != key.Epoch || receipt.binding.GrantRevision >= key.Revision {
|
|
62
|
-
return GrantQuiescence{}, ErrStale
|
|
63
|
-
}
|
|
64
|
-
proof.Started++
|
|
65
|
-
proof.Reaped++
|
|
66
|
-
proof.AdmittedBytes += receipt.bytes
|
|
67
|
-
if receipt.write != nil {
|
|
68
|
-
proof.WriteOperations++
|
|
69
|
-
proof.BytesWritten += receipt.write.receipt.BytesWritten
|
|
70
|
-
if receipt.write.unknown || receipt.write.code == ErrCommitUncertain {
|
|
71
|
-
proof.WriteEffectsUnknown = true
|
|
72
|
-
}
|
|
73
|
-
if receipt.write.receipt.Published {
|
|
74
|
-
proof.PublishedOperations++
|
|
75
|
-
}
|
|
76
|
-
if receipt.write.receipt.Committed {
|
|
77
|
-
proof.CommittedOperations++
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
if !proof.valid() {
|
|
82
|
-
return GrantQuiescence{}, ErrCleanupRequired
|
|
83
|
-
}
|
|
84
|
-
return GrantQuiescence{Key: key, Cohort: &proof, ChildrenReaped: true, RelayClosed: true, LeasesClosed: true, FDsClosed: true, EffectsRecorded: true}, ""
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
type supervisorGrants struct {
|
|
88
|
-
authority *GrantAuthority
|
|
89
|
-
cohort *operationCohort
|
|
90
|
-
services supervisorGrantServices
|
|
91
|
-
tickets, nonces map[string]bool // one bounded window/epoch, never evicted
|
|
92
|
-
streamTickets, streamNonces map[string]bool
|
|
93
|
-
streamRPCNonces map[string]bool
|
|
94
|
-
rpcNonces map[string]bool
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
func newSupervisorGrants(repo GrantRepository, cohort *operationCohort, services supervisorGrantServices) (*supervisorGrants, Code) {
|
|
98
|
-
if cohort == nil || cohort.gate == nil {
|
|
99
|
-
return nil, ErrUnavailable
|
|
100
|
-
}
|
|
101
|
-
authority, code := NewGrantAuthority(repo, services.native, services.consent, cohort)
|
|
102
|
-
if code != "" {
|
|
103
|
-
return nil, code
|
|
104
|
-
}
|
|
105
|
-
if authority.policy.Inventory != cohort.inventory || authority.policy.Epoch != cohort.epoch {
|
|
106
|
-
return nil, ErrIncompatible
|
|
107
|
-
}
|
|
108
|
-
// Set before publishing the runtime; observer fencing and all grant mutations
|
|
109
|
-
// now share the SAME mutex. No helper-local or cross-process mutex claim.
|
|
110
|
-
authority.mu = &cohort.gate.mu
|
|
111
|
-
authority.gate = cohort.gate
|
|
112
|
-
authority.writes = services.writes
|
|
113
|
-
return &supervisorGrants{authority: authority, cohort: cohort, services: services, tickets: map[string]bool{}, nonces: map[string]bool{}, rpcNonces: map[string]bool{}, streamTickets: map[string]bool{}, streamNonces: map[string]bool{}, streamRPCNonces: map[string]bool{}}, ""
|
|
114
|
-
}
|
|
115
|
-
func (a *GrantAuthority) grantForActor(actor NativeActor, r DataRequest) (Grant, Code) {
|
|
116
|
-
a.mu.Lock()
|
|
117
|
-
defer a.mu.Unlock()
|
|
118
|
-
var result Grant
|
|
119
|
-
code := a.transaction(func(s *GrantStore) (bool, Code) {
|
|
120
|
-
g := findGrant(s, r.GrantID)
|
|
121
|
-
if g == nil {
|
|
122
|
-
return false, ErrDenied
|
|
123
|
-
}
|
|
124
|
-
if g.Scope.Kind == ScopePersonal && g.Owner != actor.Principal() {
|
|
125
|
-
return false, ErrDenied
|
|
126
|
-
}
|
|
127
|
-
if g.State == GrantRevoked {
|
|
128
|
-
return false, ErrRevoked
|
|
129
|
-
}
|
|
130
|
-
if g.Revision != r.GrantRevision {
|
|
131
|
-
return false, ErrStale
|
|
132
|
-
}
|
|
133
|
-
if g.State == GrantSuspended {
|
|
134
|
-
return false, ErrSuspended
|
|
135
|
-
}
|
|
136
|
-
if !slices.Contains(g.Actions, r.Op) {
|
|
137
|
-
return false, ErrDenied
|
|
138
|
-
}
|
|
139
|
-
result = cloneAuthorityGrant(*g)
|
|
140
|
-
return false, ""
|
|
141
|
-
})
|
|
142
|
-
return result, code
|
|
143
|
-
}
|
|
144
|
-
func (s *supervisorGrants) validate(ctx context.Context, carriers SessionCarriers, r DataRequest, old *NativeActor) (NativeActor, GrantUseValidation, Code) {
|
|
145
|
-
if code := validateOperationRequest(r, s.services.writes); code != "" {
|
|
146
|
-
return NativeActor{}, GrantUseValidation{}, code
|
|
147
|
-
}
|
|
148
|
-
if !r.Op.ReadOnly() && !s.services.writes.allows(r.Op) {
|
|
149
|
-
return NativeActor{}, GrantUseValidation{}, ErrUnsupported
|
|
150
|
-
}
|
|
151
|
-
if r.Inventory != s.cohort.inventory || r.Epoch != s.cohort.epoch {
|
|
152
|
-
return NativeActor{}, GrantUseValidation{}, ErrStale
|
|
153
|
-
}
|
|
154
|
-
actor, code := s.authority.actor(ctx, carriers, old)
|
|
155
|
-
if code != "" {
|
|
156
|
-
return NativeActor{}, GrantUseValidation{}, code
|
|
157
|
-
}
|
|
158
|
-
g, code := s.authority.grantForActor(actor, r)
|
|
159
|
-
if code != "" {
|
|
160
|
-
return NativeActor{}, GrantUseValidation{}, code
|
|
161
|
-
}
|
|
162
|
-
if s.services.operations == nil {
|
|
163
|
-
return NativeActor{}, GrantUseValidation{}, ErrUnavailable
|
|
164
|
-
}
|
|
165
|
-
proof, code := s.services.operations.ValidateOperation(ctx, actor, r, g)
|
|
166
|
-
if code = nativeObservationCode(ctx, code); code != "" {
|
|
167
|
-
return NativeActor{}, GrantUseValidation{}, code
|
|
168
|
-
}
|
|
169
|
-
actor, code = s.authority.actor(ctx, carriers, &actor)
|
|
170
|
-
if code != "" {
|
|
171
|
-
return NativeActor{}, GrantUseValidation{}, code
|
|
172
|
-
}
|
|
173
|
-
return actor, proof, ""
|
|
174
|
-
}
|
|
175
|
-
func (s *supervisorGrants) ticketLocked(r DataRequest, b TicketBinding, actor NativeActor) Code {
|
|
176
|
-
if b.Inventory != r.Inventory || b.Epoch != r.Epoch || b.SubjectRef != actor.Principal().SubjectRef || b.SessionRef != actor.SessionRef() || b.Action != r.Op || b.GrantID != r.GrantID || b.GrantRevision != r.GrantRevision || b.OperationID != r.OperationID || b.Nonce != r.Nonce || b.Ticket != r.Ticket || b.RequestDigest != r.Digest() {
|
|
177
|
-
return ErrDenied
|
|
178
|
-
}
|
|
179
|
-
now := s.authority.now()
|
|
180
|
-
if !now.Before(b.ExpiresAt) {
|
|
181
|
-
return ErrExpired
|
|
182
|
-
}
|
|
183
|
-
if b.ExpiresAt.Sub(now) > IntentTTL {
|
|
184
|
-
return ErrInvalid
|
|
185
|
-
}
|
|
186
|
-
if s.tickets[r.Ticket] || s.nonces[r.Nonce] || s.streamTickets[r.Ticket] || s.streamNonces[r.Nonce] {
|
|
187
|
-
return ErrReplay
|
|
188
|
-
}
|
|
189
|
-
full := len(s.tickets) >= MaxReplayEntries
|
|
190
|
-
if r.Op == ActionReadStream || r.Op == ActionWriteStream {
|
|
191
|
-
full = len(s.streamTickets) >= MaxStreamReplayEntries
|
|
192
|
-
}
|
|
193
|
-
if full {
|
|
194
|
-
return ErrBusy
|
|
195
|
-
}
|
|
196
|
-
return ""
|
|
197
|
-
}
|
|
198
|
-
func (s *supervisorGrants) burnTicket(r DataRequest) {
|
|
199
|
-
if r.Op == ActionReadStream || r.Op == ActionWriteStream {
|
|
200
|
-
s.streamTickets[r.Ticket] = true
|
|
201
|
-
s.streamNonces[r.Nonce] = true
|
|
202
|
-
return
|
|
203
|
-
}
|
|
204
|
-
s.tickets[r.Ticket] = true
|
|
205
|
-
s.nonces[r.Nonce] = true
|
|
206
|
-
}
|
|
207
|
-
func (s *supervisorGrants) start(ctx context.Context, peer operationPeer, carriers SessionCarriers, r DataRequest) Code {
|
|
208
|
-
if !r.Op.ReadOnly() {
|
|
209
|
-
return s.startWrite(ctx, peer, carriers, r)
|
|
210
|
-
}
|
|
211
|
-
if !s.cohort.peerAllowed(peer) {
|
|
212
|
-
return ErrDenied
|
|
213
|
-
}
|
|
214
|
-
actor, proof, code := s.validate(ctx, carriers, r, nil)
|
|
215
|
-
if code != "" {
|
|
216
|
-
return code
|
|
217
|
-
}
|
|
218
|
-
work, code := readOnlyRequestWork(r, proof.root)
|
|
219
|
-
if code != "" {
|
|
220
|
-
return code
|
|
221
|
-
}
|
|
222
|
-
binding := operationBinding{r.Inventory, r.Epoch, r.OperationID, r.Nonce, r.GrantID, r.GrantRevision}
|
|
223
|
-
var op *cohortOperation
|
|
224
|
-
code = s.authority.WithGrantAdmission(GrantAdmission{actor, r.GrantID, r.GrantRevision, r.Op, proof.Binding, proof.Continuous}, func(g Grant, a NativeActor) Code {
|
|
225
|
-
if ctx.Err() != nil {
|
|
226
|
-
return nativeContextCode(ctx)
|
|
227
|
-
}
|
|
228
|
-
if code := s.ticketLocked(r, proof.Ticket, a); code != "" {
|
|
229
|
-
return code
|
|
230
|
-
}
|
|
231
|
-
var code Code
|
|
232
|
-
op, code = s.cohort.reserveLocked(a, binding)
|
|
233
|
-
if code != "" {
|
|
234
|
-
return code
|
|
235
|
-
}
|
|
236
|
-
op.maxBytes = work.MaxBytes
|
|
237
|
-
op.segments = slices.Clone(work.Segments)
|
|
238
|
-
op.work = work
|
|
239
|
-
op.root = proof.root
|
|
240
|
-
s.burnTicket(r)
|
|
241
|
-
return ""
|
|
242
|
-
})
|
|
243
|
-
if code != "" {
|
|
244
|
-
return code
|
|
245
|
-
}
|
|
246
|
-
return s.cohort.launchReserved(op)
|
|
247
|
-
}
|
|
248
|
-
func (s *supervisorGrants) chunk(ctx context.Context, peer operationPeer, carriers SessionCarriers, r DataRequest) Code {
|
|
249
|
-
if !r.Op.ReadOnly() {
|
|
250
|
-
return s.writeControl(ctx, peer, carriers, r, false)
|
|
251
|
-
}
|
|
252
|
-
if !s.cohort.peerAllowed(peer) {
|
|
253
|
-
return ErrDenied
|
|
254
|
-
}
|
|
255
|
-
op := s.cohort.operations[r.OperationID]
|
|
256
|
-
if op == nil || op.binding.Inventory != r.Inventory || op.binding.Epoch != r.Epoch || op.binding.GrantID != r.GrantID || op.binding.GrantRevision != r.GrantRevision {
|
|
257
|
-
return ErrDenied
|
|
258
|
-
}
|
|
259
|
-
if op.canceled || op.process == nil {
|
|
260
|
-
return ErrCanceled
|
|
261
|
-
}
|
|
262
|
-
if op.expired(s.cohort.now()) {
|
|
263
|
-
op.canceled = true
|
|
264
|
-
op.process.stopRelay()
|
|
265
|
-
return ErrTimeout
|
|
266
|
-
}
|
|
267
|
-
actor, proof, code := s.validate(ctx, carriers, r, &op.actor)
|
|
268
|
-
if code != "" {
|
|
269
|
-
op.canceled = true
|
|
270
|
-
op.process.stopRelay()
|
|
271
|
-
return code
|
|
272
|
-
}
|
|
273
|
-
work, code := readOnlyRequestWork(r, proof.root)
|
|
274
|
-
if code != "" {
|
|
275
|
-
return code
|
|
276
|
-
}
|
|
277
|
-
if (r.Op != ActionRead && r.Op != ActionReadStream) || !sameReadOnlyRequest(op, work, proof.root, false) {
|
|
278
|
-
return ErrDenied
|
|
279
|
-
}
|
|
280
|
-
if work.MaxBytes > MaxChunkBytes {
|
|
281
|
-
return ErrLimit
|
|
282
|
-
}
|
|
283
|
-
if p, ok := op.process.(readOnlyMetadataProcess); ok {
|
|
284
|
-
if code := p.readOnlyLeaseReady(uint32(work.MaxBytes)); code != "" {
|
|
285
|
-
return code
|
|
286
|
-
}
|
|
287
|
-
}
|
|
288
|
-
code = s.authority.WithGrantAdmission(GrantAdmission{actor, r.GrantID, r.GrantRevision, r.Op, proof.Binding, proof.Continuous}, func(g Grant, a NativeActor) Code {
|
|
289
|
-
if ctx.Err() != nil {
|
|
290
|
-
return nativeContextCode(ctx)
|
|
291
|
-
}
|
|
292
|
-
if code := s.ticketLocked(r, proof.Ticket, a); code != "" {
|
|
293
|
-
return code
|
|
294
|
-
}
|
|
295
|
-
if code := s.cohort.reserveChunkLocked(op, a, uint32(work.MaxBytes)); code != "" {
|
|
296
|
-
return code
|
|
297
|
-
}
|
|
298
|
-
s.burnTicket(r)
|
|
299
|
-
return ""
|
|
300
|
-
})
|
|
301
|
-
if code != "" {
|
|
302
|
-
return code
|
|
303
|
-
}
|
|
304
|
-
return s.cohort.deliverChunk(op, uint32(work.MaxBytes))
|
|
305
|
-
}
|
|
306
|
-
|
|
307
|
-
// JSON-only, bounded decoded controls; no credential serialization here.
|
|
308
|
-
func bytesReader(b json.RawMessage) *bytes.Reader { return bytes.NewReader(b) }
|
|
309
|
-
|
|
310
|
-
// Nonblocking metadata polling on the SAME S3 owner/admission/ticket path.
|
|
311
|
-
// Filesystem IO has already run in the actor child; metadata is never published
|
|
312
|
-
// until fresh identity, grant, continuity, action, decoded args and ticket pass.
|
|
313
|
-
func (s *supervisorGrants) result(ctx context.Context, peer operationPeer, carriers SessionCarriers, r DataRequest) (*readOnlyResult, Code) {
|
|
314
|
-
if !s.cohort.peerAllowed(peer) {
|
|
315
|
-
return nil, ErrDenied
|
|
316
|
-
}
|
|
317
|
-
op := s.cohort.operations[r.OperationID]
|
|
318
|
-
if op == nil || op.binding.Inventory != r.Inventory || op.binding.Epoch != r.Epoch || op.binding.GrantID != r.GrantID || op.binding.GrantRevision != r.GrantRevision {
|
|
319
|
-
return nil, ErrDenied
|
|
320
|
-
}
|
|
321
|
-
if op.canceled || op.process == nil {
|
|
322
|
-
return nil, ErrCanceled
|
|
323
|
-
}
|
|
324
|
-
if op.expired(s.cohort.now()) {
|
|
325
|
-
op.canceled = true
|
|
326
|
-
op.process.stopRelay()
|
|
327
|
-
return nil, ErrTimeout
|
|
328
|
-
}
|
|
329
|
-
actor, proof, code := s.validate(ctx, carriers, r, &op.actor)
|
|
330
|
-
if code != "" {
|
|
331
|
-
op.canceled = true
|
|
332
|
-
op.process.stopRelay()
|
|
333
|
-
return nil, code
|
|
334
|
-
}
|
|
335
|
-
work, code := readOnlyRequestWork(r, proof.root)
|
|
336
|
-
if code != "" {
|
|
337
|
-
return nil, code
|
|
338
|
-
}
|
|
339
|
-
if !sameReadOnlyRequest(op, work, proof.root, true) {
|
|
340
|
-
return nil, ErrDenied
|
|
341
|
-
}
|
|
342
|
-
p, ok := op.process.(readOnlyMetadataProcess)
|
|
343
|
-
if !ok {
|
|
344
|
-
return nil, ErrUnavailable
|
|
345
|
-
}
|
|
346
|
-
value, ready, err := p.readOnlyMetadata()
|
|
347
|
-
if err != nil {
|
|
348
|
-
op.canceled = true
|
|
349
|
-
op.process.stopRelay()
|
|
350
|
-
return nil, ErrCleanupRequired
|
|
351
|
-
}
|
|
352
|
-
if !ready {
|
|
353
|
-
return nil, ErrBusy
|
|
354
|
-
}
|
|
355
|
-
var result *readOnlyResult
|
|
356
|
-
code = s.authority.WithGrantAdmission(GrantAdmission{actor, r.GrantID, r.GrantRevision, r.Op, proof.Binding, proof.Continuous}, func(_ Grant, a NativeActor) Code {
|
|
357
|
-
if ctx.Err() != nil {
|
|
358
|
-
return nativeContextCode(ctx)
|
|
359
|
-
}
|
|
360
|
-
if op.canceled {
|
|
361
|
-
return ErrCanceled
|
|
362
|
-
}
|
|
363
|
-
if op.expired(s.cohort.now()) {
|
|
364
|
-
op.canceled = true
|
|
365
|
-
op.process.stopRelay()
|
|
366
|
-
return ErrTimeout
|
|
367
|
-
}
|
|
368
|
-
if code := s.ticketLocked(r, proof.Ticket, a); code != "" {
|
|
369
|
-
return code
|
|
370
|
-
}
|
|
371
|
-
result = cloneReadOnlyResult(value)
|
|
372
|
-
if result == nil {
|
|
373
|
-
return ErrUnavailable
|
|
374
|
-
}
|
|
375
|
-
op.actor = a
|
|
376
|
-
s.burnTicket(r)
|
|
377
|
-
return ""
|
|
378
|
-
})
|
|
379
|
-
if code != "" {
|
|
380
|
-
return nil, code
|
|
381
|
-
}
|
|
382
|
-
// Private completion ACK/IO stays outside grant/policy/admission locks.
|
|
383
|
-
if err := p.releaseReadOnlyMetadata(); err != nil {
|
|
384
|
-
op.canceled = true
|
|
385
|
-
op.process.stopRelay()
|
|
386
|
-
return nil, ErrCleanupRequired
|
|
387
|
-
}
|
|
388
|
-
return result, ""
|
|
389
|
-
}
|
|
@@ -1,239 +0,0 @@
|
|
|
1
|
-
package helper
|
|
2
|
-
|
|
3
|
-
import (
|
|
4
|
-
"context"
|
|
5
|
-
"encoding/json"
|
|
6
|
-
"syscall"
|
|
7
|
-
"testing"
|
|
8
|
-
"time"
|
|
9
|
-
)
|
|
10
|
-
|
|
11
|
-
type grantOperationStub struct {
|
|
12
|
-
after func()
|
|
13
|
-
code Code
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
func (v grantOperationStub) ValidateOperation(_ context.Context, a NativeActor, r DataRequest, g Grant) (GrantUseValidation, Code) {
|
|
17
|
-
if v.after != nil {
|
|
18
|
-
v.after()
|
|
19
|
-
}
|
|
20
|
-
return GrantUseValidation{Binding: g.LastValidated, Continuous: true, Ticket: TicketBinding{Inventory: r.Inventory, Epoch: r.Epoch, SubjectRef: a.Principal().SubjectRef, SessionRef: a.SessionRef(), Action: r.Op, GrantID: r.GrantID, GrantRevision: r.GrantRevision, OperationID: r.OperationID, Nonce: r.Nonce, Ticket: r.Ticket, RequestDigest: r.Digest(), ExpiresAt: a.account.CheckedAt.Add(IntentTTL)}}, v.code
|
|
21
|
-
}
|
|
22
|
-
func grantCohortFixture(t *testing.T) (*supervisorGrants, *memoryGrantRepository, *operationCohort, SessionCarriers, Grant, *[]*operationFixture) {
|
|
23
|
-
t.Helper()
|
|
24
|
-
a, r, p, _, _, consent, carriers, now := grantAuthorityFixture(t)
|
|
25
|
-
gate := newAdmission(Binding{Boot: "boot", Install: "install"})
|
|
26
|
-
gate.observe(gate.binding, 1, true, now)
|
|
27
|
-
children := new([]*operationFixture)
|
|
28
|
-
cohort := newOperationCohort(r.policy.Inventory, r.policy.Epoch, 42, gate, func() bool { return true })
|
|
29
|
-
cohort.now = func() time.Time { return now }
|
|
30
|
-
cohort.startChild = func(NativeActor, operationBinding) (operationProcess, error) {
|
|
31
|
-
child := &operationFixture{childFixture: childFixture{exitOn: syscall.SIGTERM}}
|
|
32
|
-
*children = append(*children, child)
|
|
33
|
-
return child, nil
|
|
34
|
-
}
|
|
35
|
-
runtime, code := newSupervisorGrants(r, cohort, supervisorGrantServices{native: p, consent: consent, operations: grantOperationStub{}})
|
|
36
|
-
if code != "" {
|
|
37
|
-
t.Fatal(code)
|
|
38
|
-
}
|
|
39
|
-
runtime.authority.now = a.now
|
|
40
|
-
grant := confirmGrant(t, runtime.authority, r, carriers, prepareGrant(t, runtime.authority, carriers, ScopePersonal))
|
|
41
|
-
return runtime, r, cohort, carriers, grant, children
|
|
42
|
-
}
|
|
43
|
-
func grantControl(t *testing.T, g Grant, op, nonce, ticket byte, n uint64) DataRequest {
|
|
44
|
-
t.Helper()
|
|
45
|
-
args, _ := json.Marshal(ReadArgs{Segments: []string{"fixture"}, MaxBytes: n})
|
|
46
|
-
return DataRequest{Inventory: g.Inventory, Op: ActionRead, Epoch: g.LastValidated.Epoch, GrantID: g.ID, GrantRevision: g.Revision, OperationID: grantRef(op), Nonce: grantRef(nonce), Ticket: grantRef(ticket), Args: args}
|
|
47
|
-
}
|
|
48
|
-
func TestGrantCohortReservationRevokeAndS2Proof(t *testing.T) {
|
|
49
|
-
runtime, r, c, carriers, g, children := grantCohortFixture(t)
|
|
50
|
-
request := grantControl(t, g, '1', '2', '3', MaxBoundedBytes)
|
|
51
|
-
if code := runtime.start(context.Background(), operationPeer{42, 0}, carriers, request); code != "" {
|
|
52
|
-
t.Fatal(code)
|
|
53
|
-
}
|
|
54
|
-
chunk := grantControl(t, g, '1', '4', '5', MaxChunkBytes)
|
|
55
|
-
if code := runtime.chunk(context.Background(), operationPeer{42, 0}, carriers, chunk); code != "" {
|
|
56
|
-
t.Fatal(code)
|
|
57
|
-
}
|
|
58
|
-
result, code := runtime.authority.Revoke(context.Background(), carriers, g.ID, 1, r.store.Revision)
|
|
59
|
-
if code != "" || !result.Revoked || !result.Drained || !(*children)[0].reaped || len(c.operations) != 0 {
|
|
60
|
-
t.Fatal(result, code)
|
|
61
|
-
}
|
|
62
|
-
if r.q.Cohort == nil || r.q.Cohort.Started != 1 || r.q.Cohort.Reaped != 1 || r.q.Cohort.AdmittedBytes != MaxChunkBytes {
|
|
63
|
-
t.Fatal("Q did not carry S2 proof", r.q)
|
|
64
|
-
}
|
|
65
|
-
if code := runtime.chunk(context.Background(), operationPeer{42, 0}, carriers, grantControl(t, g, '1', '6', '7', 1)); code == "" {
|
|
66
|
-
t.Fatal("lease after R")
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
func TestGrantCohortSharedFenceAndNoBootstrapInDiskLocks(t *testing.T) {
|
|
70
|
-
runtime, repo, cohort, carriers, g, children := grantCohortFixture(t)
|
|
71
|
-
if runtime.authority.mu != &cohort.gate.mu {
|
|
72
|
-
t.Fatal("independent ordering mutex")
|
|
73
|
-
}
|
|
74
|
-
original := cohort.startChild
|
|
75
|
-
cohort.startChild = func(a NativeActor, b operationBinding) (operationProcess, error) {
|
|
76
|
-
if repo.inTransaction {
|
|
77
|
-
t.Fatal("bootstrap while disk locks held")
|
|
78
|
-
}
|
|
79
|
-
cohort.gate.fence("during-bootstrap")
|
|
80
|
-
return original(a, b)
|
|
81
|
-
}
|
|
82
|
-
if code := runtime.start(context.Background(), operationPeer{42, 0}, carriers, grantControl(t, g, '1', '2', '3', 1)); code != ErrFenced {
|
|
83
|
-
t.Fatal(code)
|
|
84
|
-
}
|
|
85
|
-
if len(*children) != 1 || !(*children)[0].stopped || len((*children)[0].signals) != 0 {
|
|
86
|
-
t.Fatal("lost owned child or signalled before durable fence")
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
}
|
|
90
|
-
func TestGrantCohortPeerTicketAndGrantChecks(t *testing.T) {
|
|
91
|
-
for _, kind := range []string{"peer", "uid", "revision", "suspended", "fence", "ticket", "nil-validator", "replay"} {
|
|
92
|
-
t.Run(kind, func(t *testing.T) {
|
|
93
|
-
runtime, r, c, carriers, g, children := grantCohortFixture(t)
|
|
94
|
-
request := grantControl(t, g, '1', '2', '3', 1)
|
|
95
|
-
peer := operationPeer{42, 0}
|
|
96
|
-
switch kind {
|
|
97
|
-
case "peer":
|
|
98
|
-
peer.PID++
|
|
99
|
-
case "uid":
|
|
100
|
-
peer.UID++
|
|
101
|
-
case "revision":
|
|
102
|
-
request.GrantRevision++
|
|
103
|
-
case "suspended":
|
|
104
|
-
r.store.Grants[0].State = GrantSuspended
|
|
105
|
-
r.store.Grants[0].Reason = ErrSuspended
|
|
106
|
-
case "fence":
|
|
107
|
-
c.gate.fence("test")
|
|
108
|
-
case "ticket":
|
|
109
|
-
runtime.services.operations = grantOperationStub{code: ErrDenied}
|
|
110
|
-
case "nil-validator":
|
|
111
|
-
runtime.services.operations = nil
|
|
112
|
-
case "replay":
|
|
113
|
-
if code := runtime.start(context.Background(), peer, carriers, request); code != "" {
|
|
114
|
-
t.Fatal(code)
|
|
115
|
-
}
|
|
116
|
-
}
|
|
117
|
-
before := len(*children)
|
|
118
|
-
if code := runtime.start(context.Background(), peer, carriers, request); code == "" || len(*children) != before {
|
|
119
|
-
t.Fatal("invalid reservation launched", kind, code)
|
|
120
|
-
}
|
|
121
|
-
})
|
|
122
|
-
}
|
|
123
|
-
}
|
|
124
|
-
func TestGrantCohortChunkRevalidatesGrantAndTicket(t *testing.T) {
|
|
125
|
-
runtime, r, c, carriers, g, children := grantCohortFixture(t)
|
|
126
|
-
if code := runtime.start(context.Background(), operationPeer{42, 0}, carriers, grantControl(t, g, '1', '2', '3', 10)); code != "" {
|
|
127
|
-
t.Fatal(code)
|
|
128
|
-
}
|
|
129
|
-
if code := runtime.chunk(context.Background(), operationPeer{42, 0}, carriers, grantControl(t, g, '1', '4', '5', 11)); code != ErrLimit {
|
|
130
|
-
t.Fatal("requested byte ceiling", code)
|
|
131
|
-
}
|
|
132
|
-
chunk := grantControl(t, g, '1', '6', '7', 1)
|
|
133
|
-
if code := runtime.chunk(context.Background(), operationPeer{42, 0}, carriers, chunk); code != "" {
|
|
134
|
-
t.Fatal(code)
|
|
135
|
-
}
|
|
136
|
-
if code := runtime.chunk(context.Background(), operationPeer{42, 0}, carriers, chunk); code != ErrReplay {
|
|
137
|
-
t.Fatal("ticket replay", code)
|
|
138
|
-
}
|
|
139
|
-
(*children)[0].pending = false
|
|
140
|
-
r.store.Grants[0].State = GrantRevoked
|
|
141
|
-
r.store.Grants[0].Reason = ErrRevoked
|
|
142
|
-
r.store.Grants[0].RevokedAt = g.CreatedAt
|
|
143
|
-
r.store.Grants[0].Revision++
|
|
144
|
-
if code := runtime.chunk(context.Background(), operationPeer{42, 0}, carriers, grantControl(t, g, '1', '8', '9', 1)); code != ErrRevoked {
|
|
145
|
-
t.Fatal(code)
|
|
146
|
-
}
|
|
147
|
-
if err := c.cancelGrant(context.Background(), g.ID, 2); err != nil {
|
|
148
|
-
t.Fatal(err)
|
|
149
|
-
}
|
|
150
|
-
}
|
|
151
|
-
func TestGrantCohortNoQForUnknownChildOrRelay(t *testing.T) {
|
|
152
|
-
for _, kind := range []string{"child", "relay"} {
|
|
153
|
-
t.Run(kind, func(t *testing.T) {
|
|
154
|
-
runtime, r, _, carriers, g, children := grantCohortFixture(t)
|
|
155
|
-
if code := runtime.start(context.Background(), operationPeer{42, 0}, carriers, grantControl(t, g, '1', '2', '3', 1)); code != "" {
|
|
156
|
-
t.Fatal(code)
|
|
157
|
-
}
|
|
158
|
-
if kind == "child" {
|
|
159
|
-
(*children)[0].err = syscall.ECHILD
|
|
160
|
-
} else {
|
|
161
|
-
(*children)[0].stuck = true
|
|
162
|
-
(*children)[0].pending = true
|
|
163
|
-
}
|
|
164
|
-
ctx, cancel := context.WithTimeout(context.Background(), 20*time.Millisecond)
|
|
165
|
-
defer cancel()
|
|
166
|
-
result, code := runtime.authority.Revoke(ctx, carriers, g.ID, 1, r.store.Revision)
|
|
167
|
-
if code != ErrCleanupRequired || !result.Revoked || result.Drained {
|
|
168
|
-
t.Fatal("false Q", result, code)
|
|
169
|
-
}
|
|
170
|
-
if kind == "child" && len((*children)[0].signals) != 0 {
|
|
171
|
-
t.Fatal("foreign signal")
|
|
172
|
-
}
|
|
173
|
-
})
|
|
174
|
-
}
|
|
175
|
-
}
|
|
176
|
-
|
|
177
|
-
func TestGrantCohortRejectsInvalidReceipt(t *testing.T) {
|
|
178
|
-
key := GrantDrainKey{grantRef('e'), grantRef('f'), 2}
|
|
179
|
-
q := completeGrantProof(key)
|
|
180
|
-
q.Cohort = &GrantDrainProof{Key: key, Started: 1, Reaped: 0}
|
|
181
|
-
if completeQuiescence(q) {
|
|
182
|
-
t.Fatal("unreaped child accepted")
|
|
183
|
-
}
|
|
184
|
-
q.Cohort.Reaped = 1
|
|
185
|
-
q.Cohort.Key.Revision++
|
|
186
|
-
if completeQuiescence(q) {
|
|
187
|
-
t.Fatal("foreign receipt accepted")
|
|
188
|
-
}
|
|
189
|
-
}
|
|
190
|
-
|
|
191
|
-
type alteredGrantTicket struct{ grantOperationStub }
|
|
192
|
-
|
|
193
|
-
func (v alteredGrantTicket) ValidateOperation(ctx context.Context, a NativeActor, r DataRequest, g Grant) (GrantUseValidation, Code) {
|
|
194
|
-
p, c := v.grantOperationStub.ValidateOperation(ctx, a, r, g)
|
|
195
|
-
p.Ticket.RequestDigest = grantRef('f')
|
|
196
|
-
return p, c
|
|
197
|
-
}
|
|
198
|
-
func TestGrantCohortBindsCompleteTicketDigest(t *testing.T) {
|
|
199
|
-
s, _, _, carriers, g, children := grantCohortFixture(t)
|
|
200
|
-
s.services.operations = alteredGrantTicket{}
|
|
201
|
-
if code := s.start(context.Background(), operationPeer{42, 0}, carriers, grantControl(t, g, '1', '2', '3', 1)); code != ErrDenied || len(*children) != 0 {
|
|
202
|
-
t.Fatal("substituted control ticket", code)
|
|
203
|
-
}
|
|
204
|
-
}
|
|
205
|
-
|
|
206
|
-
func TestReloadSuspensionBlocksGrantAndCohortWithoutRevokingEpoch(t *testing.T) {
|
|
207
|
-
runtime, repo, c, carriers, g, children := grantCohortFixture(t)
|
|
208
|
-
now := c.now()
|
|
209
|
-
c.gate.requestUnitCheck(true, now)
|
|
210
|
-
commits := repo.commits
|
|
211
|
-
c.gate.mu.Lock()
|
|
212
|
-
code := runtime.authority.transaction(func(*GrantStore) (bool, Code) { t.Fatal("disk transaction during suspension"); return true, "" })
|
|
213
|
-
c.gate.mu.Unlock()
|
|
214
|
-
if code != ErrFenced || runtime.authority.fenced || c.fenced || repo.commits != commits {
|
|
215
|
-
t.Fatal("suspension permanently revoked authority")
|
|
216
|
-
}
|
|
217
|
-
if code = c.start(context.Background(), operationPeer{42, 0}, runtime.authority.native, carriers, NativeActor{}, operationBinding{}); code == "" {
|
|
218
|
-
t.Fatal("start admitted during suspension")
|
|
219
|
-
}
|
|
220
|
-
c.gate.mu.Lock()
|
|
221
|
-
allowed := c.allowed()
|
|
222
|
-
c.gate.mu.Unlock()
|
|
223
|
-
if allowed || len(*children) != 0 {
|
|
224
|
-
t.Fatal("cohort bypassed suspension")
|
|
225
|
-
}
|
|
226
|
-
c.gate.requestUnitCheck(false, now)
|
|
227
|
-
serial, _ := c.gate.unitProbe(now)
|
|
228
|
-
c.gate.observeUnit(c.gate.binding, 1, "", false, true, serial, now)
|
|
229
|
-
if code = runtime.start(context.Background(), operationPeer{42, 0}, carriers, grantControl(t, g, '1', '2', '3', 1)); code != "" || len(*children) != 1 {
|
|
230
|
-
t.Fatal("verified reload could not resume original grant/epoch", code)
|
|
231
|
-
}
|
|
232
|
-
c.gate.fence("unit-stopped")
|
|
233
|
-
c.gate.mu.Lock()
|
|
234
|
-
code = runtime.authority.transaction(func(*GrantStore) (bool, Code) { return false, "" })
|
|
235
|
-
c.gate.mu.Unlock()
|
|
236
|
-
if code != ErrFenced || !runtime.authority.fenced {
|
|
237
|
-
t.Fatal("real stop did not permanently fence authority")
|
|
238
|
-
}
|
|
239
|
-
}
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
package helper
|
|
2
|
-
|
|
3
|
-
import (
|
|
4
|
-
"io"
|
|
5
|
-
"net"
|
|
6
|
-
"sync"
|
|
7
|
-
"time"
|
|
8
|
-
)
|
|
9
|
-
|
|
10
|
-
// Private epoch-owned delivery state. These are not RPCs, identity providers,
|
|
11
|
-
// or admission authority. Only a trusted native/ACL validator may issue tickets;
|
|
12
|
-
// the S3 owner still consumes its replay window at the common admission order.
|
|
13
|
-
// Missing DSM proof must not be replaced with these delivery bindings.
|
|
14
|
-
type operationTickets struct {
|
|
15
|
-
writes writeGates
|
|
16
|
-
mu sync.Mutex
|
|
17
|
-
inventory Inventory
|
|
18
|
-
epoch string
|
|
19
|
-
now func() time.Time
|
|
20
|
-
random io.Reader
|
|
21
|
-
issued map[string]issuedOperationTicket
|
|
22
|
-
closed bool
|
|
23
|
-
streamIssued int
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
type issuedOperationTicket struct {
|
|
27
|
-
binding TicketBinding
|
|
28
|
-
principal Principal
|
|
29
|
-
used bool
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
// outputHandoff transfers an already authenticated, owned transport to the S2
|
|
33
|
-
// relay exactly once. It never dials a caller address or publishes data itself.
|
|
34
|
-
// The registering transport owns peer authentication and disconnect observation.
|
|
35
|
-
type outputHandoff struct {
|
|
36
|
-
mu sync.Mutex
|
|
37
|
-
inventory Inventory
|
|
38
|
-
epoch string
|
|
39
|
-
now func() time.Time
|
|
40
|
-
entries map[string]operationOutput
|
|
41
|
-
closed bool
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
type operationOutput struct {
|
|
45
|
-
binding operationBinding
|
|
46
|
-
conn net.Conn
|
|
47
|
-
expires time.Time
|
|
48
|
-
taken bool
|
|
49
|
-
}
|