Skip to main content

SSH.NET EUVDEUVD-2026-80878

| CVE-2026-85756 HIGH
OS Command Injection (CWE-78)
2026-09-16 GitHub_M GHSA-mggc-4xg6-vcxf
7.5
CVSS 3.1 · Vendor: GitHub_M
View

Attack ChainAIDerived

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

  1. Access
    Identify app using ScpClient with untrusted remote path
  2. Delivery
    Supply path containing shell metacharacters
  3. Exploit
    DoubleQuote transformation fails to neutralize
  4. Execution
    scp command interpreted by server shell
  5. Impact
    Arbitrary commands execute as authenticated SSH user

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization OS command sanitization, avoid shell exec
MITRE ATT&CK

2 techniques across 1 tactic: Execution

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

Exploitation Conditions

All of the following must hold: the application uses ScpClient (not SftpClient, which avoids a remote shell entirely); it passes an attacker-controlled or otherwise untrusted remote path; the active IRemotePathTransformation does not fully neutralize the path for the target shell - specifically the default RemotePathTransformation.DoubleQuote, which cannot safely quote every remote command interpreter; the target SSH server is shell-based; and the path is crafted for that shell's parsing rules. A valid authenticated SSH session is required (PR:L). NOT affected: non-shell-based servers, paths fully neutralized by the selected transformation, use of RemotePathTransformation.ShellQuote against POSIX shells, or use of SftpClient. These conditions (shell-based server plus a shell-specific crafted path) are the AC:H limiting factors that reduce realistic exploitability below a default-config remote RCE.

Impact

This is a genuine but conditionally-exploitable command injection (CWE-78) in SSH.NET's ScpClient, not an inflated high-CVSS finding. The vendor CVSS 3.1 vector (AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H = 7.5) is internally consistent and I broadly agree with it: AV:N reflects the SSH-over-network transport, AC:H correctly captures that exploitation depends on the target being a shell-based server AND a path crafted for that specific shell's parsing rules, PR:L reflects that commands run in the context of an already-authenticated SSH session, and C/I/A:H are justified because successful injection yields arbitrary command execution as the authenticated SSH user. The key limiter is that this only bites applications that (a) use ScpClient rather than SftpClient, (b) feed attacker-influenced remote paths, and (c) target a shell-based server with the default DoubleQuote transformation - a real but narrower slice than the CVSS base score alone suggests. No EPSS score, KEV listing, POC, or SSVC decision data was provided in the input, so the exploitation-probability and automatability dimensions cannot be assessed from signals here; absence of those is not evidence of safety given the library's wide deployment. Priority should be driven by whether your code path matches the exploitation conditions rather than by the 7.5 alone.

Exploit ScenarioDerived

An application uses ScpClient with the default RemotePathTransformation.DoubleQuote and passes a remote path derived from untrusted input (e.g., a user-supplied filename) to a shell-based SSH server. The attacker embeds shell metacharacters not neutralized by DoubleQuote (such as command substitution via backticks or $()), so when the server's shell interprets the assembled scp command it executes the injected commands as the authenticated SSH user. No public exploit was identified at time of analysis, though the fix commit and advisory describe the mechanism in detail.

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

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

Alert me

AnalysisAIv1 – Sep 16, 2026

Command injection in SSH.NET's ScpClient (Renci.SshNet, all releases prior to 2026.0.0) lets a remote attacker who can influence the remote path supplied by a calling application execute arbitrary commands as the authenticated SSH user on a shell-based server. The default RemotePathTransformation.DoubleQuote cannot safely quote every remote command interpreter, so shell metacharacters that survive the transformation are parsed by the server's shell when the scp command line is assembled. Exploitation is conditional rather than automatic: the target must be a shell-based SSH server and the path must be crafted for that shell's parsing rules, and the assessed vector (AV:N/AC:H/PR:L/UI:N) requires an authenticated SSH session; no public exploit code or active exploitation has been identified at time of analysis, and applications using SftpClient, non-shell-based servers, or fully neutralizing transformations such as ShellQuote against POSIX shells are not affected.

RemediationAI

Vendor-released patch: upgrade SSH.NET to 2026.0.0 (https://github.com/sshnet/SSH.NET/releases/tag/2026.0.0). Because the fix centres on selecting the right path transformation, upgrading alone is not sufficient unless constructor usage is reviewed: 2026.0.0 adds ScpClient constructors that accept an explicit IRemotePathTransformation, marks the older constructors obsolete, and has those obsolete overloads continue to apply RemotePathTransformation.DoubleQuote, so code that passes untrusted paths should be changed to inject RemotePathTransformation.ShellQuote when the remote server is a POSIX shell. Where a remote shell is not required, migrate to SftpClient, which never runs a remote command and is therefore unaffected; the trade-off is a different protocol feature set and potentially different throughput or permission semantics than SCP. If ScpClient must be retained against a non-shell-based server, explicitly choose RemotePathTransformation.None, keeping in mind that quoting there corrupts the path rather than creating an injection risk. Applications that cannot change their transformation handling should stop passing attacker-influenced strings as remote paths, instead validating and canonicalizing them against a known-good set, or route those operations over SFTP. Patch details and developer guidance are in the advisory GHSA-mggc-4xg6-vcxf (https://github.com/sshnet/SSH.NET/security/advisories/GHSA-mggc-4xg6-vcxf) and the fix commit https://github.com/sshnet/SSH.NET/commit/c66b9f8fb06c12e71761e58a577b1e796026310f.

Affected VersionsENISA

SSH.NET < 2026.0.0

Affected Packages

nuget ssh.net fix: 2026.0.0

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in nuget

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

Technical ContextAI · show details

SSH.NET implements SCP by opening an SSH session and running the scp binary on the server with the remote path embedded directly into the command string; the path is passed through an IRemotePathTransformation before insertion. The default transformation, RemotePathTransformation.DoubleQuote, wraps the path in double quotes and backslash-escapes embedded double quotes, which is only adequate for a subset of real command interpreters - POSIX shells still perform expansions such as command substitution inside double quotes, and other shells parse the same characters by different rules. Since no single transformation is correct for every shell, a path that is not fully neutralized is evaluated by the remote shell and produces CWE-78 OS command injection running as the authenticated SSH user. The 2026.0.0 fix restructures the API around this: ScpClient constructors now take an explicit IRemotePathTransformation, the older constructors are marked obsolete and still fall back to DoubleQuote through an internal DefaultTransform property, the IServiceFactory.CreateRemotePathDoubleQuoteTransformation factory method is removed, and the documentation warns that shell-based servers require shell-matched quoting while non-shell servers require the literal path (RemotePathTransformation.None). RemotePathTransformation.ShellQuote is supplied for POSIX shells, and SftpClient avoids a remote shell entirely. The affected library releases are tracked by CPE cpe:2.3:a:sshnet:ssh.net:*:*:*:*:*:*:*:*, covering everything before 2026.0.0.

Know when Ssh Net 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 (GitHub_M) PRIMARY 7.5 HIGH
AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H
vuln.today AI 7.5 HIGH

Network SSH transport (AV:N); dependent on a shell-based server and shell-tailored path (AC:H); runs within an authenticated SSH session (PR:L); arbitrary command execution as the SSH user yields full C/I/A:H.

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

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Network
Attack Complexity
High
Privileges Required
Low
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High

Lifecycle Timeline

2
Patch available
Sep 16, 2026 - 18:19 EUVD
CVE Published
Sep 16, 2026 - 16:31 cve.org
HIGH 7.5

DescriptionCVE.org

SSH.NET is a Secure Shell (SSH) library for .NET. Prior to 2026.0.0, ScpClient places caller-supplied remote paths into the command used to run scp on the server, and the default RemotePathTransformation.DoubleQuote transformation cannot safely quote every remote command interpreter. When an application passes an attacker-controlled path to a shell-based server, shell metacharacters not neutralized by the active IRemotePathTransformation can execute commands as the authenticated SSH user. Exploitation requires a shell-based server and a path crafted for that shell's parsing rules; non-shell servers and paths fully neutralized by the selected transformation are not affected. RemotePathTransformation.ShellQuote is available for POSIX shells, while SftpClient avoids a remote shell entirely. This issue is fixed in version 2026.0.0.

Technical POC Analysis

Evidence note: this analysis is based on advisory GHSA-mggc-4xg6-vcxf and the accompanying description.

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

Organizations using SSH.NET’s ScpClient (Renci.SshNet versions before 2026.0.0) face a high-severity command-injection risk when an application lets remote input influence the path used for file transfer to a shell-based SSH server. Exploitation requires an authenticated SSH session and specific server/path conditions, and no public exploit identified at time of analysis, but successful abuse could allow commands to run as the authenticated SSH user. Leadership should prioritize inventory and mitigation because affected applications may depend on SSH.NET for automated file-transfer workflows that carry sensitive access.

Business Impact: High
Compensating Controls

No vendor-released patch identified at time of analysis. Interim mitigations include disabling ScpClient where not required; migrating to SftpClient; applying a fully neutralizing RemotePathTransformation such as ShellQuote against POSIX shells; validating and constraining remote paths so untrusted input cannot reach ScpClient; restricting SSH accounts to least privilege; using non-shell-based SSH servers; and monitoring for anomalous commands from affected accounts.

Threat Intelligence Overview

EPSS Score
0.6%
Top 54% exploitable
Prevalence
High
most widely-used .NET SSH library, very large NuGet footprint
Threat Intel
1
1 sources
Data Quality
6 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment GHSA GitHub

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.6%
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
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
No
Human Impact
High
Technical Impact
Total

Priority Score

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

Attack Technique

OS command injection occurs when an application passes unsanitized user input directly into system shell commands.

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