OpenSSH *sshole Flaw Lets Attackers Bypass Password-Disabled Accounts On Alpine Linux
A newly disclosed vulnerability in OpenSSH, dubbed "*sshole," allows attackers to log into accounts that were explicitly configured to block password authentication on musl-based Linux distributions, simply by entering an oversized password.
The flaw stems from a subtle interaction between OpenSSH's password handling and the musl C library's crypt() function. It affects Alpine Linux, OpenWrt, Buildroot, and Yocto systems where PAM authentication is disabled and SSH password authentication is enabled.
How It Works
Linux accounts can be locked down by replacing their password hash with an asterisk (*) in /etc/shadow. Since * is not a valid hash, no password should ever match it.
In 2016, OpenSSH was patched to fix a username enumeration vulnerability (CVE-2016-6210). The fix made OpenSSH perform password hashing even for accounts with no usable hash, to normalize response times. The problem: musl's crypt() returns * when hashing fails, including when a password exceeds its 256-byte limit.
So an attacker submits a password longer than 256 bytes, musl's crypt() returns *, and OpenSSH compares that * against the stored *. They match. The attacker is logged in.
Exploitation Requirements
The vulnerability requires all of the following conditions:
- OpenSSH running on a musl-based system (Alpine Linux, OpenWrt, Buildroot, Yocto)
- PAM authentication disabled (Alpine's default)
- SSH password authentication enabled
- At least one account with
*as its password hash - Another account with a valid password hash
Alpine Linux's official AWS and Azure cloud images ship with an affected default alpine account that has passwordless doas privileges, meaning an attacker could pivot from SSH login to root access.
Systems using glibc (Debian, Ubuntu, Fedora) or PAM authentication are not vulnerable.
Discovery via AI Agents
Security researcher Ozgun Kultekin says he found the vulnerability using AI agents that ran approximately 17'600 authentication tests across different OpenSSH configurations, malformed password hashes, and oversized passwords. The flaw has existed since 2016.
Fix Available
OpenSSH 10.6p2 patches the vulnerability. Alpine Linux administrators should run apk upgrade openssh immediately.
Those who cannot update right away should disable SSH password authentication in sshd_config:
PasswordAuthentication no
Administrators can check for signs of exploitation by searching logs for successful password logins on accounts that should not allow them:
grep "Accepted password" /var/log/messages
The vulnerability is a reminder that security fixes can introduce new attack surfaces in unexpected ways. A 2016 patch designed to prevent username enumeration ended up creating a login bypass that went undetected for a decade.