CVE-2026-4631

NameCVE-2026-4631
DescriptionCockpit's remote login feature passes user-supplied hostnames and usernames from the web interface to the SSH client without validation or sanitization. An attacker with network access to the Cockpit web service can craft a single HTTP request to the login endpoint that injects malicious SSH options or shell commands, achieving code execution on the Cockpit host without valid credentials. The injection occurs during the authentication flow before any credential verification takes place, meaning no login is required to exploit the vulnerability.
SourceCVE (at NVD; CERT, ENISA, LWN, oss-sec, fulldisc, Debian ELTS, Red Hat, Ubuntu, Gentoo, SUSE bugzilla/CVE, GitHub advisories/code/issues, web search, more)
Debian Bugs1133022

Vulnerable and fixed packages

The table below lists information on source packages.

Source PackageReleaseVersionStatus
cockpit (PTS)bullseye239-1fixed
bookworm287.1-0+deb12u3fixed
bookworm (security)287.1-0+deb12u2fixed
trixie337-1vulnerable
forky, sid360-1fixed

The information below is based on the following data on fixed versions.

PackageTypeReleaseFixed VersionUrgencyOriginDebian Bugs
cockpitsourcebullseye(not affected)
cockpitsourcebookworm(not affected)
cockpitsource(unstable)360-11133022

Notes

[trixie] - cockpit <no-dsa> (Minor issue)
[bookworm] - cockpit <not-affected> (beiboot helper only used since 326)
[bullseye] - cockpit <not-affected> (beiboot helper only used since 326)
https://bugzilla.redhat.com/show_bug.cgi?id=2450246
https://github.com/cockpit-project/cockpit/pull/23105
Fixed by: https://github.com/cockpit-project/cockpit/commit/9d0695647cb6f6209e68231fd165917123aa502d (360)
OpenSSH versions which contain the fix for CVE-2023-51385 introduced early
hostname validation that band shell hell metacharacters in command-line hostnames
and usernames before establishing the SSH connection. With such OpenSSH versions
the command injection via "-oProxyCommand=<malicious_command>" fails.

Search for package or bug name: Reporting problems