yau-plant-assistant/db
Claude 12439fa387 Close two Phase 1 gate failures found on lin001
agent_ro could still create temporary tables: Postgres grants TEMP on every
database to PUBLIC, and revoking it from the role alone does not remove what
PUBLIC grants. Revoke it from PUBLIC too. postgres is a superuser and keeps
its temp tables, so the seed load is unaffected.

Nothing but the superuser could read schema fixture: 003_roles.sql grants only
on schema public, and the fixture schema is created afterwards. Grant read to
agent_ro and cube_rw. The grants live in 002_fixtures.sql because that file
opens with DROP SCHEMA fixture CASCADE, which would destroy grants held
anywhere else on every fixture reload.

Both re-verified on pg-ai: 11/11 privilege tests and 10/10 fixture access
tests pass, reads work for both roles, writes are rejected for both.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-20 15:02:51 +10:00
..
seed Scaffold the WRPS plant operations assistant repository 2026-08-20 13:56:32 +10:00
001_schema.sql Scaffold the WRPS plant operations assistant repository 2026-08-20 13:56:32 +10:00
002_fixtures.sql Close two Phase 1 gate failures found on lin001 2026-08-20 15:02:51 +10:00
003_roles.sql Close two Phase 1 gate failures found on lin001 2026-08-20 15:02:51 +10:00