Skip to content
OpenAdvisories
Medium · 4.7 CVE-2024-5206 EUVD-2024-0161GHSA-jw8x-6495-233vPYSEC-2024-110

Sensitive Data Leakage in sklearn.feature_extraction.text.TfidfVectorizer in scikit-learn/scikit-learn

Published Jun 6, 2024 · Updated Aug 1, 2024 · Assigned by @huntr_ai

Description

A sensitive data leakage vulnerability was identified in scikit-learn's TfidfVectorizer, specifically in versions up to and including 1.4.1.post1, which was fixed in version 1.5.0. The vulnerability arises from the unexpected storage of all tokens present in the training data within the `stop_words_` attribute, rather than only storing the subset of tokens required for the TF-IDF technique to function. This behavior leads to the potential leakage of sensitive information, as the `stop_words_` attribute could contain tokens that were meant to be discarded and not stored, such as passwords or keys. The impact of this vulnerability varies based on the nature of the data being processed by the vectorizer.

Affected products

VendorProductAffectedFixed
scikit-learn scikit-learn/scikit-learn unspecified – < 1.5.0 1.5.0

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
Debian 14 scikit-learn No fix yet —
Debian 13 scikit-learn No fix yet —
Debian 12 scikit-learn No fix yet —
ReleasePackageFixed inAdvisory
Ubuntu 26.10 scikit-learn No fix yet —
Ubuntu 25.10 scikit-learn No fix yet —
Ubuntu 24.04 LTS scikit-learn No fix yet —
Ubuntu 22.04 LTS scikit-learn No fix yet —
Ubuntu 20.04 LTS scikit-learn No fix yet —
Show 3 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
Ubuntu 18.04 LTS scikit-learn No fix yet —
Ubuntu 16.04 LTS scikit-learn No fix yet —
Ubuntu 14.04 LTS scikit-learn No fix yet —
ReleasePackageFixed inAdvisory
SLES 15 SP6 python-scikit-learn 0.23.2-150300.3.3.1 SUSE-SU-2024:2029-1
SLES 15 SP5 python-scikit-learn 0.23.2-150300.3.3.1 SUSE-SU-2024:2029-1
ReleasePackageFixed inAdvisory
openSUSE Tumbleweed python-scikit-learn 1.5.0-1.1 openSUSE-SU-2026:11498-1, openSUSE-SU-2024:14043-1
openSUSE Leap 15.6 python-scikit-learn 0.23.2-150300.3.3.1 SUSE-SU-2024:2029-1
openSUSE Leap 15.5 python-scikit-learn 0.23.2-150300.3.3.1 SUSE-SU-2024:2029-1

Wolfi

ReleasePackageFixed inAdvisory
Wolfi rolling kubeflow-katib 0.16.0-r12 —
Wolfi rolling kubeflow-pipelines-visualization-server 2.3.0-r1 —
Wolfi rolling py3-scikit-learn 1.5.0-r0 —

Affected packages

EcosystemPackageAffectedFixedRecord
PyPI scikit-learn < 1.5.0 1.5.0 GHSA-jw8x-6495-233v

Advisories 7

References