llamaCVEVulnerability Intelligence
/
Advisory · GitHub · npm · @budibase/server

GHSA-PP5R-Q4FP-MCJ3

Cross-workspace privilege escalation via POST /api/global/groups/:groupId/apps (missing per-app authorization)

Sin parche publicado
Descargar PNG JSON
CVSS 3.1
8.1
Alta
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N Fuente: GitHub
ExplotaciónSin evidenciaNo figura en CISA KEV
Exploits públicos0Ninguno conocido
ParcheSin parcheEl fabricante no ha publicado corrección
Exposición70 dDesde la divulgación, 10 sept 2026, 4:10 a. m.
Detección69 dDesde la divulgación hasta su ingreso al índice
Timeline

Ciclo de vida de la vulnerabilidad

Hoy
Divulgación
Publicada
Explotación
Remediación
Monitoreo
Detectada +1
10 sept 26
18 nov 26
19 nov 26
10 sept 26
28 sept 26
15 oct 26
2 nov 26
19 nov 26
FechaFaseEventoDetalle
Divulgación Publicada GHSA-PP5R-Q4FP-MCJ3 divulgada · CVSS 8.1 (GitHub)
Monitoreo Detectada Ingresó al índice
Monitoreo Verificada Última verificación contra las fuentes
Resumen
Descripción del advisory
Texto original · GitHub · en inglés

## Summary
The user-group app-assignment endpoint `POST /api/global/groups/:groupId/apps` is guarded by `builderOrAdmin`, whereas every other user-group mutation endpoint is guarded by the stricter `adminOnly`. The controller writes caller-supplied `{appId, roleId}` pairs into the group's role map without checking that the caller is a builder of each target `appId`. A user who is a builder of a single workspace can therefore grant a user group (including the default "all users" group, which contains every org user and the attacker) an application role such as `ADMIN` in any other workspace whose appId they know, escalating their own privileges across the workspace boundary.

Details

Route registration, the guard is the odd one out (`packages/worker/src/api/routes/global/groups.ts`):

.post("/api/global/groups", auth.adminOnly, ... save)
.post("/api/global/groups/:groupId/users", auth.adminOnly, ... updateGroupUsers)
.post("/api/global/groups/:groupId/users/bulk", auth.adminOnly, ... bulkAddUsersFromCsv)
.delete("/api/global/groups/:groupId/:rev", auth.adminOnly, ... destroy)
.post("/api/global/groups/:groupId/apps", auth.builderOrAdmin, ... updateGroupApps) // <-- weaker

Controller, no per-app authorization (`packages/worker/src/api/controllers/global/groups.ts`):

export async function updateGroupApps(ctx) {
const groupId = ctx.params.groupId
const toAdd = ctx.request.body.add, toRemove = ctx.request.body.remove // each { appId, roleId }
if ((toAdd && !Array.isArray(toAdd)) || (toRemove && !Array.isArray(toRemove))) {
ctx.throw(400, "Must supply a list of objects, with appId and roleId to add or remove")
}
ctx.body = await groups.updateGroupApps(groupId, { appsToAdd: toAdd, appsToRemove: toRemove })
}

`add[].appId` / `add[].roleId` flow into the group's `roles` map (`UserGroup.roles: {[appId]: roleId}`); members inherit those app roles. Nothing checks the caller builds each target appId.

Why `builderOrAdmin` passes for a single-workspace builder (`packages/backend-core/src/middleware/builderOrAdmin.ts`):

const workspaceId = await getWorkspaceIdFromCtx(ctx) // reads header/body.appId/path/query
// target appId is nested in body.add[].appId, NOT body.appId -> workspaceId is undefined
if (!workspaceId && !env.isWorker()) { ctx.throw(403) }
else if (!workspaceId && !hasBuilderPermissions(ctx.user)) { ctx.throw(403) } // worker: passes if hasBuilderPermissions
else if (workspaceId && !isBuilder(ctx.user, workspaceId)) { ctx.throw(403) } // skipped (workspaceId undefined)

`hasBuilderPermissions` (`packages/shared-core/src/sdk/documents/users.ts`) returns true for `builder.global` OR any `builder.apps` entry OR creator, so a builder of a single workspace satisfies it. `getWorkspaceIdFromCtx` never inspects `add[].appId`, so no per-target-app check occurs on the path. This is exactly the authorization the hardened public-roles path added per target app in `packages/server/src/api/controllers/public/globalRoleValidation.ts` (`validateAppRoleUpdate(ctx, appId)` re-checks `isBuilder(ctx.user, appId)`), introduced with the CVE-2026-48150 / CVE-2026-54351 fixes; the `updateGroupApps` sibling did not receive it.

## PoC
Prerequisites: a licensed instance with USER_GROUPS enabled; two workspaces A (`app_AAA`) and B (`app_BBB`); user `mallory` who is a builder of A only and a member of the default "all users" group `us_G`.

  1. As `mallory`: `GET /api/global/groups` to obtain `us_G`; list applications to obtain `app_BBB`.
  2. As `mallory`, send:

POST /api/global/groups/us_G/apps
Content-Type: application/json

{ "add": [ { "appId": "app_BBB", "roleId": "ADMIN" } ] }

  1. Response `200 { id, rev }`; `us_G.roles["app_BBB"] = "ADMIN"`. `mallory` (and every default-group member) now resolves an ADMIN role in workspace B, which they do not build.

Positive control: the same request with `appId: "app_AAA"` (a workspace `mallory` legitimately builds) succeeds on both current and patched builds, isolating the cross-workspace case as the defect.

## Impact
Cross-workspace privilege escalation: a single-workspace builder grants themselves (via a user group) an application role in workspaces they do not build, breaking the workspace isolation boundary and exposing those workspaces' data.

## Remediation
Change the route guard to `auth.adminOnly` (matching the sibling group mutations), or add a per-item `validateAppRoleUpdate(ctx, appId)` over every `add[]` / `remove[]` entry before calling `groups.updateGroupApps`, mirroring `public/globalRoleValidation.ts`.

## Disclosure note
The authorization gap (route guard asymmetry + controller + middleware chain) is fully in the open-source tree and verified there. The final role-map write (`groups.updateGroupApps`) lives in the `@budibase/pro` package, which is not part of the OSS clone; its semantics are fixed by the `UserGroup.roles: {[appId]: roleId}` type. USER_GROUPS is gated to Team/Business/Enterprise (the self-hosted FREE plan has `features: []`), which is why this is submitted as a coordinated static report for your team to confirm against a licensed build.

Incluye detalles técnicos publicados por el investigador. Úselos solo para validar y corregir sus propios sistemas.

Vector CVSS 3.1

Desglose de métricas

Opción resaltada = valor del vector · izquierda = peor caso · GitHub
Vector de ataqueAV:N
RedAdyacenteLocalFísica
ComplejidadAC:L
BajaAlta
PrivilegiosPR:L
NingunoBajosAltos
InteracciónUI:N
NingunaRequerida
AlcanceS:U
CambiadoSin cambio
ConfidencialidadC:H
AltoBajoNinguno
IntegridadI:H
AltoBajoNinguno
DisponibilidadA:N
AltoBajoNinguno
Versiones

Rangos afectados

Afectada Corregida Última
@budibase/server< 3.45.0
3.38.1
3.45.0
Remediación

Estado del parche por paquete

Paquete / productoEstadoCorregida enDesde divulgaciónÚltima versión
npm@budibase/server
Sin parche — — 3.38.1 afectada
Versiones corregidas3.45.0
Explotación

Arsenal público

Sin exploits, módulos ni PoC públicos conocidos a la fecha de verificación.

Referencias
Advisoryhttps://github.com/Budibase/budibase/security/advisories/GHSA-pp5r-q4fp-mcj3

Las referencias externas se muestran para copiar: cve.llama.ec no lo redirige a otros sitios.