{"id":"EUVD-2026-58527","revision":null,"records":[{"revision":"b9e4333615ab412290bc9012f89dc6ca","observedAt":"2026-10-23T15:48:27.903+00:00","statement":{"source":"cve-program","id":"CVE-2026-73304","aliases":[],"title":"Budibase: SSO OAuth2 Token Leakage via User Metadata Endpoints to Power-Role Users","description":"Budibase is an open-source low-code platform. Prior to 3.39.25, GET /api/users/metadata and GET /api/users/metadata/:id returned user objects processed by packages/server/src/utilities/global.ts without removing oauth2.accessToken or oauth2.refreshToken. A user with the POWER role could retrieve the identity-provider credentials of SSO-authenticated users and use the refresh tokens for persistent access to connected services. This issue is fixed in version 3.39.25.","state":0,"publishedAt":"2026-08-13T22:05:00.355+00:00","modifiedAt":"2026-08-14T15:09:18.395+00:00","affected":[{"ecosystem":"Vendor product","name":"budibase","ranges":[],"versions":[],"rawVersionEvidence":"{\n                    \"vendor\": \"Budibase\",\n                    \"product\": \"budibase\",\n                    \"versions\": [\n                        {\n                            \"version\": \"< 3.39.25\",\n                            \"status\": \"affected\"\n                        }\n                    ]\n                }"}],"metrics":[{"system":"CVSS 3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:N/A:N","score":4.9,"severity":"MEDIUM"}],"references":["https://github.com/Budibase/budibase/security/advisories/GHSA-fcrw-f7gg-6g9f","https://github.com/Budibase/budibase/pull/19110","https://github.com/Budibase/budibase/commit/80a31f6c3354620aa90e50af8a2c614333084621","https://github.com/Budibase/budibase/releases/tag/3.39.25"],"sourceUrl":"https://www.cve.org/CVERecord?id=CVE-2026-73304","license":"CVE Program Terms of Use","key":"cve-program:CVE-2026-73304","identifiers":["CVE-2026-73304"]},"retained":false,"historicalAffected":[]},{"revision":"1d9df3d8ce0d444a8692282106363195","observedAt":"2026-11-17T19:40:26.185+00:00","statement":{"source":"euvd","id":"EUVD-2026-58527","aliases":["CVE-2026-73304","GHSA-fcrw-f7gg-6g9f"],"title":"Budibase is an open-source low-code platform. Prior to 3.39.25, GET /api/users/metadata and GET /api/users/metadata/:id returned user objects processed by packages/server/src/utilities/global.ts without removing oauth2.accessToken or oauth2…","description":"Budibase is an open-source low-code platform. Prior to 3.39.25, GET /api/users/metadata and GET /api/users/metadata/:id returned user objects processed by packages/server/src/utilities/global.ts without removing oauth2.accessToken or oauth2.refreshToken. A user with the POWER role could retrieve the identity-provider credentials of SSO-authenticated users and use the refresh tokens for persistent access to connected services. This issue is fixed in version 3.39.25.","state":0,"publishedAt":null,"modifiedAt":null,"affected":[],"metrics":[{"system":"EUVD CVSS 3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:N/A:N","score":4.9,"severity":null}],"references":["https://github.com/Budibase/budibase/security/advisories/GHSA-fcrw-f7gg-6g9f","https://github.com/Budibase/budibase/pull/19110","https://github.com/Budibase/budibase/commit/80a31f6c3354620aa90e50af8a2c614333084621","https://github.com/Budibase/budibase/releases/tag/3.39.25"],"sourceUrl":"https://euvd.enisa.europa.eu/vulnerability/EUVD-2026-58527","license":"ENISA EUVD · source terms and attribution apply","enrichment":{"sourceStatus":null,"weaknesses":[],"productCriteria":[],"sourceDates":{"datePublished":"Aug 13, 2026, 10:05:00 PM","dateUpdated":"Aug 14, 2026, 3:09:18 PM"},"relatedAdvisories":[],"note":"EUVD source date text has no stated timezone and is retained without inventing a UTC instant. Related bulletin membership is not an alias, common cause or applicability claim. A missing vector with a zero score is treated as unrated. Complete vendor/product and underlying source evidence remains in the original JSON."},"key":"euvd:EUVD-2026-58527","identifiers":["EUVD-2026-58527","CVE-2026-73304","GHSA-fcrw-f7gg-6g9f"]},"retained":false,"historicalAffected":[]},{"revision":"eb1502f504ae410aa88f4b57fd9288b4","observedAt":"2026-10-25T15:19:03.401+00:00","statement":{"source":"nvd","id":"CVE-2026-73304","aliases":[],"title":"Budibase is an open-source low-code platform. Prior to 3.39.25, GET /api/users/metadata and GET /api/users/metadata/:id returned user objects processed by packages/server/src/utilities/global.ts without removing oauth2.accessToken or oauth2…","description":"Budibase is an open-source low-code platform. Prior to 3.39.25, GET /api/users/metadata and GET /api/users/metadata/:id returned user objects processed by packages/server/src/utilities/global.ts without removing oauth2.accessToken or oauth2.refreshToken. A user with the POWER role could retrieve the identity-provider credentials of SSO-authenticated users and use the refresh tokens for persistent access to connected services. This issue is fixed in version 3.39.25.","state":0,"publishedAt":"2026-08-13T22:17:25.5+00:00","modifiedAt":"2026-09-08T20:56:50.52+00:00","affected":[],"metrics":[{"system":"CVSS 3.1 · security-advisories@github.com · Secondary","vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:N/A:N","score":4.9,"severity":"MEDIUM"}],"references":["https://github.com/Budibase/budibase/commit/80a31f6c3354620aa90e50af8a2c614333084621","https://github.com/Budibase/budibase/pull/19110","https://github.com/Budibase/budibase/releases/tag/3.39.25","https://github.com/Budibase/budibase/security/advisories/GHSA-fcrw-f7gg-6g9f"],"sourceUrl":"https://nvd.nist.gov/vuln/detail/CVE-2026-73304","license":"NIST NVD usage terms; underlying source attribution retained","enrichment":{"sourceStatus":"Deferred","weaknesses":["CWE-200"],"productCriteria":[],"sourceDates":{"published":"2026-08-13T22:17:25.500","lastModified":"2026-09-08T20:56:50.520"},"relatedAdvisories":[],"note":"NVD analysis and CPE criteria are source context, not proof that a package or your environment is affected. Complete affected data, logical configurations and SSVC are retained in the original JSON."},"key":"nvd:CVE-2026-73304","identifiers":["CVE-2026-73304"]},"retained":false,"historicalAffected":[]},{"revision":"e730a0bba4144952957bcf8548b8e505","observedAt":"2026-10-24T13:17:17.793+00:00","statement":{"source":"osv","id":"GHSA-fcrw-f7gg-6g9f","aliases":["CVE-2026-73304"],"title":" Budibase: SSO OAuth2 Token Leakage via User Metadata Endpoints to Power-Role Users","description":"## Summary\n\nThe `/api/users/metadata` and `/api/users/metadata/:id` endpoints in `@budibase/server` return full global user profiles to any user with POWER role or above. For SSO-authenticated users (OIDC, Google), the response includes `oauth2.accessToken` and `oauth2.refreshToken` fields, leaking identity provider credentials to other users who should not have access to them.\n\n## Details\n\nWhen a user authenticates via SSO (OIDC or Google), the OAuth2 tokens are stored in the global CouchDB user document at `packages/backend-core/src/auth/auth.ts:170-173`:\n\n```typescript\ndbUser.oauth2 = {\n  ...dbUser.oauth2,\n  ...details,\n}\nawait db.put(dbUser)\n```\n\nThe user metadata endpoints are protected by `PermissionType.USER, PermissionLevel.READ` (`packages/server/src/api/routes/user.ts:11`), which maps to the POWER permission set (`packages/backend-core/src/security/permissions.ts:99`).\n\n**Path 1 — List all users** (`GET /api/users/metadata`):\n1. `controller.fetchMetadata` → `sdk.users.fetchMetadata()` (`packages/server/src/sdk/users/utils.ts:78`)\n2. → `getGlobalUsers()` → `getRawGlobalUsers()` (`packages/server/src/utilities/global.ts:101-122`) — strips only `password` and `forceResetPassword`\n3. → `processUser()` (`packages/server/src/utilities/global.ts:15-76`) — strips only `password` and `roles`\n4. The `oauth2` field containing `accessToken` and `refreshToken` is **never removed**\n\n**Path 2 — Single user** (`GET /api/users/metadata/:id`):\n1. `controller.findMetadata` → `getFullUser()` (`packages/server/src/utilities/users.ts:6`)\n2. → `getGlobalUser()` → `getRawGlobalUser()` (`packages/server/src/utilities/global.ts:90-92`) — raw CouchDB fetch, **no field stripping at all**\n3. → `processUser()` — strips only `password` and `roles`\n4. Same result: `oauth2` tokens are returned\n\nThere is no output sanitization middleware on these routes that would strip sensitive fields before the response reaches the client.\n\n## PoC\n\n**Prerequisites:** A Budibase instance with at least one SSO-authenticated user (OIDC or Google) and a separate user with POWER role in an app.\n\n**Step 1 — As the POWER user, list all users:**\n```bash\ncurl -s -X GET 'http://localhost:10000/api/users/metadata' \\\n  -H 'Cookie: budibase:auth=<power-user-jwt>' \\\n  -H 'x-budibase-app-id: app_<appid>' | jq '.[].oauth2'\n```\n\n**Expected output:** `null` for all users (tokens should not be exposed)\n\n**Actual output:** For SSO users, the response includes:\n```json\n{\n  \"accessToken\": \"ya29.a0ARrdaM...\",\n  \"refreshToken\": \"1//0eXxXxXxXx...\"\n}\n```\n\n**Step 2 — Fetch a specific SSO user's profile:**\n```bash\ncurl -s -X GET 'http://localhost:10000/api/users/metadata/ro_ta_users_us_<sso-user-id>' \\\n  -H 'Cookie: budibase:auth=<power-user-jwt>' \\\n  -H 'x-budibase-app-id: app_<appid>' | jq '.oauth2'\n```\n\nThis also returns the full OAuth2 tokens.\n\n## Impact\n\n- A user with POWER role in any app can read **all SSO users' OAuth2 access tokens and refresh tokens** via the list endpoint, without needing to know individual user IDs.\n- Stolen access tokens can be used to access external identity provider resources (Google Workspace, Azure AD, Okta-protected services) as the victim user.\n- Refresh tokens allow indefinite token renewal, persisting access even after the original access token expires.\n- Additionally, `admin`, `builder`, `tenantId`, `ssoId`, and `userGroups` fields are leaked, revealing the full authorization topology of the instance.\n\n## Recommended Fix\n\nStrip sensitive SSO fields in `processUser()` at `packages/server/src/utilities/global.ts:15`:\n\n```typescript\nexport async function processUser(\n  user: ContextUser,\n  opts: { appId?: string; groups?: UserGroup[] } = {}\n) {\n  if (!user || (!user.roles && !user.userGroups)) {\n    return user\n  }\n  user = cloneDeep(user)\n  delete user.password\n+ delete (user as any).oauth2\n+ delete (user as any).provider\n+ delete (user as any).providerType\n+ delete (user as any).thirdPartyProfile\n+ delete (user as any).profile\n+ delete (user as any).ssoId\n+ delete (user as any).forceResetPassword\n  // ... rest of function\n```\n\nAdditionally, `getRawGlobalUsers()` at line 101 should also strip `oauth2` alongside its existing `password`/`forceResetPassword` stripping for defense in depth.","state":0,"publishedAt":"2026-07-24T21:14:31+00:00","modifiedAt":"2026-08-15T05:20:18.5324131+00:00","affected":[{"ecosystem":"npm","name":"@budibase/server","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"0"},{"kind":"fixed","version":"3.39.25"}]}],"versions":[],"rawVersionEvidence":null}],"metrics":[{"system":"CVSS_V3","vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:N/A:N","score":null,"severity":null},{"system":"Publisher rating","vector":null,"score":null,"severity":"MODERATE"}],"references":["https://github.com/Budibase/budibase/security/advisories/GHSA-fcrw-f7gg-6g9f","https://github.com/Budibase/budibase/pull/19110","https://github.com/Budibase/budibase/commit/7b8ba11a2c8b233c35e7728dd752dba25ef919a4","https://github.com/Budibase/budibase/commit/80a31f6c3354620aa90e50af8a2c614333084621","https://github.com/Budibase/budibase","https://github.com/Budibase/budibase/releases/tag/3.39.25"],"sourceUrl":"https://github.com/advisories/GHSA-fcrw-f7gg-6g9f","license":"GitHub Advisory Database · CC-BY-4.0","key":"osv:GHSA-fcrw-f7gg-6g9f","identifiers":["GHSA-fcrw-f7gg-6g9f","CVE-2026-73304"]},"retained":false,"historicalAffected":[]}],"coverage":[{"source":"cisa-kev:global","scope":"Complete CISA KEV catalog; all vendors. Missing entries do not establish absence of exploitation.","generation":"2026-11-19T09:40:31.8345493+00:00","complete":true,"records":1786,"lastAttemptAt":"2026-11-19T09:40:31.8345493+00:00","lastSuccessAt":"2026-11-19T09:40:32.3515264+00:00","error":null,"lastVerifiedAt":"2026-11-19T09:40:32.3515283+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"cve-program","scope":"Official CVE Program baseline and cumulative hourly delta; all vendors, published and rejected records","generation":"cve-e55c589538e0700b45c7d6d41fe1447a79199283262c371c864535c791a040b9-9e2db0084925c841be762919585cd511a893087e7961941f7ebd76ab552c4302","complete":true,"records":428265,"lastAttemptAt":"2026-11-19T09:40:24.3145117+00:00","lastSuccessAt":"2026-11-19T09:40:24.1463366+00:00","error":null,"lastVerifiedAt":"2026-11-19T09:40:24.3145117+00:00","snapshotPublishedAt":"2026-11-19T09:30:40+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"euvd","scope":"Rolling EUVD lookups of CVE aliases in current public OSV archives; 500 identifiers per refresh, rechecked after 48 hours. Not a global EUVD catalog. Successful not-found lookups count as checked; they do not imply withdrawal or safety. No reader inventory is sent.","generation":"enrichment-6e19c69ebb974886991d5dad9f632f81","complete":false,"records":13861,"lastAttemptAt":"2026-11-19T09:50:13.3657605+00:00","lastSuccessAt":"2026-11-19T09:50:12.338+00:00","error":"272 identifier lookups failed; latest failures include AccessDenied (HTTP 403). Other identifiers were checked independently.","lastVerifiedAt":"2026-11-19T09:50:12.338+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13636,"expectedIdentifiers":13908,"failedIdentifiers":272},{"source":"first-epss:nuget","scope":"FIRST EPSS for explicit CVE aliases in the collected public NuGet archive. Not a global EPSS backfill.","generation":"2026-11-19T09:40:31.8345493+00:00","complete":true,"records":1125,"lastAttemptAt":"2026-11-19T09:40:31.8345493+00:00","lastSuccessAt":"2026-11-19T09:40:32.3815873+00:00","error":null,"lastVerifiedAt":"2026-11-19T09:40:32.3815895+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"nvd","scope":"Rolling NVD lookups of CVE aliases in current public OSV archives; 500 identifiers per refresh, rechecked after 48 hours. Not a global NVD catalog. Successful not-found lookups count as checked; they do not imply withdrawal or safety. No reader inventory is sent.","generation":"enrichment-8b5fdf678977402cb60bbe3c5e89bf16","complete":true,"records":13873,"lastAttemptAt":"2026-11-19T09:40:33.0523055+00:00","lastSuccessAt":"2026-11-19T09:22:49.229+00:00","error":null,"lastVerifiedAt":"2026-11-19T09:22:49.229+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13908,"expectedIdentifiers":13908,"failedIdentifiers":0},{"source":"osv:Go","scope":"Complete OSV Go ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"go-76574c95b6792d47ba90af64983ed5843633f14426346d676016e94a5f383202","complete":true,"records":9963,"lastAttemptAt":"2026-11-19T09:40:25.2441782+00:00","lastSuccessAt":"2026-11-19T01:24:31.4213722+00:00","error":null,"lastVerifiedAt":"2026-11-19T09:40:25.2441782+00:00","snapshotPublishedAt":"2026-11-19T01:03:15+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:NuGet","scope":"Complete OSV NuGet ecosystem archive, including GitHub Advisory Database records; NuGet version matching only","generation":"nuget-f4424d7d4861b1af1404bd15abcb83f295dcd003412a9340ca99dc8200aa148a","complete":true,"records":2014,"lastAttemptAt":"2026-11-19T09:40:24.3875329+00:00","lastSuccessAt":"2026-11-13T19:57:08.2864435+00:00","error":null,"lastVerifiedAt":"2026-11-19T09:40:24.3875329+00:00","snapshotPublishedAt":"2026-11-13T19:33:10+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:crates.io","scope":"Complete OSV crates.io ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"crates.io-313d8afdba3867de110bc2f0cc252c7b787cb94e08a055d09b0542017e147ca8","complete":true,"records":3194,"lastAttemptAt":"2026-11-19T09:40:31.7231448+00:00","lastSuccessAt":"2026-11-19T09:40:31.5988269+00:00","error":null,"lastVerifiedAt":"2026-11-19T09:40:31.7231448+00:00","snapshotPublishedAt":"2026-11-19T09:03:08+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:npm","scope":"Complete OSV npm ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"npm-151b9ac741fba7353ad731a68476d546237cc5b2becb54fa011ca91249746bea","complete":true,"records":232733,"lastAttemptAt":"2026-11-19T09:40:24.5744302+00:00","lastSuccessAt":"2026-11-19T08:24:21.1829126+00:00","error":null,"lastVerifiedAt":"2026-11-19T09:40:24.5744302+00:00","snapshotPublishedAt":"2026-11-19T07:32:56+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null}]}