postgres-rls-pattern

Pass

Audited by Gen Agent Trust Hub on Sep 11, 2026

Risk Level: SAFE
Full Analysis
  • [SAFE]: The skill implements database security best practices by enforcing tenant isolation at the storage layer using Postgres Row Level Security (RLS), which provides a robust guardrail against accidental cross-tenant data access.\n- [SAFE]: SQL parameterization is handled securely using tagged template literals from the 'postgres' library (e.g., txSELECT set_config(..., ${orgId}, true)), which effectively prevents SQL injection vulnerabilities.\n- [SAFE]: The application wrapper pattern uses database transactions and session-local configurations ('set_config' with the local parameter set to true) to ensure that tenant context is safely managed and not leaked across pooled database connections.
Audit Metadata
Risk Level
SAFE
Analyzed
Sep 11, 2026, 02:29 PM