A critical flaw in the Netkit Telnet server could let remote attackers obtain full root access on Ubuntu, Kali Linux, and Debian systems without ever entering a valid password. Security researcher Liad Levy disclosed the issue, now tracked as CVE-2026-141380, via the OSS-Security mailing list on December 2, assigning it a CVSS 3.1 score of 9.8 — just shy of the maximum possible severity. An affected Netkit package on Gentoo is also implicated.
How the Bypass Actually Works
The bug traces back to a Debian-specific patch that changed how Netkit’s telnetd handles environment variables — the configuration values programs pass to one another during setup. During the initial connection handshake, the server accepts settings flagged as “user-defined” without properly checking them against its normal allow-list, and the remote client controls that flag. A privileged helper process then forwards those unchecked settings straight to the system login program, before the connecting user has proven their identity at all.
What happens next depends heavily on configuration. If the Telnet service is running as root, the login program can be made to load attacker-controlled code with full system privileges in one step. Running the service under a lower-privileged account closes that particular door, but Levy found a second route: on systems running util-linux 2.40 or newer, the login program itself can still be tricked into skipping its normal authentication checks.
It’s important to distinguish this from the passwordless Telnet access abused by the Kairos botnet, where attackers simply logged in using blank passwords left configured on poorly secured devices. This flaw is different — and arguably worse — because it bypasses the password verification step itself, rather than exploiting weak credentials.
Confirmed Vulnerable Systems
Levy reported successfully demonstrating passwordless root access on Debian 13 (“Trixie”), Ubuntu 25.04, Ubuntu 25.10, and Kali Linux Rolling. The affected components are Debian’s Netkit-based telnetd and telnetd-ssl packages, along with Gentoo’s net-misc/netkit-telnetd. Debian 11 (“Bullseye”) does accept the same untrusted settings but ships an older util-linux (2.36) that lacks the specific login feature the second attack path depends on — a reminder that the installed login version and service configuration matter as much as the distribution name itself.
To be clear, this disclosure describes successful lab testing rather than confirmed real-world attacks. But given how trivial the prerequisites are — simply being able to reach an open Telnet port and write a file somewhere on the target — that gap between proof-of-concept and active exploitation may not last long once the technical details circulate more widely.
No Patch Yet — Here’s What To Do
As of this writing, there is no released fix. Levy has proposed either restoring strict validation of client-supplied settings or filtering what the privileged helper process hands off to the login program, but those remain proposals rather than shipped patches. Administrators should not wait around:
- Identify whether Netkit Telnet is installed and whether TCP port 23 is reachable from outside trusted management networks.
- Disable the Telnet service entirely if it isn’t actively needed — SSH should be the default for remote administration in nearly every case.
- If a legacy system genuinely requires Telnet, restrict access strictly to trusted management hosts and firewall off untrusted networks.
- Watch vendor security notices closely for an update explicitly referencing CVE-2026-141380 that covers your specific Netkit package — a separate fix issued for CVE-2026-28372 in GNU Inetutils does not address this Netkit flaw.
The Bigger Picture
This disclosure lands alongside other recent research into pre-authentication weaknesses on port 23, reinforcing a theme: Telnet’s fundamental design predates modern security expectations, and patching around individual bugs in it is a losing long-term strategy. Until a confirmed fix ships, the safest posture is simply keeping the protocol off any network an untrusted party could reach — treating password strength as irrelevant, since this bypass skips the password check entirely.
Leave a Reply
You must be logged in to post a comment.