CVE-2025-26465Openssh: machine-in-the-middle attack if verifyhostkeydns is enabled
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.
What to do
Fixed builds are available from AlmaLinux, Alpine, Debian, Red Hat, Rocky Linux, Ubuntu: see the table below for the fixed version per release.
Ubuntu has not shipped a fix for every release yet.
Is your server affected? One read-only command checks every installed package against this CVE and all others, using each vendor's fixed versions. Get started or get a free API key.
curl -sS "https://api.cvefocus.com/v1/check?format=text" -H "Authorization: Bearer $CVEFOCUS_KEY" \ -H "Content-Type: text/plain" --data-binary @inventory.txt
Vendor status at a glance
Status by vendor and release
From each vendor's own security data and VEX statements. "Fixed" means a fixed build is published for that release.
| Release | Package | Status | Fixed version | Advisory |
|---|---|---|---|---|
| Ubuntu 26.10 | openssh-ssh1 | Fix pending | UBUNTU-CVE-2025-26465 | |
| Ubuntu 26.04 | openssh-ssh1 | Will not fix openssh-ssh1 is only provided for compatibility with old devices that cannot be upgraded to modern protocols. We will not be providing any security support… | UBUNTU-CVE-2025-26465 | |
| Ubuntu 25.10 | openssh-ssh1 | Will not fix openssh-ssh1 is only provided for compatibility with old devices that cannot be upgraded to modern protocols. We will not be providing any security support… | UBUNTU-CVE-2025-26465 | |
| Ubuntu 24.04 | openssh | Fixed | 1:9.6p1-3ubuntu13.8 | UBUNTU-CVE-2025-26465 |
| Ubuntu 24.04 | openssh-ssh1 | Will not fix openssh-ssh1 is only provided for compatibility with old devices that cannot be upgraded to modern protocols. We will not be providing any security support… | UBUNTU-CVE-2025-26465 | |
| Ubuntu 22.04 | openssh | Fixed | 1:8.9p1-3ubuntu0.11 | UBUNTU-CVE-2025-26465 |
| Ubuntu 22.04 | openssh-ssh1 | Will not fix openssh-ssh1 is only provided for compatibility with old devices that cannot be upgraded to modern protocols. We will not be providing any security support… | UBUNTU-CVE-2025-26465 | |
| Ubuntu 20.04 | openssh | Fixed | 1:8.2p1-4ubuntu0.12 | UBUNTU-CVE-2025-26465 |
| Ubuntu 20.04 | openssh-ssh1 | Will not fix openssh-ssh1 is only provided for compatibility with old devices that cannot be upgraded to modern protocols. We will not be providing any security support… | UBUNTU-CVE-2025-26465 | |
| Ubuntu 18.04 | openssh | Fix pending | 1:7.6p1-4ubuntu0.7+esm4 (Ubuntu Pro) | UBUNTU-CVE-2025-26465 |
| Ubuntu 18.04 | openssh-ssh1 | Fix pending | UBUNTU-CVE-2025-26465 | |
| Ubuntu 16.04 | openssh | Fix pending | 1:7.2p2-4ubuntu2.10+esm7 (Ubuntu Pro) | UBUNTU-CVE-2025-26465 |
| Debian 14 | openssh | Fixed | 1:9.9p2-1 | DEBIAN-CVE-2025-26465 |
| Debian 13 | openssh | Fixed | 1:9.9p2-1 | DEBIAN-CVE-2025-26465 |
| Debian 12 | openssh | Fixed | 1:9.2p1-2+deb12u5 | DEBIAN-CVE-2025-26465 |
| Red Hat Enterprise Linux 10 | openssh | Not affected | ||
| Red Hat Enterprise Linux 10 | openssh-askpass | Not affected | ||
| Red Hat Enterprise Linux 10 | openssh-clients | Not affected | ||
| Red Hat Enterprise Linux 10 | openssh-keycat | Not affected | ||
| Red Hat Enterprise Linux 10 | openssh-keysign | Not affected | ||
| Red Hat Enterprise Linux 10 | openssh-server | Not affected | ||
| Red Hat Enterprise Linux 9 | openssh | Fixed | 0:8.7p1-45.el9 | RHSA-2025:6993 |
| Red Hat Enterprise Linux 9 | openssh-askpass | Fixed | 0:8.7p1-45.el9 | RHSA-2025:6993 |
| Red Hat Enterprise Linux 9 | openssh-clients | Fixed | 0:8.7p1-45.el9 | RHSA-2025:6993 |
| Red Hat Enterprise Linux 9 | openssh-keycat | Fixed | 0:8.7p1-45.el9 | RHSA-2025:6993 |
| Red Hat Enterprise Linux 9 | openssh-server | Fixed | 0:8.7p1-45.el9 | RHSA-2025:6993 |
| Red Hat Enterprise Linux 9 | pam_ssh_agent_auth | Fixed | 0:0.10.4-5.45.el9 | RHSA-2025:6993 |
| Red Hat Enterprise Linux 8 | openssh | Fixed | 0:8.0p1-26.el8_10 | RHSA-2025:16823 |
| Red Hat Enterprise Linux 8 | openssh-askpass | Fixed | 0:8.0p1-26.el8_10 | RHSA-2025:16823 |
| Red Hat Enterprise Linux 8 | openssh-cavs | Fixed | 0:8.0p1-26.el8_10 | RHSA-2025:16823 |
| Red Hat Enterprise Linux 8 | openssh-clients | Fixed | 0:8.0p1-26.el8_10 | RHSA-2025:16823 |
| Red Hat Enterprise Linux 8 | openssh-keycat | Fixed | 0:8.0p1-26.el8_10 | RHSA-2025:16823 |
| Red Hat Enterprise Linux 8 | openssh-ldap | Fixed | 0:8.0p1-26.el8_10 | RHSA-2025:16823 |
| Red Hat Enterprise Linux 8 | openssh-server | Fixed | 0:8.0p1-26.el8_10 | RHSA-2025:16823 |
| Red Hat Enterprise Linux 8 | pam_ssh_agent_auth | Fixed | 0:0.10.3-7.26.el8_10 | RHSA-2025:16823 |
| Red Hat Enterprise Linux 7 | openssh | Will not fix Out of support scope | ||
| Red Hat Enterprise Linux 7 | openssh-askpass | Will not fix Out of support scope | ||
| Red Hat Enterprise Linux 7 | openssh-cavs | Will not fix Out of support scope | ||
| Red Hat Enterprise Linux 7 | openssh-clients | Will not fix Out of support scope | ||
| Red Hat Enterprise Linux 7 | openssh-keycat | Will not fix Out of support scope | ||
| Red Hat Enterprise Linux 7 | openssh-ldap | Will not fix Out of support scope | ||
| Red Hat Enterprise Linux 7 | openssh-server | Will not fix Out of support scope | ||
| Red Hat Enterprise Linux 7 | openssh-server-sysvinit | Will not fix Out of support scope | ||
| Red Hat Enterprise Linux 7 | pam_ssh_agent_auth | Will not fix Out of support scope | ||
| Red Hat Enterprise Linux 6 | openssh | Will not fix Out of support scope | ||
| Red Hat Enterprise Linux 6 | openssh-askpass | Will not fix Out of support scope | ||
| Red Hat Enterprise Linux 6 | openssh-clients | Will not fix Out of support scope | ||
| Red Hat Enterprise Linux 6 | openssh-ldap | Will not fix Out of support scope | ||
| Red Hat Enterprise Linux 6 | openssh-server | Will not fix Out of support scope | ||
| Red Hat Enterprise Linux 6 | pam_ssh_agent_auth | Will not fix Out of support scope | ||
| AlmaLinux 9 | openssh | Fixed | 8.7p1-45.el9 | ALSA-2025:6993 |
| AlmaLinux 9 | openssh-askpass | Fixed | 8.7p1-45.el9 | ALSA-2025:6993 |
| AlmaLinux 9 | openssh-clients | Fixed | 8.7p1-45.el9 | ALSA-2025:6993 |
| AlmaLinux 9 | openssh-keycat | Fixed | 8.7p1-45.el9 | ALSA-2025:6993 |
| AlmaLinux 9 | openssh-server | Fixed | 8.7p1-45.el9 | ALSA-2025:6993 |
| AlmaLinux 9 | pam_ssh_agent_auth | Fixed | 0.10.4-5.45.el9 | ALSA-2025:6993 |
| AlmaLinux 8 | openssh | Fixed | 8.0p1-26.el8_10 | ALSA-2025:16823 |
| AlmaLinux 8 | openssh-askpass | Fixed | 8.0p1-26.el8_10 | ALSA-2025:16823 |
| AlmaLinux 8 | openssh-cavs | Fixed | 8.0p1-26.el8_10 | ALSA-2025:16823 |
| AlmaLinux 8 | openssh-clients | Fixed | 8.0p1-26.el8_10 | ALSA-2025:16823 |
| AlmaLinux 8 | openssh-keycat | Fixed | 8.0p1-26.el8_10 | ALSA-2025:16823 |
| AlmaLinux 8 | openssh-ldap | Fixed | 8.0p1-26.el8_10 | ALSA-2025:16823 |
| AlmaLinux 8 | openssh-server | Fixed | 8.0p1-26.el8_10 | ALSA-2025:16823 |
| AlmaLinux 8 | pam_ssh_agent_auth | Fixed | 0.10.3-7.26.el8_10 | ALSA-2025:16823 |
| Rocky Linux 9 | openssh | Fixed | 0:8.7p1-45.el9 | RLSA-2025:6993 |
| Rocky Linux 8 | openssh | Fixed | 0:8.0p1-26.el8_10 | RLSA-2025:16823 |
| Alpine Linux 3.24 | openssh | Fixed | 9.9_p2-r0 | ALPINE-CVE-2025-26465 |
| Alpine Linux 3.23 | openssh | Fixed | 9.9_p2-r0 | ALPINE-CVE-2025-26465 |
| Alpine Linux 3.22 | openssh | Fixed | 9.9_p2-r0 | ALPINE-CVE-2025-26465 |
| Alpine Linux 3.21 | openssh | Fixed | 9.9_p2-r0 | ALPINE-CVE-2025-26465 |
| Alpine Linux 3.20 | openssh | Fixed | 9.7_p1-r5 | ALPINE-CVE-2025-26465 |
| Alpine Linux 3.19 | openssh | Fixed | 9.6_p1-r2 | ALPINE-CVE-2025-26465 |
| Alpine Linux 3.18 | openssh | Fixed | 9.3_p2-r3 | ALPINE-CVE-2025-26465 |
What the vendor says
As published in the CVE record by redhat, the CVE's assigner (usually the vendor). Check the vendor's advisory before acting.
- OpenSSH: affected: 6.8p1 to 9.9p1
- Red Hat Enterprise Linux 8
- Red Hat Enterprise Linux 9
- Red Hat Enterprise Linux 9.4 Extended Update Support
- Red Hat Discovery 1.14
- Red Hat Enterprise Linux 10
- Red Hat Enterprise Linux 6
- Red Hat Enterprise Linux 7
- Red Hat OpenShift Container Platform 4
Workaround: This issue can be mitigated by disabling VerifyHostKeyDNS by setting that option to 'no' in an SSH client configuration file (such as /etc/ssh/ssh_config, ~/.ssh/config, or one of the files in the /etc/ssh/ssh_config.d/ directory). This is the default configuration in Red Hat Enterprise Linux. For configurations that require VerifyHostKeyDNS to be enabled (set to either 'yes' or 'ask'), mitigation for this issue is either not available or the currently available options do not meet the Red Hat Product Security criteria comprising ease of use and deployment, applicability to widespread installation base or stability.
Vendor advisories:
- https://access.redhat.com/errata/RHSA-2025:16823 (vendor-advisory)
- https://access.redhat.com/errata/RHSA-2025:3837 (vendor-advisory)
- https://access.redhat.com/errata/RHSA-2025:6993 (vendor-advisory)
- https://access.redhat.com/errata/RHSA-2025:8385 (vendor-advisory)
References
- https://access.redhat.com/errata/RHSA-2025:16823
- https://access.redhat.com/errata/RHSA-2025:3837
- https://access.redhat.com/errata/RHSA-2025:6993
- https://access.redhat.com/errata/RHSA-2025:8385
- https://access.redhat.com/security/cve/CVE-2025-26465
- https://access.redhat.com/solutions/7109879
- https://bugzilla.redhat.com/show_bug.cgi?id=2344780
- https://seclists.org/oss-sec/2025/q1/144
About this page
Compiled by CVEfocus from the CVE List, the security data and VEX statements of Ubuntu, Debian, Red Hat, AlmaLinux, Rocky Linux and Microsoft, CISA's Known Exploited Vulnerabilities catalog and FIRST EPSS, refreshed several times a day (data status). Information only; see the disclaimer. Official record: cve.org · NVD.