HomeRules
Rule reference

Twelve deterministic checks for migration-time tenant boundaries.

Each BoundaryCI rule has a narrow, reviewable condition. Findings include the final-state evidence, migration location, severity, and a specific remediation.

Rule reference

BND001high

Exposed table does not enable row-level security

Finds tables in an exposed schema when no ENABLE ROW LEVEL SECURITY statement remains in the final migration state.

Read rule
BND002medium

RLS-enabled table has no policies

Finds RLS-protected tables with no remaining policy, which normally denies client access and often signals an incomplete migration.

Read rule
BND003critical

Public policy grants unrestricted row access

Finds unconditional USING (true) or WITH CHECK (true) policies granted to anon or PUBLIC callers.

Read rule
BND004high

Authenticated policy is not tenant-scoped

Finds unconditional policies that authorize every signed-in user without proving membership in the active tenant.

Read rule
BND005high

SECURITY DEFINER function has an unpinned search path

Finds privileged PostgreSQL functions that do not pin search_path to trusted schemas and schema-qualify referenced objects.

Read rule
BND006high

SECURITY DEFINER function remains executable by PUBLIC

Finds privileged functions where migration history never revokes PostgreSQL's default PUBLIC execute privilege.

Read rule
BND007high

Exposed view may bypass underlying row-level security

Finds views in exposed schemas that do not use security_invoker and may apply the view creator's privileges instead of the caller's.

Read rule
BND008high

RLS policy trusts user-editable authentication metadata

Finds authorization expressions that trust user_metadata or raw_user_meta_data, which users can modify through authentication APIs.

Read rule
BND009high

Materialized view is exposed to API roles

Finds materialized views that store query results in exposed schemas and remain selectable by anonymous or authenticated API callers.

Read rule
BND010high

Foreign table is exposed to API roles

Finds foreign tables that make external data sources reachable through an exposed Supabase Data API schema.

Read rule
BND011medium

Default privileges automatically expose future objects

Finds ALTER DEFAULT PRIVILEGES grants that give API roles automatic access to future relations or functions.

Read rule
BND012high

SECURITY DEFINER function is executable by API roles

Finds privileged functions in exposed schemas that remain directly executable by anon or authenticated after PUBLIC execution is revoked.

Read rule

What deterministic means

These rules do not ask a model to decide whether a pull request passes. The same ordered migrations and configuration produce the same finding set. Optional semantic review remains advisory unless a team explicitly changes that behavior.

Rules evaluate final migration state

BoundaryCI accounts for later policy changes, relation drops, function replacements, object grants, revokes, and default privileges. This avoids reporting a dangerous statement that a later migration already removed while still catching a safe object that was later exposed.

Protect the boundary

Make tenant isolation a repeatable pull-request check.

Run the deterministic scanner locally without database credentials, then add Cloud only when your team needs shared history.

Run the deterministic checks Read the quickstart