GHSA-q6x4-v3qx-85qwCritical· 9.6▾ MidnightBudibase: SQL Injection via `multipleStatements: true`
▾ Midnight zone — Critical, or high with PoC / in-the-wild
impact 52.8 · likelihood 0 · exploitation 0
Need a working PoC? Pro members can cast a request and our team develops one — it lands right here.
A critical SQL injection vulnerability was discovered in Budibase's MySQL integration that allows remote attackers to execute arbitrary SQL commands.
SQL Injection
The MySQL integration component in Budibase is configured with multipleStatements: true, enabling execution of multiple SQL statements in a single query. Attackers can inject malicious SQL commands through user input fields, leading to complete database compromise.
// File: packages/server/src/integrations/mysql.ts
// Line: 173
this.config = {
...config,
typeCast: defaultTypeCasting,
multipleStatements: true, // VULNERABLE
timezone: "Z",
}
const mysql = require('mysql2');
// Budibase vulnerable configuration
const connection = mysql.createConnection({
host: 'localhost',
user: 'root',
password: 'password',
multipleStatements: true, // Vulnerable setting
timezone: "Z"
});
// Attack: Data destruction
connection.query(
`SELECT * FROM users WHERE id = 1; DROP TABLE sensitive_data; --`,
(err, results) => {
if (!err) console.log("Table dropped successfully");
}
);
--- a/packages/server/src/integrations/mysql.ts
+++ b/packages/server/src/integrations/mysql.ts
@@ -170,7 +170,7 @@ class MySQLIntegration extends Sql implements DatasourcePlus {
this.config = {
...config,
typeCast: defaultTypeCasting,
- multipleStatements: true,
+ multipleStatements: false,
timezone: "Z",
}
}
@budibase/server <= 3.38.1Refer to the advisory for the patched release.
Connected by shared product, vendor, weakness, or advisory.
GHSA-pmpg-2mxq-6xwrHigh· 7.1Budibase: NoSQL injection in MongoDB integration: collection dump, $where JS exec, cross-collection pivot, arbitrary update/delete
GHSA-j9fc-w3mr-x6mvHigh· 8.8Budibase: Privilege escalation via public role assignment API missing app-level authorization
GHSA-c8vc-7pv3-g98pHighBudibase: Email Change IDOR via POST /api/v2/email allows full Account Takeover (accountId not validated against session)
GHSA-ppr4-5f46-j9c6HighBudibase: Server Filesystem Existence/Read Oracle via Builder-Controlled MongoDB tlsCertificateKeyFile
GHSA-xcx6-4f2g-hhgxHigh· 7.7Budibase: S3 presigned URL endpoint authorization regression in v3.39.4 allows BASIC users to obtain S3 PutObject presigned URLs
GHSA-2xgg-r2wc-c5r2High· 7.6Budibase: MySQL DESCRIBE Backtick Injection via multipleStatements in Database Connector