/

CVE-2026-56214

Severity:

HIGH RISK

(7.5)

Info Exposure (CWE-200) in Capgo Supabase Billing RPC

CVE-2026-56214

Deferred

Vulnerability type

Category:

Information Disclosure

CWE:

CWE-200

Impact:

Exposure of Sensitive Business and Billing Metadata

Severity:

HIGH RISK

(7.5)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

Capgo exposes sensitive organization and billing information through unauthenticated Supabase PostgREST RPC endpoints.

By abusing these endpoints with only a public key, an attacker can enumerate organizations and infer which ones are paying or trial customers for profiling or targeted abuse.

Affected context

This vulnerability appears in Capgo deployments that expose Supabase PostgREST RPC endpoints is_trial_org and is_paying_org without strong authorization controls.

It is relevant where:

  • Public sb_publishable keys are usable against backend RPC endpoints
  • The endpoints return different responses for existing vs. non-existing organizations
  • Billing-related flags (e.g., trial vs. paying) are computed and returned to unauthenticated callers

In such setups, calls to these endpoints can leak organization existence and payment status across tenants or customers.

Exploit preconditions

  • Attack surface: Publicly reachable Supabase PostgREST API where the RPC endpoints is_trial_org and is_paying_org are accessible.
  • Required access: No authenticated user account; knowledge of the public sb_publishable key and the ability to send HTTP requests to the API.
  • Trigger point: Invoking the RPC endpoints with candidate organization identifiers (IDs, slugs, or similar identifiers).
  • Why exploitation is possible: The RPC functions expose distinct return values or error patterns that:
  • Reveal whether an organization exists
  • Disclose whether the organization is on trial or paying

This logic is reachable without tenant-aware authorization or role checks, allowing enumeration and profiling.

Why this happens

The core issue is an authorization gap in how sensitive business metadata is exposed via API endpoints.

The RPC functions is_trial_org and is_paying_org treat requests authenticated only with a public key as trusted enough to reveal tenant existence and billing status.

This maps to CWE-200: Exposure of Sensitive Information to an Unauthorized Actor, where an API provides more information than necessary to unauthenticated or low-privilege callers.

The endpoints are effectively acting as an oracle: their distinguishable outputs for valid vs. invalid organizations, and for paying vs. non-paying accounts, leak sensitive attributes that should be guarded behind access controls.

Potential impact

  • Attackers may enumerate valid organizations or tenants within a Capgo deployment.
  • Adversaries could build lists of paying vs. non-paying customers for targeted phishing, scams, or competitive intelligence.
  • Attackers can infer business relationships and revenue indicators based on who is a paying customer.
  • Automated scripts can profile the customer base, aiding in credential stuffing, social engineering, or targeted attacks against high-value organizations.
  • Combined with other data, enumeration results can support large-scale reconnaissance and privacy violations.

General mitigation guidance

Effective mitigation focuses on tightening access control around metadata and minimizing what unauthenticated callers can learn:

  • Treat billing status, trial flags, and tenant existence as sensitive attributes that require authenticated and authorized access.
  • Implement role-based or policy-based checks within RPC handlers so that only users with legitimate relationships to an organization can query its status.
  • Normalize error and response behavior so that non-authorized callers see generic, non-enumerable responses that do not distinguish between "not found," "no access," and "exists."
  • Avoid exposing "is_*" style helper endpoints that directly reveal internal state; instead, bundle necessary information into authorized business workflows.
  • Apply the principle of least privilege at the API layer, ensuring public keys or anonymous roles cannot access tenant-specific or billing-related information.
  • Conduct regular design reviews of API contracts to ensure that metadata considered "low risk" in isolation is not exposed in a way that enables large-scale profiling.

How teams detect issues like this

Detection can focus on both code-level patterns and runtime behavior:

  • Static analysis / schema review: Identify RPC functions and endpoints that:
  • Return billing, subscription, or trial flags
  • Perform lookups based on tenant or organization identifiers
  • Are mapped to public or anonymous roles in Supabase/PostgREST configuration
  • Configuration review: Inspect database security policies, RLS rules, and API role mappings to ensure billing-related RPC calls require authenticated roles.
  • Code review cues: Flag endpoints whose names suggest existence or status checks (is_*, has_*, check_*) and verify they do not respond differently based on resource presence for unauthenticated callers.
  • Monitoring and logging: Track unusual patterns of requests to these RPC endpoints, such as:
  • High-volume queries with varying organization identifiers
  • Sequential or pattern-based enumeration of IDs or slugs

Alert on enumeration-like behavior to detect ongoing profiling.

  • Automated API security testing tools and open-source scanners can be configured with test cases that probe for tenant enumeration and information disclosure via status endpoints.

Sources

SourceLink
github.comgithub.com/Cap-go/capgo/security/advisories/GHSA-mh5p-rrhp-442q
vulncheck.comvulncheck.com/advisories/capgo-unauthenticated-organization-enumeration-and-billing-status-disclosure-via-supabase-rpc

Frequently asked

questions

Yes. If the affected Supabase/PostgREST API is exposed publicly and the RPC endpoints are reachable, an attacker on the internet can exploit this issue using only the public key and HTTP requests.

No dedicated user account is required if the endpoints are callable with an anonymous or public role using the sb_publishable key. However, exploitation depends on how roles and access policies are configured in a specific deployment.

The most robust fix is to enforce strict authorization around all billing and organization-status endpoints. Restrict is_trial_org, is_paying_org, or equivalent logic to authenticated users who are explicitly associated with the target organization, and ensure that unauthorized requests receive generic, non-informative responses.

Adopt a defense-in-depth strategy for API design:

  • Classify billing, tenant existence, and customer metadata as sensitive.
  • Apply least-privilege, role-based access control at both the API gateway and database policy levels.
  • Avoid exposing helper endpoints that reveal internal state to anonymous callers.
  • Integrate security reviews and automated checks into the development lifecycle to catch enumeration and excessive data exposure risks before release.
Find out what's already
exploitable in your codebase.