cve.bz

CVE-2023-38408 Unquoted Search Path or Element

9.8 criticalExploit referenceEPSS 80%Fix available

Critical (9.8). EPSS 80% estimated probability of exploitation activity in the next 30 days.

On this page
The PKCS#11 feature in ssh-agent in OpenSSH before 9.3p2 has an insufficiently trustworthy search path, leading to remote code execution if an agent is forwarded to an attacker-controlled system. (Code in /usr/lib is not necessarily safe for loading into ssh-agent.) NOTE: this issue exists because of an incomplete fix for CVE-2016-10009.

Severity

CVSS 3.1

9.8 critical
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
EPSS
80% (unchanged from 80% a week ago; 80% 30 days ago) estimated probability of exploitation activity in the next 30 days; 100th percentile. Scored 2026-11-22. A forecast for this CVE across the internet, not for your own systems.
CISA's assessment (SSVC)
Exploitation: none · Automatable: yes · Technical impact: total, assessed 2024-10-15. From CISA's Vulnrichment in the CVE List: whether it is exploited, whether exploiting it can be automated, and how much control it gives.
CWE
CWE-428 Unquoted Search Path or Element
Published
Modified
NVD analysis
Analyzed, since modified
Record from
the NVD, synced

Fix and patched versions

Ask an AI about this CVE

Show the promptExplain CVE-2023-38408 for an engineer deciding whether to act. Use https://cve.bz/api/public/cves/CVE-2023-38408?via=ask-ai-copy and https://cve.bz/cve/CVE-2023-38408?via=ask-ai-copy as the source of truth: what is affected and which versions fix it, whether it is in CISA KEV, public exploits, and its EPSS (an internet-wide 30-day estimate of exploitation activity, not a forecast for my systems). If they give no fixed versions, use the CVE record https://cveawg.mitre.org/api/cve/CVE-2023-38408 or the vendor advisory, not third-party mirrors. Tell me how to check whether I am affected and how to verify a fix. Cite the sources and say where they are uncertain.

Opens a third-party assistant; its answer is its own, not cve.bz's. The prompt holds only this CVE's id and public links.

Affected

Versions

From the NVD's CPE matches.

ProductAffected
openbsd:opensshbefore 9.3
openbsd:openssh9.3
openbsd:openssh9.3:p1
fedoraproject:fedora37
fedoraproject:fedora38

Linux distributions

DistributionReleasePackageFixed inAdvisory
Debian10openssh1:7.9p1-10+deb10u3DLA-3532-1
Debian12openssh1:9.2p1-2+deb12u1DEBIAN-CVE-2023-38408
Debian13, 14openssh1:9.3p2-1DEBIAN-CVE-2023-38408
Ubuntu18.04:LTS, 20.04:LTS, 22.04:LTS and 4 moreopenssh-ssh1no fix listedUBUNTU-CVE-2023-38408
Ubuntu20.04:LTSopenssh1:8.2p1-4ubuntu0.8UBUNTU-CVE-2023-38408 USN-6242-1
Ubuntu22.04:LTSopenssh1:8.9p1-3ubuntu0.3UBUNTU-CVE-2023-38408 USN-6242-1
UbuntuPro:14.04:LTSopenssh1:6.6p1-2ubuntu2.13+esm1UBUNTU-CVE-2023-38408 USN-6242-2
UbuntuPro:16.04:LTSopenssh1:7.2p2-4ubuntu2.10+esm3UBUNTU-CVE-2023-38408 USN-6242-2
UbuntuPro:18.04:LTSopenssh1:7.6p1-4ubuntu0.7+esm1UBUNTU-CVE-2023-38408 USN-6242-2
UbuntuPro:FIPS-updates:16.04:LTSopenssh1:7.2p2-4ubuntu2.fips.2.10.4UBUNTU-CVE-2023-38408
UbuntuPro:FIPS-updates:18.04:LTSopenssh1:7.9p1-10~ubuntu18.04.fips.0.8UBUNTU-CVE-2023-38408
UbuntuPro:FIPS-updates:20.04:LTSopenssh1:8.2p1-4ubuntu0.fips.0.8UBUNTU-CVE-2023-38408
UbuntuPro:FIPS:16.04:LTS, Pro:FIPS:18.04:LTS, Pro:FIPS:20.04:LTSopensshno fix listedUBUNTU-CVE-2023-38408
Red Hatenterprise_linux:7::client, enterprise_linux:7::computenode, enterprise_linux:7::server and 1 morepam_ssh_agent_auth0:0.10.3-2.23.el7_9RHSA-2023:4382
Red Hatenterprise_linux:7::client, enterprise_linux:7::server, enterprise_linux:7::workstationopenssh, openssh-cavs, openssh-ldap and 6 more0:7.4p1-23.el7_9RHSA-2023:4382
Red Hatenterprise_linux:7::computenodeopenssh-cavs, openssh-ldap, openssh-askpass and 2 more0:7.4p1-23.el7_9RHSA-2023:4382
Red Hatenterprise_linux:8::appstreamopenssh-askpass, openssh-debuginfo, openssh-debugsource and 6 more0:8.0p1-19.el8_8RHSA-2023:4419
Red Hatenterprise_linux:8::appstreampam_ssh_agent_auth-debuginfo0:0.10.3-7.19.el8_8RHSA-2023:4419
Red Hatenterprise_linux:8::baseosopenssh, openssh-cavs, openssh-ldap and 11 more0:8.0p1-19.el8_8RHSA-2023:4419
Red Hatenterprise_linux:8::baseospam_ssh_agent_auth, pam_ssh_agent_auth-debuginfo0:0.10.3-7.19.el8_8RHSA-2023:4419
Red Hatenterprise_linux:9::appstreamopenssh-askpass, openssh-debuginfo, openssh-debugsource and 5 more0:8.7p1-30.el9_2RHSA-2023:4412
Red Hatenterprise_linux:9::appstreampam_ssh_agent_auth, pam_ssh_agent_auth-debuginfo0:0.10.4-5.30.el9_2RHSA-2023:4412
Red Hatenterprise_linux:9::baseosopenssh, openssh-keycat, openssh-server and 8 more0:8.7p1-30.el9_2RHSA-2023:4412
Red Hatenterprise_linux:9::baseospam_ssh_agent_auth-debuginfo0:0.10.4-5.30.el9_2RHSA-2023:4412
Red Hatrhel_aus:8.2::appstream, rhel_e4s:8.2::appstream, rhel_tus:8.2::appstreamopenssh-askpass, openssh-debuginfo, openssh-debugsource and 6 more0:8.0p1-5.el8_2RHSA-2023:4384
21 more for Red Hat in the JSON and on Red Hat's page.
SUSEEnterprise Storage 7, Linux Enterprise High Performance Computing 15 SP2-LTSS, Linux Enterprise Server 15 SP2-LTSS and 1 moreopenssh, openssh-askpass-gnome8.1p1-150200.5.37.1SUSE-SU-2023:2946-1
SUSEEnterprise Storage 7.1, Linux Enterprise High Performance Computing 15 SP3-ESPOS, Linux Enterprise High Performance Computing 15 SP3-LTSS and 3 moreopenssh, openssh-askpass-gnome8.4p1-150300.3.22.1SUSE-SU-2023:2945-1
SUSELinux Enterprise High Performance Computing 15 SP1-LTSS, Linux Enterprise Server 15 SP1-LTSS, Linux Enterprise Server for SAP Applications 15 SP1openssh, openssh-askpass-gnome7.9p1-150100.6.31.1SUSE-SU-2023:2947-1
SUSELinux Enterprise Micro 5.1, Linux Enterprise Micro 5.2, Linux Enterprise Micro 5.3 and 5 moreopenssh8.4p1-150300.3.22.1SUSE-SU-2023:2945-1
SUSELinux Enterprise Module for Desktop Applications 15 SP4, Linux Enterprise Module for Desktop Applications 15 SP5openssh-askpass-gnome8.4p1-150300.3.22.1SUSE-SU-2023:2945-1
SUSELinux Enterprise Server 12 SP2-BCLopenssh, openssh-askpass-gnome7.2p2-74.63.1SUSE-SU-2023:2940-1
SUSELinux Enterprise Server 12 SP5, Linux Enterprise Server for SAP Applications 12 SP5openssh, openssh-askpass-gnome7.2p2-81.4.2SUSE-SU-2023:2950-1
openSUSELeap 15.4, Leap 15.5openssh, openssh-askpass-gnome8.4p1-150300.3.22.1SUSE-SU-2023:2945-1
openSUSELeap Micro 5.3openssh8.4p1-150300.3.22.1SUSE-SU-2023:2945-1
openSUSETumbleweedopenssh9.3p2-1.1openSUSE-SU-2024:13063-1
AlmaLinux8openssh, openssh-cavs, openssh-ldap and 4 more8.0p1-19.el8_8ALSA-2023:4419
AlmaLinux8openssh, openssh-cavs, openssh-ldap and 4 more8.0p1-33.el8_10ALSA-2026:69266
AlmaLinux8pam_ssh_agent_auth0.10.3-7.19.el8_8ALSA-2023:4419
AlmaLinux8pam_ssh_agent_auth0.10.3-8.33.el8_10ALSA-2026:69266
AlmaLinux9openssh, openssh-keycat, openssh-server and 2 more8.7p1-30.el9_2ALSA-2023:4412
AlmaLinux9pam_ssh_agent_auth0.10.4-5.30.el9_2ALSA-2023:4412
Rocky Linux8openssh0:8.0p1-19.el8_8RLSA-2023:4419
Alpinev3.16openssh9.0_p1-r4ALPINE-CVE-2023-38408
Alpinev3.17openssh9.1_p1-r4ALPINE-CVE-2023-38408
Azure Linux2openssh8.9p1-1AZL-27651

From the distributions' data via OSV.dev: the Debian Security Tracker; Ubuntu Security Notices © Canonical Ltd., CC BY-SA 4.0; Red Hat Security Data © Red Hat, Inc., CC BY 4.0; SUSE security data, CC BY 4.0; AlmaLinux's OSV database, MIT; Rocky Linux's errata, BSD-3-Clause; the Alpine secdb, CC BY-SA 4.0; Microsoft's Azure Linux vulnerability data, MIT. Modified: reformatted and linked to CVE records. Credits. On the distributions' own pages: Debian · Ubuntu · Red Hat · SUSE · openSUSE · Alpine.

Red Hat

Red Hat rates this Important.

Red Hat's statement

This issue is marked as Important as we successfully identified that it can do a Remote Code Execution atleast at some circumstances in Red Hat Enterprise Linux 6, 7, 8 and 9 and It can easily compromise the confidentiality, integrity or availability of resources.

Red Hat's mitigation

Remote exploitation required that a user establishes an SSH connection to a compromised or malicious SSH server with agent forwarding enabled. The agent forwarding is disabled by default. Review your ssh client configuration files for the use of ForwardAgent configuration directive and invocations of ssh client for the use of -A command line argument to see if agent forwarding is enabled for specific connections.

Exploitation can also be prevented by starting ssh-agent(1) with an empty PKCS#11/FIDO allowlist (ssh-agent -P '') or by configuring an allowlist that contains only specific provider libraries.

ProductPackageStateAdvisory
DEVWORKSPACE-1.0-RHEL-8devworkspace/devworkspace-operator-bundle:0.22-2Fixed 2023-08-30RHSA-2023:4889
DEVWORKSPACE-1.0-RHEL-8devworkspace/devworkspace-project-clone-rhel8:0.22-2Fixed 2023-08-30RHSA-2023:4889
DEVWORKSPACE-1.0-RHEL-8devworkspace/devworkspace-rhel8-operator:0.22-2Fixed 2023-08-30RHSA-2023:4889
Red Hat Enterprise Linux 6 Extended Lifecycle Supportopenssh-0:5.3p1-125.el6_10Fixed 2023-08-02RHSA-2023:4428
Red Hat Enterprise Linux 7openssh-0:7.4p1-23.el7_9Fixed 2023-08-01RHSA-2023:4382
Red Hat Enterprise Linux 8openssh-0:8.0p1-19.el8_8Fixed 2023-08-01RHSA-2023:4419
Red Hat Enterprise Linux 8.1 Update Services for SAP Solutionsopenssh-0:8.0p1-5.el8_1.1Fixed 2023-08-01RHSA-2023:4383
Red Hat Enterprise Linux 8.2 Advanced Update Supportopenssh-0:8.0p1-5.el8_2Fixed 2023-08-01RHSA-2023:4384
Red Hat Enterprise Linux 8.2 Telecommunications Update Serviceopenssh-0:8.0p1-5.el8_2Fixed 2023-08-01RHSA-2023:4384
Red Hat Enterprise Linux 8.2 Update Services for SAP Solutionsopenssh-0:8.0p1-5.el8_2Fixed 2023-08-01RHSA-2023:4384
Red Hat Enterprise Linux 8.4 Advanced Mission Critical Update Supportopenssh-0:8.0p1-7.el8_4Fixed 2023-08-01RHSA-2023:4381
Red Hat Enterprise Linux 8.4 Telecommunications Update Serviceopenssh-0:8.0p1-7.el8_4Fixed 2023-08-01RHSA-2023:4381
Red Hat Enterprise Linux 8.4 Update Services for SAP Solutionsopenssh-0:8.0p1-7.el8_4Fixed 2023-08-01RHSA-2023:4381
Red Hat Enterprise Linux 8.6 Extended Update Supportopenssh-0:8.0p1-15.el8_6Fixed 2023-08-01RHSA-2023:4413
Red Hat Enterprise Linux 9openssh-0:8.7p1-30.el9_2Fixed 2023-08-01RHSA-2023:4412
Red Hat Enterprise Linux 9.0 Extended Update Supportopenssh-0:8.7p1-11.el9_0Fixed 2023-07-31RHSA-2023:4329

Contains Red Hat Security Data © Red Hat, Inc., licensed under CC BY 4.0. Source: https://access.redhat.com/security/data. Modified: reformatted. Red Hat's page for CVE-2023-38408.

ICS advisories (CISA)

AdvisoryTitlePublishedSectorsAffectedFixed
ICSA-25-105-08ABB M2M Gateway2025-04-07EnergyABB M2M Gateway ARM600, firmware versions = 4.1.2 <= 5.0.3, ABB M2M Gateway SW, software versions = 5.0.1 <= 5.0.3none listed
ICSA-23-348-10Siemens SIMATIC S7-15002023-12-12Critical Manufacturing, Transportation Systems, Energy, Healthcare and Public Health, Financial Services, Government Services and FacilitiesSIMATIC S7-1500 CPU 1518-4 PN/DP MFP (6ES7518-4AX00-1AB0), SIMATIC S7-1500 CPU 1518-4 PN/DP MFP (6ES7518-4AX00-1AC0), SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP (6ES7518-4FX00-1AB0) and 2 morenone listed

From CISA's ICS advisories (CSAF), provided under CISA's notification. Only the facts are shown; each advisory is on CISA's page. Credits.

GitHub PoC (unverified)

Repositories on GitHub named after this CVE. Nobody has checked them and they are not scanned: some hold a working proof of concept, some nothing useful, and some malware made to look like one. Read the code before you run any of it.

References

Check your stackJSON