Researchers have disclosed a decade-old vulnerability, dubbed *sshole, that can let attackers log into some Linux devices without a password. The flaw sits in the interaction between OpenSSH and musl, a lightweight C library used by Alpine Linux. According to the source, the vulnerability may also affect other distributions that use the same configuration.

Exploitation requires several conditions. The system must run OpenSSH with musl and without PAM. It must also have at least one account that uses a SHA256 or SHA512 password hash and is set to passwordless by a "*" in the password field of /etc/shadow. Checkpoint said the account must be active, and that root accounts are safe under the default PermitRootLogin setting, though accessible accounts with doas or sudo rights can still reach root.

The Alpine maintainers said an attacker who can reach the SSH port can log in "without knowing any password" in a single connection. The source says that, when logging into a passwordless account, the attacker can gain access by entering more than 256 characters in the password field.

The source notes that Alpine is widely used, with the Docker Hub base image exceeding 1 billion downloads. It is also common in routers, smart TVs, industrial controllers, and other embedded devices, many of which are hard to update. Detectify said Shodan lists around 22 million systems with SSH open on port 22, though only a fraction meet the conditions for exploitation.

OpenSSH said it considers the root cause to be outside sshd, but that the bug can be exploited through sshd and avoided there. Musl developer Rich Felker wrote that he does not consider it a musl bug but an erroneous use by the caller. He said musl developers plan to change the mechanism in an upcoming release. Alpine and OpenSSH have both issued updates.

The discoverer said OpenWRT is affected, though by default it uses Dropbear rather than OpenSSH. The discoverer also named buildroot and yocto, but the source says those claims are not yet confirmed. No CVE designation has been assigned.

Users of Linux systems that run both musl and OpenSSH should check whether they are affected and install the Alpine and OpenSSH patches.