GHSA-9237-rg5p-rhfw
@saltcorn/data: Tenant user role is used for tenant creation role check
Blast Radius
@saltcorn/data📦@saltcorn/data📦@saltcorn/dataReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects npm packages — download data is not available via public APIs for these ecosystems.
Description
Summary
When a tenant admin is logged out of the root domain (e.g., saltcorn.com) but logged in to their own tenant space as admin, they can simply append /tenant/create to their tenant URL. The system reads the role from the tenant context (admin), and a new tenant is created on the root domain (in PUBLIC SCHEMA > _sc_tenants), rather than in the tenant's own _sc_tenants table.
If the same logic applies to other routes, a tenant admin effectively gains admin rights on the root domain.
PoC
A tenant-created subtenant appears under the Saltcorn public schema instead of the tenant's own schema.
- Even when
role_id=1is required for tenant creation on saltcorn.com (only admin can create tenants), existing tenant admins can still create new tenants because their localrole_id:1is evaluated against the root domain. - Even when
role_to_create_tenantis set to0in the tenant's_sc_configschema, or removed entirely, the tenant admin can still create sub-tenants on the root domain — suggestingrole_to_create_tenantis not being read at all.
Impact
Tenant admins gain unauthorized admin-level access to the root domain. Any authenticated tenant admin can perform privileged operations (e.g., creating tenants) on the root domain by exploiting the role context mismatch.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 📦npm | @saltcorn/data | all versions | 1.4.4 |
| 📦npm | @saltcorn/data | ≥ 1.5.0-beta.0&&< 1.5.2 | 1.5.2 |
| 📦npm | @saltcorn/data | ≥ 1.6.0-alpha.0&&< 1.6.0-beta.2 | 1.6.0-beta.2 |
Detection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for @saltcorn/data. O3's reachability analysis confirms whether the vulnerable code path is actually invoked in your application, so you act on real exposure instead of every transitive match.
Fix
Update @saltcorn/data to 1.4.4 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms GHSA-9237-rg5p-rhfw is resolved across your whole dependency graph.
Workarounds
If you can't upgrade right away: gate or disable the affected feature, validate untrusted input at the boundary, and avoid passing attacker-controlled data into the vulnerable path. O3's runtime protection blocks exploitation in production as an interim safeguard until the upgrade lands.
How O3 protects you
O3 pinpoints whether GHSA-9237-rg5p-rhfw is reachable in your code and exactly where to fix it, then blocks exploitation in production at runtime until the patched version is deployed.
Tailored to GHSA-9237-rg5p-rhfw. Runtime protection reduces exposure until a permanent patch is applied and verified — it complements patching, it doesn't replace it.
Frequently Asked Questions
Is GHSA-9237-rg5p-rhfw in your dependencies?
O3 detects GHSA-9237-rg5p-rhfw across npm dependencies and uses function-level reachability to confirm whether the vulnerable code path is actually reachable — not just present. No false positives.