Skip to main content

AsyncSSH CVE-2026-138376

| EUVDEUVD-2026-137775 HIGH
Improper Authentication (CWE-287)
2026-11-29 VulnCheck GHSA-g8x2-2xvf-wjqh
7.4
CVSS 4.0 · Vendor: VulnCheck
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Obtain private host key of one trusted client host
  2. Delivery
    Open SSH connection and send host-based attempt naming that host
  3. Exploit
    Retry host-based attempt naming a different authorized host, signed with same key
  4. Execution
    Carried-over trust passes host key check
  5. Impact
    Authenticate as user restricted to the other host

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A07:2025 - Authentication Failures
ASVS 5.0
V6 - Authentication Authentication mechanism validation
MITRE ATT&CK

2 techniques across 2 tactics: Defense Evasion, Initial Access

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Problem 1 requires all of: a server using host-based authentication with known_client_hosts; trust_client_host enabled (this is NOT the default, which is disabled); the application overriding validate_host_based_user() and using the client_host argument in its authorization decision (the stock default compares only user names and is not affected); and the attacker holding the private host key of one host already trusted in known_client_hosts. It further requires issuing multiple host-based attempts on a single connection, and because the stock client sends only one host name per connection, a modified client. Problem 2 requires the server to list X.509 certificates in known_client_hosts while its authorized keys accept X.509 user certificates by subject name; this variant does NOT require trust_client_host. Limiting factors: non-default configuration, possession of a trusted client host private key (PR:H), custom application logic, and a modified SSH client - the default configuration and default validate_host_based_user() are not exploitable. The only complete fix is updating to AsyncSSH 2.24.2; workarounds are leaving trust_client_host disabled / not relying on client_host (Problem 1) and not listing X.509 certificates in known_client_hosts on servers that also accept X.509 user certificates by subject name (Problem 2).

Impact

The input CVSS 4.0 score of 7.4 (AV:N/AC:H/AT:P/PR:H/UI:N) is driven by high confidentiality and integrity impact, but three of its base metrics materially temper real-world risk: AC:H and AT:P reflect that exploitation needs a specific non-default server configuration and a multi-step sequence, and PR:H reflects that the attacker must already hold the private host key of a legitimately trusted client host. No EPSS score is provided and the CVE is not listed in CISA KEV, so there is no public exploitation-probability or active-exploitation signal; the only exploitation artifact is the conceptual proof-of-concept described in the GHSA/VulnCheck advisories, which is not verified as working exploit code. The vuln.today decision label is 'this_week', consistent with a real but non-emergency patching priority. Overall this is a genuine authentication-bypass flaw rather than an inflated high-CVSS issue, but its realistic exposure is narrow: it only affects servers that enable trust_client_host and override validate_host_based_user() to key decisions on client_host (Problem 1), or that list X.509 certificates in known_client_hosts while also accepting X.509 user certificates by subject name (Problem 2). The default validate_host_based_user() implementation, which compares only user names, is not affected, so most deployments using AsyncSSH's defaults are not exploitable.

Exploit ScenarioDerived

An attacker who possesses the private host key of one host listed in a server's known_client_hosts opens an SSH connection and makes a host-based authentication attempt naming that host, then makes a second attempt on the same connection naming a different trusted host while signing with the same key. Because trust from the first attempt carried over, the second attempt passes the host key check and the attacker logs in as a user the application authorizes only from that other host. A conceptual proof-of-concept is published in the vendor advisory (including a modified client that sends a different host name on its second attempt), but it is not verified as working exploit code; CVSS AC:H/AT:P reflects the required non-default configuration and multi-attempt sequence.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.5% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Nov 29, 2026

Improper authentication in AsyncSSH 1.13.1 through 2.24.1 causes server-side host-based authentication state to persist across attempts within a single connection: host keys trusted in known_client_hosts accumulate instead of being replaced, and X.509 certificates listed in known_client_hosts are appended to the trust anchors used later to validate X.509 user certificates. An attacker who already holds the private host key of one client host trusted in known_client_hosts can, when trust_client_host is enabled and the application's validate_host_based_user() authorizes on the client_host argument, make a first host-based attempt naming that host and a second attempt naming a different trusted host signed with the same key, logging in as users the application permits only from that other host. The X.509 variant does not require trust_client_host but needs known_client_hosts to list certificates while authorized keys accept X.509 user certificates by subject name; both paths require a non-default configuration and a client modified to send a second host name on the same connection (the stock client sends one per connection), and the vendor advisory documents a proof-of-concept scenario for each rather than confirmed working exploit code, with no KEV listing.

RemediationAI

Vendor-released patch: upgrade to AsyncSSH 2.24.2, which replaces rather than accumulates trusted host keys per attempt and moves known_client_hosts X.509 certificates into a separate list used only for host certificate validation (commit 19731a172894f7d82fbb69cb477f6f3c2103bf97; release notes at https://github.com/ronf/asyncssh/blob/v2.24.2/docs/changes.rst; advisory https://github.com/ronf/asyncssh/security/advisories/GHSA-4hgp-7gmx-wvfg). The vendor states that updating is the only complete fix. If upgrading cannot be done immediately, the advisory's workarounds target each problem separately: for Problem 1, leave trust_client_host disabled (the default) or stop relying on the client_host argument inside validate_host_based_user() - the trade-off is that host-based authorization can no longer be scoped per client host and falls back to username-only checks; for Problem 2, remove X.509 certificates from known_client_hosts on any server whose authorized keys also accept X.509 user certificates by subject name - the trade-off is that X.509 client host certificates can no longer be trusted through known_client_hosts on those servers and must be validated by another mechanism or the host-based path disabled. Neither workaround addresses the other problem, so deployments matching both configurations should upgrade.

Affected VersionsENISA

asyncssh 1.13.1 <2.24.2

Affected Packages

euvd asyncssh fix: 2.24.2

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

AsyncSSH is a Python asyncio implementation of the SSH client and server protocols. The flaw is classified CWE-287 (Improper Authentication), with the advisory also tagging CWE-668 (Exposure of Resource to Wrong Sphere), and lives in SSHConnection._match_known_hosts in asyncssh/connection.py. For each host-based authentication attempt the server looks up known_client_hosts to resolve the host keys, CA keys and X.509 certificates trusted for the client host - using the client-supplied host name when trust_client_host is set. In versions 1.13.1 through 2.24.1, the matched host keys were added to a connection-scoped self._trusted_host_keys set rather than replacing the previous lookup's results, and matched X.509 certificates were appended to self._x509_trusted_certs, the same list used as trust anchors when validating X.509 certificates presented for public key user authentication. The fix commit 19731a172894f7d82fbb69cb477f6f3c2103bf97 replaces the key set on each match (and clears the algorithm list), and segregates host-certificate trust into a new self._x509_known_host_certs list that is consulted only during X.509 host certificate chain validation, not during user certificate validation. The supplied CVSS 4.0 vector (AV:N/AC:H/AT:P/PR:H/UI:N/VC:H/VI:H/VA:N) and the independent CVSS 3.1 assessment (AV:N/AC:H/PR:H/UI:N/S:U/C:H/I:H/A:N) agree on network reachability, high attack complexity, high privileges required and high confidentiality/integrity impact with no availability impact; the high privilege metric reflects possession of a legitimately trusted client host private key. The default validate_host_based_user() compares only user names and is not affected, and trust_client_host is disabled by default.

Know when Asyncssh gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (VulnCheck) PRIMARY 7.4 HIGH
CVSS:4.0/AV:N/AC:H/AT:P/PR:H/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N
vuln.today AI 5.9 MEDIUM

AC:H and PR:H because exploitation needs non-default config plus a trusted host's private key and a multi-attempt sequence; C:H/I:H from user impersonation, A:N as no availability loss.

3.1 AV:N/AC:H/PR:H/UI:N/S:U/C:H/I:H/A:N
4.0 AV:N/AC:H/AT:P/PR:H/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N

Primary rating from Vendor (VulnCheck).

CVSS VectorVendor: VulnCheck

Attack Vector
Network
Attack Complexity
High
Attack Requirements
Present
Privileges Required
High
User Interaction
None
Vulnerable system: Confidentiality
High
Vulnerable system: Integrity
High
Vulnerable system: Availability
None
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

DescriptionCVE.org

AsyncSSH 1.13.1 before 2.24.2 contains an improper authentication vulnerability in SSHConnection._match_known_hosts that accumulates trusted client host keys across host-based authentication attempts on one connection. With trust_client_host enabled, attackers holding one known client host's private key can retry naming another known host and log in as users authorized only from that host.

Technical POC Analysis

CWE-287 (Improper Authentication); the advisory also tags CWE-668.

Full technical POC analysis - root cause, step-by-step exploitation and patch breakdown - is part of the Pro and Business plans.

Executive ViewAI

Why It Matters

AsyncSSH versions 1.13.1 through 2.24.1 contain a high-severity improper authentication flaw (CVE-2026-138376) that can allow an attacker with a trusted client host private key to impersonate other trusted hosts and log in as users authorized only from those hosts. This impacts organizations using AsyncSSH for SSH server authentication with host-based or X.509 certificate validation, potentially enabling unauthorized access to systems and data. Leadership should prioritize remediation because the vulnerability undermines trust boundaries in SSH authentication and could lead to lateral movement or privilege escalation within the environment.

Business Impact: High
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.5%
Top 62% exploitable
Prevalence
Medium
popular Python async SSH library; vulnerable host-based config is niche
Social Media
1
Sightings
Data Quality
5 sources
Confidence: Medium

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC No
EPSS 0.5%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Open
Automatable· derived
No
Human Impact
High

Priority Score

38
Low Medium High Critical
KEV: 0
EPSS: +1
CVSS: +37
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Authentication bypass attacks exploit flaws in the verification mechanisms that control access to systems and applications.

CVE-2023-48795 MEDIUM POC
5.9 Dec 18

The SSH transport protocol with certain OpenSSH extensions, found in OpenSSH before 9.6 and other products, allows remot

CVE-2018-7749 CRITICAL
9.8 Mar 12

The SSH server implementation of AsyncSSH before 1.12.1 does not properly check whether authentication is completed befo

CVE-2026-102643 HIGH
8.8 Nov 09

Chroot escape in AsyncSSH's SFTP server (versions <= 2.24.0) lets an authenticated SFTP user read and write files outsid

CVE-2026-138374 HIGH
7.7 Nov 29

Argument injection in the AsyncSSH Python library (2.7.0 through 2.24.1) lets whoever can influence the host or user nam

CVE-2026-138377 HIGH
7.6 Nov 29

Improper X.509 certificate validation in AsyncSSH 1.13.1 through 2.24.1 allows authenticated remote clients to log in as

CVE-2023-46446 MEDIUM
6.8 Nov 14

An issue in AsyncSSH before 2.14.1 allows attackers to control the remote end of an SSH client session via packet inject

CVE-2026-77473 MEDIUM
6.5 Nov 09

Path traversal in AsyncSSH's recursive remote-to-local SFTP copy logic (SFTPClient._copy(), reached through get(), mget(

CVE-2026-62949 MEDIUM
6.5 Sep 16

A peer-supplied maximum packet size of zero is accepted during SSH channel-open negotiation in AsyncSSH versions prior t

CVE-2023-46445 MEDIUM
5.9 Nov 14

An issue in AsyncSSH before 2.14.1 allows attackers to control the extension info message (RFC 8308) via a man-in-the-mi

CVE-2026-138375 LOW
2.3 Nov 29

Environment-variable disclosure in AsyncSSH 2.20.0 through 2.24.1 allows a name supplied to connect() to pull process en

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy