Skip to content
KitploitKITPLOIT
HerramientasBlog
Enviar
HerramientasBlog
Enviar

¡Herramientas de Hacking, PenTest y Ciberseguridad para tu Arsenal de Seguridad!

Kitploit es un directorio de herramientas de hacking, ciberseguridad y pentesting. Descubre las últimas actualizaciones de proyectos para encontrar vulnerabilidades, analizar sistemas, automatizar pruebas y fortalecer tu seguridad.

··Feeds·Contacto·Privacidad·© 2026 Kitploit

Directorio de Herramientas

Categorías

Ver todas las categorías
Loading categories
CVE-2025-60709 — PoC de exploit de LPE en CLFS de Windows para investigación en seguridad | Kitploit
Herramientas/GitHubGitHub/kondordevsecuritycorp/cve-2025-60709
Herramientas DefensivasEscalada de PrivilegiosAnálisis de VulnerabilidadesExplotaciónAprendizaje y EducaciónDesarrollo de PayloadsExplotación de Binarios
GitHubkondordevsecuritycorp/cve-2025-60709

Más Populares

Ver todos →

Descubre las herramientas más usadas por nuestra comunidad.

Explora todas las herramientas

Explora nuestra colección de herramientas

Ver todas las herramientas →

CVE-2025-60709

PoC de exploit de LPE en CLFS de Windows para investigación en seguridad

Ver Repositorio
2hace 5 mesesAún no revisado
Compartir

CVE Type Target Component C Go Research


🚨 EXPLOIT PoC — FOR SECURITY RESEARCH, VULNERABILITY ANALYSIS AND DEFENSIVE PURPOSES ONLY

🚨 PoC DE EXPLOIT — SOLO PARA INVESTIGACIÓN DE SEGURIDAD, ANÁLISIS DE VULNERABILIDADES Y FINES DEFENSIVOS


🌐 Idiomas / Languages

  • 🇪🇸 Español
  • 🇬🇧 English

🇪🇸 Documentación en Español

Descripción

CVE-2025-60709 es una vulnerabilidad de escalación de privilegios locales (LPE) en el controlador CLFS.sys (Common Log File System) de Windows. Permite a un atacante con ejecución de código local escalar desde usuario estándar hasta NT AUTHORITY\SYSTEM mediante un buffer overflow en el parsing de contenedores CLFS, obteniendo una primitiva de escritura arbitraria en memoria del kernel.

Este repositorio contiene dos implementaciones:

  • CVE-2025-60709.c — Implementación original en C (acceso directo a APIs nativas de Windows)
  • CVE-2025-60709.go — Port en Go (versión de demostración/educativa — NO explota vulnerabilidades reales)

🎯 Detalles de la Vulnerabilidad

CampoDetalle
CVE IDCVE-2025-60709
TipoLocal Privilege Escalation (LPE)
ComponenteCLFS.sys (Common Log File System driver)
Sistema objetivoWindows 11 24H2 (build 26100.3485+)
Arquitecturax64 únicamente
VectorBuffer overflow en parsing de contenedor CLFS
ImpactoEscalación a NT AUTHORITY\SYSTEM
PrerequisitosEjecución local de código (usuario estándar)

🏗️ Estructura del Repositorio

root@kitploit:~
CVE-2025-60709/
├── CVE-2025-60709.c    (5.3 KB, 157 líneas) — Exploit C original
├── CVE-2025-60709.go   (9.2 KB, 285 líneas) — Port Go (demo educativa)
└── README.txt          (4.2 KB, 132 líneas) — Documentación original

🔬 Análisis Técnico Detallado

Flujo de Explotación Completo

root@kitploit:~
┌─────────────────────────────────────────────────────────────┐
│                    CVE-2025-60709 LPE                       │
└─────────────────────────────────────────────────────────────┘

[1] EVASIÓN DE DEFENSAS
    ├─ KillETW()   → Parchea EtwEventWrite en ntdll con RET (0xC3)
    └─ KillAMSI()  → Parchea AmsiScanBuffer en amsi.dll con RET (0xC3)

[2] HEAP GROOMING (preparación de memoria)
    └─ GroomLookaside()
       ├─ Crea 4096 archivos: C:\Windows\Temp\groom_00000.blf
       ├─ Llama CreateLogFile() + AddLogContainer() por cada uno
       └─ Agota lookaside lists → garantiza layout de heap predecible

[3] PRIMITIVA DE ESCRITURA ARBITRARIA — ClfsArbWrite(Address, Value)
    ├─ Construye buffer CLFS malformado (0x102010 bytes)
    │    ├─ Firma válida CLFS en +0x00: 0x0201
    │    ├─ Sector size shift en +0x14: 2
    │    ├─ First client region en +0x28: 0x100
    │    ├─ cbRecord OVERSIZED en +0x100: 0xFF00 (64 KB > datos reales)
    │    ├─ Marcador shadow zone en +0x9A8: 0x13371337
    │    └─ CClfsContainerContext falso en offset (0xFF00 + 0x100):
    │         ├─ pContainer = TargetAddress - 0x10
    │         └─ cbContainer = Value (dato a escribir)
    ├─ Calcula checksum CLFS correcto (driver lo valida)
    ├─ Escribe contenedor malformado → C:\Windows\Temp\evil.blf
    ├─ Crea log apuntando a evil.blf
    ├─ Llama ClfsReadRestartArea() → dispara parsing kernel
    └─ Driver desborda buffer → escribe Value en Address ✓

[4] ROBO DE TOKEN SYSTEM
    ├─ Lee EPROCESS del proceso SYSTEM via PsInitialSystemProcess
    └─ Extrae token en EPROCESS + EPROCESS_TOKEN (offset 0x4c0)

[5] ESCALACIÓN DE PRIVILEGIOS
    └─ ClfsArbWrite(CurrentEprocess + 0x4c0, SystemToken)
       └─ Sobreescribe token del proceso actual con token SYSTEM ✓

[6] EJECUCIÓN DE PAYLOAD C2
    ├─ VirtualAlloc(PAGE_EXECUTE_READWRITE)
    ├─ Copia shellcode beacon de 1789 bytes
    ├─ CreateThread() → ejecución como NT AUTHORITY\SYSTEM
    └─ Beacon C2: IPv6 + DoH → fallback Gmail drafts
       └─ sRDI + sleep obfuscation + ETW/AMSI ya parcheados

[7] PERSISTENCIA
    └─ Sleep(INFINITE) → proceso mantiene token SYSTEM

Offsets EPROCESS (Windows 11 24H2 build 26100.3485+)

CampoOffsetDescripción
EPROCESS_TOKEN0x4C0Token de seguridad del proceso
EPROCESS_PID0x440Process ID (PID)
EPROCESS_LINKS0x448Lista enlazada de procesos activos
EPROCESS_NAME0x5A8Nombre del proceso (ImageFileName)

⚠️ Estos offsets varían entre builds de Windows. Requieren actualización para otras versiones.


Mecanismo del Buffer Overflow en CLFS

root@kitploit:~
Contenedor CLFS legítimo:
  [Header 0x100 bytes][Record: cbRecord bytes de datos reales]

Contenedor malformado (evil.blf):
  [Header válido][cbRecord=0xFF00 → kernel lee 65,280 bytes]
                          ↓
  Kernel overflow → llega a CClfsContainerContext falso
                          ↓
  pContainer  = TargetKernelAddress - 0x10
  cbContainer = ValueToWrite
                          ↓
  Driver usa estructura falsa → escribe ValueToWrite en TargetKernelAddress

Funciones Clave — CVE-2025-60709.c

FunciónPropósito
GetKernelBase()ZwQuerySystemInformation(SystemModuleInformation) → base de ntoskrnl.exe
KillETW()VirtualProtect + sobreescribe EtwEventWrite en ntdll.dll con 0xC3 (RET)
KillAMSI()Carga amsi.dll + sobreescribe AmsiScanBuffer con 0xC3 (RET)
GroomLookaside()Crea 4096 logs CLFS para exhaust de lookaside lists → heap determinista
ClfsArbWrite()Núcleo del exploit — primitiva de escritura arbitraria en kernel
main()Orquesta ataque: ETW→AMSI→groom→token theft→arb write→beacon

Diferencias C vs Go

AspectoVersión CVersión Go
TipoExploit funcional (según documentación)Demo educativa únicamente
APIsAcceso directo (ntdll, clfsw32, advapi32)syscall.NewLazyDLL() wrappers
Checksum CLFSAlgoritmo completoPlaceholder simplificado
Direcciones kernelRealesHardcoded placeholder (0x123456)
Payload C2Shellcode 1789 bytesBytes NOP (0x90) de prueba
Resultado esperadoEscalación a SYSTEMMensaje "Arb write failed (yeah)"

Compilación

Versión C (requiere Visual Studio Build Tools + Windows SDK):

root@kitploit:~
cl /O1 /MT /link ntdll.lib advapi32.lib clfsw32.lib CVE-2025-60709.c

Versión Go (requiere Go 1.19+ en Windows x64):

root@kitploit:~
go build -ldflags="-s -w" -o CVE-2025-60709.exe CVE-2025-60709.go

🛡️ Mitigaciones y Detección

Mitigaciones de Windows

MitigaciónEfectividad
HVCI (Hypervisor-protected Code Integrity)Alta — previene escritura en memoria kernel
kCFI (Kernel Control Flow Integrity)Alta — dificulta ROP/JOP chains
CFG (Control Flow Guard)Media — dificulta ejecución de shellcode
Windows DefenderMedia — detecta técnicas conocidas
Actualización WindowsAlta — parche oficial elimina la vulnerabilidad

Regla YARA

root@kitploit:~
rule CVE_2025_60709_CLFS_LPE {
    meta:
        description = "Detects CVE-2025-60709 CLFS LPE exploit"
        author      = "KONDORDEVSECURITYCORP"
        date        = "2026-03"
        cve         = "CVE-2025-60709"
        severity    = "critical"

    strings:
        $clfs_sig   = { 01 02 00 00 }
        $magic      = { 37 13 37 13 }
        $evil_file  = "evil.blf" ascii wide
        $groom_file = "groom_" ascii wide
        $etw_func   = "EtwEventWrite" ascii wide
        $amsi_func  = "AmsiScanBuffer" ascii wide
        $token_off  = { C0 04 00 00 }       // EPROCESS_TOKEN = 0x4C0

    condition:
        3 of them
}

IOCs — Artefactos del Sistema

TipoValor
Archivo malformadoC:\Windows\Temp\evil.blf
Log malformado\\.\C:\Windows\Temp\evil_log
Archivos groomingC:\Windows\Temp\groom_00000.blf … groom_04095.blf
ProcesoAlta prioridad (REALTIME_PRIORITY_CLASS) anómala

Detección Comportamental

root@kitploit:~
ARCHIVO:   Creación masiva de *.blf en C:\Windows\Temp\ (> 100 en segundos)
ARCHIVO:   Creación de C:\Windows\Temp\evil.blf
PROCESO:   Proceso en modo REALTIME_PRIORITY + llamadas a ClfsReadRestartArea
MEMORIA:   Escritura en PAGE_EXECUTE_READWRITE + CreateThread inmediato
API:       VirtualProtect sobre EtwEventWrite o AmsiScanBuffer
KERNEL:    Acceso a PsInitialSystemProcess desde user-mode

Verificación Rápida

root@kitploit:~
# Verificar archivos de grooming
Get-ChildItem C:\Windows\Temp -Filter "groom_*.blf" | Measure-Object

# Verificar archivo exploit
Test-Path C:\Windows\Temp\evil.blf

# Verificar integridad de ntdll (ETW patch)
Get-AuthenticodeSignature (Get-Process -Name notepad | Select -First 1).Path

🇬🇧 Documentación en Inglés

Descripción

CVE-2025-60709 es una vulnerabilidad de escalación de privilegios locales (LPE) en el controlador CLFS.sys (Common Log File System) de Windows. Permite a un atacante con ejecución de código local escalar desde un usuario estándar hasta NT AUTHORITY\SYSTEM a través de un buffer overflow en el análisis de contenedores CLFS, obteniendo una primitiva de escritura arbitraria en la memoria del kernel.

Este repositorio contiene dos implementaciones:

  • CVE-2025-60709.c — Implementación original en C (acceso directo a APIs nativas de Windows)
  • CVE-2025-60709.go — Port en Go (versión de demostración/educativa — NO explota vulnerabilidades reales)

🎯 Detalles de la Vulnerabilidad

CampoDetalle
CVE IDCVE-2025-60709
TipoEscalación de Privilegios Local (LPE)
ComponenteCLFS.sys (controlador Common Log File System)
SO objetivoWindows 11 24H2 (build 26100.3485+)
ArquitecturaSolo x64
VectorBuffer overflow en análisis de contenedor CLFS
ImpactoEscalación a NT AUTHORITY\SYSTEM
PrerrequisitosEjecución local de código (usuario estándar)

🔬 Análisis Técnico

Flujo de Explotación

root@kitploit:~
[1] EVASIÓN DE DEFENSAS
    ├─ KillETW()   → Parchea EtwEventWrite en ntdll con RET (0xC3)
    └─ KillAMSI()  → Parchea AmsiScanBuffer en amsi.dll con RET (0xC3)

[2] HEAP GROOMING
    └─ GroomLookaside()
       ├─ Crea 4096 archivos: C:\Windows\Temp\groom_00000.blf
       ├─ Llama CreateLogFile() + AddLogContainer() para cada uno
       └─ Agota lookaside lists → garantiza diseño de heap predecible

[3] PRIMITIVA DE ESCRITURA ARBITRARIA — ClfsArbWrite(Dirección, Valor)
    ├─ Construye buffer CLFS malformado (0x102010 bytes)
    │    ├─ Firma CLFS válida en +0x00: 0x0201
    │    ├─ cbRecord sobredimensionado en +0x100: 0xFF00 (65,280 bytes)
    │    ├─ Marcador de zona sombra en +0x9A8: 0x13371337
    │    └─ CClfsContainerContext falso en offset (0xFF00 + 0x100):
    │         ├─ pContainer  = DirecciónObjetivo - 0x10
    │         └─ cbContainer = Valor (dato a escribir)
    ├─ Calcula checksum CLFS válido (el controlador lo valida)
    ├─ Escribe contenedor malformado → C:\Windows\Temp\evil.blf
    ├─ Crea log apuntando a evil.blf
    ├─ Llama ClfsReadRestartArea() → dispara análisis del kernel
    └─ El controlador desborda el buffer → escribe Valor en Dirección ✓

[4] ROBO DE TOKEN DE SYSTEM
    ├─ Lee EPROCESS del proceso SYSTEM vía PsInitialSystemProcess
    └─ Extrae token en EPROCESS + 0x4C0

[5] ESCALACIÓN DE PRIVILEGIOS
    └─ ClfsArbWrite(CurrentEprocess + 0x4C0, SystemToken)
       └─ Sobrescribe el token del proceso actual con el token SYSTEM ✓

[6] EJECUCIÓN DE PAYLOAD C2
    ├─ VirtualAlloc(PAGE_EXECUTE_READWRITE)
    ├─ Copia shellcode beacon de 1789 bytes
    ├─ CreateThread() → se ejecuta como NT AUTHORITY\SYSTEM
    └─ Beacon: C2 IPv6 + DoH → respaldo Gmail drafts
       └─ sRDI + ofuscación sleep + ETW/AMSI ya parcheados

[7] PERSISTENCIA
    └─ Sleep(INFINITE) → el proceso conserva el token SYSTEM

Offsets EPROCESS (Windows 11 24H2 build 26100.3485+)

CampoOffsetDescripción
EPROCESS_TOKEN0x4C0Token de seguridad del proceso
EPROCESS_PID0x440ID del proceso
EPROCESS_LINKS0x448Lista enlazada de procesos activos
EPROCESS_NAME0x5A8Nombre del proceso (ImageFileName)

⚠️ Estos offsets varían entre builds de Windows. Deben actualizarse para otras versiones.


Mecanismo del Buffer Overflow en CLFS

root@kitploit:~
Contenedor CLFS legítimo:
  [Cabecera de 0x100 bytes][Registro: cbRecord bytes de datos reales]

Contenedor malformado (evil.blf):
  [Cabecera válida][cbRecord=0xFF00 → el kernel lee 65,280 bytes]
                        ↓
  El kernel se desborda → alcanza CClfsContainerContext falso
                        ↓
  pContainer  = DirecciónKernelObjetivo - 0x10
  cbContainer = ValorAEscribir
                        ↓
  El controlador usa la estructura falsa → escribe ValorAEscribir en DirecciónKernelObjetivo

Funciones Clave — CVE-2025-60709.c

FunciónPropósito
GetKernelBase()ZwQuerySystemInformation(SystemModuleInformation) → base de ntoskrnl.exe
KillETW()VirtualProtect + sobrescribe EtwEventWrite en ntdll.dll con 0xC3 (RET)
KillAMSI()Carga amsi.dll + sobrescribe AmsiScanBuffer con 0xC3 (RET)
GroomLookaside()Crea 4096 logs CLFS para agotar lookaside lists → heap determinista
ClfsArbWrite()Núcleo del exploit — primitiva de escritura arbitraria en memoria del kernel
main()Orquesta: ETW→AMSI→groom→robo de token→escritura arbitraria→beacon

Diferencias entre C y Go

AspectoVersión CVersión Go
TipoExploit funcional (según la documentación)Demo educativa solamente
APIsDirectas (ntdll, clfsw32, advapi32)Wrappers con syscall.NewLazyDLL()
Checksum CLFSAlgoritmo completoPlaceholder simplificado
Direcciones del kernelRealesPlaceholder hardcodeado (0x123456)
Payload C2Shellcode de 1789 bytesBytes NOP (0x90) de prueba
Resultado esperadoEscalación a SYSTEMMensaje "Arb write failed (yeah)"

Instrucciones de Compilación

Versión C (requiere Visual Studio Build Tools + Windows SDK):

root@kitploit:~
cl /O1 /MT /link ntdll.lib advapi32.lib clfsw32.lib CVE-2025-60709.c

Versión Go (requiere Go 1.19+ en Windows x64):

root@kitploit:~
go build -ldflags="-s -w" -o CVE-2025-60709.exe CVE-2025-60709.go

🛡️ Mitigaciones y Detección

Mitigaciones de Windows

MitigaciónEfectividad
HVCI (Integridad de Código Protegida por Hypervisor)Alta — previene escrituras en memoria del kernel
kCFI (Integridad de Flujo de Control del Kernel)Alta — bloquea cadenas ROP/JOP
CFG (Guardia de Flujo de Control)Media — dificulta la ejecución de shellcode
Windows DefenderMedia — detecta técnicas conocidas
Actualización de WindowsAlta — el parche oficial elimina la vulnerabilidad

Regla YARA

root@kitploit:~
rule CVE_2025_60709_CLFS_LPE {
    meta:
        description = "Detecta el exploit LPE de CLFS CVE-2025-60709"
        author      = "KONDORDEVSECURITYCORP"
        date        = "2026-03"
        cve         = "CVE-2025-60709"
        severity    = "critical"

    strings:
        $evil_file  = "evil.blf" ascii wide
        $groom_file = "groom_" ascii wide
        $etw_func   = "EtwEventWrite" ascii wide
        $amsi_func  = "AmsiScanBuffer" ascii wide
        $magic      = { 37 13 37 13 }
        $token_off  = { C0 04 00 00 }

    condition:
        3 of them
}

IOCs — Artefactos del Sistema

TipoValor
Archivo malformadoC:\Windows\Temp\evil.blf
Log malformado\\.\C:\Windows\Temp\evil_log
Archivos de groomingC:\Windows\Temp\groom_00000.blf … groom_04095.blf
ProcesoPrioridad REALTIME_PRIORITY_CLASS anómala

Detección Comportamental

root@kitploit:~
ARCHIVO:   Creación masiva de *.blf en C:\Windows\Temp\ (> 100 en segundos)
ARCHIVO:   Creación de C:\Windows\Temp\evil.blf
PROCESO:   Proceso con REALTIME_PRIORITY + llamadas a ClfsReadRestartArea
MEMORIA:  Escritura en PAGE_EXECUTE_READWRITE + CreateThread inmediato
API:      VirtualProtect sobre EtwEventWrite o AmsiScanBuffer
KERNEL:   Acceso a PsInitialSystemProcess desde modo usuario

Verificación Rápida

root@kitploit:~
# Verificar archivos de grooming
Get-ChildItem C:\Windows\Temp -Filter "groom_*.blf" | Measure-Object

# Verificar archivo exploit
Test-Path C:\Windows\Temp\evil.blf

📚 Referencias Técnicas / Technical References

  • Common Log File System (CLFS) Architecture — Microsoft Docs
  • EPROCESS Structure Analysis — Windows Internals
  • Lookaside List Heap Grooming Techniques
  • Windows Kernel Exploitation — Token Stealing
  • HVCI and Virtualization Based Security — Microsoft

⚠️ Legal Notice / Aviso Legal

EN: This exploit PoC is published for security research, vulnerability analysis, threat intelligence, and defensive purposes ONLY. Using this code against systems without explicit written authorization is illegal and may violate the CFAA, Computer Misuse Act, and equivalent laws. Authors assume no liability for misuse.

ES: Este PoC de exploit se publica únicamente para investigación de seguridad, análisis de vulnerabilidades, inteligencia de amenazas y fines defensivos. Usar este código contra sistemas sin autorización escrita explícita es ilegal y puede violar el CFAA, Computer Misuse Act y legislación equivalente. Los autores no asumen responsabilidad por el uso indebido.


GitHub Telegram

Descargar herramienta