CVE-2016-0787
The diffie_hellman_sha256 function in kex.c in libssh2 before 1.7.0 improperly truncates secrets to 128 or 256 bits, which makes it easier for man-in-the-middle attackers to decrypt or intercept SSH sessions via unspecified vectors, aka a "bits/bytes confusion bug."
What to do
Fixed builds are available from Alpine, Debian, Red Hat, Ubuntu: see the table below for the fixed version per release.
Is your server affected? One read-only command checks every installed package against this CVE and all others, using each vendor's fixed versions. Get started or get a free API key.
curl -sS "https://api.cvefocus.com/v1/check?format=text" -H "Authorization: Bearer $CVEFOCUS_KEY" \ -H "Content-Type: text/plain" --data-binary @inventory.txt
Vendor status at a glance
Status by vendor and release
From each vendor's own security data and VEX statements. "Fixed" means a fixed build is published for that release.
| Release | Package | Status | Fixed version | Advisory |
|---|---|---|---|---|
| Ubuntu 16.04 | libssh2 | Fixed | 1.5.0-2ubuntu0.1 | UBUNTU-CVE-2016-0787 |
| Ubuntu 14.04 | libssh2 | Fixed | 1.4.3-2ubuntu0.1 | UBUNTU-CVE-2016-0787 |
| Debian 14 | libssh2 | Fixed | 1.5.0-2.1 | DEBIAN-CVE-2016-0787 |
| Debian 13 | libssh2 | Fixed | 1.5.0-2.1 | DEBIAN-CVE-2016-0787 |
| Debian 12 | libssh2 | Fixed | 1.5.0-2.1 | DEBIAN-CVE-2016-0787 |
| Red Hat Enterprise Linux 7 | libssh2 | Fixed | 0:1.4.3-10.el7_2.1 | RHSA-2016:0428 |
| Red Hat Enterprise Linux 7 | libssh2-devel | Fixed | 0:1.4.3-10.el7_2.1 | RHSA-2016:0428 |
| Red Hat Enterprise Linux 7 | libssh2-docs | Fixed | 0:1.4.3-10.el7_2.1 | RHSA-2016:0428 |
| Red Hat Enterprise Linux 6 | libssh2 | Fixed | 0:1.4.2-2.el6_7.1 | RHSA-2016:0428 |
| Red Hat Enterprise Linux 6 | libssh2-devel | Fixed | 0:1.4.2-2.el6_7.1 | RHSA-2016:0428 |
| Red Hat Enterprise Linux 6 | libssh2-docs | Fixed | 0:1.4.2-2.el6_7.1 | RHSA-2016:0428 |
| Alpine Linux 3.4 | libssh2 | Fixed | 1.7.0-r0 | ALPINE-CVE-2016-0787 |
What the vendor says
As published in the CVE record by redhat, the CVE's assigner (usually the vendor). Check the vendor's advisory before acting.
Vendor advisories:
- http://lists.fedoraproject.org/pipermail/package-announce/2016-February/177980.html (vendor-advisory)
- http://lists.fedoraproject.org/pipermail/package-announce/2016-March/178573.html (vendor-advisory)
- https://security.gentoo.org/glsa/201606-12 (vendor-advisory)
- http://lists.opensuse.org/opensuse-updates/2016-03/msg00008.html (vendor-advisory)
- http://www.debian.org/security/2016/dsa-3487 (vendor-advisory)
References
- http://lists.fedoraproject.org/pipermail/package-announce/2016-February/177980.html
- https://kc.mcafee.com/corporate/index?page=content&id=SB10156
- http://www.oracle.com/technetwork/topics/security/linuxbulletinjan2016-2867209.html
- https://www.libssh2.org/CVE-2016-0787.patch
- https://www.libssh2.org/adv_20160223.html
- https://puppet.com/security/cve/CVE-2016-0787
- http://lists.fedoraproject.org/pipermail/package-announce/2016-March/178573.html
- https://security.gentoo.org/glsa/201606-12
- http://lists.opensuse.org/opensuse-updates/2016-03/msg00008.html
- https://bto.bluecoat.com/security-advisory/sa120
- http://www.debian.org/security/2016/dsa-3487
- http://www.securityfocus.com/bid/82514
About this page
Compiled by CVEfocus from the CVE List, the security data and VEX statements of Ubuntu, Debian, Red Hat, AlmaLinux, Rocky Linux and Microsoft, CISA's Known Exploited Vulnerabilities catalog and FIRST EPSS, refreshed several times a day (data status). Information only; see the disclaimer. Official record: cve.org · NVD.