CVE-2021-3634: Medium severity libssh libssh vulnerability

Published Jul 2, 2021
·
Updated

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 secrethash and the other sessionid. Initially, both of them are the same, but after key re-exchange, previous sessionid is kept and used as an input to new secrethash. 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 "secrethash" of different size than the sessionid has. This becomes an issue when the sessionid memory is zeroed or when it is used again during second key re-exchange.

Other sources

The SSH protocol keeps track of two shared secrets during the lifetime of the session. One of them is called secrethash and the other sessionid. Initially, both of them are the same, but after key re-exchange, previous sessionid is kept and used as an input to new secrethash. 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 secrethash of different size than the sessionid has. This becomes an issue when the sessionid memory is zeroized or when it is used again during second key re-exchange.

Red Hat

Affected Software

13 affected componentsFixes available
debian/libssh
0.8.7-1+deb10u10.8.7-1+deb10u20.9.7-0+deb11u10.9.8-0+deb11u10.10.5-20.10.6-0+deb12u10.10.6-2
libssh libssh>=0.9.1<0.9.6
redhat Virtualization=4.0
redhat Enterprise Linux=8.0
Debian Debian Linux=10.0
Debian Debian Linux=11.0
Fedoraproject Fedora=33
Fedoraproject Fedora=34
Fedoraproject Fedora=35
Oracle MySQL Workbench<=8.0.27
NetApp Cloud Backup
redhat/libssh<0.9.6
0.9.6
Microsoft cbl2 libssh

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade debian/libssh to a version that resolves this vulnerability.

    Fixed in 0.8.7-1+deb10u1Fixed in 0.8.7-1+deb10u2Fixed in 0.9.7-0+deb11u1Fixed in 0.9.8-0+deb11u1Fixed in 0.10.5-2Fixed in 0.10.6-0+deb12u1Fixed in 0.10.6-2
  2. Upgrade

    Upgrade redhat/libssh to a version that resolves this vulnerability.

    Fixed in 0.9.6

Event History

Jul 2, 2021
Data Sourced
via Red Hat·07:54 PM
DescriptionSeverityAffected Software
Aug 26, 2021
Data Sourced
08:24 PM
SeverityAffected Software
Aug 31, 2021
CVE Published
via MITRE·12:00 AM
Data Sourced
via MITRE·12:00 AM
DescriptionWeakness
Data Sourced
via NVD·05:15 PM
RemedyDescriptionSeverityWeaknessAffected Software
Oct 1, 2025
Data Sourced
via Microsoft·11:11 PM
DescriptionSeverityWeakness
Data Sourced
via Microsoft·11:11 PM
Affected Software
Updated
via Microsoft·11:11 PM
DescriptionSeverity
Free Weekly Intel

Don't miss critical vulnerabilities

Join thousands of security professionals who receive our weekly digest of trending CVEs, zero-days, and exploited vulnerabilities.

No spam. Unsubscribe anytime.

Frequently Asked Questions

1

What is CVE-2021-3634?

CVE-2021-3634 is a vulnerability found in libssh in versions prior to 0.9.6.

2

What is the severity of CVE-2021-3634?

CVE-2021-3634 has a severity level of 6.5 (high).

3

Is libssh version 0.9.6 affected by CVE-2021-3634?

No, libssh version 0.9.6 is not affected by CVE-2021-3634.

4

How can I fix CVE-2021-3634 in libssh?

To fix CVE-2021-3634 in libssh, you should upgrade to version 0.9.6 or later.

5

Where can I find more information about CVE-2021-3634?

You can find more information about CVE-2021-3634 in the following references: [Link 1](https://bugzilla.redhat.com/show_bug.cgi?id=1978810), [Link 2](https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/DRK67AJCWYYVAGF5SGAHNZXCX3PN3ZFP/), [Link 3](https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/JKYD3ZRAMDAQX3ZW6THHUF3GXN7FF6B4/)

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203