CVE-2026-104851: fsspec Remote Code Execution via Server-Side Template Injection

fsspec Updated 06 Oct 2026

Summary

05/10/2026
Yes i
High
8.8

CVE-2026-104851: fsspec: Server-Side Template Injection in ReferenceFileSystem leads to Remote Code Execution. Affects fsspec versions >= 0.9.0, < 2026.6.0. Fixed in 2026.6.0. 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 Penetration testing for web, API and mobile Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

fsspec is a Python package that provides a unified interface for file system operations across various storage backends. It is widely used in data science applications, particularly for handling cloud-optimized views of data formats like HDF5 and NetCDF. The package allows users to interact with remote file systems seamlessly, making it a valuable tool in the Pangeo and Earth-observation ecosystems. However, a critical vulnerability has been identified that allows for remote code execution due to improper handling of template rendering.

Vulnerability Detail

The vulnerability arises from the ReferenceFileSystem implementation in fsspec, which processes a JSON document containing references. The parser uses un-sandboxed Jinja2 template rendering, allowing an attacker to inject arbitrary Python code through crafted JSON. This can lead to remote code execution on the victim's machine when they access the malicious JSON document. The vulnerability affects all versions of fsspec from 0.9.0 onward, with the most severe impact occurring when the JSON contains a 'gen' field, which is always processed.

How To Fix

Latest published version: 2026.9.0 as of 22 Oct 2026

pip install --upgrade "fsspec==2026.9.0"

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

2026.6.0

This is the first release that contains the fix.

pip install --upgrade "fsspec==2026.6.0"

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

As a temporary workaround, avoid using the ReferenceFileSystem with untrusted JSON documents until you can update to the patched version. Additionally, you can implement your own validation of the JSON input to prevent the execution of potentially harmful templates.

Conclusion

The vulnerability identified as CVE-2026-104851 in the fsspec package poses a significant risk due to its potential for remote code execution via server-side template injection. Users are strongly advised to update to the latest patched version to mitigate this risk and ensure the security of their applications.

See every vulnerability recorded for fsspec →

Share this vulnerability

FAQ

The CVSS score of this vulnerability is 8.8, indicating a high severity level.

You can use Vulert to monitor and alert for open-source vulnerabilities in your software. Visit Vulert Scanner to check if your application is affected without requiring signup.

If exploited, this vulnerability can lead to arbitrary code execution on the victim's machine, potentially allowing attackers to compromise the system.

Yes, a proof of concept has been provided that demonstrates how an attacker can exploit this vulnerability to execute arbitrary commands on the victim's machine.

If you cannot update the package right away, ensure that you do not use the vulnerable features with untrusted input, and consider implementing additional input validation.

Related vulnerabilities

Recent vulnerabilities recorded for fsspec.

How To Fix

Latest published version: 2026.9.0 as of 22 Oct 2026

pip install --upgrade "fsspec==2026.9.0"

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

2026.6.0

This is the first release that contains the fix.

pip install --upgrade "fsspec==2026.6.0"

Tip — Not sure which version your app runs? Vulert can match this fix to it. 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