Skip to content

Governance and security

Governance and security

Workspace isolation, roles and permissions, credentials, identity, audit, retention and deletion.

Last updated 1 min read Edit this page on GitHub
On this page

UserTasks is built to be operated by more than one team and called by more than one system, so every surface — app, REST, MCP, CLI — goes through the same checks.

Workspace isolation#

Every row belongs to a workspace. Postgres row-level security enforces isolation for signed-in users, and service code adds explicit workspace checks on every query, including the queue workers and SECURITY DEFINER functions.

Who can do what#

Credentials#

  • API keys: workspace or user context, a permission ceiling, optional workflow/table allow-lists and expiry.
  • OAuth apps and scopes: authorization code with PKCE, client credentials, refresh rotation with reuse detection.
  • Integration and log-destination secrets are encrypted with ENCRYPTION_KEY, write-only and masked as __SECRET__ in every response and export.

Evidence and lifecycle#

  • Workspace theme: the one brand theme every member sees, edited in the theme designer or through the API.
  • Audit, retention and deletion: audit log, permission changes, security events, retention policies with review and purge, and a deletion queue that checks dependencies.
  • Every change and security event is in the event stream and can be shipped to your SIEM.
Roles and permissions settings
Roles: the system roles and a custom "Finance approver" role.

Hardening checklist (self-hosted)#

  • Set ENCRYPTION_KEY; without it stored secrets are plaintext.
  • Keep SUPABASE_SERVICE_ROLE_KEY, CRON_SECRET and ENCRYPTION_KEY out of the browser and version control.
  • Leave ALLOW_PRIVATE_EGRESS and ALLOW_QUERY_KEY_AUTH off unless you need them. Custom workflow actions always run sandboxed; CUSTOM_ACTIONS_DISABLED=true switches them off entirely.
  • Serve over HTTPS; the app sends HSTS, a strict CSP, X-Frame-Options: DENY and nosniff by default (only the form link pages — /f/, /form/, /p/ and /form-login — may be framed, for embedding).

Was this page helpful?