Garry Tan and Claude Opus 4.8
b19eb35548
fix(security): schema-lint hardening migration (search_path + view security_invoker)
...
Migration v120 brings existing brains to the same posture as fresh installs:
- ALTER VIEW page_links SET (security_invoker = on) on Postgres so the view
honors the caller's RLS instead of the owner's (the view-through-RLS bypass).
- ALTER FUNCTION ... SET search_path on the gbrain-owned trigger/event functions
(both engines, IF EXISTS so engine-only functions are skipped; body untouched,
so the load-bearing auto_enable_rls event trigger is unchanged). Closes #171 .
- Broaden the BYPASSRLS preflight in the historical RLS migration gates to honor
superuser and inherited-role BYPASSRLS, so a superuser-connected fresh install
no longer aborts (#1385 ).
Fresh-install function definitions in schema.sql / pglite-schema.ts are
born-correct (regenerated schema-embedded.ts). scripts/check-search-path.sh is a
new CI guard (wired into verify) that fails if a trigger function in the schema
base files is added without SET search_path. Postgres-only assertions live in the
bootstrap E2E; the PGLite path is covered by test/migration-v120.test.ts.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com >
2026-06-24 15:38:45 -07:00
..
2026-04-18 16:57:38 +08:00
2026-04-09 10:17:13 -07:00
2026-05-07 21:52:58 -07:00
2026-05-06 21:14:34 -07:00
2026-05-09 22:58:19 -07:00
2026-06-21 06:36:43 -07:00
2026-05-24 11:37:03 -07:00
2026-05-07 21:52:58 -07:00
2026-05-22 11:53:11 -07:00
2026-05-27 08:50:53 -07:00
2026-05-23 08:49:28 -07:00
2026-05-06 21:14:34 -07:00
2026-05-11 22:54:35 -07:00
2026-04-29 23:46:36 -07:00
2026-05-14 19:50:50 -04:00
2026-05-24 09:30:57 -07:00
2026-06-03 06:43:11 -07:00
2026-05-23 08:49:28 -07:00
2026-06-03 15:24:00 -07:00
2026-05-23 08:49:28 -07:00
2026-05-26 17:31:48 -07:00
2026-05-10 20:06:31 -07:00
2026-05-09 16:57:47 -07:00
2026-05-07 21:52:58 -07:00
2026-06-01 22:01:14 -07:00
2026-06-03 08:59:39 -07:00
2026-05-09 16:57:47 -07:00
2026-04-30 01:23:29 -07:00
2026-06-03 15:24:00 -07:00
2026-05-09 16:57:47 -07:00
2026-05-08 17:07:51 -07:00
2026-05-25 10:39:09 -07:00
2026-05-30 10:30:56 -07:00
2026-05-14 21:22:10 -07:00
2026-05-18 21:26:12 -07:00
2026-05-18 21:26:12 -07:00
2026-05-07 21:52:58 -07:00
2026-06-16 22:32:38 -07:00
2026-06-01 22:13:19 -07:00
2026-05-01 09:02:43 -07:00
2026-05-17 08:32:03 -07:00
2026-05-24 21:50:08 -07:00
2026-05-18 21:26:12 -07:00
2026-05-10 06:34:40 -07:00
2026-05-25 15:10:23 -07:00
2026-05-09 16:57:47 -07:00
2026-05-09 16:57:47 -07:00
2026-05-11 19:25:48 -07:00
2026-05-10 12:49:14 -07:00
2026-05-09 16:57:47 -07:00
2026-05-09 16:57:47 -07:00
2026-05-24 11:37:03 -07:00
2026-04-26 20:45:05 -07:00
2026-06-02 16:33:06 -07:00
2026-05-14 19:13:14 -07:00
2026-05-23 10:01:08 -07:00
2026-05-23 10:01:08 -07:00
2026-06-14 09:32:58 -07:00
2026-05-09 16:57:47 -07:00
2026-05-25 14:43:12 -07:00
2026-06-03 15:24:00 -07:00
2026-05-21 18:57:05 -07:00
2026-05-11 23:02:03 -07:00
2026-05-24 11:37:03 -07:00
2026-06-10 22:00:36 -07:00
2026-05-09 16:57:47 -07:00
2026-05-22 21:04:30 -07:00
2026-05-07 21:52:58 -07:00
2026-04-08 23:26:11 -10:00
2026-05-25 12:48:55 -07:00
2026-05-09 16:57:47 -07:00
2026-05-09 20:46:34 -07:00
2026-05-09 16:57:47 -07:00
2026-05-10 12:49:14 -07:00
2026-05-10 12:49:14 -07:00
2026-05-24 11:37:03 -07:00
2026-05-09 16:57:47 -07:00
2026-05-24 11:37:03 -07:00
2026-05-24 11:37:03 -07:00
2026-05-24 11:37:03 -07:00
2026-06-21 06:36:43 -07:00
2026-05-24 11:37:03 -07:00
2026-05-19 13:12:40 -07:00
2026-05-09 16:57:47 -07:00
2026-05-22 21:04:30 -07:00
2026-05-07 21:52:58 -07:00
2026-05-22 13:38:07 -07:00
2026-05-09 16:57:47 -07:00
2026-06-03 07:09:20 -07:00
2026-05-31 08:20:25 -07:00
2026-05-11 21:49:57 -07:00
2026-05-11 21:49:57 -07:00
2026-04-23 19:34:27 -07:00
2026-05-25 14:56:38 -07:00
2026-06-14 09:32:58 -07:00
2026-06-12 07:28:13 -07:00
2026-05-23 10:21:59 -07:00
2026-06-24 15:38:45 -07:00
2026-06-03 08:59:39 -07:00
2026-05-09 16:57:47 -07:00
2026-06-03 08:42:25 -07:00
2026-06-01 23:03:09 -07:00
2026-05-07 21:52:58 -07:00
2026-05-07 21:52:58 -07:00
2026-05-22 13:38:07 -07:00
2026-05-20 09:19:18 -07:00
2026-06-03 06:28:21 -07:00
2026-04-22 01:34:22 -07:00
2026-04-30 23:17:54 -07:00
2026-06-03 06:20:03 -07:00
2026-06-03 06:20:03 -07:00
2026-05-22 21:18:09 -07:00
2026-05-09 16:57:47 -07:00
2026-05-18 20:55:57 -07:00
2026-06-03 15:24:00 -07:00
2026-05-20 13:55:12 -07:00
2026-06-03 05:50:21 -07:00
2026-05-31 08:20:25 -07:00
2026-05-18 12:53:01 -07:00
2026-05-19 18:12:01 -07:00
2026-05-09 16:57:47 -07:00
2026-05-14 20:15:29 -07:00
2026-05-14 19:50:50 -04:00
2026-05-09 16:57:47 -07:00
2026-06-21 06:36:43 -07:00
2026-04-29 22:21:07 -07:00
2026-05-22 09:10:20 -07:00
2026-05-22 09:10:20 -07:00
2026-05-14 19:50:50 -04:00
2026-05-11 22:54:35 -07:00
2026-05-25 14:43:12 -07:00
2026-06-03 15:24:00 -07:00
2026-05-26 16:58:18 -07:00
2026-05-30 10:30:56 -07:00
2026-06-07 19:22:33 -07:00
2026-05-11 19:25:48 -07:00
2026-05-07 23:07:00 -07:00
2026-05-07 23:07:00 -07:00
2026-05-10 06:34:40 -07:00
2026-05-22 13:38:07 -07:00
2026-05-22 22:37:15 -07:00
2026-05-27 07:01:28 -07:00
2026-04-09 12:25:04 -10:00
2026-05-21 22:11:00 -07:00
2026-05-07 21:52:58 -07:00
2026-05-09 20:46:34 -07:00
2026-05-19 17:14:53 -07:00
2026-06-14 09:32:58 -07:00
2026-05-24 11:37:03 -07:00
2026-05-12 14:33:29 -07:00
2026-04-26 15:49:48 -07:00
2026-05-17 08:00:29 -07:00
2026-05-24 11:37:03 -07:00