CVE-2026-61852
Received Received - Intake

SQL Injection in Chartbrew via AI Tool Row Limit

Vulnerability report for CVE-2026-61852, including description, CVSS score, EPSS score, affected products, exploitability, helpful resources, and attack-flow context.

Publication date: 2026-09-21

Last updated on: 2026-09-21

Assigner: GitHub, Inc.

Description

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.2, Chartbrew's runQuery() implementation in server/modules/ai/orchestrator/tools/runQuery.js interpolates the AI tool's row_limit parameter into a SQL LIMIT clause without runtime integer validation. The read-only keyword check runs before this value is appended, so an authenticated user who can influence a model-generated non-integer row_limit can add SQL that bypasses the earlier check. Successful exploitation can execute arbitrary statements against the connected database, including reading or changing data and, where database permissions permit, accessing files or executing operating-system commands. This issue is fixed in version 5.2.2.

CVSS Scores

EPSS Scores

Probability:
Percentile:

Meta Information

Published
2026-09-21
Last Modified
2026-09-21
Generated
2026-09-22
AI Q&A
2026-09-22
EPSS Evaluated
N/A
NVD

Affected Vendors & Products

Showing 1 associated CPE
Vendor Product Version / Range
chartbrew chartbrew 5.2.2

Helpful Resources

Exploitability

CWE
CWE Icon
KEV
KEV Icon
CWE ID Description
CWE-89 The product constructs all or part of an SQL command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended SQL command when it is sent to a downstream component. Without sufficient removal or quoting of SQL syntax in user-controllable inputs, the generated SQL query can cause those inputs to be interpreted as SQL instead of ordinary user data.

Attack-Flow Graph

AI Quick Actions

Instant insights powered by AI
Executive Summary

Chartbrew before 5.2.2 has a flaw in its runQuery() function where the row_limit parameter from AI tools is directly inserted into a SQL LIMIT clause without checking if it is an integer. An authenticated user can manipulate this parameter to inject malicious SQL code, bypassing a read-only check and executing arbitrary database commands.

Detection Guidance

Check Chartbrew version with npm list chartbrew or by inspecting package.json. Look for SQL queries in application logs that include non-integer row_limit values. Monitor database logs for unusual queries or commands.

Impact Analysis

This vulnerability allows attackers with access to Chartbrew to read, modify, or delete data in the connected database. If database permissions permit, they may also access files or execute operating system commands, potentially leading to full system compromise.

Compliance Impact

This vulnerability could lead to unauthorized data access or modification, violating GDPR's data protection principles or HIPAA's requirements for safeguarding protected health information. Compliance breaches may result in legal penalties or reputational damage.

Mitigation Strategies

Upgrade Chartbrew to version 5.2.2 or later immediately. Review and restrict database permissions for Chartbrew users. Disable AI tool integration if not required. Monitor database activity for suspicious queries.

Chat Assistant

Ask questions about this CVE
Hi! I’m here to help you understand CVE-2026-61852. Ask me anything about the vulnerability, its impact, or mitigation strategies.
0/70

EPSS Chart