OpenSSH SSHole (CVE-2026-123158): Is Your Server or Docker Affected?
Imagine your server's front door has a lock that opens if you type a password that's long enough. Not the right password. Just a long one. That's roughly what SSHole (CVE-2026-123158) does to some Linux machines running OpenSSH, the program almost everyone uses to log in to servers remotely.
Attackers found it fast. The fix came out on November 5, and the first break-in attempts showed up within hours. By November 9, the US cybersecurity agency CISA had added it to its list of bugs being actively exploited.
Here's the good part: most servers are not affected. The bug only bites on a specific kind of Linux, and Alpine Linux is the big one. This guide shows you how to tell in two minutes whether you need to act, and exactly what to do if you do.
Last checked: November 17, 2026.
The short version
| What it is | A login bypass in OpenSSH's server (sshd). A password of a few hundred characters can open certain accounts |
| Who's affected | Linux built on the musl library without PAM, such as Alpine Linux, with password logins switched on |
| Who's safe | Ubuntu, Debian, Fedora, Red Hat and other glibc systems; servers that only allow SSH keys |
| Fixed in | OpenSSH 10.6p2, and patched Alpine packages for 3.19 to edge |
| Being exploited? | Yes. Attackers have gained root on real systems |
| Severity | CVSS 8.1 (High) |
| Quick workaround | Set PasswordAuthentication no and restart sshd |
What is SSHole, in plain English?
Every Linux account has a password field. Some accounts deliberately have no usable password. Their field just holds a *, which means "nobody can log in with a password here." Root on recent Alpine images, users who only log in with keys, and many directory accounts look like this.
When you type a password, the server scrambles it and compares the result with what's stored. On systems using the musl C library, that scrambling step gives up on passwords longer than 256 characters and returns, you guessed it, *.
So the server compares * with *, sees a match, and lets the attacker in. No real password needed. Any password between 256 and 1,024 characters works, and the Alpine team says the attack "works every time."
The bug came from two old decisions meeting each other: a 2012 choice in musl and a 2016 OpenSSH security change. It sat there for years until researcher Özgün Kültekin of Wakefield reported it. OpenSSH 10.6p2 now blocks it inside sshd itself.
Does a strong password protect me?
No, and that's what makes this bug unusual. The attacker never guesses your password. They target accounts that have no password. Long, unique passwords are still a good idea for everything else (test yours with our password strength checker), but they won't stop SSHole.
Am I affected? Check in two minutes
You're only at risk if all four of these are true:
- Your system uses musl instead of glibc.
sshdruns without PAM (Alpine's defaultopenssh-serverpackage does).- Password logins are on (
PasswordAuthentication yes, the default). - At least one account has
*as its password, and at least one other account has a real password hash (starting$5$or$6$).
Run these on the server. They only read settings and change nothing. (Alpine often has no sudo: run them as root or swap in doas.)
Step 1: Which C library do you have?
ldd --version 2>&1 | head -1
If it mentions GLIBC, you're not affected by this bug. If it mentions musl, keep going.
We ran this on our own Ubuntu 24.04 server first. It printed GLIBC 2.39, so we were safe, even though ssh -V showed OpenSSH 9.6p1, which is "before 10.6p2." That's the trap: the version number alone doesn't tell you if you're at risk. The C library does.
Step 2: Are password logins switched on?
sudo sshd -T | grep -Ei '^(usepam|passwordauthentication)'
passwordauthentication no means you're safe. usepam yes also protects you.
Step 3: Which accounts match the pattern?
# Accounts with no usable password (the target)
sudo awk -F: '$2=="*"{print $1}' /etc/shadow
# Accounts with a real password hash (needed for the attack to work)
sudo awk -F: '$2 ~ /^\$[56]\$/{print $1}' /etc/shadow
If the first command prints names, and the second prints at least one, and Steps 1 and 2 didn't clear you, you are exposed. Patch now.
What about Docker and Alpine containers?
Alpine is one of the most popular base images on Docker Hub, so this is the question most people are asking. Relax a little: a container is only affected if it actually runs sshd. Most Alpine containers (web apps, Nginx, Node, Redis) don't, and the Alpine team confirms those are fine.
Check what your running containers have inside:
for c in $(docker ps -q); do
echo "== $(docker inspect -f '{{.Name}}' $c)"
docker exec $c sh -c 'cat /etc/alpine-release 2>/dev/null; command -v sshd' 2>/dev/null
done
Look for any container that prints both an Alpine version and an sshd path. Those are the ones to fix. Rebuild them on an updated base image. Restarting an old container changes nothing.
Also check routers and small devices built on OpenWrt, Buildroot or Yocto, which often use musl. The researcher flagged them, so check their firmware updates.
Alpine cloud images: a hidden catch
Official Alpine cloud images (tiny-cloud) from 3.18.11 to 3.24.3 come with a user called alpine that has no password and can run admin commands without one. They're safe on first boot. But the moment anyone sets a password for any account on that machine, the condition in Step 3 becomes true, and an attacker can log in as alpine and become root. Images from 3.24.4 onward include the fix.
How to fix it on Alpine
1. Update and restart.
apk upgrade -U -a
rc-service sshd restart
Don't skip the restart. The Alpine team warns that upgrading the package doesn't restart the running sshd. The old, vulnerable program keeps answering connections until you do.
2. Confirm you got a fixed version:
apk info -v openssh-server
| Alpine branch | Fixed openssh package |
|---|---|
| edge | 10.6_p2-r0 |
| 3.24 | 10.3_p1-r2 |
| 3.23 | 10.2_p1-r1 |
| 3.22 | 10.0_p1-r11 |
| 3.21 | 9.9_p2-r1 |
| 3.20 | 9.7_p1-r6 |
| 3.19 | 9.7_p2-r5 or 9.6_p1-r3 |
Your version should be the one listed or newer. Older branches aren't in Alpine's fixed list, so move those machines to a current release.
Built OpenSSH from source? Upgrade to OpenSSH 10.6p2 and restart sshd.
Can't update today? Turn off password logins
This closes the hole completely, and it's good practice anyway. First, make sure you can log in with an SSH key, and keep your current session open while you test, so you can't lock yourself out.
echo 'PasswordAuthentication no' | sudo tee /etc/ssh/sshd_config.d/00-no-passwords.conf
sudo sshd -t && sudo rc-service sshd restart
sudo sshd -T | grep -i passwordauthentication
The last line should print passwordauthentication no. On Alpine, also check the main /etc/ssh/sshd_config for a PasswordAuthentication yes line and change it, as the Alpine advisory recommends. Then open a new terminal and log in with your key before closing the old one.
Our Linux VPS security checklist walks through setting up SSH keys from scratch, if you haven't yet.
Was I hacked? Signs to look for
Attackers didn't just test this bug. Security firm GreyNoise recorded the first successful break-in on November 7, about 40 hours after the fix came out. Attackers looked around the system, tried to read password hashes and SSH keys, and added their own keys for future access. One installed a Python remote-control program as root.
If you were exposed, check these:
# Password logins to accounts that shouldn't have one
grep 'Accepted password for' /var/log/messages
# Unknown SSH keys
cat /root/.ssh/authorized_keys /home/*/.ssh/authorized_keys 2>/dev/null
# Recently added users
tail -5 /etc/passwd
Red flags: a password login for root, alpine, or a user who only ever uses keys; a key you don't recognize; a user you didn't create. Also review recent doas use and any new startup services.
If you can't rule out a break-in, treat the server as compromised. Back up your data, build a fresh server from a patched image, and change every key and password that lived on the old one.
The bigger lesson
SSHole hit fast because it was easy: no guessing, no timing tricks, one long password. But it only worked where password logins were left on. Servers that used SSH keys only were never at risk, whatever library they used.
So the two habits that keep coming up in our patch guides are the same here:
- Switch off SSH passwords and use keys.
- Let security updates install automatically, then make sure services restart.
We used the same check-then-patch routine for the Apache HTTP/2 flaw and the PHP2Shell and Node.js bugs earlier this month.
Quick answers
What is CVE-2026-123158?
A password authentication bypass in OpenSSH's sshd, nicknamed SSHole. On Linux using musl without PAM, a password of 256 to 1,024 characters can log in to accounts that have no usable password.
Is Ubuntu or Debian affected by SSHole? No. Ubuntu, Debian, Fedora and Red Hat use glibc, not musl, so the bug doesn't apply to their standard OpenSSH. Update anyway as part of normal maintenance.
Is Alpine Linux affected?
Yes, if sshd runs with password logins on (the default) and the account conditions are met. Patched packages are out for Alpine 3.19 to edge.
Which OpenSSH version fixes SSHole? OpenSSH 10.6p2, released November 5, 2026. Alpine backported the fix to older package versions, listed in the table above.
Do I need to restart sshd after updating?
Yes. The update doesn't restart the running server. Run rc-service sshd restart on Alpine.
Are Docker containers affected?
Only containers that run sshd on a musl-based image, usually Alpine. Most containers don't run SSH at all.
Is SSHole being exploited? Yes. CISA added it to its Known Exploited Vulnerabilities list on November 9, 2026, and researchers have seen attackers gain root on real machines.
What's the fastest fix if I can't update?
Set PasswordAuthentication no in your SSH config and restart sshd, after confirming your key login works.
Sources
The facts in this article were checked against these sources.
- OpenSSH 10.6p2 release notes openssh.org
- Alpine Linux: openssh-server password authentication bypass alpinelinux.org
- Alpine security tracker: CVE-2026-123158 security.alpinelinux.org
- NVD: CVE-2026-123158 nvd.nist.gov
- CISA Known Exploited Vulnerabilities catalog cisa.gov
- Help Net Security: OpenSSH flaw exploited hours after disclosure helpnetsecurity.com
- BleepingComputer: Hackers exploit SSHole OpenSSH flaw bleepingcomputer.com