CVE-2026-4229: SQL Injection Vulnerability in Vanna Package

vanna Updated 17 Mar 2026

Summary

16/03/2026
No i
Moderate
7.3

CVE-2026-4229: Vanna has a SQL injection in the remove_training_data function. Affects vanna versions < 2.0.2. No fix is published. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Your last release was probably never penetration tested Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

Vanna is an AI-driven package available on PyPI that facilitates machine learning operations, particularly in managing and processing training data. It is designed to streamline workflows for data scientists and developers by providing tools for data manipulation and analysis. However, versions up to 2.0.2 contain a critical vulnerability that exposes users to SQL injection attacks, potentially compromising the integrity of their databases.

Vulnerability Detail

A SQL injection vulnerability exists in the remove_training_data function of the Vanna package, specifically in the file src/vanna/legacy/google/bigquery_vector.py. This flaw arises from improper handling of the argument ID, allowing attackers to manipulate SQL queries executed by the application. The vulnerability can be exploited remotely, leading to unauthorized access to sensitive data or even complete database compromise. The issue has been acknowledged by the vendor, but no response was received regarding a fix.

How To Fix

No fixed version is published for this vulnerability.

Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →

Workaround

As a temporary measure, users can sanitize inputs to the remove_training_data function to prevent SQL injection. This can be done by validating and escaping the ID parameter before it is used in any SQL queries. For example:

def safe_remove_training_data(id):
    sanitized_id = escape_sql(id)  # Implement escape_sql to sanitize input
    # Proceed with the database operation using sanitized_id

Implementing input validation can help mitigate the risk until an upgrade is performed.

Conclusion

The SQL injection vulnerability in the Vanna package poses a significant risk to users, particularly those utilizing versions up to 2.0.2. It is crucial to update to the latest version to mitigate this risk. Additionally, implementing input validation can serve as a temporary workaround until the update is applied.

See every vulnerability recorded for vanna →

Share this vulnerability

FAQ

The vulnerability is a SQL injection flaw that allows attackers to manipulate SQL queries through the remove_training_data function.

If you are using Vanna version 2.0.2 or earlier, your application is vulnerable. You can check your version using 'pip show vanna'.

Exploitation of this vulnerability can lead to unauthorized access to your database, data leakage, or even complete data loss.

Yes, you can use Vulert to monitor and alert for open-source vulnerabilities in your software. It requires no installation and uses your Pipfile.lock to provide real-time alerts.

You can use the Vulert playground at Vulert Scanner to check for vulnerabilities in your application without any signup.

Related vulnerabilities

Recent vulnerabilities recorded for vanna.

How To Fix

No fixed version is published for this vulnerability.

Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback