(CVE-2025-50170) Windows Cloud Files Mini Filter Driver Elevation of Privilege
嗯,用户让我帮忙总结一篇文章的内容,控制在一百个字以内,而且不需要特定的开头。首先,我需要仔细阅读文章内容,理解其主要信息。 这篇文章看起来是一个安全漏洞的公告,涉及到Windows系统中的一个驱动程序cldflt.sys。漏洞的CVE编号是CVE-2025-50170,影响多个版本的Windows 10、11和Windows Server。CVSS评分是7.8,属于高危。 漏洞的描述部分提到,这是一个逻辑错误,允许无权限的本地攻击者破坏任意文件并以SYSTEM权限执行代码。攻击者可以利用cldapi.dll!CfCreatePlaceholders() API来创建占位符文件,并通过内核中的函数HsmpOpCreatePlaceholders()进行操作。问题出在内存映射过程中,开发者只检查了读取权限,但实际进行了写入操作,导致文件被覆盖。 影响方面包括文件和内存损坏,可能导致系统崩溃或后门植入。微软已经在8月的安全更新中发布了补丁。 总结时需要涵盖漏洞名称、影响版本、CVSS评分、攻击者权限、漏洞利用方式以及修复情况。要简洁明了,在100字以内。 现在组织语言:漏洞名称是CVE-2025-50170,影响多个Windows版本和服务器版本。CVSS3.1评分7.8,高危。无权限本地攻击者可破坏文件并执行代码。通过API创建占位符文件,在内核中写入未验证的内存导致问题。微软已发布补丁修复。 这样应该符合用户的要求。 </think> Microsoft Windows Cloud Files Mini Filter Driver (cldflt.sys) 存在逻辑错误漏洞(CVE-2025-50170),影响 Windows 10、11 和部分 Server 版本。该漏洞允许无特权本地攻击者通过创建占位符文件破坏任意文件并以 SYSTEM 权限执行代码。微软已在 2025 年 8 月安全更新中修复此问题。 2025-8-12 00:0:0 Author: starlabs.sg(查看原文) 阅读量:3 收藏

Advisory August 12, 2025 By Chen Le Qi 4 min read

CVE: CVE-2025-50170

Affected Versions: Windows 10 (1809, 21H2, 22H2), Windows 11 (22H2, 23H2, 24H2), Windows Server 2019, 2022, 2025

CVSS3.1: 7.8 (High) — CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

Summary

Product Windows Cloud Files Mini Filter Driver (cldflt.sys)
Vendor Microsoft
Severity High — an unprivileged local attacker may corrupt arbitrary files to achieve code execution as SYSTEM
Affected Versions Windows 10 (1809, 21H2, 22H2), Windows 11 (22H2, 23H2, 24H2), Windows Server 2019 / 2022 / 2025
Tested Versions Windows 11 23H2 (Build 22631.4249)
CVE Identifier CVE-2025-50170
CVE Description A logic error in the Windows Cloud Files Mini Filter Driver allows an unprivileged local attacker to corrupt arbitrary files and execute code as SYSTEM
CWE Classification(s) CWE-280: Improper Handling of Insufficient Permissions or Privileges

CVSS3.1 Scoring System

Base Score: 7.8 (High) Vector String: CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

Metric Value
Attack Vector (AV) Local
Attack Complexity (AC) Low
Privileges Required (PR) Low
User Interaction (UI) None
Scope (S) Unchanged
Confidentiality (C) High
Integrity (I) High
Availability (A) High

Product Background

cldflt.sys is a filesystem minifilter driver that acts as a proxy between user applications and cloud sync engines. The sync engine handles on-demand downloading and uploading of data, while cldflt.sys works with the Windows Shell to present cloud-backed files as if they were locally available. It underpins technologies such as OneDrive.

Description of the vulnerability

A logic error during creation of placeholder files allows an unprivileged attacker to corrupt arbitrary files on the system, which can be leveraged to execute arbitrary code as SYSTEM.

Users of cldflt can create placeholder files under syncroot directories via the cldapi.dll!CfCreatePlaceholders() usermode API, which internally calls cldflt.sys!HsmpOpCreatePlaceholders() in the kernel.

This function accepts a usermode pointer, creates an MDL from it, and maps it to system memory:

MemoryDescriptorList = IoAllocateMdl(UserPtr, UserPtrLen, 0, 0, 0LL);
ProbeForRead(UserPtr, UserPtrLen, 4u);
v10 = MemoryDescriptorList;
MmProbeAndLockPages(MemoryDescriptorList, 1, IoReadAccess);
if ( (MemoryDescriptorList->MdlFlags & 5) != 0 )
  MappedSystemVa = MemoryDescriptorList->MappedSystemVa;
else
  MappedSystemVa = MmMapLockedPagesSpecifyCache(MemoryDescriptorList, 0, MmCached, 0LL, 0, 0x40000010u);

The developer specified IoReadAccess when probing the usermode pointer, signalling the address is only used to read data. However, the function subsequently writes to this address in multiple places.

It writes FILE_BASIC_INFORMATION data directly at address + 0x10:

status_ = FltQueryInformationFile(Instance, FileObject, &v72, 0x28u, FileBasicInformation, 0LL);
HsmDbgBreakOnStatus(status_);
if ( status_ >= 0 )
{
  *(curEntry_ + 0x10) = v72; // curEntry_ points to the user-supplied address
  goto LABEL_158;
}

And it writes an error status at address + 0x40:

*(curEntry_ + 0x40) = status_;

Because the kernel writes to this address without verifying write access, an attacker can map a read-only file to that address and pass it to the kernel, causing the file to be overwritten.

The attacker can further bypass internal validations and precisely control the write offset by spraying a writable page contiguous in virtual memory with the read-only target file:

puts("first create neighbouring page");

for (DWORD counter = 1; ; counter++) {
    attackerView = MapViewOfFile(hAttackerMap, FILE_MAP_ALL_ACCESS, 0, 0, 0);
    victimView   = MapViewOfFile(hVictimMap,   FILE_MAP_READ,       0, 0, 0);

    if (attackerView + 0x10000 == victimView)
        break;

    printf("trying %d\n", counter);
}

By mapping a 0x10000-byte attacker-controlled region immediately before the victim read-only file, the attacker passes victimView - 0x40 as the usermode pointer. The first 0x40 bytes fall within the attacker-controlled writable region and pass all internal validations (only the first 0x10 bytes are checked), while the kernel write lands precisely at the start of the victim file.

Impact

File corruption: Corrupting core system binaries or data storage. For example, corrupting a shell script executed as SYSTEM — such as one containing cmd.exe /c C:\Windows\System32\notepad.exe — to redirect execution to an attacker-controlled directory achieves arbitrary code execution. Normal users can create directories under C:\, making this escalation practical.

In-memory corruption: Because all copies of a loaded DLL across different processes share the same physical memory pages, this bug can corrupt DLLs and EXEs that are currently loaded and running — without leaving any traces on disk. This can be abused to kill security processes or introduce subtle, forensically invisible backdoors.

Proof of Concept

The PoC corrupts C:\Windows\win.ini to demonstrate arbitrary file write. Below, the left pane shows the PoC output confirming the first QWORD of win.ini changed from 0x363120726f66203b to 0x36312072c000000d. The right pane shows the resulting corrupted file opened in Notepad.

PoC — win.ini corrupted after exploit

Credit

Chen Le Qi (@cplearns2h4ck) of STAR Labs SG Pte. Ltd.

Timeline


文章来源: https://starlabs.sg/advisories/25/25-50170/
如有侵权请联系:admin#unsafe.sh