Files
Heimdall/skills/camera-access-groups/SKILL.md
T
arnaud.dartois f20ec93f6f
Heimdall Gitea / Detect CI scope (push) Successful in 5s
Heimdall Gitea / Build and tests (push) Skipped
Heimdall Gitea / Build and scan server image (push) Skipped
Heimdall Gitea / Build and scan agent image (push) Skipped
Heimdall Gitea / Build and scan NVIDIA Agent image (push) Skipped
Heimdall Gitea / Publish versioned installer release (push) Skipped
Heimdall Gitea / CI policy (push) Successful in 1s
docs: align auth guide with current camera access (#368)
Co-authored-by: Arnaud Dartois <admin@tordais.cc>
2026-11-13 10:34:53 +01:00

2.3 KiB

name, description
name description
camera-access-groups Implement and validate Heimdall user-to-camera grants and group camera access through the administration UI and API.

Camera access and groups

Camera visibility is the union of direct camera grants, site-wide grants, legacy user site assignments, and cameras granted to groups the user belongs to. Keep that union in CameraAccessService and ResourceAccess; do not reimplement partial scope rules in controllers or UI queries. Site and camera resource checks must continue to run at API/application boundaries, including snapshots, events, hubs, and agent assignment.

When editing authorization examples in docs/auth-roles.md, verify routes against the actual controller mappings and explain the query/service-level access filtering. Human JWTs carry role/permission and session claims, not a frozen list of site IDs; do not describe a global SiteScopeMiddleware unless one is implemented.

Manage group-camera membership through the authenticated api/groups/{groupId}/cameras endpoints. The administration page loads all sites and their cameras with bounded paging, displays site names beside cameras, and adds/removes grants through the API. Treat failed loads and mutations as errors; do not optimistically report success.

When changing this area, verify:

  • ResourceAccessTests for the role/grant matrix, live group membership revocation, and union of direct plus group grants.
  • HttpIsolationTests and the affected API integration tests for real HTTP authorization outcomes.
  • GroupsPageTests for site/camera labels and the UI add/remove request sequence.
  • PostgreSQL integration tests for persistence or query changes; do not use EF InMemory as relational proof.
  • The disposable Compose recipe in skills/compose-disposable-recipe/SKILL.md for behavior or deployment changes, using a unique project, network, credentials, ports, and volumes.
  • If Compose builds Central from source, record a project-unique tag and install an EXIT cleanup trap before build/start. After teardown remove and verify absence of that exact tag even on failure; retain shared base images and report cleanup errors.

Use synthetic camera metadata in automated tests. Physical RTSP, snapshot and reconnect behavior is a separate Agent/camera acceptance and must be reported as unverified unless run against real hardware.