critical CVSS 9.5 EPSS 0.36%

CVE-2026-35386·OpenSSH vulnerability

In OpenSSH before 10.3, command execution can occur via shell metacharacters in a username within a command line. This requires a scenario where the username on the command line is untrusted, and also requires a non-default configurations of % in ssh_config.

Severity
critical
Software
OpenSSH
Fixed in
1:9.2p1-2+deb12u10
Published

How likely is exploitation

FIRST's Exploit Prediction Scoring System puts the probability of this CVE being exploited in the next 30 days at 0.36% — higher than 27% of all published CVEs. EPSS is an independent forecast of exploitation, not a severity rating: it says nothing about how much damage a successful attack does, which is what a CVSS score measures.

Read the two together. CVE-2026-35386 scores 9.5 on CVSS, so a successful attack would be serious — but at 0.36%, almost nobody is currently attempting it. That is a different situation from a flaw under mass exploitation, and it is usually the difference between patching on your next maintenance window and patching tonight.

Affected versions

Until: 1:9.2p1-2+deb12u10

Fixed in: 1:9.2p1-2+deb12u10

How to fix this CVE

Update OpenSSH to version 1:9.2p1-2+deb12u10 or later to eliminate the risk of command injection through maliciously crafted usernames. This vulnerability requires non-standard ssh_config settings that include the % character in hostname templates, making it exploitable primarily in environments with dynamic or user-supplied SSH connection strings. Audit your ssh_config files for any % substitutions and restrict SSH command execution to trusted sources immediately.

sudo dnf update openssh-server openssh-clients

Defensia detects this vulnerability

What an exploitation attempt looks like

Sample log line indicative of exploitation attempts:

sshd log entries showing rejected authentication attempts with usernames containing shell metacharacters (e.g., $(command), `command`, |, &, ;, <, >) or unusual % patterns followed by connection drops or command execution attempts.

How to check if you are affected

  1. Check your installed OpenSSH version: ssh -V or sshd -v
  2. Review your /etc/ssh/ssh_config and /etc/ssh/sshd_config for any % character usage in hostname or user directives with grep '%' /etc/ssh/ssh_config
  3. Search authentication logs for unusual username patterns: grep -i 'invalid user.*[$(`;|&<>]' /var/log/auth.log or /var/log/secure
  4. Verify the patch is applied by running ssh -V again and confirming the version is 1:9.2p1-2+deb12u10 or newer

FAQ

What is CVE-2026-35386?

CVE-2026-35386 is a command injection vulnerability in OpenSSH that arises when shell metacharacters in a username are not properly sanitized, particularly when non-standard ssh_config templates containing % substitution tokens are used. An attacker can inject shell commands through a crafted username argument to execute arbitrary code with the privileges of the SSH process.

Is CVE-2026-35386 being actively exploited?

No, CVE-2026-35386 is not currently listed on the CISA KEV catalog and no public exploits are available. However, the critical CVSS score of 9.5 indicates organizations should prioritize patching regardless of current exploitation status.

What versions of OpenSSH are affected by CVE-2026-35386?

All versions prior to OpenSSH 10.3 are potentially affected, with confirmed vulnerable packages up to Debian's 1:9.2p1-2+deb12u10. Systems running OpenSSH 9.2p1 and earlier on Debian-based distributions are vulnerable if % substitution is configured in ssh_config.

How do I check if my server is vulnerable to CVE-2026-35386?

Run ssh -V to check your version (should be before 10.3). Then grep for '%' in /etc/ssh/ssh_config and /etc/ssh/sshd_config—if found and untrusted users can control SSH usernames, your configuration is at risk.

Does Defensia detect CVE-2026-35386?

Yes — Defensia's CVE advisory scanner compares installed package versions against the NVD database. If OpenSSH is installed on a monitored server, CVE-2026-35386 will appear in your dashboard with remediation steps.

Related OpenSSH CVEs

References

Track CVEs across your fleet automatically

Defensia scans your Linux servers and tells you exactly which ones are running vulnerable versions — including CVE-2026-35386. Free for 1 server.

Get started free