CVE-2026-46705

russh server userauth state is not reset when authentication principal changes

Published Jun 10, 2026 CVSS 3.1 · 5.3 Medium EPSS < 1% KEV · Not listed
Description
Russh is a Rust SSH client & server library. From version 0.34.0-beta.1 to before version 0.61.0, the russh server authentication path keeps internal userauth state across SSH_MSG_USERAUTH_REQUEST messages without separating that state when the request principal changes. RFC 4252 allows the user name and service name fields to change between authentication requests. The issue is not that such changes are invalid. The issue is that russh-owned authentication state, such as remaining methods, partial-success state, and in-progress method state, can remain associated with the connection and then influence a later request for a different (user, service). This is an internal library state mismatch. This issue has been patched in version 0.61.0.

Analysis

AI-generated

Technical impact

The vulnerability occurs when the russh server library fails to reset user authentication state between successive SSH authentication requests when the principal changes. This allows residual authentication state—such as remaining methods or partial‑success flags—to carry over to a subsequent request for a different user or service, potentially enabling an attacker to bypass authentication checks or gain unauthorized access. The weakness arises from improper state separation during authentication and is classified as an authentication bypass (CWE‑287).

Affected Systems

Affected systems are those that host an SSH server implemented with the russh Rust SSH library, specifically versions from 0.34.0-beta.1 up to, but not including, 0.61.0. Custom servers or services embedding this library are impacted; the defect is absent in russh 0.61.0 and later.

Risk and Exploitability

The CVSS score of 5.3 indicates moderate severity, while EPSS is not available and the issue is not listed in the CISA KEV catalog, suggesting no public exploitation yet. The attack vector is remote network access via the SSH protocol; an attacker would need to perform a sequence of authentication attempts with changing principals to exploit the retained state. Although code execution is not granted, unauthorized logins could lead to privilege escalation if used in concert with other vulnerabilities.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade the russh library to version 0.61.0 or later where the issue is resolved.
  • Rebuild any custom SSH server components that depend on older russh versions using the patched library.
  • Restart or reload all services that use russh after upgrading to ensure a fresh authentication state.

Generated by OpenCVE AI on June 10, 2026 at 22:59 UTC.

Tracking

Sign in to view the affected projects.

Advisories

Source ID Title
Github GHSA Github GHSA GHSA-hpv4-5h6f-wqr3 russh server userauth state is not reset when authentication principal changes
History
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'yes', 'Exploitation': 'poc', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
First Time appeared Eugeny
Eugeny russh
Vendors & Products Eugeny
Eugeny russh
Type Values Removed Values Added
Description Russh is a Rust SSH client & server library. From version 0.34.0-beta.1 to before version 0.61.0, the russh server authentication path keeps internal userauth state across SSH_MSG_USERAUTH_REQUEST messages without separating that state when the request principal changes. RFC 4252 allows the user name and service name fields to change between authentication requests. The issue is not that such changes are invalid. The issue is that russh-owned authentication state, such as remaining methods, partial-success state, and in-progress method state, can remain associated with the connection and then influence a later request for a different (user, service). This is an internal library state mismatch. This issue has been patched in version 0.61.0.
Title russh server userauth state is not reset when authentication principal changes
Weaknesses CWE-287
References
Metrics cvssV3_1

{'score': 5.3, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N'}

Weaknesses

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Jun 11, 2026, 2:14 PM
Reserved
May 15, 2026, 11:26 PM
Status
Deferred
Published
Jun 10, 2026, 10:17 PM
Modified
Jul 23, 2026, 9:10 AM