hsiegeln 34186518ce
All checks were successful
CI / cleanup-branch (push) Has been skipped
CI / build (push) Successful in 3m46s
CI / docker (push) Successful in 4m2s
CI / deploy (push) Successful in 1m0s
CI / deploy-feature (push) Has been skipped
fix(auth): allow VIEWER+ to list environments for the SPA env switcher
The SPA's env switcher calls GET /api/v1/admin/environments for every
authenticated user, not just admins. The URL-level /api/v1/admin/** ADMIN
matcher in SecurityConfig was shadowing the controller's intentional
@PreAuthorize("isAuthenticated()") override on listEnvironments(), so
OPERATOR and VIEWER got 403 and could not pick an env after login.

Add a more specific matcher for GET on the collection only — per-env
GET/PUT/DELETE stay ADMIN-locked under the catch-all. Regression tests in
SecurityFilterIT cover viewer/operator/admin → 200, no-JWT → 401/403,
and per-env GET as OPERATOR → 403 to guard against an over-broad widening.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-29 08:53:17 +02:00
2026-04-15 15:28:42 +02:00
Description
Observability server for Cameleer agents
27 MiB
Languages
Java 64.3%
TypeScript 28.1%
HTML 4.8%
CSS 2.7%