{"id":"CVE-2026-41640","published":"2026-05-07T04:09:59Z","modified":"2026-05-07T12:55:04Z","title":"NocoBase Vulnerable to SQL Injection via String Concatenation in Recursive Eager Loading","vendor":"nocobase","product":"nocobase","tier":"tail","description":{"text":"NocoBase is an AI-powered no-code/low-code platform for building business applications and enterprise solutions. Prior to version 2.0.39, the queryParentSQL() function in the core database package constructs a recursive CTE query by joining nodeIds with string concatenation instead of using parameterized queries. The nodeIds array contains primary key values read from database rows. An attacker who can create a record with a malicious string primary key can inject arbitrary SQL when any subsequent request triggers recursive eager loading on that collection. This issue has been patched in version 2.0.39.","provenance":"source","from":"CVE.org"},"cvss":{"score":7.5,"severity":"HIGH","version":"3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.01875,"percentile":0.79915,"provenance":"source"},"cwes":[{"id":"CWE-89","name":"Improper Neutralization of Special Elements used in an SQL Command"}],"references":[{"url":"https://github.com/nocobase/nocobase/security/advisories/GHSA-4948-f92q-f432","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/nocobase/nocobase/pull/9133","tags":["x_refsource_MISC"]},{"url":"https://github.com/nocobase/nocobase/commit/202e2b8efe44ba90adbf1087f6f70881ff947604","tags":["x_refsource_MISC"]},{"url":"https://github.com/nocobase/nocobase/releases/tag/v2.0.39","tags":["x_refsource_MISC"]}],"priority":{"score":26.2,"factors":[{"name":"EPSS percentile","points":15.98},{"name":"Public exploit code","points":5.0},{"name":"CVSS severity","points":5.25}]},"exploitSources":{"nuclei":[{"id":"CVE-2026-41640","name":"NocoBase - SQL Injection","severity":"high","path":"http/cves/2026/CVE-2026-41640.yaml","url":"https://github.com/projectdiscovery/nuclei-templates/blob/main/http/cves/2026/CVE-2026-41640.yaml"}],"provenance":"source"},"vendorSlug":"nocobase","affectedVersions":[{"vendor":"nocobase","product":"nocobase","versions":["< 2.0.39"]}],"ssvc":{"exploitation":"poc","automatable":"no","technicalImpact":"total","timestamp":"2026-05-07T12:54:23.331234Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"npm","package":"@nocobase/database","vulnerableRanges":["<2.0.39"],"patched":["2.0.39"],"from":["GHSA-4948-f92q-f432"],"provenance":"source"}],"summary":{"text":"The flaw is an SQL injection in the queryParentSQL() function of the core database package in NocoBase, a no-code/low-code platform for building business applications. The function builds a recursive CTE query by concatenating primary key values as strings rather than using parameterized queries. An attacker with low-privilege authenticated access and the ability to create a record with a malicious string primary key can inject arbitrary SQL that runs when a later request triggers recursive eager loading on that collection, with a high attack complexity and no user interaction required.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-21T05:38:55Z"},"euvd":{"id":"EUVD-2026-28261","exploited":false,"provenance":"source"}}