Skip to content
OpenAdvisories
Unscored CVE-2021-3634 EUVD-2021-26935GHSA-4wwm-f449-qwpq

A flaw has been found in libssh in versions prior to 0.9.6. The SSH protocol keeps track of two shared secrets during the lifetime of the s…

Published Aug 31, 2021 · Updated Aug 3, 2024 · Assigned by redhat

Description

A flaw has been found in libssh in versions prior to 0.9.6. The SSH protocol keeps track of two shared secrets during the lifetime of the session. One of them is called secret_hash and the other session_id. Initially, both of them are the same, but after key re-exchange, previous session_id is kept and used as an input to new secret_hash. Historically, both of these buffers had shared length variable, which worked as long as these buffers were same. But the key re-exchange operation can also change the key exchange method, which can be based on hash of different size, eventually creating "secret_hash" of different size than the session_id has. This becomes an issue when the session_id memory is zeroed or when it is used again during second key re-exchange.

Affected products

VendorProductAffectedFixed
— libssh libssh 0.9.6 —

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
Debian 14 libssh 0.9.6-1 —
Debian 13 libssh 0.9.6-1 —
Debian 12 libssh 0.9.6-1 —
Debian 11 libssh 0.9.5-1+deb11u1 DSA-4965-1
ReleasePackageFixed inAdvisory
Ubuntu 22.04 LTS libssh 0.9.6-1 —
Ubuntu 20.04 LTS libssh 0.9.3-2ubuntu2.2 USN-5053-1
ReleasePackageFixed inAdvisory
RHEL 8 libssh +2 0.9.6-3.el8 RHSA-2022:2031

AlmaLinux

Errata ↗
ReleasePackageFixed inAdvisory
AlmaLinux 8 libssh +2 0.9.6-3.el8 ALSA-2022:2031

Rocky Linux

Errata ↗
ReleasePackageFixed inAdvisory
Rocky Linux 8 libssh 0.9.6-3.el8 RLSA-2022:2031
ReleasePackageFixed inAdvisory
SLES 15 SP3 libssh 0.9.8-150200.13.3.1 SUSE-SU-2024:0525-1
SLES 15 SP2 libssh 0.9.8-150200.13.3.1 SUSE-SU-2024:0525-1
SLES 12 SP5 libssh 0.9.8-3.12.2 SUSE-SU-2024:0539-1
Show 8 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
SLES for SAP 15 SP3 libssh 0.9.8-150200.13.3.1 SUSE-SU-2024:0525-1
SLES for SAP 15 SP2 libssh 0.9.8-150200.13.3.1 SUSE-SU-2024:0525-1
SLES for SAP 12 SP5 libssh 0.9.8-3.12.2 SUSE-SU-2024:0539-1
SLE Micro 5.2 libssh 0.9.8-150200.13.3.1 SUSE-SU-2024:0525-1
SLE Micro 5.1 libssh 0.9.8-150200.13.3.1 SUSE-SU-2024:0525-1
SLE HPC 15 SP3 libssh 0.9.8-150200.13.3.1 SUSE-SU-2024:0525-1
SLE HPC 15 SP2 libssh 0.9.8-150200.13.3.1 SUSE-SU-2024:0525-1
SUSE Enterprise Storage 7.1 libssh 0.9.8-150200.13.3.1 SUSE-SU-2024:0525-1
ReleasePackageFixed inAdvisory
openSUSE Tumbleweed libssh 0.9.6-1.2 openSUSE-SU-2024:10998-1
ReleasePackageFixed inAdvisory
Alpine v3.24 libssh 0.9.6-r0 —
Alpine v3.23 libssh 0.9.6-r0 —
Alpine v3.22 libssh 0.9.6-r0 —
Alpine v3.21 libssh 0.9.6-r0 —
Alpine v3.20 libssh 0.9.6-r0 —
Show 6 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
Alpine v3.19 libssh 0.9.6-r0 —
Alpine v3.18 libssh 0.9.6-r0 —
Alpine v3.17 libssh 0.9.6-r0 —
Alpine v3.16 libssh 0.9.6-r0 —
Alpine v3.15 libssh 0.9.6-r0 —
Alpine v3.14 libssh 0.9.6-r0 —

Oracle Linux

ReleasePackageFixed inAdvisory
Oracle Linux 8 libssh +2 0.9.6-3.el8 ELSA-2022-2031

Advisories 11

References