Skip to main content

Chartbrew CVE-2026-54349

| EUVDEUVD-2026-118501 CRITICAL
SQL Injection (CWE-89)
2026-11-06 security-advisories@github.com
9.8
CVSS 3.1 · Vendor: github
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Find public/embedded chart with SQL variables
  2. Delivery
    Send crafted URL filter value (?var=payload)
  3. Exploit
    Break out of quoted literal via $-sequence or backslash
  4. Execution
    Inject UNION/DML into author's stored query
  5. Impact
    Read, modify, or delete connected database data

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Parameterized queries, prepared statements
MITRE ATT&CK

2 techniques across 2 tactics: Initial Access, Persistence

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires that the target deploy a public (/chart/share/:share_string) or embedded (/chart/:share_string/embedded) chart that is backed by a stored SQL query referencing URL-controlled dashboard variables (the applyMysqlOrPostgresVariables / applySqlVariables path); these two endpoints are protected only by apiLimiter(50) and lack verifyToken, so no authentication is needed. The engine-independent dollar-sequence replacement-string attack works against any configured SQL connector (MySQL, PostgreSQL, etc.), while the second backslash-based quoted-string escape path is specific to MySQL and MariaDB. Limiting factors: the chart author must actually use URL-controlled variables inside a SQL query and expose it publicly/embedded (a chart without such variables or not shared is not reachable); impact is further bounded by the privileges of the configured database account. Affected versions are <=5.2.0; fixed in 5.2.1.

Impact

This is a genuine high priority, not a CVSS-inflated paper risk. The CVSS 3.1 vector (AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H, 9.8) is corroborated by the source evidence rather than contradicting it: the GHSA advisory shows the share/embed routes (/chart/:share_string/embedded and /chart/share/:share_string) use only apiLimiter with no verifyToken, confirming PR:N and AV:N, and the attacker fully controls the URL filter values with no interaction, supporting AC:L/UI:N. The decision label is act_now, which aligns with unauthenticated remote SQL injection into databases that Chartbrew is explicitly designed to connect to production analytics data. No CISA KEV listing is present in the input and no EPSS score was provided, so I cannot claim active exploitation or quantify exploitation probability; the absence of those two signals is the main gap in the picture. However, a detailed public PoC (Docker setup plus working UNION-based curl payload) is published directly in the GHSA advisory, which materially raises real-world likelihood compared to a theoretical finding. The impact is bounded by the privileges of the configured database account (C/I/A:H assumes a typical read/write analytics account), and one of the two escape paths (backslash) is MySQL/MariaDB-specific, but the dollar-sequence replacement path is engine-independent and affects all SQL connectors.

Exploit ScenarioDerived

An unauthenticated attacker finds a public or embedded Chartbrew chart whose stored SQL query uses URL-controlled dashboard variables, then sends crafted filter values via query parameters (e.g. ?name=<payload>) that break out of the quoted string literal. Using either a JavaScript $-sequence in the replacement string or, on MySQL/MariaDB, a trailing backslash to defeat quote-doubling, they inject a UNION or other SQL to read, modify, or delete data in the connected database. A full working PoC with a UNION reading information_schema is published in the GHSA advisory.

Act Now Prioritize within 24-48h. Why: CRITICAL severity.
Patch available 0.4% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Nov 06, 2026

Unauthenticated SQL injection in Chartbrew through 5.2.0 lets anyone who can reach a publicly shared or embedded chart rewrite the author's stored SQL query by supplying crafted URL filter values, allowing reads, modifications or deletions in whatever database the chart's connection is bound to (CVSS 9.8, CWE-89, AV:N/AC:L/PR:N/UI:N). Two distinct defects combine: dashboard-variable values are passed as JavaScript replacement strings to String.prototype.replace, so dollar sequences such as $' mutate the SQL at substitution time on every engine, and the string escaper never handles backslashes, giving a second quoted-literal breakout specific to MySQL and MariaDB. The vendor rated this high priority and a public PoC reference exists in the GHSA advisory, but no confirmed active exploitation or KEV listing is present in the supplied data; the fix ships in 5.2.1.

RemediationAI

Vendor-released patch: Chartbrew 5.2.1. Upgrade all instances from <=5.2.0 to 5.2.1 (release notes: https://github.com/chartbrew/chartbrew/releases/tag/v5.2.1), which implements the fixes in commit f93d31ac586091f72a7eb97d89fa3b4db271bd24 - placeholder replacement via a callback so dollar sequences are treated literally, plus backslash escaping for the MySQL and RDS-MySQL variable processors - as documented in advisory GHSA-4wj7-9gq7-mrr2. If immediate upgrade is not possible, reduce exposure by removing public sharing and disabling or placing authentication in front of the /chart/share/:share_string and /chart/:share_string/embedded endpoints, since those two routes carry only apiLimiter(50) and no verifyToken and are the entire unauthenticated attack surface; the trade-off is that legitimate public/embedded dashboards stop rendering for external viewers. Because the impact is bounded by the privileges of the configured database account, restrict Chartbrew's data-source credentials to read-only or narrowly scoped grants where feasible - this limits data modification and deletion but not disclosure of data the account can legitimately read.

Affected VersionsENISA

chartbrew < 5.2.1

Affected Packages

euvd chartbrew fix: 5.2.1

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

Chartbrew's SQL connectors build chart queries by interpolating dashboard variables into a stored query template. In server/sources/shared/sql/sql.variables.js, escapeSqlString only doubled single (and double) quotes and then handed the result to String.prototype.replace as the replacement argument; JavaScript expands $-patterns ($', $, $&, $$, $n) inside replacement strings, so an attacker value containing $' or $ rewrites the surrounding SQL and shifts the auto-appended closing quote, breaking out of the literal regardless of database engine. Independently, the escaper had no backslash handling, so a value containing \' escapes the quote-doubling on MySQL/MariaDB and terminates the string from inside. The resulting string is executed raw via Sequelize's dbConnection.query(..., { type: Sequelize.QueryTypes.SELECT }) in sql.protocol.js, with no bind parameters, so this is classic CWE-89 improper neutralization of special elements in an SQL command affecting the MySQL, RDS MySQL and shared SQL/Postgres protocol paths. The fixed commit f93d31ac adds an escapeBackslash option wired through the MySQL and RDS-MySQL protocol wrappers and replaces placeholder substitution with a callback form (query.replace(placeholder, () => value)) so attacker-controlled text is never interpreted as a replacement pattern.

Know when the next one hits your stack

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (github) PRIMARY 9.8 CRITICAL
AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
vuln.today AI 9.8 CRITICAL

Unauthenticated share/embed routes lack verifyToken so PR:N/AV:N; attacker fully controls URL filter values with no interaction (AC:L/UI:N); SQLi allows read/modify/delete so C/I/A:H.

3.1 AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
4.0 AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (github).

CVSS VectorVendor: github

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High

Lifecycle Timeline

2
Patch available
Nov 06, 2026 - 22:03 EUVD
CVE Published
Nov 06, 2026 - 21:17 cve.org
CRITICAL 9.8

DescriptionCVE.org

Chartbrew is an open-source web application that can connect directly to databases and APIs and use the data to create charts. Prior to 5.2.1, SQL dashboard-variable substitution used attacker-controlled JavaScript replacement strings unsafely across SQL connectors and separately failed to escape backslashes for MySQL and MariaDB quoted contexts. The vulnerable surface is public and embedded dashboard/chart requests that call applyMysqlOrPostgresVariables. An unauthenticated user sends crafted URL filter values to a public or embedded chart backed by a stored SQL query. Replacement-string dollar sequences can alter SQL independently of the database engine, while MySQL and MariaDB backslash handling provides a second quoted-string escape path. The target must expose a public or embedded chart using URL-controlled variables in a SQL query; only the backslash branch is specific to MySQL and MariaDB. Injected SQL can read, modify, or delete data available to the configured database account. This issue is fixed in version 5.2.1.

Technical POC Analysis

CWE-89: SQL injection.

Full technical POC analysis - root cause, step-by-step exploitation and patch breakdown - is part of the Pro and Business plans.

Executive ViewAI

Why It Matters

CVE-2026-54349 is a critical unauthenticated SQL injection vulnerability in Chartbrew through version 5.2.0, allowing any external attacker to execute arbitrary SQL queries on the databases connected to publicly shared or embedded charts. This compromises the confidentiality, integrity, and availability of sensitive business data, and the accessible nature of shared dashboards lowers the barrier to exploitation, putting customer and operational data at risk.

Business Impact: High
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.4%
Top 63% exploitable
Prevalence
Low
Niche open-source analytics app, limited enterprise deployment footprint
Social Media
2
Sightings
Data Quality
5 sources
Confidence: Medium

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity CRITICAL
CISA KEV No
Public POC No
EPSS 0.4%
Patch available Yes
Active threat No
Deciding rule
CRITICAL severity
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Open
Automatable· derived
Yes
Human Impact
High

Priority Score

49
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +49
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

SQL injection exploits the way applications construct database queries by mixing user input directly into SQL statements.

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy