fix(site): retain state when controller inventory is scope-filtered #7

Merged
Andreas merged 1 commit from test/site-permissions into main 2026-10-02 13:48:40 +00:00
Owner

The isolated permission test reproduced a real unsafe absence classification: an existing site hidden from a scoped account was returned as ErrSiteNotFound. Require confirmed /users/current privilege.all=true before treating a complete inventory absence as deletion; unknown/scoped/denied visibility retains state with an error.

Adds client scope regressions and both-engine acceptance proving the existing binding survives permission-filtered inventory and visibility restoration without another create. Generated resource documentation updated. Candidate version advances to 0.13.1-homelab.3, with no production publication/deployment.

Adds opt-in exact-controller restricted-account proof using synthetic custom roles. Metadata role permits only globalDashboard=2, siteNetwork=2, devices=1; returned privileges are checked against the requested map. User/role inventories are denied. Both engines perform full provider lifecycle under the restricted account. A view-only role cannot create/update/delete; a primary-only account cannot falsely classify a hidden existing site as deleted. All accounts/roles remain inside the network-none disposable controller, with no production credentials/backend.

Local full Terraform mock suite, exact deployed OpenTofu site acceptance, generated docs, vet and lint pass. Isolated proof evidence/limits are in SITE_BOOTSTRAP_PROOF.md. This proves a narrow site role, not all-root/Open API permissions or a mathematically minimal permission set. Production ownership is unchanged. Follow-up for issue #3.

The isolated permission test reproduced a real unsafe absence classification: an existing site hidden from a scoped account was returned as ErrSiteNotFound. Require confirmed /users/current privilege.all=true before treating a complete inventory absence as deletion; unknown/scoped/denied visibility retains state with an error. Adds client scope regressions and both-engine acceptance proving the existing binding survives permission-filtered inventory and visibility restoration without another create. Generated resource documentation updated. Candidate version advances to 0.13.1-homelab.3, with no production publication/deployment. Adds opt-in exact-controller restricted-account proof using synthetic custom roles. Metadata role permits only globalDashboard=2, siteNetwork=2, devices=1; returned privileges are checked against the requested map. User/role inventories are denied. Both engines perform full provider lifecycle under the restricted account. A view-only role cannot create/update/delete; a primary-only account cannot falsely classify a hidden existing site as deleted. All accounts/roles remain inside the network-none disposable controller, with no production credentials/backend. Local full Terraform mock suite, exact deployed OpenTofu site acceptance, generated docs, vet and lint pass. Isolated proof evidence/limits are in SITE_BOOTSTRAP_PROOF.md. This proves a narrow site role, not all-root/Open API permissions or a mathematically minimal permission set. Production ownership is unchanged. Follow-up for issue #3.
fix(site): retain state when controller inventory is scope-filtered
All checks were successful
Validate and package Omada provider / provider (pull_request) Successful in 3m53s
Validate and package Omada provider / provider (push) Successful in 3m49s
c82a916784
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
Andreas/terraform-provider-omada!7
No description provided.