Vulnerability · Published Feb 18, 2025 · Assigned by redhat

CVE-2025-26465Openssh: machine-in-the-middle attack if verifyhostkeydns is enabled

Medium 6.8

In plain English

A medium-severity security flaw in OpenSSH. Proof-of-concept exploit code is public. The chance it is exploited in the next 30 days is estimated at 7.7% (higher than 95% of all known vulnerabilities). Ready-made attack tooling exists: public proof-of-concept code. Fixed versions are available - upgrade the affected package.

Severity (CVSS 3.1)6.8Medium
Exploit odds (30 days)7.7%top 5.4% of all CVEs
Exploited in the wildNo reportsCISA SSVC: poc
Attack tooling1Public PoC

Official description

A vulnerability was found in OpenSSH when the VerifyHostKeyDNS option is enabled. A machine-in-the-middle attack can be performed by a malicious machine impersonating a legit server. This issue occurs due to how OpenSSH mishandles error codes in specific conditions when verifying the host key. For an attack to be considered successful, the attacker needs to manage to exhaust the client's memory resource first, turning the attack complexity high.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
AlmaLinux:8openssh8.0p1-26.el8_10ALSA-2025:16823
AlmaLinux:9openssh8.7p1-45.el9ALSA-2025:6993
AlmaLinux:8openssh-askpass8.0p1-26.el8_10ALSA-2025:16823
AlmaLinux:9openssh-askpass8.7p1-45.el9ALSA-2025:6993
AlmaLinux:8openssh-cavs8.0p1-26.el8_10ALSA-2025:16823
AlmaLinux:8openssh-clients8.0p1-26.el8_10ALSA-2025:16823
AlmaLinux:9openssh-clients8.7p1-45.el9ALSA-2025:6993
AlmaLinux:8openssh-keycat8.0p1-26.el8_10ALSA-2025:16823
AlmaLinux:9openssh-keycat8.7p1-45.el9ALSA-2025:6993
AlmaLinux:8openssh-ldap8.0p1-26.el8_10ALSA-2025:16823
AlmaLinux:8openssh-server8.0p1-26.el8_10ALSA-2025:16823
AlmaLinux:9openssh-server8.7p1-45.el9ALSA-2025:6993
AlmaLinux:8pam_ssh_agent_auth0.10.3-7.26.el8_10ALSA-2025:16823
AlmaLinux:9pam_ssh_agent_auth0.10.4-5.45.el9ALSA-2025:6993
Alpine:v3.20openssh9.7_p1-r5ALPINE-CVE-2025-26465
Alpine:v3.21openssh9.9_p2-r0ALPINE-CVE-2025-26465
Alpine:v3.22openssh9.9_p2-r0ALPINE-CVE-2025-26465
Alpine:v3.23openssh9.9_p2-r0ALPINE-CVE-2025-26465
Alpine:v3.24openssh9.9_p2-r0ALPINE-CVE-2025-26465
Debian:12openssh1:9.2p1-2+deb12u5DSA-5868-1
Debian:12openssh1:9.2p1-2+deb12u5DEBIAN-CVE-2025-26465
Debian:13openssh1:9.9p2-1DEBIAN-CVE-2025-26465
Debian:14openssh1:9.9p2-1DEBIAN-CVE-2025-26465
Rocky Linux:8openssh0:8.0p1-26.el8_10RLSA-2025:16823
Rocky Linux:9openssh0:8.7p1-45.el9RLSA-2025:6993
Ubuntu:22.04:LTSopenssh1:8.9p1-3ubuntu0.11UBUNTU-CVE-2025-26465
Ubuntu:22.04:LTSopenssh1:8.9p1-3ubuntu0.11USN-7270-1
Ubuntu:24.04:LTSopenssh1:9.6p1-3ubuntu13.8USN-7270-1
Ubuntu:24.04:LTSopenssh1:9.6p1-3ubuntu13.8UBUNTU-CVE-2025-26465
Ubuntu:22.04:LTSopenssh-ssh1no fix listedUBUNTU-CVE-2025-26465
Ubuntu:24.04:LTSopenssh-ssh1no fix listedUBUNTU-CVE-2025-26465
Ubuntu:25.10openssh-ssh1no fix listedUBUNTU-CVE-2025-26465
Ubuntu:26.04:LTSopenssh-ssh1no fix listedUBUNTU-CVE-2025-26465
Ubuntu:26.10openssh-ssh1no fix listedUBUNTU-CVE-2025-26465

Affected products (as reported)

Weakness: CWE-390 · Vector: CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:N

References