Two observations from browser-verifying the ADR-0090 showcase permission zoo (fresh `objectstack dev` boot, 2 private notes exist — one owned by admin, one by a plain member):
1. `total` vs `records` mismatch — count not scoped (leak)
`GET /api/v1/data/showcase_private_note` as the plain member returns `{"total": 2, "records": [<their own 1 note>]}` — the OWD/RLS read filter is applied to the rows but NOT to the count. A principal can enumerate how many records exist beyond their visibility (row-count oracle), and pagination math is wrong. Expected: `total: 1`.
Inconsistently, the ADMIN's request returns `total: 1` (scoped to own) — so the count path applies a filter for one principal shape and not the other.
2. Platform admin's `'*'` wildcard `viewAllRecords` does not widen private-object list reads
The seeded platform admin (`admin_full_access`: `objects['*'].viewAllRecords: true`, superuser) sees ONLY their own private notes (1), while a user holding a set with object-level `viewAllRecords` on `showcase_private_note` (`showcase_auditor`) correctly sees all (2). If ADR-0066's superuser-wildcard semantics are meant to include read-widening, the sharing read-filter builder is ignoring wildcard VAMA; if the narrower behavior is intended (explicit per-object VAMA only), it should be documented — today the admin sees strictly less than an auditor, which surprises.
Repro: examples/app-showcase zoo — `showcase_auditor` vs the seeded dev admin over `/api/v1/data/showcase_private_note`.
Two observations from browser-verifying the ADR-0090 showcase permission zoo (fresh `objectstack dev` boot, 2 private notes exist — one owned by admin, one by a plain member):
1. `total` vs `records` mismatch — count not scoped (leak)
`GET /api/v1/data/showcase_private_note` as the plain member returns `{"total": 2, "records": [<their own 1 note>]}` — the OWD/RLS read filter is applied to the rows but NOT to the count. A principal can enumerate how many records exist beyond their visibility (row-count oracle), and pagination math is wrong. Expected: `total: 1`.
Inconsistently, the ADMIN's request returns `total: 1` (scoped to own) — so the count path applies a filter for one principal shape and not the other.
2. Platform admin's `'*'` wildcard `viewAllRecords` does not widen private-object list reads
The seeded platform admin (`admin_full_access`: `objects['*'].viewAllRecords: true`, superuser) sees ONLY their own private notes (1), while a user holding a set with object-level `viewAllRecords` on `showcase_private_note` (`showcase_auditor`) correctly sees all (2). If ADR-0066's superuser-wildcard semantics are meant to include read-widening, the sharing read-filter builder is ignoring wildcard VAMA; if the narrower behavior is intended (explicit per-object VAMA only), it should be documented — today the admin sees strictly less than an auditor, which surprises.
Repro: examples/app-showcase zoo — `showcase_auditor` vs the seeded dev admin over `/api/v1/data/showcase_private_note`.