critical

CVE

CVE-2026-123158, CVE-2026-109518, CVE-2026-85091, CVE-2026-107891, CVE-2026-4738, CVE-2026-122054, CVE-2016-6210, CVE-2019-5021

CWE

CWE-287, CWE-367, CWE-59, CWE-787, CWE-190

Affected Surface

  • Portable OpenSSH (`openssh-portable` / `sshd`) versions `7.3p1` through `10.6p1` running on Linux with `musl` libc and `UsePAM no` (including Alpine Linux, OpenWrt, Buildroot, and Yocto images where `/etc/shadow` contains `'*'` entries alongside at least one `$5$` or `$6$` password hash, `CVE-2026-123158`, CVSS 8.1 High, fixed in `10.6p2`)
  • Debian, Ubuntu, and derivative `apt` package manager versions `< 3.0.4` (`trixie`), `< 2.6.1+deb12u2` (`bookworm`), and `< 2.2.4+deb11u2` (`bullseye`) (`CVE-2026-109518`, `DSA-6607-1` / `DLA-4855-1` / `APT-2026-11-01`)
  • C / C++ compression library `zlib` (`madler/zlib`) and bundled `minizip` versions `< 1.4` (`CVE-2026-85091` / `TOB-ZLIB-003`, `THM-ZLIB-001` in `1.3.1` and `1.3.2`, `TOB-ZLIB-004`, `TOB-ZLIB-013`, `TOB-ZLIB-014`, `CVE-2026-4738`, fixed in `zlib 1.4`)
  • `musl` libc versions `< 1.2.7` (`CVE-2026-107891`, CVSS 8.1 High, `regcomp` integer overflows leading to heap out-of-bounds writes) and GNU C Library (`glibc`) `2.18` through `2.31` (`CVE-2026-122054` / `GLIBC-SA-2026-0026`)

TL;DR

Between 4 and 6 November 2026, four advisories hit foundational Linux system daemons and C libraries that underpin container base images, cloud VMs, and native dependencies:

  1. Portable OpenSSH 10.6p2 patches "sshole" (CVE-2026-123158, CVSS 8.1 High, public PoC): Discovered by Özgün Kültekin of Wakefield (sshhole.com), "sshole" allows an unauthenticated remote attacker to log into any account whose /etc/shadow password field is "*" by submitting any password between 257 and 1,024 characters on Linux systems running sshd with musl libc and without PAM (UsePAM no, the default on Alpine Linux, OpenWrt, Buildroot, and Yocto). Whenever at least one user on the system has a SHA-256 ($5$) or SHA-512 ($6$) password hash in /etc/shadow, OpenSSH’s pick_salt() helper borrows that salt when hashing a candidate password for a "*" account (!valid_salt). Because musl’s crypt_sha512 and crypt_sha256 reject keys longer than KEY_MAX (256 bytes) by returning 0 and musl’s crypt() wrapper returns the literal string "*" on failure, strcmp(encrypted_password, pw_password) compares "*" against "*" and succeeds on the first try. On Alpine >= 3.16, root and key-only accounts (including the default alpine user with passwordless doas on official Alpine AWS and Azure cloud images) use "*" in /etc/shadow. Fixed in OpenSSH 10.6p2.
  2. Debian and Ubuntu apt (CVE-2026-109518, CVSS 7.7 High / Debian Critical DSA-6607-1 & DLA-4855-1): Discovered by Max Justicz (max@justi.cz), apt versions prior to 3.0.4 (trixie), 2.6.1+deb12u2 (bookworm), and 2.2.4+deb11u2 (bullseye) can be tricked by an on-path HTTP attacker or malicious mirror into merging two package downloads onto the same destination file via HTTP redirects and Acquire::Retries download resumption (206 Partial Content). Because HttpMethod::DealWithHeaders() opened Queue->DestFile with FileFd::WriteAny without FileFd::Exclusive, resuming a download followed an existing hardlink and overwrote an already-verified .deb package before dpkg installed it as root.
  3. zlib 1.4 security release (CVE-2026-85091 / TOB-ZLIB-003, THM-ZLIB-001, TOB-ZLIB-004, TOB-ZLIB-013, TOB-ZLIB-014): Released on 4-5 November 2026, zlib 1.4 patches a heap buffer overflow in non-blocking gzwrite() (CVE-2026-85091), an 8 MB out-of-bounds heap/stack write in inflateGetDictionary() past the caller’s 32 KB buffer affecting zlib 1.3.1 and 1.3.2 (THM-ZLIB-001), a 1-byte window allocation overrun in inflateSync() (TOB-ZLIB-004), out-of-bounds reads/writes in inflatePrime() and deflatePrime(), and a double free (block_central_name()) plus directory traversal (miniunz) in minizip.
  4. musl libc < 1.2.7 (CVE-2026-107891, CVSS 8.1 High) and glibc (CVE-2026-122054 / GLIBC-SA-2026-0026): CVE-2026-107891 tracks multiple integer overflows in musl’s regcomp() regular-expression compiler that cause undersized heap allocations and out-of-bounds heap writes when compiling untrusted regex patterns.

What to do now: Upgrade OpenSSH on Alpine and other musl-based systems to >= 10.6p2 (apk upgrade openssh) or set PasswordAuthentication no in /etc/ssh/sshd_config immediately. Upgrade apt on Debian and Ubuntu hosts (apt >= 3.0.4, 2.6.1+deb12u2, or 2.2.4+deb11u2, or set Acquire::Retries 0; in /etc/apt/apt.conf before running apt update && apt upgrade), and update zlib to >= 1.4 and musl to >= 1.2.7.

Affected packages and components

Ecosystem / DistroPackage / ProjectCVE / AdvisorySeverityAffected versionsFixed versionVulnerable component
Linux / C (musl without PAM)Portable OpenSSH (sshd)CVE-2026-123158 (“sshole”)CVSS 8.1 High7.3p1 through 10.6p1 (when built with musl libc and run with UsePAM no)10.6p2sys_auth_passwd() in auth-passwd.c and xcrypt() / pick_salt() in openbsd-compat/xcrypt.c
Debian / UbuntuaptCVE-2026-109518 (DSA-6607-1, DLA-4855-1, APT-2026-11-01)CVSS 7.7 High (Debian Critical)< 3.0.4 (trixie), < 2.6.1+deb12u2 (bookworm), < 2.2.4+deb11u2 (bullseye)3.0.4, 2.6.1+deb12u2, 2.2.4+deb11u2HttpMethod::DealWithHeaders() in methods/http.cc, methods/rred.cc, methods/store.cc
C / C++zlib & minizip (madler/zlib)CVE-2026-85091, THM-ZLIB-001, TOB-ZLIB-004, TOB-ZLIB-013, TOB-ZLIB-014High<= 1.3.2 (THM-ZLIB-001 affects 1.3.1 and 1.3.2)1.4gzwrite.c, inflate.c (inflateGetDictionary, inflateSync, inflatePrime), deflate.c, contrib/minizip
Linux / Cmusl libcCVE-2026-107891CVSS 8.1 High< 1.2.71.2.7regcomp() regular-expression compiler

Technical analysis

1. "sshole" (CVE-2026-123158): how four separate design choices over 46 years turned "*" in /etc/shadow into a 257-byte wildcard password

In Unix /etc/passwd and /etc/shadow files, setting an account’s password hash field to "*" marks the account as unable to authenticate with a password while still allowing SSH public-key logins (unlike "!", which OpenSSH treats as a locked account when PAM is disabled). In 2022 (CVE-2019-5021 follow-up commit fbe926af), Alpine Linux 3.16 changed its default root shadow entry from ! to * so key-based SSH logins to root and cloud-init accounts would work out of the box without PAM.

Four independent commits across musl and OpenSSH combined to break that invariant:

  1. August 2012 (musl commit b3c4cc12): Instead of returning NULL when crypt(key, salt) fails, musl’s crypt() returns a static two-byte failure token: "*".
  2. August 2012 (musl commit 88bf5a8a): Twenty days later, musl added SHA-256 and SHA-512 password hashing (src/crypt/crypt_sha512.c) with a hard length cap of #define KEY_MAX 256 to prevent CPU denial-of-service from giant passwords. If strlen(key) > 256, __crypt_sha512() returns 0 (NULL), causing musl’s outer crypt() wrapper to return "*".
  3. July 2016 (OpenSSH 7.3p1 fix for CVE-2016-6210): To stop attackers from timing how fast sshd rejects accounts without a valid password hash (pw_password = "*"), openbsd-compat/xcrypt.c added pick_salt(). When pw_password is "*" (which fails valid_salt), xcrypt(password, pw_password) calls pick_salt(), which scans /etc/shadow via getpwent() / shadow_pw() and copies the $6$... (or $5$...) salt prefix from the first real password-enabled account on the machine.
  4. The collision in sys_auth_passwd() (auth-passwd.c): When a remote attacker attempts to log in as root (or alpine, or any "*" user) and sends a password between 257 and 1,024 bytes (MAX_PASSWORD_LEN), xcrypt(password, "*") substitutes the borrowed $6$<salt>$ and calls musl’s crypt(). Because the password exceeds 256 bytes, __crypt_sha512 fails and crypt() returns "*". Back in sys_auth_passwd(), sshd compares encrypted_password ("*") against pw_password ("*"):
--- a/auth-passwd.c
+++ b/auth-passwd.c
@@ -67,6 +68,7 @@ extern login_cap_t *lc;
 #define DAY		(24L * 60 * 60) /* 1 day in seconds */
 #define TWO_WEEKS	(2L * 7 * DAY)	/* 2 weeks in seconds */
 
+#define MIN_PASSWORD_HASH_LEN	4
 #define MAX_PASSWORD_LEN	1024
...
@@ -221,7 +227,10 @@ sys_auth_passwd(struct ssh *ssh, const char *password)
 	 * Authentication is accepted if the encrypted passwords
 	 * are identical.
 	 */
-	return encrypted_password != NULL &&
+	ret = encrypted_password != NULL &&
+	    strlen(pw_password) >= MIN_PASSWORD_HASH_LEN &&
 	    strcmp(encrypted_password, pw_password) == 0;
+	freezero(pw_password, strlen(pw_password));
+	return ret;
 }

In Portable OpenSSH 10.6p2 (commit 4353fdc43ef6), sys_auth_passwd() requires strlen(pw_password) >= MIN_PASSWORD_HASH_LEN (4, since even traditional DES crypt(3) hashes are 13 characters long), ensuring a 1-character "*" or 2-character "*0" failure token can never match pw_password.

When apt downloads .deb packages over HTTP (or through a local caching proxy), it verifies the downloaded archive’s SHA-256 digest against the signed Packages index before handing the file to dpkg for installation as root. Since apt 2.3.2, Acquire::Retries defaults to 3, so transient HTTP errors automatically trigger a retry with an HTTP Range request (Req.StartPos > 0) to resume the partial download.

Max Justicz discovered that an on-path attacker or malicious HTTP mirror can redirect a second download item to the same URI while returning a transient error that triggers download resumption. In methods/http.cc, HttpMethod::DealWithHeaders() previously opened Queue->DestFile in place with FileFd::WriteAny (without FileFd::Exclusive), writing the resumed bytes directly through any existing hardlink pointing to an already-verified package file.

Commit 5af16a8ad0f1 fixes methods/http.cc, methods/rred.cc, and methods/store.cc by opening the existing partial file read-only, re-opening Queue->DestFile with FileFd::WriteAny | FileFd::Exclusive (which unlinks the old path first so any hardlink is broken), and copying the partial prefix into the newly created inode:

--- a/methods/http.cc
+++ b/methods/http.cc
@@ -1004,8 +1004,24 @@ BaseHttpMethod::DealWithHeadersResult HttpMethod::DealWithHeaders(FetchResult &R
    auto ret = BaseHttpMethod::DealWithHeaders(Res, Req);
    if (ret != BaseHttpMethod::FILE_IS_OPEN)
       return ret;
-   if (Req.File.Open(Queue->DestFile, FileFd::WriteAny) == false)
+
+   // If we are resuming, we first need to rescue the data we already have
+   FileFd partial;
+   if (Req.StartPos > 0 && FileExists(Queue->DestFile))
+   {
+      if (not partial.Open(Queue->DestFile, FileFd::ReadOnly))
+         return ERROR_NOT_FROM_SERVER;
+   }
+   // Open the file exclusively to avoid injection attacks by links
+   if (Req.File.Open(Queue->DestFile, FileFd::WriteAny | FileFd::Exclusive) == false)
       return ERROR_NOT_FROM_SERVER;
+   if (partial.IsOpen())
+   {
+      // The exclusive open unlinked the old file; copy its content
+      // into the new one and rewind for hashing.
+      if (not CopyFile(partial, Req.File) || not partial.Close() || not Req.File.Seek(0))
+         return ERROR_NOT_FROM_SERVER;
+   }

3. zlib 1.4 (CVE-2026-85091, THM-ZLIB-001, TOB-ZLIB-004)

zlib 1.4 bundles fixes from an audit by Trail of Bits (TOB-ZLIB-*), Theorem (THM-ZLIB-001), and independent researchers:

  • THM-ZLIB-001 (inflateGetDictionary() 8 MB buffer overrun in 1.3.1 and 1.3.2): Callers of inflateGetDictionary(strm, dictionary, &dictLength) provide a 32 KiB (32768-byte) buffer, the maximum valid deflate window size (1 << 15). In zlib 1.3.1 and 1.3.2, feeding a stream with an invalid zlib header window size followed by inflateReset() or inflateSync() left state->wsize corrupted so inflateGetDictionary() copied up to 8 MB past the caller’s 32 KiB buffer.
  • CVE-2026-85091 / TOB-ZLIB-003 (non-blocking gzwrite() buffer overflow): When gzwrite() operated on a non-blocking file descriptor where write() returned a partial count or EAGAIN, internal buffer state accounting overflowed the gz_state buffer.
  • TOB-ZLIB-004 (inflateSync() 1-byte window overrun): Calling inflateSync() before the stream window size was known allocated a 1-byte sliding window that subsequent inflate() calls overran.

Detection and remediation

# 1. Check whether the host uses musl libc, what OpenSSH version is running, and whether '*' accounts coexist with $5$/$6$ hashes
ldd /usr/sbin/sshd 2>/dev/null | rg 'musl' || true
sshd -V 2>&1 | head -n 2
sshd -T 2>/dev/null | rg -i '^(usepam|passwordauthentication|permitrootlogin)\b'
awk -F: '$2 == "*" {print "star-account:", $1} $2 ~ /^\$[56]\$/ {print "sha-salt-account:", $1}' /etc/shadow 2>/dev/null

# 2. Hunt auth logs on Alpine / musl hosts for password logins to root or key-only '*' accounts ("Accepted password for")
rg -n 'Accepted password for (root|alpine|deploy)' /var/log/messages /var/log/auth.log 2>/dev/null || true

# 3. Check apt and zlib versions on Debian / Ubuntu / Alpine hosts
apt --version 2>/dev/null || true
dpkg -l apt zlib1g 2>/dev/null || apk info -v openssh musl zlib 2>/dev/null || true
  1. Patch or mitigate OpenSSH "sshole" (CVE-2026-123158) immediately on musl hosts:
    • Upgrade to OpenSSH >= 10.6p2 (apk update && apk upgrade openssh on Alpine Linux, then rc-service sshd restart).
    • If you cannot upgrade immediately, disable password authentication in /etc/ssh/sshd_config:
      echo "PasswordAuthentication no" > /etc/ssh/sshd_config.d/00-no-passwords.conf
      rc-service sshd restart
    • Check /var/log/messages (or your syslog collector) for any "Accepted password for <user>" event on an account whose /etc/shadow field is "*". Because those accounts have no password set, any "Accepted password" log line for a "*" account is definitive evidence of exploitation.
  2. Safely upgrade apt on Debian and Ubuntu (CVE-2026-109518):
    • Pass -o Acquire::Retries=0 on the command line when downloading the patched apt package itself so the vulnerable retry-resume code path cannot be triggered during the upgrade:
      sudo apt-get -o Acquire::Retries=0 update
      sudo apt-get -o Acquire::Retries=0 install --only-upgrade apt libapt-pkg*
    • Verify that apt is on >= 3.0.4 (Debian 13 trixie), >= 2.6.1+deb12u2 (Debian 12 bookworm), or >= 2.2.4+deb11u2 (Debian 11 bullseye).
  3. Upgrade zlib to >= 1.4 and musl to >= 1.2.7: Rebuild container images and native C/C++/Rust/Python wheels that statically link zlib 1.3.1 or 1.3.2 (particularly services that call inflateGetDictionary(), inflateSync(), or gzwrite()).

Timeline

  • 2012-08-09 & 2012-08-29: musl libc changes crypt() to return "*" on error (b3c4cc12) and caps crypt_sha512 / crypt_sha256 keys at 256 bytes (88bf5a8a).
  • 2016-07-18: OpenSSH 7.3p1 adds pick_salt() (CVE-2016-6210 timing mitigation), borrowing a real salt from /etc/shadow when hashing candidate passwords for "*" accounts.
  • 2026-10-21: musl announces CVE-2026-107891 (regcomp integer overflows, fixed in musl 1.2.7).
  • 2026-11-04: Debian publishes DSA-6607-1, DLA-4855-1, and APT-2026-11-01 for CVE-2026-109518 in apt (3.0.4, 2.6.1+deb12u2, 2.2.4+deb11u2); Mark Adler tags zlib 1.4.
  • 2026-11-05 (03:01 to 16:17 UTC): Damien Miller announces Portable OpenSSH 10.6p2 (4353fdc43ef6); Özgün Kültekin publishes sshhole.com; NVD publishes CVE-2026-123158 (sshd), CVE-2026-85091 (zlib), and CVE-2026-107891 (musl).

From research to remediation

Check whether this pattern exists in your codebase

Turn this research into a remediation workflow. Scan dependencies and package manifests for similar supply-chain risk, then prioritize fixes with reachability context.

References